OpenRCS API reference · v1 ← Back to console Swagger UI
Accounts

Refresh the session (exchange a refresh token for a fresh token set)

POST /refresh public

Send the `refresh_token` from POST /login and receive the same token envelope as a `/login` success. Refresh tokens do not rotate: the returned `refresh_token` echoes the submitted token — the envelope is unchanged either way. Throttled and unauthenticated.

Request body

FieldTypeRequiredDescription
refresh_token string yes The refresh token returned by POST /login.

Exchange a refresh token

{
  "refresh_token": "eyJhbGciOi..."
}

Responses

StatusDescription
200 A fresh token set. `refresh_token` echoes the submitted token.
400 Missing or malformed refresh_token.
401 Invalid or expired refresh token.
429 Too many attempts; retry later.
502 Upstream authentication call failed; a generic error is returned and no internals are leaked.

200 example

{
  "id_token": "eyJhbGciOi...",
  "access_token": "eyJhbGciOi...",
  "refresh_token": "<the submitted refresh token>",
  "expires_in": 3600,
  "token_type": "Bearer"
}