Create an access token
POST/auth/v1/oauth2/access_token
Create an access token using a Client ID and Client Secret.
Your Client ID is your HTTP basic authentication username, your Client Secret is your HTTP basic authentication password.
Your Client ID and Client Secrets are created by Strata Cloud Manager when you create a service account or reset your service account.
All access tokens created using this API have a lifetime of 15 minutes.
Request
- application/x-www-form-urlencoded
Body
required
Possible values: [client_credentials
]
Access token grant type. This must always be client_credentials
.
The scope of the access request. This must be the TSG ID for which you want to perform API access, and it must be formatted in the following way:
"scope": "tsg_id:<TSG_ID>"
If the service account that you use to authenticate this request does not have role access to the TSG specified in this scope, this API call will fail.
Responses
- 200
- 400
- 401
Returns an access token and access token metadata.
- application/json
- Schema
- Example (from schema)
Schema
The access token issued by the authorization server
The type of the token issued (default bearer)
The lifetime in seconds of the access token.
The scopes contained in the access token.
{
"access_token": "string",
"token_type": "string",
"expires_in": 0,
"scope": "string"
}
Invalid Request
Invalid Client