authRefresh
const url = 'http://localhost:8300/auth/refresh';const options = { method: 'POST', headers: {'x-api-key': '<x-api-key>', 'Content-Type': 'application/json'}, body: '{"refresh_token":"example"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url http://localhost:8300/auth/refresh \ --header 'Content-Type: application/json' \ --header 'x-api-key: <x-api-key>' \ --data '{ "refresh_token": "example" }'Authorizations
Section titled “Authorizations”Request Bodyrequired
Section titled “Request Bodyrequired”object
Empty = 401
Example generated
{ "refresh_token": "example"}Responses
Section titled “Responses”Rotated session (same family); the presented refresh token is now used
object
RS256 JWT (kid in the header; claims iss, sub, email, roles, jti, fid = session family, iat, exp); ACCESS_TTL, default 15 min
Opaque; REFRESH_TTL, default 30 days; single use, rotated by /auth/refresh
object
Sorted; may be empty
Example
{ "user": { "roles": [ "user" ] }}Unknown, expired, revoked or already-used refresh token (reuse revokes the whole family), or the user is disabled: “invalid or expired token”
object
Example generated
{ "detail": "example"}Invalid input: “invalid JSON body”, or the failed rule (“invalid email”, “name must be 1-200 characters”, “password must be at least 10 characters”, “password is too common”, “roles must not be empty”, …)
object
Example generated
{ "detail": "example"}Kong rate limit (20/min, 200/h per IP) — Kong answers with {message}
Error body generated by Kong itself (rate limiting)
object
Example generated
{ "message": "example"}