Skip to content
/oauth/token

Token — exchange code (+PKCE verifier) for an access token, or refresh

OAuth 2.1 token endpoint (public client, `token_endpoint_auth_method: none`). `grant_type=authorization_code` exchanges a one-time code + `code_verifier` for `{ access_token (RS256 JWT), token_type: Bearer, expires_in, refresh_token, scope }`. `grant_type=refresh_token` rotates the refresh token (reuse of a rotated token revokes the whole family).

free

Parameters

NameInRequiredDefaultAllowedDescriptionExample
grant_typebodyrequired`authorization_code` or `refresh_token`.authorization_code
codebodyoptionalAuthorization code (authorization_code grant).<one-time code>
code_verifierbodyoptionalPKCE verifier (authorization_code grant).<pkce verifier>
redirect_uribodyoptionalMust match the authorize request.http://127.0.0.1:51000/callback
refresh_tokenbodyoptionalRefresh token (refresh_token grant).<refresh token>
client_idbodyrequiredClient id.cursor

Response schema

Schema not yet documented

Full response schema, sample response, and curated examples for this endpoint are landing in Phase 59. The hero, parameters, code samples, and metadata above remain accurate today.

Errors

StatusLabelDescription
200OKRequest succeeded.
400Bad RequestInvalid query, body, or path parameter.
401UnauthorizedMissing or invalid Authorization header / api_Token.
402Payment RequiredInsufficient token balance for this call. Top up
429Too Many RequestsRate limit exceeded for your tier (see /pricing for tier limits). Tier limits
500Server ErrorUnexpected server-side failure. Retry with backoff; report if persistent.

Code samples

curl -X POST "https://api.finradar.ai/oauth/token" \
  -H "Authorization: Bearer YOUR_JWT_TOKEN"

Generate an API key in /account/credentials to run live queries (literal YOUR_API_KEY placeholder shown until then).