Skip to main content
POST
/
oauth
/
token
Exchange code or credentials for an access token
curl --request POST \
  --url https://app.dosfinds.co.uk/oauth/token \
  --header 'Content-Type: application/x-www-form-urlencoded' \
  --data grant_type=authorization_code \
  --data 'code=<string>' \
  --data 'redirect_uri=<string>' \
  --data 'client_id=<string>' \
  --data 'client_secret=<string>' \
  --data 'refresh_token=<string>' \
  --data 'scope=<string>'
{
  "access_token": "abc123",
  "token_type": "Bearer",
  "expires_in": 7200,
  "created_at": 1618884471,
  "refresh_token": "def456"
}

Body

application/x-www-form-urlencoded
grant_type
enum<string>
required
Available options:
authorization_code,
refresh_token,
client_credentials
code
string

Authorization code (for authorization_code flow)

redirect_uri
string<uri>

Must match the one used in authorize

client_id
string
client_secret
string
refresh_token
string

Refresh token (for refresh_token flow)

scope
string

Requested scopes (optional)

Response

200 - application/json

Access token response

access_token
string
required
Example:

"abc123"

token_type
string
required
Example:

"Bearer"

expires_in
integer
required
Example:

7200

created_at
integer
required
Example:

1618884471

refresh_token
string
Example:

"def456"