APIMASTERDevelopersHelp centerOpen app

API reference

Base URL https://app.apimaster.in. All requests need Authorization: Bearer am_live_…. Machine-readable spec: openapi.json (OpenAPI 3.1).

GET/v1/public/me

Who am I

Responses

200Organisation and key scopes
401Missing, invalid or revoked API key
402No active subscription
403Scope missing or plan has no API access
429Rate limited (120 requests/minute per key)
curl -X GET https://app.apimaster.in/v1/public/me \
  -H "Authorization: Bearer $APIMASTER_KEY"

GET/v1/public/templates

List approved templates — Scope: templates:read

Responses

200Approved templates
401Missing, invalid or revoked API key
402No active subscription
403Scope missing or plan has no API access
429Rate limited (120 requests/minute per key)
curl -X GET https://app.apimaster.in/v1/public/templates \
  -H "Authorization: Bearer $APIMASTER_KEY"

GET/v1/public/contacts

Find a contact by WhatsApp number — Scope: contacts:read

Parameters

NameInTypeRequired
wa_idquerystring (^[1-9]\d{7,14}$)yes

Responses

200Contact
401Missing, invalid or revoked API key
402No active subscription
403Scope missing or plan has no API access
404Not found
429Rate limited (120 requests/minute per key)
curl -X GET https://app.apimaster.in/v1/public/contacts?wa_id=919812345678 \
  -H "Authorization: Bearer $APIMASTER_KEY"

POST/v1/public/contacts

Create or update a contact (optionally recording consent) — Scope: contacts:write. Consent requires evidence and never overrides a customer STOP.

Request body

FieldTypeRequired
wa_idstringyes
namestringno
emailstringno
tagsstring[]no
consentobject { utility, marketing, evidence }no

Responses

201Created/updated
401Missing, invalid or revoked API key
402No active subscription
403Scope missing or plan has no API access
429Rate limited (120 requests/minute per key)
curl -X POST https://app.apimaster.in/v1/public/contacts \
  -H "Authorization: Bearer $APIMASTER_KEY" \
  -H "Content-Type: application/json" \
  -d '{"wa_id":"919812345678","name":"Asha (demo)"}'

POST/v1/public/messages

Send a message — Scope: messages:send. text is allowed only inside the 24-hour customer service window; otherwise send an approved template. Templates require recorded consent for their category.

Request body

FieldTypeRequired
tostringyes
textstringno
templateobject { name, language, variables }no
{
  "to": "+919812345678",
  "template": {
    "name": "order_shipped",
    "language": "en",
    "variables": [
      "Asha",
      "AM-2041"
    ]
  }
}

Responses

202Queued
401Missing, invalid or revoked API key
402No active subscription
403Scope missing or plan has no API access
404Contact not found — create it first
422Policy violation (window, consent, template)
429Rate limited (120 requests/minute per key)
curl -X POST https://app.apimaster.in/v1/public/messages \
  -H "Authorization: Bearer $APIMASTER_KEY" \
  -H "Content-Type: application/json" \
  -d '{"to":"+919812345678","template":{"name":"order_shipped","language":"en","variables":["Asha","AM-2041"]}}'

GET/v1/public/messages/{id}

Message status — Scope: messages:read

Parameters

NameInTypeRequired
idpathstringyes

Responses

200Message
401Missing, invalid or revoked API key
402No active subscription
403Scope missing or plan has no API access
404Not found
429Rate limited (120 requests/minute per key)
curl -X GET https://app.apimaster.in/v1/public/messages/<message-id> \
  -H "Authorization: Bearer $APIMASTER_KEY"

Schemas

Error

errorobject

Contact

idstring
wa_idstring
namestring | null
emailstring | null
tagsstring[]
consent_utilityboolean
consent_marketingboolean
opted_out_atstring | null

Message

idstring
direction"in" | "out"
typestring
bodystring | null
status"received" | "queued" | "sent" | "delivered" | "read" | "failed"
error_codestring | null
wa_message_idstring | null

WebhookEvent

idstring
event"message.received" | "message.sent" | "message.status"
created_atstring
dataobject