Token

Operation ID: post_Nd
POST
https://idp.authpi.com/{issuer_id}/token

Exchange codes and tokens for access tokens, refresh tokens, and ID tokens

Request

No parameters.

Request body

Schema | application/json
grant_type

The grant type

One of: authorization_coderefresh_token
required string
code

The authorization code

string
refresh_token

The refresh token

string
client_id

The client ID

string
client_secret

The client secret

string
redirect_uri

The redirect URI

string
scope

The requested scope

string
code_verifier

The code verifier, when using PKCE

string
Schema | application/x-www-form-urlencoded
grant_type

The grant type

One of: authorization_coderefresh_token
required string
code

The authorization code

string
refresh_token

The refresh token

string
client_id

The client ID

string
client_secret

The client secret

string
redirect_uri

The redirect URI

string
scope

The requested scope

string
code_verifier

The code verifier, when using PKCE

string

Responses

200

Success

400

Bad request - The request is not valid or missing required parameters.

401

Unauthorized - The request is not allowed because the client or user is not authenticated.

403

Forbidden - The request is not allowed because the client or user does not have the necessary permissions.

404

Not found - The requested resource does not exist.

422

Unprocessable entity - The data provided in the request is not valid.

429

Too many requests - The client has sent too many requests in a given amount of time.

500

Internal server error - An unexpected error occurred while processing the request.