Skip to main content

How to provide additional parameters from application side to redirects?

You can include additional query parameters in the authorization request. These parameters are preserved throughout the authentication flow and can be accessed during login, registration, and after successful authentication in your application.

Overview

Additional parameters (also called "extra params") allow you to pass custom data through the authentication flow. These parameters are automatically attached to all redirect URLs, enabling you to maintain application state and context throughout the authentication process.


Usage

Adding parameters to the authorization request

Include your custom parameters as query parameters in the authorization URL:

{base_url}/authz-srv/authz?redirect_uri=https://yourapp.com/callback&additional_state_data=anydata&anyfurther_additional_data=anythingelse

Example

const authzUrl = `https://yourdomain.cidaas.com/authz-srv/authz?
redirect_uri=https://yourapp.com/callback&
client_id=your-client-id&
response_type=code&
scope=openid profile email&
additional_state_data=user-context-123&
campaign_id=summer-2024&
referrer=landing-page`;

How it works

  1. Authorization request: Add your custom parameters to the authorization URL
  2. Flow preservation: Parameters are automatically attached to all redirect URLs during the flow
  3. Access in application: Retrieve parameters from the callback URL after successful authentication

Use cases

  • State management: Pass application state through the authentication flow
  • Analytics: Track campaign IDs, referrers, or user context
  • Deep linking: Maintain context for post-authentication redirects
  • Custom routing: Pass routing information for post-login navigation

API reference

APIDescriptionLink
Authorization EndpointPerforms single sign-on or prompts for authentication when the user session is no longer validView API

Need support?

For assistance, visit our Support Portal.