Token endpoint
POSThttps://merchant.shuttleglobal.com/token
Authenticate your client in one of two ways:
- In the request body, with the
client_idandclient_secretparameters, or - With HTTP Basic authentication, using your
client_idas the username and yourclient_secretas the password
Use one method per request, not both. If you put client_id or client_secret in the body, put both there.
This endpoint supports two use cases:
-
Authorization Code Exchange:
- Use this when you have received an authorization code from the /authorize flow
- Required parameters: grant_type=authorization_code, code, redirect_uri, plus your client credentials (see above)
- Returns both access_token and refresh_token
- The redirect_uri must match the one used in the original /authorize request
- The authorization code must be exchanged within 15 minutes of being generated
-
Refresh Token Exchange:
- Use this to get a new access_token when your current one expires
- Required parameters: grant_type=refresh_token, refresh_token, plus your client credentials (see above)
- Returns only access_token (refresh_token remains the same)
- No redirect_uri needed for this flow
Notes:
- Access tokens expire after 1 hour (3600 seconds)
- Always store refresh_tokens securely - they are long-lived credentials
- If a refresh_token becomes compromised, obtain a new authorization code through the /authorize flow
Authorizations
Section titled “Authorizations”- clientAuth
- None
Request Bodyrequired
Section titled “Request Bodyrequired”object
Your client ID. Required unless you send it with HTTP Basic authentication.
Your client secret. Required unless you send it with HTTP Basic authentication.
Required for authorization_code grant
Required for authorization_code grant
Required for refresh_token grant
object
Your client ID. Required unless you send it with HTTP Basic authentication.
Your client secret. Required unless you send it with HTTP Basic authentication.
Responses
Section titled “Responses”Token response
object
The access token string as issued by the authorization server
3600Lifetime of the access token in seconds (RECOMMENDED)
Token used to obtain new access tokens using the same authorization grant (OPTIONAL)
Type of token (RFC 6749 Section 7.1) MUST be “Bearer” as per RFC 6750
Was this page helpful?
What went wrong?
Thanks for telling us.