OIDC/OAuth Flows with Identity Orchestration
When to Use
Prerequisites
Before configuring an OIDC/OAuth flow with IO, you need:
| Requirement | Details |
|---|---|
| OIDC or OAuth application | Configured in Admin Console → Applications. Note the Client ID. |
| IO workflow | Built and published in Admin Console → Platform Config → Authentication → Workflows. Note the Workflow Name. |
| Script node (optional) | Required only if you need to inject custom claims into tokens. |
| Auth Studio style (optional) | Required only if you want branded workflow pages. Note the style name. |
Configuration
Step 1: Create or Select an OIDC/OAuth Application
- In the Admin Console, go to Applications (or the OAuth apps section).
- Create a new application or select an existing one.
- Note the Client ID: you will pass it as
client_idin the authorize URL.
For full OIDC app configuration, see the Authorization Code Flow documentation.
Step 2: Build and Deploy the IO Workflow
- In the Admin Console, go to Platform Config → Authentication → Workflows.
- Create a new workflow from a template or from scratch.
- Add an Auth node, any additional verification or profiling nodes, and a Success Final node.
- Note the Workflow Name: this becomes the
workflowquery parameter value. - Click Update to publish the workflow.
For a full walkthrough of the Workflow Builder, see Building Flows from Scratch and the Node Reference.
Step 3 (Optional): Attach a Script Node for Custom Claims
If you need custom claims in the ID token or access token:
- In the Workflow Builder, drag a Script node from the Helper Nodes section and connect it after the Auth node.
- Use
hook.accessToken.setCustomClaim()and/orhook.idToken.setCustomClaim()to inject the desired claims. - Save and redeploy the workflow.
For script examples and the full API reference, see the Scripts documentation.
How It Works
- Authorize request: Your application redirects the user to the LoginRadius OIDC authorize endpoint with
workflow=<workflowName>. - IO workflow executes: LoginRadius routes the request through the specified workflow. All nodes (Auth, MFA, Script, etc.) run in sequence.
- Authorization code issued: Once the workflow completes successfully, LoginRadius issues an authorization code and redirects to your
redirect_uri. - Token exchange: Your application exchanges the code at the token endpoint for an access token, ID token, and refresh token.
- Custom claims included: If a Script node was used in the workflow, custom claims are present in the returned tokens.
Authorize URL Format
https://<siteurl>/service/oidc/{oidcAppName}/authorize
?client_id=<OIDC Client ID>
&redirect_uri=<Callback URL>
&scope=openid
&response_type=code
&state=<random string>
&nonce=<unique nonce>
&workflow=<workflowName>
&s=<styleName>
&debugMode=<true|false>
| Parameter | Required | Description |
|---|---|---|
client_id | Yes | The Client ID of the OIDC/OAuth application. |
redirect_uri | Yes | The URL LoginRadius redirects to after authentication. Must be whitelisted in the app config. |
scope | Yes | Must include openid. Add email, profile, or custom scopes as needed. |
response_type | Yes | Set to code for Authorization Code Flow. |
state | Yes | A random, unguessable string for CSRF protection. |
nonce | Yes | A unique value to prevent token replay attacks. |
workflow | Yes (for IO) | The name of the IO workflow to execute. Found in Admin Console → Platform Config → Authentication → Workflows. |
s | No | The Auth Studio style name. Controls the branding/theme of the workflow pages. |
debugMode | No | Set to true to enable debug logging during workflow execution. |