Skip to main content

OAuth Endpoints

This section documents the OAuth 2.0 and OpenID Connect endpoints for authorization, user info retrieval, and logout.

Authorization Endpoint​

GET /realms/:realmName/protocol/openid-connect/auth

The authorization endpoint initiates the OAuth 2.0 authorization code flow. It redirects the user to authenticate and authorize the client application.

Query Parameters​

ParameterRequiredDescription
client_idYesThe client identifier
redirect_uriYesThe URI to redirect after authorization
response_typeYesMust be "code" for authorization code flow
scopeNoSpace-separated list of scopes (default: "openid")
stateRecommendedCSRF protection token
nonceConditionalRequired for implicit/hybrid flows, recommended for code
code_challengeConditionalPKCE challenge; required for public clients
code_challenge_methodConditionalMust be "S256" when code_challenge provided
promptNo"none", "login" or "consent"
acr_valuesNoRequested ACR: urn:idenplane:acr:password, urn:idenplane:acr:mfa or urn:idenplane:acr:webauthn
login_hintNoUsername hint for pre-filling login form

Authorization Code Flow Example​

# Direct user to authorization endpoint
https://localhost:3000/realms/master/protocol/openid-connect/auth \
?client_id=my-app \
&redirect_uri=https://myapp.com/callback \
&response_type=code \
&scope=openid%20profile%20email \
&state=xyz789 \
&code_challenge=Kjcsjkk... \
&code_challenge_method=S256

Prompt Parameter​

ValueDescription
noneDo not display authentication UI; error if not authenticated
loginForce re-authentication even with existing session
consentForce consent prompt even if previously granted

select_account is not supported.

Response​

Upon successful authorization, the user is redirected to the redirect_uri with an authorization code:

https://myapp.com/callback?code=SplxlOBeZQQYbYS6WxSbIA&state=xyz789

On error, the user is redirected to the redirect_uri with error parameters:

https://myapp.com/callback?error=access_denied&error_description=The+user+denied+the+request&state=xyz789

UserInfo Endpoint​

GET /realms/:realmName/protocol/openid-connect/userinfo

Returns claims about the authenticated user. Requires a valid access token with the openid scope.

Request​

curl -X GET "http://localhost:3000/realms/master/protocol/openid-connect/userinfo" \
-H "Authorization: Bearer eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9..."

Response​

{
"sub": "user-uuid-123",
"preferred_username": "johndoe",
"email": "johndoe@example.com",
"email_verified": true,
"given_name": "John",
"family_name": "Doe",
"name": "John Doe",
"updated_at": 1620000000
}

Standard Claims​

ClaimDescription
subSubject identifier (user UUID)
preferred_usernameUser's username
emailUser's email address
email_verifiedWhether email has been verified
given_nameUser's first name
family_nameUser's last name
nameUser's full display name
pictureURL to user's profile picture
updated_atLast update timestamp

Logout Endpoints​

Logout Endpoint​

GET /realms/:realmName/protocol/openid-connect/logout

Initiates single logout (SLO) to terminate the user's session.

Query Parameters​

ParameterRequiredDescription
id_token_hintNoID token for session identification
post_logout_redirect_uriNoURI to redirect after logout
stateNoCSRF protection token

Request Example​

GET /realms/master/protocol/openid-connect/logout \
?id_token_hint=eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9... \
&post_logout_redirect_uri=https://myapp.com \
&state=xyz789

Front-channel logout is not supported; logout is propagated to clients over the back channel (see below).

OpenID Connect Discovery​

GET /realms/:realmName/.well-known/openid-configuration

Returns the OpenID Connect discovery document with endpoint locations and capabilities.

Response​

