For AI agents: the documentation index is at /llms.txt, and this page is available as Markdown at /api/auth/oauth-token.md.
Exchange a grant for tokens
The token endpoint (RFC 6749 4.1.3 and 6), form encoded.
authorization_code consumes the code atomically, checks it was issued
to this client and this redirect_uri, and verifies PKCE. A code is
single-use: unknown, expired and already-redeemed are one answer, so a
caller cannot tell them apart.
refresh_token rotates: the presented token is consumed and the
response carries its replacement, minted with the stored audience and
scopes, so neither can widen on refresh. Refresh tokens are opaque and
single-use; replaying a consumed one revokes every token descended
from the same grant.
Rate limit: counts against the Sign-in verification limit, 30 a minute (per ip address, for every caller). See Rate limits.
application/x-www-form-urlencoded- body
grant_type*string"authorization_code""refresh_token"client_id*stringcode?stringRequired for authorization_code.
redirect_uri?stringRequired for authorization_code; must match the authorize request.
uricode_verifier?stringRequired for authorization_code.
refresh_token?stringRequired for refresh_token.
Tokens issued
application/json- response
access_token*stringAudience-bound to the resource named in the authorize request.
token_type*"Bearer""Bearer"expires_in*integerSeconds until the access token expires.
int64refresh_token?stringOpaque and single-use; each refresh response replaces it.
scope*stringSpace-delimited scopes the grant carries.
curl -X POST 'https://api.truemarkets.co/v1/auth/oauth/token' \ -H 'Content-Type: application/x-www-form-urlencoded' \ -d 'grant_type=authorization_code&client_id=string'{ "access_token": "string", "token_type": "Bearer", "expires_in": 0, "refresh_token": "string", "scope": "string"}Record a consent decision POST
The signed-in user's answer to the consent screen. Approving records the grant and mints an authorization code; denying returns the client to its redirect with error=access_denied.
OAuth resource token key set GET
The key set for OAuth resource tokens, served separately from /.well-known/jwks.json.