Prove a fresh re-authentication (step-up)
const url = 'https://api.deploybase.eu/api/v1/api/v1/me/step-up';const options = { method: 'POST', headers: {Authorization: '<Authorization>', 'Content-Type': 'application/json'}, body: '{"session_id":"312909075212468632","session_token":"yMDi6uVPJAcphbbz0LaxC07ihWkNTe7m0Xqch8SzfM5Cz3HSIQIDZ65x1f5Qal0jxz0MEyo-_zYcUg"}'};
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.deploybase.eu/api/v1/api/v1/me/step-up \ --header 'Authorization: <Authorization>' \ --header 'Content-Type: application/json' \ --data '{ "session_id": "312909075212468632", "session_token": "yMDi6uVPJAcphbbz0LaxC07ihWkNTe7m0Xqch8SzfM5Cz3HSIQIDZ65x1f5Qal0jxz0MEyo-_zYcUg" }'Exchanges a Zitadel session the caller has just authenticated (password plus TOTP when enrolled, a passkey with user verification, or an identity provider) for a single-use 10-minute grant that unlocks one sensitive account change. The response’s grant_token is shown only once and only to this caller: the client must keep it and send it as the X-Deploybase-Step-Up header on the guarded request (for example POST /api/v1/me/email-change); without it the guarded request is refused with REAUTH_REQUIRED. The session must belong to the signed-in user and its credential checks must be at most 10 minutes old; it is deleted afterwards and can be used once. Limited to 10 attempts per user per hour. Requires a signed-in person: API keys are refused.
Authorizations
Section titled “ Authorizations ”Request Body
Section titled “ Request Body ”The freshly authenticated Zitadel session
object
Example
312909075212468632Example
yMDi6uVPJAcphbbz0LaxC07ihWkNTe7m0Xqch8SzfM5Cz3HSIQIDZ65x1f5Qal0jxz0MEyo-_zYcUgResponses
Section titled “ Responses ”OK
object
object
object
Example
{ "data": { "expires_at": "2026-10-03T12:10:00Z", "factors": [ "password", "totp" ], "grant_token": "q3Xv0bT9mJ2pLr8cWn5ZyK1eHs7AdUf4GiOx6VtRlEw" }}Malformed body, or the session is invalid, foreign or already used (STEP_UP_INVALID)
object
object
Example generated
{ "code": "example", "details": "example", "error": "example", "meta": { "request_id": "example", "timestamp": "example", "trace_id": "example" }}Unauthorized
object
object
Example generated
{ "code": "example", "details": "example", "error": "example", "meta": { "request_id": "example", "timestamp": "example", "trace_id": "example" }}REAUTH_REQUIRED (factors too weak), STEP_UP_UNSUPPORTED or HUMAN_SESSION_REQUIRED
object
object
object
Example
{ "details": { "required": "any" }}Too many attempts; see Retry-After
object
object
Example generated
{ "code": "example", "details": "example", "error": "example", "meta": { "request_id": "example", "timestamp": "example", "trace_id": "example" }}Internal Server Error
object
object
Example generated
{ "code": "example", "details": "example", "error": "example", "meta": { "request_id": "example", "timestamp": "example", "trace_id": "example" }}Live 174db30c built