Hibot Copy Code Authentication Templates for WhatsApp Business API
- Bot Automation

- Apr 7
- 4 min read
Copy code authentication templates in Hibot WhatsApp Business API let businesses send one-time passwords (OTP) or verification codes directly through WhatsApp. Users simply tap the Copy Code button, and the code is copied to their clipboard automatically.
They can then return to your app or website and paste the verification code instantly.
This makes copy code templates one of the easiest and most reliable ways to deliver OTPs through WhatsApp.
What Are Copy Code Authentication Templates?
A copy code authentication template contains:
A fixed verification message
An optional security warning
An optional expiration timer
A Copy Code button
The WhatsApp message appears like this:
123456 is your verification code.
For your security, do not share this code.
This code expires in 5 minutes.
Copy Code button
When the user taps the button, WhatsApp copies the code automatically to the device clipboard.
Why Use Copy Code Authentication Templates?
Businesses use copy code templates because they:
Improve OTP completion rates
Reduce typing errors
Speed up login and signup verification
Work across Android and iPhone devices
Require no custom app integration
Unlike Zero-Tap or One-Tap Autofill templates, Copy Code templates work even if your users do not have your mobile app installed.
Limitations of Copy Code Templates
Before creating a template, keep these limitations in mind:
URLs are not supported
Media files are not supported
Emojis are not supported
Only plain verification text and the copy code button can be used
Create a Copy Code Authentication Template in Hibot
Use the WhatsApp Business Account message_templates endpoint to create your authentication template.
curl 'https://graph.facebook.com/v25.0/WHATSAPP_BUSINESS_ACCOUNT_ID/message_templates' \
-H 'Content-Type: application/json' \
-H 'Authorization: Bearer ACCESS_TOKEN' \
-d '
{
"name": "authentication_code_copy_code_button",
"language": "en_US",
"category": "authentication",
"message_send_ttl_seconds": 60,
"components": [
{
"type": "body",
"add_security_recommendation": true
},
{
"type": "footer",
"code_expiration_minutes": 5
},
{
"type": "buttons",
"buttons": [
{
"type": "otp",
"otp_type": "copy_code",
"text": "Copy Code"
}
]
}
]
}'
Important Template Fields
Template Name
The template name must be unique inside your WhatsApp Business Account.
Example:
verification_code
Maximum length: 512 characters.
Language
Choose the template language and locale.
Example:
en_US
Security Recommendation
You can optionally display the message:
For your security, do not share this code.
To enable it:
"add_security_recommendation": true
Code Expiration
You can show when the OTP expires.
Example:
"code_expiration_minutes": 5
Allowed range:
Minimum: 1 minute
Maximum: 90 minutes
Copy Code Button Text
You can customize the button label.
Example:
"text": "Copy Code"
Maximum length: 25 characters.
If you do not provide a label, WhatsApp automatically uses a localized default.
Example Successful Response
After creating the template, Hibot returns a pending approval response.
{
"id": "594425479261596",
"status": "PENDING",
"category": "AUTHENTICATION"
}
Once approved, you can begin sending the template to customers.
Send a Copy Code Authentication Template
After approval, use the WhatsApp messages endpoint to send the OTP.
curl -L 'https://graph.facebook.com/v25.0/WHATSAPP_BUSINESS_PHONE_NUMBER_ID/messages' \
-H 'Content-Type: application/json' \
-H 'Authorization: Bearer ACCESS_TOKEN' \
-d '{
"messaging_product": "whatsapp",
"recipient_type": "individual",
"to": "12015553931",
"type": "template",
"template": {
"name": "verification_code",
"language": {
"code": "en_US"
},
"components": [
{
"type": "body",
"parameters": [
{
"type": "text",
"text": "J$FpnYnP"
}
]
},
{
"type": "button",
"sub_type": "url",
"index": "0",
"parameters": [
{
"type": "text",
"text": "J$FpnYnP"
}
]
}
]
}
}'
Important: The OTP value must appear twice:
Once in the message body
Once inside the button parameter
Example API Response
{
"messaging_product": "whatsapp",
"contacts": [
{
"input": "12015553931",
"wa_id": "12015553931"
}
],
"messages": [
{
"id": "wamid.HBgLMTY1MDM4Nzk0MzkVAgARGBI4Qzc5QkNGNTc5NTMyMDU5QzEA"
}
]
}
The returned message ID can be used to track delivery and read status.
Understanding the “I Didn’t Request a Code” Button
Hibot also supports the optional “I didn’t request a code” button.
This feature is currently in beta and is gradually rolling out.
If a customer taps this button, your webhook receives an event so you can:
Detect possible fraud attempts
Alert the customer
Block suspicious login attempts
Trigger additional verification
Example webhook payload:
{
"button": {
"payload": "DID_NOT_REQUEST_CODE",
"text": "I didn't request a code"
}
}
Sample Webhook for “I Didn’t Request a Code”
{
"object": "whatsapp_business_account",
"entry": [
{
"changes": [
{
"value": {
"messages": [
{
"type": "button",
"button": {
"payload": "DID_NOT_REQUEST_CODE",
"text": "I didn't request a code"
}
}
]
}
}
]
}
]
}
Best Practices for Copy Code Authentication Templates
To improve OTP success rates:
Keep codes short and easy to paste
Set expiration between 3 and 10 minutes
Always enable the security recommendation
Send OTPs only after explicit user action
Avoid making WhatsApp your only verification method
Provide SMS or email fallback if WhatsApp delivery fails
Recommended OTP examples:
482913
A8K4P7
Maximum OTP length: 15 characters.
Copy Code vs One-Tap vs Zero-Tap
Feature | Copy Code | One-Tap Autofill | Zero-Tap |
Works on Android | Yes | Yes | Yes |
Works on iPhone | Yes | No | No |
Requires app integration | No | Yes | Yes |
Requires manual user action | Yes | Minimal | No |
Best for websites | Yes | No | No |
Best for mobile apps | Good | Better | Best |
If your users are primarily on websites or multiple devices, Copy Code templates are usually the safest and most compatible option.
Why Businesses Choose Hibot Copy Code Templates
With Hibot WhatsApp Business API, businesses can:
Send OTPs instantly through WhatsApp
Improve verification success rates
Reduce customer login friction
Secure accounts with fast code delivery
Track delivery through message IDs and webhooks
Copy Code authentication templates are ideal for:
User registration
Login verification
Password reset
Two-factor authentication
Payment confirmation
Secure account recovery
Final Thoughts
Copy Code authentication templates are the easiest way to deliver secure OTPs through Hibot WhatsApp Business API.
They work across Android and iPhone, require no app integration, and provide a fast user experience with a simple tap-to-copy action.
If you want reliable and widely supported WhatsApp authentication, Copy Code templates are the best place to start.
.png)
Comments