Rotate a legacy bearer into a cookie without extending expiry
POST
/v1/auth/browser-session
const url = 'https://example.com/v1/auth/browser-session';const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://example.com/v1/auth/browser-session \ --header 'Authorization: Bearer <token>'Moves a legacy bearer session into the HttpOnly cookie once, rotating the bearer without extending the session’s expiry. Needs the bearer and X-Olivares-Session: cookie.
Authorizations
Section titled “ Authorizations ”Responses
Section titled “ Responses ”OK
Media type application/json
object
csrf_token
required
string
expires_at
required
string format: date-time
session_id
required
string format: uuid
Example generated
{ "csrf_token": "example", "expires_at": "2026-04-15T12:00:00Z", "session_id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0"}Bad request
Media type application/json
object
error
required
object
code
required
string
message
required
string
module
With code module_not_enabled: the namespace of the module this node does not run.
string
Example generated
{ "error": { "code": "example", "message": "example", "module": "example" }}Unauthenticated
Media type application/json
object
error
required
object
code
required
string
message
required
string
module
With code module_not_enabled: the namespace of the module this node does not run.
string
Example generated
{ "error": { "code": "example", "message": "example", "module": "example" }}Forbidden
Media type application/json
object
error
required
object
code
required
string
message
required
string
module
With code module_not_enabled: the namespace of the module this node does not run.
string
Example generated
{ "error": { "code": "example", "message": "example", "module": "example" }}Not found
Media type application/json
object
error
required
object
code
required
string
message
required
string
module
With code module_not_enabled: the namespace of the module this node does not run.
string
Example generated
{ "error": { "code": "example", "message": "example", "module": "example" }}Conflict / setup required
Media type application/json
object
error
required
object
code
required
string
message
required
string
module
With code module_not_enabled: the namespace of the module this node does not run.
string
Example generated
{ "error": { "code": "example", "message": "example", "module": "example" }}Rate limited
Media type application/json
object
error
required
object
code
required
string
message
required
string
module
With code module_not_enabled: the namespace of the module this node does not run.
string
Example generated
{ "error": { "code": "example", "message": "example", "module": "example" }}