Build WhatsApp integrations fast with ChatArchitect API

Easily connect your systems to WhatsApp using our REST API — send and receive messages, track delivery statuses, and manage templates.

1. Introduction

ChatArchitect provides a simple and reliable API to integrate WhatsApp messaging into your systems, apps, or CRMs. You can send text, media, and interactive messages, track statuses, manage templates, and store custom data — all with simple HTTPS requests.

2. Quickstart

  1. Authenticate with your credentials: Use your APP_ID and APP_SECRET via Basic Auth.
  2. Register your webhook
Example >>>
POST https://api.chatarchitect.com/webhook
Authorization: Basic <base64(APP_ID:APP_SECRET)>
Content-Type: application/json

{
  "channel": "whatsapp",
  "destination": "96996999699",
  "webhook": "https://your-server.com/webhook",
  "webhook_separate": "false"
}

 

  1. Send your first message
Example >>>
POST https://api.chatarchitect.com/whatsappmessage
Authorization: Basic <base64(APP_ID:APP_SECRET)>
Content-Type: application/json

{
  "channel": "whatsapp",
  "destination": "96996999699",
  "payload": {
    "type": "text",
    "message": "Hi John, how are you?"
  }
}

 

  1. Receive delivery updates via Webhook
Example >>>
{
  "type": "message-event",
  "payload": {
    "id": "ee4a68a0-1203-4c85-8dc3-49d0b3226a35",
    "type": "delivered"
  }
}

3. Supported Message Types

Type Description Example Field
text Simple text message message
image Send images (JPG/PNG) originalUrl
audio Send audio (MP3/OGG/AAC) url
video Send videos (MP4) url, caption
file Send documents filename, caption
location Send GPS coordinates latitude, longitude
contact Send contact info contact
list / quick_reply Interactive messages options

4. Message Templates (HSM)

Templates are required for business-initiated messages. Retrieve or create templates easily via API.

  1. Retrieve available templates
Example >>>
POST https://api.chatarchitect.com/getHSM
Authorization: Basic <base64(APP_ID:APP_SECRET)>
{
  "channel": "whatsapp",
  "destination": "96996999699",
  "getHSM": "true"
}

 

  1. Submit a new template
Example >>>
POST https://api.chatarchitect.com/submit_template
{
  "channel": "whatsapp",
  "destination": "96996999699",
  "submit_template": {
    "elementName": "welcome_offer",
    "languageCode": "en_US",
    "category": "MARKETING",
    "templateType": "TEXT",
    "content": "Welcome {{1}}! Your discount code is {{2}}.",
    "example": "Welcome [John]! Your discount code is [12345]."
  }
}

5. Webhooks & Events

Event Type Description
message New incoming messages
message-event Delivery statuses (sent, delivered, read, failed)
user-event User opt-in / opt-out

6. Example Code Snippets

Node.js

import fetch from "node-fetch";
const auth = Buffer.from(`${APP_ID}:${APP_SECRET}`).toString("base64");

await fetch("https://api.chatarchitect.com/whatsappmessage", {
  method: "POST",
  headers: { "Authorization": `Basic ${auth}`, "Content-Type": "application/json" },
  body: JSON.stringify({
    channel: "whatsapp",
    destination: "96996999699",
    payload: { type: "text", message: "Hi John!" }
  })
});


Python

import requests, base64
auth = base64.b64encode(f"{APP_ID}:{APP_SECRET}".encode()).decode()
r = requests.post(
  "https://api.chatarchitect.com/whatsappmessage",
  headers={"Authorization": f"Basic {auth}", "Content-Type": "application/json"},
  json={"channel": "whatsapp", "destination": "96996999699", "payload": {"type": "text", "message": "Hi John!"}}
)
print(r.json())