Revoke the access token and optionally its refresh session
POST
/v1/auth/logout
const url = 'https://api.wirevod.online/v1/auth/logout';const options = { method: 'POST', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"refresh_token":"wvr_9f2c.refresh"}'};
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://api.wirevod.online/v1/auth/logout \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "refresh_token": "wvr_9f2c.refresh" }'Authorizations
Section titled “Authorizations”Request Body
Section titled “Request Body”Media typeapplication/json
object
refresh_token
string
Example
{ "refresh_token": "wvr_9f2c.refresh"}Responses
Section titled “ Responses ”Session revoked. Idempotent when already revoked.
Missing or invalid credentials.
Media typeapplication/json
object
error
required
string
code
required
string
message
required
string
details
Example
{ "error": "unauthorized", "code": "unauthorized", "message": "Authentication required"}