Skip to main content
POST
Generate recovery codes

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
password
string | null

The person's password once more: a session alone does not change the second factor.

Required string length: 1 - 1024
totp
string | null

In place of the password, only for a person the tenant's SSO created, who has none: the current code of the authenticator app.

Pattern: ^\d{6}$

Response

The new recovery codes, shown once.

recovery_codes
string[]
required

Ten single-use codes, XXXXX-XXXXX. Shown once; Niadra keeps only a keyed hash of each, and the earlier codes of the person no longer work.