Native OAuth

Obtain an OAuth token

Changed on

This endpoint is used to obtain an OAuth token by providing the necessary credentials and parameters.

post/m2m-oauth-server/oauth/token

Request

  • Base URL
    / (relative, and the document was published on a file host, not at the API’s origin)
  • Auth
    none declared

Request body application/x-www-form-urlencoded

client_idstring

The client ID.

token_namestring

The name of the token which will be used in the name claim.

expirationinteger

The requested expiration time in unit timestamp seconds from the client. If not provided, the token will use the maximum allowed by the client, or if it exceeds the maximum allowed, an error will occur.

scopestring

The scopes that are requested, separated by space. Must be a subset of the allowed scopes for the client.

grant_typestring

The type of grant being used. Only 'client_credentials' is supported.

client_assertion_typestring

Specifies the type of client assertion. Only 'urn:ietf:params:oauth:client-assertion-type:jwt-bearer' is supported.

client_assertionstring

The JWT token signed by the configured client authority.

Response

OAuth token obtained successfully

access_tokenstring

The OAuth access token.

token_typestring

The type of token. Typically 'Bearer'.

expires_ininteger

The expiration time of the token in seconds. If not provided, the token will be valid indefinitely.

scopestring

The scopes granted for the token.

Changes

    • info

      api tag Native OAuth added

    • info

      added the new optional request property

    • info

      added the new optional request property

    • warning

      removed the request property

    • warning

      removed the request property

    • info

      api tag Native OAuth removed