Skip to main content
POST
/
oauth2
/
token
Exchange authorization code for access token
curl --request POST \
  --url https://api.sandbox.bitwage.com/oauth2/token \
  --header 'Content-Type: application/json' \
  --data '
{
  "code": "<string>",
  "client_id": "<string>",
  "client_secret": "<string>",
  "grant_type": "authorization_code"
}
'
{
  "access_token": "<string>",
  "user_id": "<string>",
  "company_id": "<string>"
}

Body

application/json
code
string
required

Authorization code from the /authorize step.

client_id
string
required

Your OAuth app client ID.

client_secret
string
required

Your OAuth app client secret.

grant_type
enum<string>
required
Available options:
authorization_code

Response

200 - application/json

Access token returned successfully.

access_token
string
user_id
string
company_id
string