Renew session token
/session-token/renew
Slides a session token forward, performed by the session token itself — authenticate this call with the session token you want to renew. It takes no request body.
The secret is not rotated: the same session_token comes back with a later expires_at, so anything holding it keeps working and there is no grace window for in-flight requests to fall into. max_lifetime_at never moves — it is the ceiling renewal exists underneath.
Renewal is refused with 403 when the session was minted is_refreshable: false, and with a distinct 403 once the absolute lifetime is reached, so a client can tell "renew again later" from "start a new session". A token that has already expired or been revoked gets 401 — there is nothing left to renew.
Response Body
The new expiry.
2026-07-28T12:00:00.000ZUnchanged from when the session was minted.
2026-07-28T23:30:00.000ZThe same secret that was sent in. Renewal does not rotate it.
1ba1f401-7183-47c5-9e39-e8e257e3c795Errors
| Status | Description |
|---|---|
401 | The session token is invalid, has expired, or has been revoked. |
403 | The caller is not a session token, the session was minted non-refreshable, or it has reached its maximum lifetime. |
curl -X POST 'https://api.truto.one/session-token/renew' \
-H 'Authorization: Bearer <your_api_token>' \
-H 'Content-Type: application/json'const response = await fetch('https://api.truto.one/session-token/renew', {
method: 'POST',
headers: {
'Authorization': 'Bearer <your_api_token>',
'Content-Type': 'application/json',
},
});
const data = await response.json();
console.log(data);import requests
url = "https://api.truto.one/session-token/renew"
headers = {
"Authorization": "Bearer <your_api_token>",
"Content-Type": "application/json",
}
params = {
}
response = requests.post(url, headers=headers, params=params)
print(response.json())