Skip to content
Reference/Outgoing Messages/Send Template Message (V2)

Send Template Message (V2)

POSThttps://public.leadpattern.com/v2/whatsapp/message/template
WhatsApp Connectedapplication/json60 req/min

Send approved templates with named key-value placeholders instead of positional strings. Recommended for clarity. Each message item can also include an optional "scheduledAt" (ISO date-time) to send at a future time instead of immediately. Media headers use the same templateData.header shape as the v1 endpoint (type, mediaUrl, and — for a DOCUMENT header only — filename, e.g. "invoice.pdf", so WhatsApp shows a readable file name instead of a generic one).

  • v2 body placeholders are named — an array of { variableName: value } objects.
  • Supports carousel templates through content.templateData.cards.
  • Pass scheduledAt (future ISO date-time) to schedule instead of sending now.

Headers

1 field
Authorizationstring
required
Your API key. Sent raw (e.g. 'lp_...'). No Bearer prefix required.

Body Parameters

1 field
messagesarray of objects
required
Batch of template messages (non-empty).
tostring
required
Recipient phone number in E.164 format (with country code).
contentobject
required

Responses

JSON Response
{
  "type": "success",
  "data": {
    "messages": [
      {
        "status": "SENT",
        "recipient": "9195XXXXXXXX",
        "messageId": "wamid.abc123"
      }
    ]
  }
}

Sample Request Body

{
  "messages": [
    {
      "to": "+9195XXXXXXXX",
      "content": {
        "templateName": "order_confirmation",
        "language": "en",
        "templateData": {
          "body": {
            "placeholders": [
              {
                "name": "John"
              },
              {
                "order_id": "ORD-1234"
              }
            ]
          }
        }
      }
    }
  ]
}