Manual
CLI
API
Log in Get started free

Start two-factor setup

Makes a new secret for an authenticator app. It counts once you confirm a code.

Makes a new secret for an authenticator app. It counts once you confirm a code.

HTTP
POST /account/mfa/setup

Access: Session token only. API keys get 403 with insufficient_scope.

Calling it again before you confirm replaces the secret.

Response 200 #

JSON
{
  "secret": "JBSWY3DPEHPK3PXPJBSWY3DPEHPK3PXP",
  "uri": "otpauth://totp/Continuous%20Translations%3Aada%40example.com?secret=JBSWY3DPEHPK3PXPJBSWY3DPEHPK3PXP&issuer=Continuous%20Translations&algorithm=SHA1&digits=6&period=30"
}

Response fields #

FieldTypeDescription
secretstringThe key to type into an authenticator app, in base32.
uristringAn otpauth:// URI with the same key. Show it as a QR code. The codes have 6 digits and last 30 seconds (SHA-1).

Errors #

StatuserrorWhen
401unauthenticatedThe token is missing or not valid.
409mfa_enabledTwo-factor authentication is on already.
429rate_limitedToo many requests, see Rate limiting.

See Errors for the error format.