whatsapp/authentication
WhatsApp/authentication
templates let companies deliver WA approved one-time-password button. Unlike other templates the body is preset by WhatsApp. Some modifications can be made by specifying certain parameters however custom authentication templates are not allowed.
- When sending
whatsapp/authentication
templates a single variable must be defined at send time and set to the one time passcode. - whatsapp/authentication templates must be approved by WhatsApp to send to customers.
Supported Channels
Message Preview
Data Parameters
add_security_recommendation: Type - boolean Required - no Variable Support - no Description - Optional field to add the message "For your security, do not share this code" or the translated language's equivalent. This field defaults to TRUE. |
code_expiration_minutes: Type - integer Required - no Variable Support - no Description - The amount of time you want to inform the customer that the one time passcode is available for. Adds a footer message stating "This code expires in x minutes" where x is the number specified.
|
actions: Type - array[actions] Required - yes Variable Support - See Common Components: Actions definition Description - Buttons that recipients can tap on to act on the message:
|
Send WA Authentication Templates Created with Content Templates
Authentication templates are slightly different from other content types in that the body field is preset and there is a pre-existing content variable.
To send these templates you will need to send them as usual but include a content variable containing the OTP code you would like to send.
The OTP code that you send must be less than 15 characters long.
--data-urlencode "ContentVariables={"1": "12345"}" \
Need some help?
We all do sometimes; code is hard. Get help now from our support team, or lean on the wisdom of the crowd by visiting Twilio's Stack Overflow Collective or browsing the Twilio tag on Stack Overflow.