Authentication (OTP) Templates
Authentication templates always have a single body variable with param_name: 1. Pass the OTP code as variables.body["1"].
POST /v1/whatsapp/send// expected_variables.body:
// [ { "param_name": 1, "example": "123456" } ]cURL
curl -X POST https://api.bahasha.app/v1/whatsapp/send \
-H "Authorization: Bearer bh_live_xxxxxxxxxxxx" \
-H "Content-Type: application/json" \
-d '{
"to": "+254700000000",
"phone_number_id": "123456789",
"template_name": "your_otp_template",
"language_code": "en_US",
"variables": {
"body": { "1": "847291" }
}
}'Use webhooks to watch for sent and delivery events for OTP messages.