Rotate a refresh token
const url = 'https://api.wirevod.online/v1/auth/refresh';const options = { method: 'POST', headers: {'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/refresh \ --header 'Content-Type: application/json' \ --data '{ "refresh_token": "wvr_9f2c.refresh" }'Exchanges a refresh token for a new token pair; the presented token
stops working. The WireVoD dashboard keeps its refresh token in a
secure cookie instead of the body; cookie refreshes are accepted only
from the dashboard’s own pages (403 csrf_rejected otherwise).
Request Body
Section titled “Request Body”object
Example
{ "refresh_token": "wvr_9f2c.refresh"}Responses
Section titled “ Responses ”New token pair issued; the presented refresh token is invalidated.
object
Omitted for the WireVoD dashboard, which receives it as a secure cookie.
Example
{ "access_token": "eyJhbGciOiJIUzI1NiJ9.access", "refresh_token": "wvr_ab12.next-refresh", "token_type": "bearer", "expires_in": 900}The request was malformed or failed validation.
object
Example
{ "error": "invalid_request", "code": "invalid_request", "message": "asset_id is required"}Missing or invalid credentials.
object
Example
{ "error": "unauthorized", "code": "unauthorized", "message": "Authentication required"}The principal lacks the required scope or role (forbidden), the
user must change their password before continuing
(password_change_required), or the workspace is suspended
(tenant_suspended; every request is refused until it is restored;
contact support).
object
Example
{ "error": "forbidden", "code": "forbidden", "message": "Missing required scope: write"}Too many requests in the current window.
object
Example
{ "error": "rate_limited", "code": "rate_limited", "message": "Too many requests", "details": { "retry_after": 60 }}Headers
Section titled “Headers”Seconds to wait before retrying.