Skip to content
Lira APILira API

Authentication

Verify 2FA code

post/auth/totp/verify

Exchange a login challenge token plus a TOTP or backup code for access and refresh tokens.

Body required

challengeTokenstringrequired

Challenge token returned by /auth/login when 2FA is enabled

codestringrequired

6-digit authenticator code or a backup code

Response

accessTokenstringrequired

Short-lived JWT — include as `Authorization: Bearer <token>`

refreshTokenstringrequired

Long-lived token — exchange via /auth/refresh for a new access token

expiresInintegerrequired

Access token lifetime in seconds

tokenTypestringrequired