Register an identity provider
This endpoint is used to register an OIDC provider. This is used to configure the provider and link it to an organization
sessiongamma.session_token<token>The session cookie a sign-in sets. Over HTTPS its name carries the __Secure- prefix. Browsers send it on their own; other clients keep it from the sign-in response.
application/json- body
providerId*stringThe ID of the provider. This is used to identify the provider during login and callback
issuer*stringThe issuer URL of the provider
domain*stringThe domain(s) of the provider. For enterprise multi-domain SSO where a single IdP serves multiple email domains, use comma-separated values (e.g., 'company.com,subsidiary.com,acquired-company.com')
oidcConfig?samlConfig?organizationId?stringIf organization plugin is enabled, the organization id to link the provider to
overrideUserInfo?booleanOverride user info with the provider info. Defaults to false
OIDC provider created successfully
application/json- response
issuer*stringThe issuer URL of the provider
uridomain*stringThe domain of the provider, used for email matching
domainVerified?booleanA boolean indicating whether the domain has been verified or not
domainVerificationToken?stringDomain verification token. It can be used to prove ownership over the SSO domain
oidcConfig*OIDC configuration for the provider
organizationId?stringID of the linked organization, if any
userId*stringID of the user who registered the provider
providerId*stringUnique identifier for the provider
redirectURI*stringThe redirect URI for the provider callback
uricurl -X POST 'http://localhost:3000/api/auth/sso/register' \ -H 'Content-Type: application/json' \ -d '{ "providerId": "string", "issuer": "string", "domain": "string"}'{ "issuer": "http://example.com", "domain": "string", "domainVerified": true, "domainVerificationToken": "string", "oidcConfig": { "issuer": "http://example.com", "pkce": true, "clientId": "string", "clientSecret": "string", "authorizationEndpoint": "http://example.com", "discoveryEndpoint": "http://example.com", "userInfoEndpoint": "http://example.com", "scopes": [ "string" ], "tokenEndpoint": "http://example.com", "tokenEndpointAuthentication": "client_secret_post", "jwksEndpoint": "http://example.com", "mapping": { "email": "string", "emailVerified": "string", "name": "string", "image": "string", "extraFields": { "property1": "string", "property2": "string" } } }, "organizationId": "string", "userId": "string", "providerId": "string", "redirectURI": "http://example.com"}