/auth/send-otp.messages:send| Field | Type | Required | Validation | Description |
|---|---|---|---|---|
phone | string | Yes | Phone number to resend OTP to | |
template_name | string | Yes | Authentication template name | |
language | string | No | max:10 | Template language code (default: en) |
expiry_minutes | integer | No | min:1, max:60 | Code expiry time in minutes (default: 10) |
purpose | string | No | max:50 | OTP purpose (default: authentication) |
otp-resend:{tenant_id}:{phone}retry_after seconds when limit exceeded/auth/send-otp (success with message_id, contact_id, phone, expiry info, etc.)| Status | Error Code | Description |
|---|---|---|
| 401 | UNAUTHORIZED | Invalid or missing API token |
| 403 | INSUFFICIENT_SCOPE | Token missing messages:send scope |
| 422 | VALIDATION_ERROR | Request validation failed |
| 429 | RATE_LIMIT_EXCEEDED | Too many resend attempts (3 per 5 min) |
| 500 | INTERNAL_ERROR | Unexpected server error |
/auth/send-otp also apply (template not found, not AUTHENTICATION category, WhatsApp not configured, etc.)| Field | Message |
|---|---|
phone | Phone number is required |
template_name | Template name is required |
curl --location --request POST '/auth/resend' \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data-raw '{
"phone": "+919999999999",
"template_name": "otp_verification",
"language": "en",
"expiry_minutes": 10,
"purpose": "authentication"
}'{}