OIDC callback – exchange code for token
GET /api/auth/sso/oidc/callback
Consumes the code and required 32-character state from the OIDC callback. State is single-use and binds the exchange to the initiation-time PKCE verifier and nonce. On success the controller returns api_token, user_id and email as JSON; it does not redirect. The unauthenticated route is limited to 20 requests per minute per IP.
This operation needs no authentication.
Parameters
codestring query requiredstatestring query requiredLength: 32 to 32 characters
Responses
200 OIDC code exchange succeeded.
application/json object
api_tokenstring requiredemailstring (email) requireduser_idinteger required
Generated sample
{
"api_token": "string",
"email": "user@example.com",
"user_id": 0
}422 Missing or invalid state, configuration, code exchange, or tenant account.
application/json GenericError
erroranyOne of
- string
- object
Any keys are accepted.
error_codestringcodestringmessagestringdetailstringstatusanyOne of
- string
- integer
errorsobjectAny keys are accepted.
429 Route rate limit exceeded.
application/json GenericError
erroranyOne of
- string
- object
Any keys are accepted.
error_codestringcodestringmessagestringdetailstringstatusanyOne of
- string
- integer
errorsobjectAny keys are accepted.
text/html string
502 Error response.
application/json GenericError
erroranyOne of
- string
- object
Any keys are accepted.
error_codestringcodestringmessagestringdetailstringstatusanyOne of
- string
- integer
errorsobjectAny keys are accepted.