WoyraDocs
Get an API key

Finish signing in with a TOTP code or a recovery code

POST/v1/auth/mfa/verify

Console · Requires an API key

Takes the six digits from the authenticator app, or one of the recovery codes (XXXXX-XXXXX, any case), which then never works again. Five wrong codes end the pending session.

Body

FieldTypeDescription
coderequiredstringSix digits from the authenticator app

Example

curl -X POST https://api.woyra.io/v1/auth/mfa/verify \
  -H "Authorization: Bearer $WOYRA_KEY" \
  -H 'Content-Type: application/json' \
  -d '{
    "code": "<code>"
  }'

Response

200 Signed in.

FieldTypeDescription
object"session"
userUser
accountobject
account.idstring
account.namestring
account.countrystring
account.currencystringThe billing currency.
account.payment_currencystringHow the account pays: USD by card, or ETB by bank deposit credited in USD.
One of ETB, USD.
account.regionstring
One of global, ethiopia.
account.statusstring
account.project_idstring
mfaobject
mfa.enabledbooleanAn authenticator app is on.
mfa.requiredboolean
mfa.pendingboolean
mfa.passkeysintegerHow many passkeys the user has. A passkey counts as a second factor.
mfa.recovery_codesintegerUnused recovery codes left.
sessionobject
session.idstring
session.expires_attimestamp
api_keyobjectOnly on signup — the test key, with its token shown once.

Errors

StatusCodes
401authentication_required, invalid_api_key
429rate_limited, daily_send_limit_reached

Also in Console