Generic OIDC provider
Myra AI Workspace signs users in through any OpenID Connect (OIDC) identity provider that publishes a standard discovery document — Okta, Auth0, Keycloak, Google Workspace, Active Directory Federation Services (ADFS), and others. For Microsoft Entra ID, follow the dedicated Microsoft Entra ID guide, which covers the Entra-specific directory pin and guest policy.
Single sign-on authenticates existing accounts only — provision the users first (or switch on just-in-time provisioning, see the SSO overview). Required role:
tenant admin or admin (the SSO_MANAGE permission).
Note: The examples use the production admin-API host
ai-api-admin.myra.eu. On the integration environment, substituteai-api-admin-int.myra.eu.
Registering the redirect URI at the provider
Register this exact redirect URI (also called the callback or reply URL) in the provider's application:
This is a single, fixed callback URL. It is not tenant-specific — Myra recovers the tenant from the signed login state, not from the URL. The provider does an exact string match on this value, so register it with no trailing slash or extra characters.
Collecting the provider values
From the provider's application, record:
- The issuer — the base URL that publishes
.../.well-known/openid-configuration(for examplehttps://example.okta.comorhttps://accounts.google.com). - The client ID.
- A client secret.
- The stable subject claim name. Myra accepts
suboroid. Do not use a mutable claim such asemail. Most generic providers (Okta, Auth0, Keycloak, Google Workspace) put the stable identifier insub.
Request the scopes openid, email, and profile. Grant admin consent at the provider if the
provider requires it.
Configuring the OIDC panel in Myra
- In the user-block menu, open Organisation, then People → Sign-in & provisioning (route
/org/<organisation>/people/sign-in-provisioning) and select the Identity provider tab.- The OIDC, SAML and SCIM panels used to live on the organisation edit dialog's Identity & SSO tab. That tab now only links here, and the former
?tab=identityaddresses/tenants/<id>?tab=identity,/tenants?tab=identityand/organisation?tab=identityredirect here, keeping the organisation (?tenant=<id>) preselected. A platform admin's?tenant=counts only once it matches an organisation in the picker; an unknown or malformed id (or a picker that failed to load) shows the "pick an organisation" prompt and loads no settings. A tenant admin always sees their own organisation; any?tenant=they carry is ignored.
- The OIDC, SAML and SCIM panels used to live on the organisation edit dialog's Identity & SSO tab. That tab now only links here, and the former
- The organisation comes from the address: a platform admin opens the organisation first (Platform › Organisations, or the context bar at the top); a tenant admin sees their own organisation.
- Find the Single sign-on (OIDC) panel.
- Select the Single sign-on (OIDC) enabled checkbox.
- In the Issuer URL field, enter the provider's issuer.
- Myra verifies that the issuer resolves an OIDC discovery document.
- In the Client ID field, enter the client ID.
- In the Client secret field, paste the client secret.
- The secret is stored encrypted and never returned. On a later update, leave the field empty to keep the stored secret.
- In the Subject claim drop-down list, select sub.
- The drop-down pre-selects oid, which is correct for Microsoft Entra. For a generic provider
that issues the stable identifier in
sub, change the selection to sub.
- The drop-down pre-selects oid, which is correct for Microsoft Entra. For a generic provider
that issues the stable identifier in
- In the Allowed email domains field, enter the comma-separated domains whose users may sign in.
- This is the allowed-domain list. The provider may only sign in users at these domains. Separate domains with commas, semicolons or new lines (a space does not separate). Public e-mail providers such as
gmail.comare refused, and so is a domain that another organisation or its users already use. Myra does not check that you own the domain.
- This is the allowed-domain list. The provider may only sign in users at these domains. Separate domains with commas, semicolons or new lines (a space does not separate). Public e-mail providers such as
- If required, map an identity attribute to Myra groups: enter the Group attribute (optional), then use Add mapping under IdP value mapping to add one row per value — the value the identity provider sends in the IdP value field, what it Becomes (Group or Department), and the Myra group or department as the target.
- Department targets need the permission to manage departments; without it, department rows are shown locked. A stored value the editor cannot edit yet is shown read-only and saved back unchanged; a stored value that is not a valid target is flagged and must be removed before saving.
- A row needs both an IdP value and a target, and an IdP value can appear only once; a row that does not is flagged and Test & save SSO refuses to save until it is fixed. Removing every row clears the mapping.
- The mapping is one per organisation, shared by OIDC, SAML and SCIM, and it is the same
group_mappingsetting the admin API takes (see SCIM). - The claim named in Group attribute is read from the ID token at every sign-in and synced into the
oidc_claimmemberships. A group with a role mapping confers that role on these members exactly as for SAML, and anoidc_claimmembership cannot be removed by hand (409 membership_managed_by_idp). An absent claim or an Entra overage marker keeps the user's memberships; an empty or malformed claim clears them (one non-string value withholds all claim-derived groups until a well-formed sign-in). Details: Identity-provider group claim sync.
-
To require multi-factor authentication at the provider, enter a value in the Required authentication context (MFA) field.
- Myra then accepts a sign-in only when the verified
id_tokencarries this value as itsacrclaim or as an entry of itsamrarray. The match is exact and case-sensitive. - Enter a value the provider emits only after multi-factor authentication, for example
mfainamr(RFC 8176). Never enterpwd, a password-onlyacr, or any value the provider emits for every sign-in: it would satisfy the requirement without any second factor. - The setting governs sign-ins through this identity provider only. It does not apply to email one-time-code sign-in or to Entra access tokens used by the Microsoft 365 integration.
- Leave the field empty for no requirement. When the provider does not assert the value, the user is
sent back to the sign-in page with a message that multi-factor authentication is required, and no
session is created. The refusal is audited as
sso.mfa.login_denied. The setting applies to new sign-ins only; sessions that are already signed in are not ended. A stored value that is unreadable is never treated as "no requirement": the sign-in is refused with the "temporarily unavailable" message.
A user whose account an administrator has disabled cannot sign in through SSO even if they were linked before: the sign-in is refused, no session is created, and the refusal is audited as
sso.account_disabled.login_denied. When several first sign-ins of the same person arrive at the same moment, they all resolve to the same account, exactly as a single sign-in would; none is refused as disabled merely because another one is creating the account. An account an administrator disabled, or one in another tenant, is still refused. - Myra then accepts a sign-in only when the verified
-
Select Test & save SSO. -> SSO configuration saved. is shown, the Single sign-on (OIDC) enabled checkbox stays selected, and the tenant's users can sign in through the provider. When Myra refuses a value, the panel shows The single sign-on configuration was not accepted: followed by the reason.
To switch OIDC off for the tenant, select Remove SSO.
User resolution
At sign-in Myra reads the identity from the email claim. (Only for a Microsoft Entra
configuration, where an Entra directory ID is set, does Myra fall back to preferred_username → upn.)
When there is no email in an allowed domain, the sign-in is refused. Myra links the identity to the
existing account and sets the session.
Trust email addresses from this identity provider. The first sign-in links to an existing account only
when the provider reports the email as verified (email_verified: true). Some providers never send that
claim. Turn the switch on only if your users cannot change their own email address at the provider; Myra then
also accepts an email with no email_verified claim. An explicit email_verified: false is always refused.
The switch is off by default, so after this change a provider that omits email_verified needs it enabled
before users can sign in for the first time (including just-in-time provisioning). Already-linked users are
not affected.
First sign-in / account already linked. The first sign-in links the identity to the existing account. It is refused when the IdP does not report the email as verified (the login page shows that the email could not be verified; sso_email_unverified), or it is refused (sso_denied) when when the account is already linked to a different identity at this provider; see First sign-in (account linking). Contact support to recover a refused link.
Token verification
Myra verifies the id_token in-process, fail-closed at every step: RS256 signatures only (keys from
the configured jwks_uri); exact issuer match; the audience must contain the client ID; and the
login-time nonce must match. For the full verification contract, see
Admin API authentication.
A sign-in is refused (the login page shows a generic sign-in error, no session is created and nothing is written) when the id_token:
- is unsigned (
alg=none), has a bad signature, or names a key the provider does not publish; - is expired, or issued more than 5 minutes in the future;
- carries the wrong issuer, audience or nonce;
- or arrives on a callback whose
statedoes not match the sign-in that started it.
Key rotation. Myra caches the provider's signing keys for up to 1 hour. When a token's signature does not verify against the cached key, Myra re-fetches the key set once and retries, so a provider that rotates its key (even under the same key ID) does not lock users out for the cache lifetime. To keep a flood of forged tokens from hammering your provider, the key set is fetched at most once every 30 seconds per provider. Sign-ins that arrive while that fetch is still running wait for it (for up to 30 seconds) and then use its result, so a burst of sign-ins after a restart, or for a new key ID once the 30-second window allows a fetch, all succeed. During a same-key-ID rotation, a sign-in that races a running re-fetch can fail once; retrying succeeds. A key ID your provider does not publish is refused. If your provider was unreachable on the last fetch, sign-ins with a key that is not yet cached fail until the next fetch is allowed (within 30 seconds).
Plain-HTTP endpoints. If the provider's discovery document advertises an http:// (not https://) jwks_uri, token_endpoint or authorization_endpoint, Myra refuses to use the provider; the OIDC panel reports the provider as not usable. The only exception is an http:// origin the operator has explicitly allowlisted (for example, an on-premises test IdP).
PKCE
Interactive OIDC sign-in uses PKCE (RFC 7636, S256) end-to-end. The /start redirect carries the
code_challenge, and the token exchange sends the matching code_verifier. PKCE is required for a
single-page-application or public app registration and is harmless for a confidential application, so
no configuration is needed.
Sign-in start limits and caching
The sign-in start (/admin/auth/oidc/{tenant}/start) accepts 1000 requests per minute per client IP and tenant by default (IPv6: per /64; the sso_flood_cap_per_min setting, range 500-100000 — see How the public rate limits behave); further requests return to the login page with a rate-limit message until the minute has passed. Separately, 500 refused sign-ins (an ID token that fails verification: signature, issuer, audience, an expired ID token (401), nonce; an unknown or expired login state (400), a malformed callback and provider outages do not count) from one client IP and tenant within a minute lock that IP's OIDC sign-in for 30 minutes; saving this OIDC panel ends the lock at once. See SSO refusal lockout. Myra caches your provider's discovery document for 5 minutes (a failed lookup is retried after 15 seconds), so a change at the provider can take up to 5 minutes to reach sign-in. The cache is kept per gateway worker and holds up to 1024 providers. Saving the OIDC panel always checks the live provider.