POST /api/campaigns/{id}/send Trigger delivery of a campaign. Optionally schedule it for a future time by providing a scheduledAt timestamp.

Headers

appid
string
required
Your CometChat App ID.
apikey
string
required
Your CometChat API Key.

Path parameters

id
string
required
The campaign ID to send.

Request body

scheduledAt
string
Optional ISO 8601 timestamp for scheduled delivery. If omitted, delivery starts immediately.

Example request

curl -X POST https://{appId}.api-{region}.cometchat.io/v3/business-messaging/api/campaigns/666c3d4e5f6a7b8c9d0e1f2a/send \
  -H "appid: YOUR_APP_ID" \
  -H "apikey: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'

Example response

{
  "id": "666c3d4e5f6a7b8c9d0e1f2a",
  "status": "sending",
  "scheduledAt": null,
  "updatedAt": "2024-01-16T10:00:00.000Z"
}
When scheduledAt is provided, the campaign status changes to scheduled instead of sending. Delivery begins automatically at the scheduled time.
The campaign’s linked template must be in approved status. The campaign must have at least one recipient added before sending.