POST /api/auth/refresh
Refreshes the user’s session by exchanging a valid refresh token for a new access token and refresh token pair.Authentication
No authentication required (uses refresh token in request body).Request Body
The refresh token obtained from the login endpoint
Response Fields
New JWT access token for API authentication
New JWT refresh token for future token refreshes
Unix timestamp when the new access token expires
Number of seconds until the new access token expires (default: 3600)
Example Request
Example Response
Error Responses
400 Bad Request
Missing refresh token:401 Unauthorized
Invalid or expired refresh token:500 Internal Server Error
The refresh token endpoint returns both a new access token and a new refresh token. Always use the latest refresh token for subsequent refresh requests.