Multi-factor authentication
When multi-factor authentication (MFA) is enabled for your account, you must complete a two-step verification process to authenticate.
MFA applies only when authenticating with user credentials. Use application tokens instead. They don’t require MFA handling and are the recommended authentication method for all API integrations.
Two-step authentication flow
Submit credentials and receive MFA token
Send your username and SHA-1 hashed password to /api/v1/authenticate.
Instead of the usual auth_token, the server returns an mfa_token and sends a one-time password (OTP) to your registered email or authenticator app.
Skip MFA with trusted devices
To avoid entering an OTP code on every login, you can register your device as trusted. Trusted devices skip the MFA verification step for 90 days.
Register a trusted device
Include the trusted_device object in your Step 2 request:
The fingerprint must be unique and consistent for each device.
You’re responsible for generating and storing this identifier in your application.
Authenticate with a trusted device
Once registered, include the fingerprint in your initial authentication request.
If the fingerprint matches a trusted device, the server returns auth_token and refresh_token immediately, skipping the OTP step.
MFA key object
The following table describes the properties of the MFA key object.
Status object
Type object
Manage MFA keys
Use the following endpoints to manage MFA keys and trusted devices:
Errors
The following table lists errors that may occur during MFA operations.
Solutions
- 401 Unauthorized: Verify your password is correctly SHA-1 hashed before sending.
Use the
-nflag withechoto avoid trailing newlines. - 409 Duplicated: Delete the existing MFA key before creating a new one.
- 422 InvalidValue: Get the available MFA types to find valid type IDs.
- 422 Required: Include both
type(withid) andpasswordfields in your request body.