Get access token
Exchange client credentials for a Bearer token using the OAuth 2.0 client_credentials flow.
Body·
required
application/json
OAuth 2.0 client credentials request
- Type: stringclient
_id Your API client ID
- Type: stringclient
_secret Your API client secret
- Type: stringgrant
_type Must be client_credentials
Responses
- application/json
- 401
Invalid client credentials
Request Example for post/v1/oauth/token
curl https://public-api.somewhatok.link/v1/oauth/token \
--request POST \
--header 'Content-Type: application/json' \
--data '{
"client_id": "",
"client_secret": "",
"grant_type": "client_credentials"
}'
{
"access_token": "string",
"token_type": "string",
"expires_in": 1
}