Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

In this grant type, the client requests an access token using only the client credentials to authenticate a request for an access token. This does not have support for refresh for the refresh token grant.

Here are the cURL commands to use the client credentials grant:

Code Block
languagepowershell
curl -v -X POST -H "Authorization: Basic <base64 encoded client id:client secret value>" -k -d "grant_type=client_credentials" -H "Content-Type:application/x-www-form-urlencoded" https://gateway.api.cloud.wso2.com:443/token

...

You will receive a response similar to the format below.following: 

Code Block
titleResponse
{"token_type":"Bearer","expires_in":2061,"access_token":"ca19a540f544777860e44e75f605d927"}