The auth/refresh endpoint in noonjs is used to renew the access token. When a POST request is sent to this endpoint, if the request comes from a browser, the refresh token is extracted from the cookie. If the refresh token is valid, a new access token is generated and returned in the response as
{ "access": "eyJhbGciOiJIUzI1NiI..." }
In this case, the refresh token is included in the request body. If the provided refresh token is valid, a new access token is generated and returned in the response.
POST /auth/refresh
{
"refresh": "eyJhbGciOiJIUzI1NiI..."
}
// result
{
"access": "eyJhbGciOiJIUzI1NiI..."
}