{
"issuer": "http://localhost:3000/realms/master",
"authorization_endpoint": "http://localhost:3000/realms/master/protocol/openid-connect/auth",
"token_endpoint": "http://localhost:3000/realms/master/protocol/openid-connect/token",
"userinfo_endpoint": "http://localhost:3000/realms/master/protocol/openid-connect/userinfo",
"jwks_uri": "http://localhost:3000/realms/master/protocol/openid-connect/certs",
"introspection_endpoint": "http://localhost:3000/realms/master/protocol/openid-connect/token/introspect",
"revocation_endpoint": "http://localhost:3000/realms/master/protocol/openid-connect/revoke",
"end_session_endpoint": "http://localhost:3000/realms/master/protocol/openid-connect/logout",
"response_types_supported": ["code"],
"device_authorization_endpoint": "http://localhost:3000/realms/master/protocol/openid-connect/auth/device",
"grant_types_supported": ["authorization_code", "client_credentials", "password", "refresh_token", "urn:ietf:params:oauth:grant-type:device_code"],
"subject_types_supported": ["public"],
"id_token_signing_alg_values_supported": ["RS256"],
"scopes_supported": ["openid", "profile", "email", "roles", "offline_access"],
"request_parameter_supported": false,
"request_uri_parameter_supported": false,
"token_endpoint_auth_methods_supported": ["client_secret_post", "client_secret_basic", "none"],
"claims_supported": ["sub", "iss", "aud", "exp", "iat", "auth_time", "nonce", "at_hash", "acr", "amr", "azp", "name", "email", "email_verified", "preferred_username", "given_name", "family_name", "updated_at", "realm_access", "resource_access"],
"code_challenge_methods_supported": ["S256"],
"backchannel_logout_supported": true,
"backchannel_logout_session_supported": true,
"acr_values_supported": ["urn:idenplane:acr:password", "urn:idenplane:acr:mfa", "urn:idenplane:acr:webauthn"],
"step_up_challenge_endpoint": "http://localhost:3000/realms/master/step-up/challenge",
"step_up_verify_endpoint": "http://localhost:3000/realms/master/step-up/verify",
"webauthn_registration_endpoint": "http://localhost:3000/realms/master/webauthn/register/options",
"webauthn_authentication_endpoint": "http://localhost:3000/realms/master/webauthn/authenticate/options"
}

With mTLS client authentication enabled the document also lists the tls_client_auth methods and mtls_endpoint_aliases.

JWKS Endpoint​

GET /realms/:realmName/protocol/openid-connect/certs

Returns the public keys used to verify JWT signatures.

Response​

{
"keys": [
{
"kty": "RSA",
"use": "sig",
"kid": "key-id-123",
"alg": "RS256",
"n": "0N5r... (base64url-encoded modulus)",
"e": "AQAB (base64url-encoded exponent)"
}
]
}

Backchannel Logout​

POST /realms/:realmName/protocol/openid-connect/logout/backchannel

OIDC Backchannel Logout endpoint for logout propagation to clients.

Request Body​

{
"logout_token": "eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9..."
}

Response​

Returns HTTP 200 with empty body on success. Returns HTTP 400 for invalid logout tokens.

Logout tokens sent to clients​

In the other direction, Idenplane POSTs a logout token to a client's registered backchannelLogoutUri when a session the client holds ends: the user signing out and, since 0.13.0, an admin ending one session or all of a user's, disabling or deleting the user, SCIM deactivation, a credential change, the SSO idle timeout, eviction at maxSessionsPerUser, a reused refresh token and a replayed authorization code. The token carries iss, aud, iat, exp, jti, events, sub and the ended session's sid (sub only when the user was signed out everywhere and the client does not set backchannelLogoutSessionRequired); never nonce. Its typ header is logout+jwt. See Back-Channel Logout for which sessions are announced and how delivery works.

Endpoints Summary​

EndpointMethodDescription
/authGETAuthorization endpoint
/tokenPOSTToken endpoint
/userinfoGETUserInfo endpoint
/logoutGET/POSTLogout endpoint
/logout/backchannelPOSTBack-channel logout
/revokePOSTToken revocation
/token/introspectPOSTToken introspection
/auth/devicePOSTDevice authorization
/certsGETJSON Web Key Set

Paths are relative to /realms/:realmName/protocol/openid-connect. The discovery document is at /realms/:realmName/.well-known/openid-configuration.