loading
Preparing LoginRadius developer resources
Mission: Help enterprises accelerate digital transformation with our fully-managed Customer IAM technology.
Skip to main content

OAuth consent

OAuth consent asks the user to approve the scopes a client requests before LoginRadius issues an authorization code. LoginRadius decides when the consent screen is required, renders it in Auth Studio, stores the user's decision, and issues tokens that carry only the approved scopes.

Consent runs after the user signs in and before LoginRadius redirects to the client's redirect_uri. The same screen renders in the standard Auth Studio login flow and in Identity Orchestration (IO) workflows.

The client type and the requested API Resource decide whether the user sees the screen. LoginRadius shows the screen only for scopes the user has not already approved for that client.

ClientConsent screen shown when
Standard OAuth 2.0 or OIDC appThe request names a resource with Enforce consent screen enabled and asks for at least one of its API scopes. A request for OIDC scopes alone does not show the screen.
DCR or CIMD clientAlways, for every requested scope, including OIDC scopes and requests without a resource.
Any client with prompt=consentAlways, even when the user has already approved the scopes.

The consent screen never appears for Auth Studio templates older than version 3.0.2 or for V2 Auth Studio templates. See Resource Indicators for the resource parameter and MCP Auth for DCR and CIMD clients.

Prompt parameter

The OIDC prompt parameter on the /authorize request changes how consent is handled.

promptBehavior
consentShows the consent screen for all eligible scopes, ignoring earlier approvals.
noneReturns consent_required to redirect_uri instead of showing the screen.
Not setShows the screen only for scopes the user has not approved.

Prerequisites

Auth Studio renders the consent screen through the LoginRadius V3 JS SDK, so the template serving your login pages must support it. Complete both steps before you enable consent on any API Resource.

  1. Upgrade the Auth Studio template to SDK version 3.0.2 or later.
  2. Update redirectIfAuthenticated() in the template's before-script.js so a signed-in user on an authorize request stays on the page.
function redirectIfAuthenticated() {
if (
params.has("response_type") ||
commonoptions.federationTokenCallback ||
authorizeFlow ||
params.has("code") ||
params.has("vtoken")
) {
return;
}
// ...existing redirect logic
}
warning

A template older than 3.0.2, including one mapped to a custom domain, skips the consent screen and returns consent_required to the client. A template without the before-script.js change redirects away before the screen renders.

Standard apps show the consent screen only for API Resources that enforce it. DCR and CIMD clients always require consent and need no configuration.

  1. Navigate to Authorization → APIs and open the API Resource.
  2. Under User Access, enable Access based on RBAC Roles.
  3. Enable Enforce consent screen.
  4. Click Update.
note

The User Access section appears only when resource-level RBAC is enabled for your Tenant. Contact LoginRadius support to enable it.

The screen lists the requested OIDC scopes as plain-language permissions and groups API scopes under their API Resource. Each API scope shows the description you set on the API Resource, so write descriptions the user can understand.

LoginRadius renders one of two variants based on the client.

VariantUsed forShows
StandardStandard OAuth 2.0 and OIDC appsTenant logo, app name, scopes, Approve and Deny
Dynamic clientDCR and CIMD clientsTenant logo and client logo, app and client name, scopes, privacy policy and terms of service links, Approve and Deny

The dynamic client variant reads the client logo, terms of service, and privacy policy from the logo_uri, tos_uri, and policy_uri the client sent at registration. A missing logo shows a placeholder, and a missing link shows as plain text.

OIDC scopes use the default labels below.

ScopeDefault label
openidVerify your identity
profileAccess your profile information
emailAccess your email address
phoneAccess your phone number
addressAccess your address

To change the screen text or translate it, edit the OAuth Consent and Dynamic Client OAuth Consent components in Auth Studio localization.

Approve and deny

The user's decision completes the authorization request. LoginRadius stores approvals and removes denied scopes from any earlier approval.

DecisionResult
ApproveLoginRadius stores the approval and redirects to redirect_uri with the authorization code.
DenyLoginRadius removes the denied scopes from the stored approval and redirects to redirect_uri with error=access_denied, error_description=user denied consent, and the original state.
No decision before the request expiresThe consent request is valid for 15 minutes, or for the app's Access Token lifetime if shorter. After it expires, the user signs in again.

Stored approvals

LoginRadius stores each approval per user and client, so later sign-ins, new sessions, and logouts do not show the screen again. The screen returns when the client requests a scope the user has not approved, when the request uses prompt=consent, or after the user denies or an administrator revokes the approval.

For DCR and CIMD clients, the Access Token scope claim contains only the scopes the user approved. For standard apps, the same narrowing applies when resource-level RBAC is enabled. See Scope Resolution for how scopes are intersected.

Administrators can view and revoke approvals granted to DCR and CIMD clients from the Admin Console, either per client or per user. Revoking consent does not invalidate tokens already issued. Existing Access Tokens remain valid until they expire, and the user sees the consent screen on the next authorization request.

  1. Navigate to Applications and open the app.
  2. Select the Clients tab and click View Details on the client.
  3. Under Consented Users, click Revoke Consent for the user.

Errors

The client receives consent errors as standard OAuth 2.0 error parameters on redirect_uri. Handle both in your callback.

errorCause
consent_requiredThe request used prompt=none and consent is required, or the Auth Studio template is older than 3.0.2.
access_deniedThe user clicked Deny.

Best practices

  • Request only the scopes you need: every additional scope appears on the screen and triggers a new prompt.
  • Write clear scope descriptions: the user reads them on the consent screen to decide.
  • Register client metadata: DCR and CIMD clients that send logo_uri, tos_uri, and policy_uri show a complete consent screen.
  • Handle consent errors: treat access_denied as a user decision and consent_required as a signal to retry without prompt=none.