Configure Okta
This guide connects DIAL to Okta so users authenticate with Okta and DIAL authorizes them by Okta group. For the shared workflow, see the SSO / IdP setup overview.
Prerequisites
- A running DIAL deployment and the URL of your DIAL Chat instance, referred to below as
<chat_url>. - An Okta org with permission to create applications and authorization server policies.
Step 1: Configure Okta
- Create an application (app integration wizard):
- Sign-in method:
OIDC - OpenID Connect - Application type:
Web Application - Sign-in redirect URI:
<chat_url>/api/auth/callback/okta - Sign-out redirect URI:
<chat_url> - Grant types:
Authorization CodeandRefresh Token
- Sign-in method:
- Enable API scopes
okta.users.readandokta.users.read.selfon the Okta API Scopes tab. - Set up an access policy on your authorization server that allows the application and grants scopes
openid,profile, andemail. - Create users under Directory → People.
- Gather facts: the Okta domain (
<okta_domain>), the issuer and jwks_uri from the authorization server metadata, and the application Client ID and Client secret. - (Optional, RBAC) Create groups, assign users and the application, and add a groups claim to the ID token (guide) using a
groupsfilter that matches.*.
Step 2: Configure DIAL Chat
Set these environment variables on DIAL Chat. See DIAL Chat configuration — Okta for the full list.
AUTH_OKTA_ISSUER: "<okta_issuer>"
AUTH_OKTA_CLIENT_ID: "<okta_client_id>"
AUTH_OKTA_CLIENT_SECRET: "<okta_client_secret>"
Step 3: Configure DIAL Core
Add the provider to the identityProviders section of DIAL Core static settings (settings.json). <okta_domain_regex> is <okta_domain> with dots escaped (for example, dev-123456\.okta\.com). Generate a random loggingSalt, for example with pwgen -s 32 1.
{
"identityProviders": {
"okta": {
"jwksUrl": "<okta_jwks_uri>",
"issuerPattern": "^https:\\/\\/<okta_domain_regex>.*$",
"loggingKey": "sub",
"loggingSalt": "<random_salt>",
"rolePath": "Groups"
}
}
}
rolePath is Groups, matching the groups claim you configured. For every setting, see the Identity providers reference.
DIAL Core reads static settings at startup. Restart Core after editing settings.json. Each setting can also be supplied as an aidial.identityProviders.okta.* environment variable.
Step 4: Assign roles to resources
In config.json (dynamic settings), add an Okta group name to a deployment's userRoles array.
{
"models": {
"chat-gpt-35-turbo": {
"userRoles": ["okta-group-name"]
}
}
}
Result
Users log in through Okta, and DIAL Core authorizes their requests based on Okta group membership.
Further reading
- Identity providers reference — all JWT validation settings
- DIAL Chat configuration: Authentication — OpenID Connect sign-in, sessions, and roles in Chat
- Configure end-user authentication with JWT — the general claim-to-resource mapping model
- Configure roles and rate limits — limit what each group may consume