Package com.vonage.client.verify
Class VerifyRequest.Builder
java.lang.Object
com.vonage.client.verify.VerifyRequest.Builder
- Enclosing class:
- VerifyRequest
public static class VerifyRequest.Builder extends java.lang.Object
Builder to create a Two Factor Authentication request
- Since:
- 5.5.0
-
Constructor Summary
Constructors Constructor Description Builder(java.lang.String number, java.lang.String brand) -
Method Summary
Modifier and Type Method Description VerifyRequestbuild()VerifyRequest.Buildercountry(java.lang.String country)The country for the destination phone number.VerifyRequest.Builderlength(java.lang.Integer length)VerifyRequest.Builderlocale(java.util.Locale locale)VerifyRequest.BuildernextEventWait(java.lang.Integer nextEventWait)VerifyRequest.BuilderpinExpiry(java.lang.Integer pinExpiry)VerifyRequest.BuildersenderId(java.lang.String senderId)VerifyRequest.Buildertype(VerifyRequest.LineType type)VerifyRequest.Builderworkflow(VerifyRequest.Workflow workflow)Set the predefined sequence of SMS and TTS (Text To Speech) actions to use in order to convey the PIN to your user.
-
Constructor Details
-
Method Details
-
senderId
- Parameters:
senderId- the short alphanumeric string to specify the SenderID for SMS sent by Verify.- Returns:
VerifyRequest.Builder
-
type
- Parameters:
type- the type of network the verification will be restricted to. This value has no effect unless it has been enabled by contactingsupport@nexmo.com.- Returns:
VerifyRequest.Builder
-
workflow
Set the predefined sequence of SMS and TTS (Text To Speech) actions to use in order to convey the PIN to your user. See https://developer.vonage.com/verify/guides/workflows-and-events- Parameters:
workflow- The workflow to use for conveying the PIN to your user.- Returns:
VerifyRequest.Builder
-
locale
- Parameters:
locale- (optional) Override the default locale used for verification. By default the locale is determined from the country code included innumber- Returns:
VerifyRequest.Builder
-
length
- Parameters:
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.- Returns:
VerifyRequest.Builder
-
pinExpiry
- Parameters:
pinExpiry- (optional) the PIN validity time from generation, in seconds. Default is 300 seconds- Returns:
VerifyRequest.Builder
-
nextEventWait
- Parameters:
nextEventWait- (optional) the wait time between attempts to deliver the PIN. A number between 600-900.- Returns:
VerifyRequest.Builder
-
country
The country for the destination phone number.If you wish to used localised number formats or you are not sure if number is correctly formatted, set this to a two-character country code. For example, GB, US. Verify will work out the international phone number for you.
- Parameters:
country- a String containing a 2-character country code- Returns:
VerifyRequest.Builder
-
build
-