Send one text or WhatsApp message as the business (sms:write). Email goes out through POST /v1/email-campaigns.

One send endpoint for texts and WhatsApp. sms goes out from the agent's own line (from_agent_id required) with the same gates and error codes as POST /v1/sms/send. whatsapp goes out from the business's number connected to WhatsApp (pass from when there is more than one) and only inside the 24-hour window after the customer last messaged that number; WhatsApp consent and Do-Not-Call are checked first. Email is not sent here: channel email is 400 use_email_campaigns. API email goes out as a campaign the business owner reviews and approves, through POST /v1/email-campaigns. Send Idempotency-Key (or idempotency_key) to make a retry return the original send (replayed: true) instead of sending again; the same key with a different message is 409 idempotency_conflict. New keyed WhatsApp sends claim a durable intent before dispatch; concurrent or uncertain replays never dispatch again. A 409 message_outcome_unknown requires reconciliation, not a new key. Pre-existing lost receipts cannot be recovered. 503 idempotency_unavailable means reservation or replay evidence could not be verified. A 200 means the provider accepted the message, not that it was delivered.

post/v1/messages

Request

  • Base URL: https://www.kaicalls.com/api
  • URL: https://www.kaicalls.com/api/v1/messages
  • Auth: HTTP bearer

Headers

Idempotency-Keystring

Request body

channel'sms' | 'whatsapp' required

email is refused with 400 use_email_campaigns.

tostring required

E.164 phone number.

bodystring required

Alias: message.

business_idstring uuid

Required when the API key reaches more than one business.

from_agent_idstring uuid

sms only, required there.

fromstring

whatsapp only: the business's connected WhatsApp number.

lead_idstring uuid
idempotency_keystring

Response

Accepted by the provider.

idstring required
channel'sms' | 'whatsapp' required
status'sent' | 'queued' required
tostring required
fromstring required
providerstring
replayedboolean

Changes

No recorded changes to this operation across all 1 revision of this API.