# \#rules

**URL:** https://community.auth0.com/tag/rules/107.md

[Latest](https://community.auth0.com/latest.md) · [Categories](https://community.auth0.com/categories.md) · [Tags](https://community.auth0.com/tags.md)

---

## [Best Practice Question: Managing system bloat due to “Private by Default” approach on asset uploads](https://community.auth0.com/t/best-practice-question-managing-system-bloat-due-to-private-by-default-approach-on-asset-uploads/188906)

<div class="topic-metadata">

**Author:** [@projectaddons.com](https://community.auth0.com/u/projectaddons.com)\
**Replies:** 1\
**Last updated:** [July 8, 2025, 3:56pm UTC](https://community.auth0.com/t/best-practice-question-managing-system-bloat-due-to-private-by-default-approach-on-asset-uploads/188906 "2025-07-08T15:56:30Z")

</div>

Hello FGA Support Team, We are implementing Fine-Grained Authorization (FGA) on our Digital Asset Management (DAM) platform. Our model includes roles, permissions, users, and teams to control access to assets, folders,…

---

## [Feature parity between Rules and Actions - Ability to switch to another user in an Action](https://community.auth0.com/t/feature-parity-between-rules-and-actions-ability-to-switch-to-another-user-in-an-action/182158)

<div class="topic-metadata">

**Author:** [@kurtfi](https://community.auth0.com/u/kurtfi)\
**Replies:** 1\
**Last updated:** [February 28, 2025, 12:19am UTC](https://community.auth0.com/t/feature-parity-between-rules-and-actions-ability-to-switch-to-another-user-in-an-action/182158 "2025-02-28T00:19:48Z")

</div>

Feature: Feature parity between Rules and Actions - Ability to switch to another user in an Action Description: With a connection to an IdP that supports only transient user ids, in Rules we could just use custom logic …

---

## [Send user invitation email on signup without changing default email template/functionality in auth0](https://community.auth0.com/t/send-user-invitation-email-on-signup-without-changing-default-email-template-functionality-in-auth0/93298)

<div class="topic-metadata">

**Author:** [@attrirahul968](https://community.auth0.com/u/attrirahul968)\
**Replies:** 2\
**Last updated:** [February 27, 2025, 5:45pm UTC](https://community.auth0.com/t/send-user-invitation-email-on-signup-without-changing-default-email-template-functionality-in-auth0/93298 "2025-02-27T17:45:02Z")

</div>

Hi Guys, currently implemented: I have implemented signUp/login functionality with Auth0, workflow as: when user signup directly or by admin/SA then send welcome email template provided by Auth0 to user. What I need…

---

## [Do not send email verification in select cases](https://community.auth0.com/t/do-not-send-email-verification-in-select-cases/92189)

<div class="topic-metadata">

**Author:** [@lee.omara](https://community.auth0.com/u/lee.omara)\
**Replies:** 6\
**Last updated:** [February 18, 2025, 5:14pm UTC](https://community.auth0.com/t/do-not-send-email-verification-in-select-cases/92189 "2025-02-18T17:14:28Z")

</div>

I see that the API for creating and updating users has a verify\_email option to omit sending the verification message on a case-by-case basis. I’d like to do something similar, but for select applications. Can I do this…

---

## [Scope not available in access token](https://community.auth0.com/t/scope-not-available-in-access-token/93460)

<div class="topic-metadata">

**Author:** [@ketanLmq](https://community.auth0.com/u/ketanLmq)\
**Replies:** 1\
**Last updated:** [December 12, 2024, 11:55pm UTC](https://community.auth0.com/t/scope-not-available-in-access-token/93460 "2024-12-12T23:55:25Z")

</div>

When fetching the access\_token using oauth/token API, the decoded access\_token doesn’t contain the scope key-value pair.

---

## [Only sign up user if own backend allows it and send (sub, email, username)](https://community.auth0.com/t/only-sign-up-user-if-own-backend-allows-it-and-send-sub-email-username/85960)

<div class="topic-metadata">

**Author:** [@amg1](https://community.auth0.com/u/amg1)\
**Replies:** 1\
**Last updated:** [November 21, 2024, 10:52pm UTC](https://community.auth0.com/t/only-sign-up-user-if-own-backend-allows-it-and-send-sub-email-username/85960 "2024-11-21T22:52:53Z")

</div>

Hey I got some questions regarding my usecase: I want to gather data (auth0\_sub, email, username) and send it to my backend to create a user with said fields. I then send back the associated internalId from my backend a…

---

## [What is the context.multifactor object?](https://community.auth0.com/t/what-is-the-context-multifactor-object/66020)

<div class="topic-metadata">

**Author:** [@cwaugh](https://community.auth0.com/u/cwaugh)\
**Replies:** 2\
**Last updated:** [October 23, 2024, 12:41am UTC](https://community.auth0.com/t/what-is-the-context-multifactor-object/66020 "2024-10-23T00:41:42Z")

</div>

On this page, we can see the following rule. function guardianMultifactor(user, context, callback) { //const CLIENTS\_WITH\_MFA = \['REPLACE\_WITH\_YOUR\_CLIENT\_ID'\]; // run only for the specified clients //if (CLIENTS…

---

## [Excluding users from MFA with rules breaks consent pop up](https://community.auth0.com/t/excluding-users-from-mfa-with-rules-breaks-consent-pop-up/93959)

<div class="topic-metadata">

**Author:** [@nitzan](https://community.auth0.com/u/nitzan)\
**Replies:** 4\
**Last updated:** [July 21, 2023, 4:45am UTC](https://community.auth0.com/t/excluding-users-from-mfa-with-rules-breaks-consent-pop-up/93959 "2023-07-21T04:45:39Z")

</div>

We added a rule that overwrites the context.multifactor field for users with specific user names. The exclusion itself worked as expected, but we saw an issue with the first log in of new users: after approving in the co…

---

## [Support jsonwebtoken@9.0.0 in Rules](https://community.auth0.com/t/support-jsonwebtoken-9-0-0-in-rules/97242)

<div class="topic-metadata">

**Author:** [@gabriel.hoff](https://community.auth0.com/u/gabriel.hoff)\
**Replies:** 2\
**Last updated:** [April 7, 2023, 10:41pm UTC](https://community.auth0.com/t/support-jsonwebtoken-9-0-0-in-rules/97242 "2023-04-07T22:41:13Z")

</div>

Feature: Support jsonwebtoken@9.0.0 in Rules Description: Looking at can-i-require, it seems version 9.0.0 of jsonwebtoken is not supported by Auth0 Rules (and possibly Actions?). When trying to use it in our Rules,…

---

## [Login Redirect /continue endpoint returns 401](https://community.auth0.com/t/login-redirect-continue-endpoint-returns-401/43308)

<div class="topic-metadata">

**Author:** [@aly.sabry](https://community.auth0.com/u/aly.sabry)\
**Replies:** 4\
**Last updated:** [March 31, 2023, 3:05pm UTC](https://community.auth0.com/t/login-redirect-continue-endpoint-returns-401/43308 "2023-03-31T15:05:58Z")

</div>

Hey, I am trying to call /continue endpoint to go back to the rule using POST because i need to pass data back to the rule. fetch(https://${auth0Domain}/continue?state=${state})\`\`. I get 401 Error. here is my

---

## [I am not getting email from my accessToken](https://community.auth0.com/t/i-am-not-getting-email-from-my-accesstoken/103322)

<div class="topic-metadata">

**Author:** [@olusanya](https://community.auth0.com/u/olusanya)\
**Replies:** 1\
**Last updated:** [March 29, 2023, 7:54pm UTC](https://community.auth0.com/t/i-am-not-getting-email-from-my-accesstoken/103322 "2023-03-29T19:54:33Z")

</div>

Hello, I am using NextJS for frontend and NestJS for backend. I created a custom claim to get email in my acessToken. exports.onExecutePostLogin = async (event, api) =\> { // This adds the authenticated user's email a…

---

## [Rule after successful MFA](https://community.auth0.com/t/rule-after-successful-mfa/67197)

<div class="topic-metadata">

**Author:** [@rodrigo.arias](https://community.auth0.com/u/rodrigo.arias)\
**Replies:** 2\
**Last updated:** [March 14, 2023, 11:14pm UTC](https://community.auth0.com/t/rule-after-successful-mfa/67197 "2023-03-14T23:14:49Z")

</div>

Hi, I’m using a custom MFA rule in which I return the context object with a multifactor challenge. I want to add a following rule, but I’m not sure if that rule would be executed after the user has succesfully acomplis…

---

## [Login Access Denied based on IP Address Redirect back to login Screen](https://community.auth0.com/t/login-access-denied-based-on-ip-address-redirect-back-to-login-screen/98443)

<div class="topic-metadata">

**Author:** [@nana.zimmer](https://community.auth0.com/u/nana.zimmer)\
**Replies:** 11\
**Last updated:** [January 20, 2023, 6:42pm UTC](https://community.auth0.com/t/login-access-denied-based-on-ip-address-redirect-back-to-login-screen/98443 "2023-01-20T18:42:24Z")

</div>

Trying to figure out how to prevent a redirect loop when the user’s login is successful but the IP address is not allowed access to the application. We have the IP address validation done in our flow but instead of movin…

---

## [Rule not used when creating a user via the Management API, is there an alternative approach?](https://community.auth0.com/t/rule-not-used-when-creating-a-user-via-the-management-api-is-there-an-alternative-approach/97829)

<div class="topic-metadata">

**Author:** [@evert](https://community.auth0.com/u/evert)\
**Replies:** 3\
**Last updated:** [January 17, 2023, 4:29pm UTC](https://community.auth0.com/t/rule-not-used-when-creating-a-user-via-the-management-api-is-there-an-alternative-approach/97829 "2023-01-17T16:29:21Z")

</div>

Given our following rule: function (user, context, callback) { var uuid = require("uuid"); user.app\_metadata = user.app\_metadata || {}; var promise = Promise.resolve(1); if (!user.app\_metadata.uuid) { use…

---

## [Know if a user is blocked by brute force protection](https://community.auth0.com/t/know-if-a-user-is-blocked-by-brute-force-protection/87164)

<div class="topic-metadata">

**Author:** [@lucas.gonzalez](https://community.auth0.com/u/lucas.gonzalez)\
**Replies:** 3\
**Last updated:** [January 11, 2023, 12:44am UTC](https://community.auth0.com/t/know-if-a-user-is-blocked-by-brute-force-protection/87164 "2023-01-11T00:44:44Z")

</div>

Hi, I want to know if there’s any way to catch if a user is or has been blocked after X number of failed attempts. I was thinking of a rule, action, or hook that could catch when the user gets blocked so we can use some…

---

## [Apple review requirement for firstName and lastName](https://community.auth0.com/t/apple-review-requirement-for-firstname-and-lastname/92661)

<div class="topic-metadata">

**Author:** [@mobileapps](https://community.auth0.com/u/mobileapps)\
**Replies:** 1\
**Last updated:** [December 26, 2022, 10:16pm UTC](https://community.auth0.com/t/apple-review-requirement-for-firstname-and-lastname/92661 "2022-12-26T22:16:55Z")

</div>

I had originally solved this problem with the information here LastName FirstName in token with apple-sign-in. The name is being returned as an email address, however the apple documentation states we should be able to …

---

## [Original granted scopes not not available in rules/action when refreshing token](https://community.auth0.com/t/original-granted-scopes-not-not-available-in-rules-action-when-refreshing-token/72419)

<div class="topic-metadata">

**Author:** [@christian.hunstad](https://community.auth0.com/u/christian.hunstad)\
**Replies:** 4\
**Last updated:** [December 24, 2022, 12:27am UTC](https://community.auth0.com/t/original-granted-scopes-not-not-available-in-rules-action-when-refreshing-token/72419 "2022-12-24T00:27:22Z")

</div>

Hello, I found this post that was closed in 2019 that describes my problem: How to get originally granted scopes when renewing token in Auth0 Rules? When refreshing an access token, the originally granted scopes is now…

---

## [Add custom information in Access tokens](https://community.auth0.com/t/add-custom-information-in-access-tokens/95700)

<div class="topic-metadata">

**Author:** [@walter.adbe](https://community.auth0.com/u/walter.adbe)\
**Replies:** 4\
**Last updated:** [December 9, 2022, 11:03pm UTC](https://community.auth0.com/t/add-custom-information-in-access-tokens/95700 "2022-12-09T23:03:20Z")

</div>

We are facing a specific scenario in the application where we have to add custom information to an access token. I have read the documents that i could find where we can add using Actions and Rules. I was able to add som…

---

## [Need to implement multi tenancy application](https://community.auth0.com/t/need-to-implement-multi-tenancy-application/96032)

<div class="topic-metadata">

**Author:** [@rjadi](https://community.auth0.com/u/rjadi)\
**Replies:** 1\
**Last updated:** [December 9, 2022, 1:41pm UTC](https://community.auth0.com/t/need-to-implement-multi-tenancy-application/96032 "2022-12-09T13:41:27Z")

</div>

Hi, We are planning to integrate the auth0 platform into our product for the OIDC platform also we have a mobile application as well which is connected to the rest API using the next.js and Postgres database. We are pl…

---

## [Is there any "global" in actions like in rules?](https://community.auth0.com/t/is-there-any-global-in-actions-like-in-rules/65790)

<div class="topic-metadata">

**Author:** [@yufuven](https://community.auth0.com/u/yufuven)\
**Replies:** 4\
**Last updated:** [November 28, 2022, 2:22pm UTC](https://community.auth0.com/t/is-there-any-global-in-actions-like-in-rules/65790 "2022-11-28T14:22:49Z")

</div>

Is there any feature in actions for caching expensive resources, like in rules? I found this article about rules, but not about actions. https://auth0.com/docs/rules/cache-resources We want to call our system for stori…

---

## [Cannot utilize error messages from actions/hooks in universal login screen](https://community.auth0.com/t/cannot-utilize-error-messages-from-actions-hooks-in-universal-login-screen/92270)

<div class="topic-metadata">

**Author:** [@dgbau](https://community.auth0.com/u/dgbau)\
**Replies:** 2\
**Last updated:** [November 11, 2022, 4:03am UTC](https://community.auth0.com/t/cannot-utilize-error-messages-from-actions-hooks-in-universal-login-screen/92270 "2022-11-11T04:03:16Z")

</div>

I am trying to show a custom message for passwordless login, when a user enters an email that has been rejected as invalid from my preUserRegistration action. I am returning an error from this hook, but I can find no way…

---

## [Require MFA once per session rule only for enrolled users](https://community.auth0.com/t/require-mfa-once-per-session-rule-only-for-enrolled-users/93525)

<div class="topic-metadata">

**Author:** [@yana.bobrysheva](https://community.auth0.com/u/yana.bobrysheva)\
**Replies:** 1\
**Last updated:** [November 2, 2022, 2:06pm UTC](https://community.auth0.com/t/require-mfa-once-per-session-rule-only-for-enrolled-users/93525 "2022-11-02T14:06:50Z")

</div>

Is there a way to configure “Require MFA once per session” rule to be applicable only to the users who have enrolled in MFA instead of all users for whom MFA is enabled?

---

## [Add custom claim to access token](https://community.auth0.com/t/add-custom-claim-to-access-token/93222)

<div class="topic-metadata">

**Author:** [@arunraj.singh](https://community.auth0.com/u/arunraj.singh)\
**Replies:** 1\
**Last updated:** [October 27, 2022, 6:29pm UTC](https://community.auth0.com/t/add-custom-claim-to-access-token/93222 "2022-10-27T18:29:40Z")

</div>

We use auth0 domain as namespace identifier in our custom claims as shown below- https://abcdapp.auth0.com/user\_metadata https://abcdapp.auth0.com/app\_metadata As per below link, we need to remove auth0 from namespace…

---

## [Ngrok “403: Forbidden”](https://community.auth0.com/t/ngrok-403-forbidden/92758)

<div class="topic-metadata">

**Author:** [@mdnssebastian](https://community.auth0.com/u/mdnssebastian)\
**Replies:** 2\
**Last updated:** [October 20, 2022, 4:49pm UTC](https://community.auth0.com/t/ngrok-403-forbidden/92758 "2022-10-20T16:49:16Z")

</div>

Hi, Related: Following this tutorial, after setting up ngrok locally: ngrok by @inconshreveable …

---

## [MFA Hook to know if the setup is completed](https://community.auth0.com/t/mfa-hook-to-know-if-the-setup-is-completed/91974)

<div class="topic-metadata">

**Author:** [@dev43](https://community.auth0.com/u/dev43)\
**Replies:** 4\
**Last updated:** [October 17, 2022, 6:01am UTC](https://community.auth0.com/t/mfa-hook-to-know-if-the-setup-is-completed/91974 "2022-10-17T06:01:06Z")

</div>

Hey there, how do I know if a MFA is setup or not? Use case: Use logins into my application, opens settings and clicks on “setup MFA”; he then gets redirected to the UI from Auth0 where the MFA will be setup. How does…

---

## [From Rule know if user is logging in or creating new account (universal login)](https://community.auth0.com/t/from-rule-know-if-user-is-logging-in-or-creating-new-account-universal-login/91716)

<div class="topic-metadata">

**Author:** [@brett2](https://community.auth0.com/u/brett2)\
**Replies:** 4\
**Last updated:** [October 4, 2022, 1:33am UTC](https://community.auth0.com/t/from-rule-know-if-user-is-logging-in-or-creating-new-account-universal-login/91716 "2022-10-04T01:33:15Z")

</div>

We are using Universal Login and are setting up a rule where we’d like to know if the user used a login page or a sign-up page. Yes, we understand we can determine if it is the user’s first login using context.stats.logi…

---

## [Auth0 actions / flow for disclaimer not sending back to logon page](https://community.auth0.com/t/auth0-actions-flow-for-disclaimer-not-sending-back-to-logon-page/90106)

<div class="topic-metadata">

**Author:** [@kris.macgillivray](https://community.auth0.com/u/kris.macgillivray)\
**Replies:** 1\
**Last updated:** [September 30, 2022, 11:47pm UTC](https://community.auth0.com/t/auth0-actions-flow-for-disclaimer-not-sending-back-to-logon-page/90106 "2022-09-30T23:47:17Z")

</div>

we have create a disclaimer service / application and have a action configured to redirect the user to this disclaimer. (The user before this is already authenticated to auth0) if the user does not accept the disclaimer…

---

## [How to load web page/static page during login flow](https://community.auth0.com/t/how-to-load-web-page-static-page-during-login-flow/90699)

<div class="topic-metadata">

**Author:** [@Jaydeeps03](https://community.auth0.com/u/Jaydeeps03)\
**Replies:** 1\
**Last updated:** [September 16, 2022, 9:30am UTC](https://community.auth0.com/t/how-to-load-web-page-static-page-during-login-flow/90699 "2022-09-16T09:30:02Z")

</div>

Hi Team, I want to display one web page during login flow, this web page will have one dropdown list and post dropdown selection I want to update scope and custom claim of access token. This webpage will be based on s…

---

## [How to redirect blocked user to custom page?](https://community.auth0.com/t/how-to-redirect-blocked-user-to-custom-page/90301)

<div class="topic-metadata">

**Author:** [@greggs](https://community.auth0.com/u/greggs)\
**Replies:** 3\
**Last updated:** [September 14, 2022, 6:13am UTC](https://community.auth0.com/t/how-to-redirect-blocked-user-to-custom-page/90301 "2022-09-14T06:13:22Z")

</div>

I would like to understand how to redirect a user that is blocked to a custom page on our website. That way we don’t see the error message. Can you provide guidance on how to accomplish this? Would this be a job for a r…

---

## [Generate JWT with custom claims from within Rule?](https://community.auth0.com/t/generate-jwt-with-custom-claims-from-within-rule/90529)

<div class="topic-metadata">

**Author:** [@camf](https://community.auth0.com/u/camf)\
**Replies:** 2\
**Last updated:** [January 8, 2024, 8:11am UTC](https://community.auth0.com/t/generate-jwt-with-custom-claims-from-within-rule/90529 "2024-01-08T08:11:12Z")

</div>

I am using a custom Rule to modify a SAML attributes mapping for SSO. I am running Hasura with JWT authentication that depends on custom claims to determine data access privileges. It is my understanding that I can add…

[Next page](https://community.auth0.com/tag/rules/107.md?match_all_tags=true&page=1&tags%5B%5D=rules)
