POST
/v1/auth/grantToken-based AuthenticationGenerates a temporary JSON Web Token (JWT) with a 30-second (by default) TTL and usage::write permission for core voice APIs, requiring an API key with Member or higher authorization. Tokens created with this endpoint will not work with the Manage APIs.
Request body
Time to live settings
application/json
objectGrantV1Request
GrantV1Request
ttl_secondsnumber · doubleTime to live in seconds for the token. Defaults to 30 seconds.
{
"ttl_seconds": 0
}Responses
objectGrantV1Response
GrantV1Response
access_tokenstringrequiredJSON Web Token (JWT)
expires_innumber · doubleTime in seconds until the JWT expires
{
"access_token": "",
"expires_in": 0
}valueErrorResponse
ErrorResponse
oneOf · 3 options
Option 1stringErrorResponseTextError
ErrorResponseTextError
Option 2objectErrorResponseLegacyError
ErrorResponseLegacyError
err_codestringThe error code
err_msgstringThe error message
request_idstringThe request ID
Option 3objectErrorResponseModernError
ErrorResponseModernError
categorystringThe category of the error
detailsstringA description of the error
messagestringA message about the error
request_idstringThe unique identifier of the request
{
"err_code": "string",
"err_msg": "string",
"request_id": "string"
}