Mint a fresh batch of recovery codes
POST /account/security/2fa/recovery/regenerate
POST
/account/security/2fa/recovery/regenerate
Invalidates the prior batch (even unused codes) + returns N new plaintext codes shown ONCE. Requires the caller’s current password.
Authorizations
Section titled “Authorizations ”Request Body required
Section titled “Request Body required ”Body for the disable + regenerate-recovery surfaces. Re-asks for the current password so a stolen-session attacker can’t kill 2FA + lock the owner out in one move.
object
current_password
required
string format: password
Responses
Section titled “ Responses ”New recovery codes shown ONCE.
object
recovery_codes
required
Array<string>
Malformed request
object
error
required
Human-readable error summary
string
Example
the request could not be completedAuthentication required, missing, or invalid
object
error
required
Human-readable error summary
string
Example
the request could not be completedExample
{ "error": "authentication required: sign in and retry with a valid session or API token"}