Get Access Token By Api Refresh Token Using POST

Get Access Token By Api Refresh Token Using POST

The end-point is for exchanging organization scoped API-tokens only, that are obtained from the CSP web console.
1. Including the api_token parameter using the application/x-www-form-urlencoded format in the HTTP request body.
2. DEPRECATED: Passing the refresh_token param name, need to use api_token
3. DEPRECATED: Passing the refresh_token via query param

Access Policy

Role User Accounts Service Accounts (Client Credentials Applications)
Anonymous ✔️ ✔️
Request
URI
POST
https://{api_host}/csp/gateway/am/api/auth/api-tokens/authorize
COPY
Request Body

The application/x-www-form-urlencoded form data type.

GetAccessTokenByApiRefreshTokenRequest of mimetype application/x-www-form-urlencoded
Optional
string
api_token
Optional

The value of the API token.

string
passcode
Optional

The multi-factor authentication passcode from the registered multi-factor authentication (MFA) device.

string
refresh_token
Optional

Deprecated, need to use api_token

Authentication
This operation uses the following authentication methods.
Responses
200

OK

Returns AccessTokenDto of type(s) application/json
{
    "access_token": "string",
    "expires_in": 0,
    "id_token": "string",
    "refresh_token": "string",
    "scope": "string",
    "token_type": "string"
}
string
access_token
Optional

The access token. This is a JWT token that grants access to resources.

integer As int64 As int64
expires_in
Optional

Access token expiration in seconds.

string
id_token
Optional

The ID Token is a signed JWT token returned from the authorization server and contains the user's profile information, including the domain of the identity provider. This domain is used to obtain the identity provider URL. This token is used for optimization so the application can know the identity of the user, without having to make any additional network requests. This token can be generated via the Authorization Code flow only.

string
refresh_token
Optional

The value of the Refresh token.

string
scope
Optional

The scope of access needed for the token

string
token_type
Optional

The type of the token.


400

Invalid request body | In case of expired refresh_token.

Returns CspErrorResponse of type(s) application/json
{
    "cspErrorCode": "string",
    "errorCode": "string",
    "message": "string",
    "moduleCode": 0,
    "requestId": "string",
    "statusCode": 0
}
string
cspErrorCode
Optional

cspErrorCode

string
errorCode
Optional

errorCode

string
message
Optional

message

integer As int32 As int32
moduleCode
Optional

moduleCode

string
requestId
Optional

requestId

integer As int32 As int32
statusCode
Optional

statusCode


404

The requested resource could not be found

Returns CspErrorResponse of type(s) application/json
{
    "cspErrorCode": "string",
    "errorCode": "string",
    "message": "string",
    "moduleCode": 0,
    "requestId": "string",
    "statusCode": 0
}
string
cspErrorCode
Optional

cspErrorCode

string
errorCode
Optional

errorCode

string
message
Optional

message

integer As int32 As int32
moduleCode
Optional

moduleCode

string
requestId
Optional

requestId

integer As int32 As int32
statusCode
Optional

statusCode


409

The request could not be processed due to a conflict

Returns CspErrorResponse of type(s) application/json
{
    "cspErrorCode": "string",
    "errorCode": "string",
    "message": "string",
    "moduleCode": 0,
    "requestId": "string",
    "statusCode": 0
}
string
cspErrorCode
Optional

cspErrorCode

string
errorCode
Optional

errorCode

string
message
Optional

message

integer As int32 As int32
moduleCode
Optional

moduleCode

string
requestId
Optional

requestId

integer As int32 As int32
statusCode
Optional

statusCode


429

The user has sent too many requests

Returns CspErrorResponse of type(s) application/json
{
    "cspErrorCode": "string",
    "errorCode": "string",
    "message": "string",
    "moduleCode": 0,
    "requestId": "string",
    "statusCode": 0
}
string
cspErrorCode
Optional

cspErrorCode

string
errorCode
Optional

errorCode

string
message
Optional

message

integer As int32 As int32
moduleCode
Optional

moduleCode

string
requestId
Optional

requestId

integer As int32 As int32
statusCode
Optional

statusCode


500

An unexpected error has occurred while processing the request

Returns CspErrorResponse of type(s) application/json
{
    "cspErrorCode": "string",
    "errorCode": "string",
    "message": "string",
    "moduleCode": 0,
    "requestId": "string",
    "statusCode": 0
}
string
cspErrorCode
Optional

cspErrorCode

string
errorCode
Optional

errorCode

string
message
Optional

message

integer As int32 As int32
moduleCode
Optional

moduleCode

string
requestId
Optional

requestId

integer As int32 As int32
statusCode
Optional

statusCode