Back

POST /oauth/token

Route source: app/oauth/token/route.ts. Access: Public OAuth protocol endpoint; client and PKCE values are validated. Status codes are read from the route implementation.

POST/oauth/token

Access

Public protocol route

Request

JSON body follows validation in route source

The accepted fields and validation are implemented in app/oauth/token/route.ts.

Synthetic curl example
curl -i -X POST 'https://portal.rfi-irfos.com/oauth/token' \
  -H 'Content-Type: application/x-www-form-urlencoded' \
  --data-urlencode 'grant_type=authorization_code' \
  --data-urlencode 'code=$AUTHORIZATION_CODE' \
  --data-urlencode 'client_id=$CLIENT_ID' \
  --data-urlencode 'redirect_uri=http://127.0.0.1:43123/callback' \
  --data-urlencode 'code_verifier=$PKCE_VERIFIER'

Response

The handler returns JSON. Response fields are defined in the linked route source.

200 503

The linked source file contains the authoritative field validation and response structure.

Error codes

  • 503 · Service or database is unavailable

Code evidence

app/oauth/token/route

Local index↑ ↓ · Enter · Esc