RASL
RASL | DashboardContact
RASL | DashboardContact
Instagram
  1. Templates
RASL
  • Introduction
  • Messages
    • Overview
    • Message Bot Management
      • List Message Bots
      • Get Message Bots Details
    • Send Simple Message
      POST
    • Send Media Message
      POST
  • Templates
    • Overview
    • Template Management
      • Template Bot
        • List Template Bots
        • Get Template Bots Details
      • List Templates
      • Get Template Details
    • Send Authentication Template
      POST
    • Send Template Message
      POST
  • Contacts
    • Overview
    • Create a New Contact
      POST
    • List Contacts
      GET
    • Get Contact Details
      GET
    • Update Contact Information
      PUT
    • Delete Contact
      DELETE
  • Groups
    • Overview
    • Create Group
      POST
    • List Groups
      GET
    • Get Group Details
      GET
    • Update Group
      PUT
    • Delete Group
      DELETE
  • Statuses
    • Overview
    • Create Status
      POST
    • List Statuses
      GET
    • Get Status Details
      GET
    • Update Status
      PUT
    • Delete Status
      DELETE
  • Sources
    • Overview
    • Create Source
    • List Sources
    • Get Source Details
    • Update Source
    • Delete Source
  • Integrations
    • N8N Webhook Integration
    • Webhook Format Reference
    • eCommerce Webhook Integration
      • Webhook Listener
      • WooCommerce Webhook Setup
RASL | DashboardContact
RASL | DashboardContact
Instagram
  1. Templates

Send Template Message

POST
https://getrasl.io/api/v1/{tenant-name}/messages/template

Send a WhatsApp template message to a specific phone number with comprehensive parameter support and template validation. Optionally creates a contact if it doesn't exist.#

📌
Important | No 24-Hour Restrictions
Template messages can be sent at any time, regardless of the customer service window. Unlike simple text and media messages, approved templates are not restricted by Meta's 24-hour policy. They are the only message type that can be sent outside a customer service window, making them perfect for marketing campaigns, notifications, and re-engaging customers after extended periods of inactivity.

Request

Authorization
Bearer Token
Provide your bearer token in the
Authorization
header when making requests to protected resources.
Example:
Authorization: Bearer ********************
or
Path Params

Header Params

Body Params multipart/form-dataRequired

Request Code Samples

Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request POST 'https://getrasl.io/api/v1//messages/template' \
--header 'Authorization: Bearer <token>' \
--form 'phone_number="201XXXXXXXXX"' \
--form 'template_name="welcome_message"' \
--form 'template_language=""' \
--form 'from_phone_number_id=""' \
--form 'contact=""' \
--form 'header_image_url=""' \
--form 'header_image_file=@""' \
--form 'header_video_url=""' \
--form 'header_video_file=@""' \
--form 'header_document_url=""' \
--form 'header_document_file=@""' \
--form 'header_document_name=""' \
--form 'header_field_1=""' \
--form 'field_1=""' \
--form 'field_2=""' \
--form 'field_3=""' \
--form 'field_4=""' \
--form 'field_5=""' \
--form 'field_6=""' \
--form 'button_0=""' \
--form 'button_1=""' \
--form 'button_2=""' \
--form 'copy_code=""'

Responses

🟢200Success
application/json
Body

Example
{
  "status": "success",
  "message": "Template message sent successfully",
  "data": {
    "message_id": "wamid.HBgMOTE5ODEwNjAwMDAwFQIAERgSNUU1RjE4MUM0QjY5MjFFNzYzAA==",
    "contact_id": 15,
    "phone": "+201XXXXXXXXX",
    "template_name": "welcome_message",
    "template_language": "en",
    "status": "sent",
    "sent_at": "2024-02-08 14:30:25",
    "chat_id": 8,
    "contact_created": false,
    "parameters_used": {
      "header": [
        "Mahmoud"
      ],
      "body": [
        "25",
        "Mahmoud Elsayed",
        "Premium"
      ],
      "buttons": [
        "mahmoud@example.com"
      ]
    }
  }
}
🟠401Unauthenticated
🟠403Conversation Limit Reached
🟠404Template Not Found
🟠422Validation Errors
🔴500Whatsapp Api Error (Meta)
Previous
Send Authentication Template
Next
Overview
Built with