public class VerifyRequest extends BaseRequest
VerifyEndpoint.| Modifier and Type | Class and Description |
|---|---|
static class |
VerifyRequest.Builder
Builder to create a Two Factor Authentication request
|
static class |
VerifyRequest.LineType
Types of phone line to be specified for
type. |
static class |
VerifyRequest.Workflow
Enumeration representing different verification workflows.
|
| Constructor and Description |
|---|
VerifyRequest(java.lang.String number,
java.lang.String brand)
Deprecated.
this construtor is deprecated use
VerifyRequest.Builder to contruct a 2FA verify request |
VerifyRequest(java.lang.String number,
java.lang.String brand,
java.lang.String from)
Deprecated.
this construtor is deprecated use
VerifyRequest.Builder to contruct a 2FA verify request |
VerifyRequest(java.lang.String number,
java.lang.String brand,
java.lang.String from,
int length,
java.util.Locale locale)
Deprecated.
this construtor is deprecated use
VerifyRequest.Builder instead |
VerifyRequest(java.lang.String number,
java.lang.String brand,
java.lang.String from,
int length,
java.util.Locale locale,
VerifyRequest.LineType type)
Deprecated.
|
VerifyRequest(VerifyRequest.Builder builder) |
| Modifier and Type | Method and Description |
|---|---|
static VerifyRequest.Builder |
builder(java.lang.String number,
java.lang.String brand) |
java.lang.String |
getBrand() |
java.lang.String |
getFrom() |
VerifyRequest.LineType |
getType() |
VerifyRequest.Workflow |
getWorkflow() |
void |
setFrom(java.lang.String from)
Deprecated.
since 5.5.0 use
VerifyRequest.Builder to create a 2FA verification request |
void |
setType(VerifyRequest.LineType type)
Deprecated.
since 5.5.0 use
VerifyRequest.Builder to create a 2FA verification request |
void |
setWorkflow(VerifyRequest.Workflow workflow)
Deprecated.
since 5.5.0 use
VerifyRequest.Builder to create a 2FA verification request |
java.lang.String |
toString() |
getCountry, getDashedLocale, getLength, getLocale, getNextEventWait, getNumber, getPinExpiry, setCountry, setLength, setLocale, setNextEventWait, setPinExpiry@Deprecated public VerifyRequest(java.lang.String number, java.lang.String brand)
VerifyRequest.Builder to contruct a 2FA verify requestnumber - (required) The recipient's phone number in E.164
format.brand - (required) The name of the company or app to be verified for. Must not be longer than 18
characters.@Deprecated public VerifyRequest(java.lang.String number, java.lang.String brand, java.lang.String from)
VerifyRequest.Builder to contruct a 2FA verify requestnumber - (required) The recipient's phone number in E.164
format.brand - (required) The name of the company or app you are verifying for. Must not be longer than 18
characters.from - (optional The Nexmo number to use as the sender for the verification SMS message and calls, in
E.164 format.@Deprecated public VerifyRequest(java.lang.String number, java.lang.String brand, java.lang.String from, int length, java.util.Locale locale)
VerifyRequest.Builder insteadnumber - (required) The recipient's phone number in E.164
format.brand - (required) The name of the company or app you are verifying for. Must not be longer than 18
characters.from - (optional The Nexmo number to use as the sender for the verification SMS message and calls, in
E.164 format.length - (optional) The length of the verification code to be sent to the user. Must be either 4 or 6. Use
-1 to use the default value.locale - (optional) Override the default locale used for verification. By default the locale is determined
from the country code included in number@Deprecated public VerifyRequest(java.lang.String number, java.lang.String brand, java.lang.String from, int length, java.util.Locale locale, VerifyRequest.LineType type)
number - (required) The recipient's phone number in E.164
format.brand - (required) The name of the company or app you are verifying for. Must not be longer than 18
characters.from - (optional A short alphanumeric string to specify the SenderID for SMS sent by Verify. Depending on
the destination of the phone number you are applying, restrictions may apply. By default, sender_id
is VERIFY. Must be 11 characters or fewer.length - (optional) The length of the verification code to be sent to the user. Must be either 4 or 6. Use
-1 to use the default value.locale - (optional) Override the default locale used for verification. By default the locale is determined
from the country code included in numbertype - (optional) If provided, restrict the verification to the specified network type. Contact
support@nexmo.com to enable this feature.public VerifyRequest(VerifyRequest.Builder builder)
public java.lang.String getBrand()
public VerifyRequest.LineType getType()
support@nexmo.com.public void setType(VerifyRequest.LineType type)
VerifyRequest.Builder to create a 2FA verification requesttype - the type of network the verification will be restricted to. This value has no effect unless it has been
enabled by contacting support@nexmo.com.Builder#type(LineType)public java.lang.String getFrom()
null if one was
not provided. This value is specified in some BaseRequest sub-class constructors.
If this value is null</tt>, the sender_id used will be <tt>VERIFY.
public void setFrom(java.lang.String from)
VerifyRequest.Builder to create a 2FA verification requestfrom - the short alphanumeric string to specify the SenderID for SMS sent by Verify.VerifyRequest.Builder.senderId(String)public VerifyRequest.Workflow getWorkflow()
public void setWorkflow(VerifyRequest.Workflow workflow)
VerifyRequest.Builder to create a 2FA verification requestworkflow - The workflow to use for conveying the PIN to your user.Builder#workflow(Workflow)public java.lang.String toString()
toString in class BaseRequestpublic static VerifyRequest.Builder builder(java.lang.String number, java.lang.String brand)