POST User/opt-in-to-2fa

Opt-in to two-factor authentication (2FA). This will send a one-time password (OTP) to the specified mobile number. You will need to call the method to verify this OTP to activate the 2FA, by the passing in the OTP and the provider user id returned as part of this call.

Request Information

URI Parameters

Name Description Type Additional information
WsAccessKey The Web Service access key for this user and file which allows access to the API for the associated file (found in File - Settings). Using OAuth authentication mechanism is the preferred method to allow API access. string

Optional. Legacy authentication method and only required if not using OAuth. OAuth is preferred.

FileId Specifies the file id of the file to perform the operation upon. integer

Required

Body Parameters

OptInTo2FARequest
Name Description Type Additional information
MobileNumber The mobile number to opt-in to two-factor authentication (2FA). Only support AU # at the moment. E.g. 0499999999 string

Required

Request Formats

application/json, text/json

Sample:
{
  "MobileNumber": "sample string 1"
}

application/xml, text/xml

Sample:
<OptInTo2FARequest xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
  <MobileNumber>sample string 1</MobileNumber>
</OptInTo2FARequest>

Response Information

Resource Description

OptInTo2FAResult
Name Description Type Additional information
ProviderUserId Provider user id of the mobile number registered for 2FA. This needs to be passed in when you verify the one-time password (OTP) sent to activate the 2FA. integer

None.

Response Formats

application/json, text/json

Sample:
{
  "ProviderUserId": 1
}

application/xml, text/xml

Sample:
<OptInTo2FAResult xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
  <ProviderUserId>1</ProviderUserId>
</OptInTo2FAResult>