Launch a campaign
Start a draft campaign: every pending contact is queued once. Needs at least one contact, unless the campaign's data_source is webhook. The plan's monthly broadcast allowance and the wallet balance are checked here. Idempotency-Key is required, so a retry does not start it twice.
Set up WhatsApp first. Connect a WhatsApp number in the dashboard or with Connect numbers. Included on every paid plan. See plans.
campaign_idrequiredcurl -X POST 'https://backend.omnidim.io/api/v1/whatsapp/campaigns/{campaign_id}/launch' \ -H 'Authorization: Bearer YOUR_API_KEY'
{ "id": 0, "name": "string", "status": "draft", "pause_reason": "human", "campaign_mode": "broadcast", "send_mode": "review", "data_source": "csv", "is_dynamic": false, "phone_number_id": 0, "template": { "id": 0, "name": "string" }, "agent_id": 0, "variable_mapping": "string", "counts": { "total": 0, "sent": 0, "delivered": 0, "read": 0, "replied": 0, "failed": 0, "skipped": 0, "opted_out": 0 }, "receipts_reported": false, "delivery_rate": 0, "read_rate": 0, "reply_rate": 0, "spend": { "amount": 0, "currency": "USD" }, "created_at": "string", "enqueued": 0 }
BearerAuthAuthorizationBearer <token>Bearer token authentication. Obtain your API key from the OmniDimension dashboard.
campaign_id*integerId of a WhatsApp campaign, from listWhatsappCampaigns.
Idempotency-Key*stringA unique string you choose, up to 255 characters. Required on this
route. The same key with the same body replays the first answer for
24 hours instead of acting twice. A different body with the same key
answers 409.
length <= 255Response body
application/jsonThe campaign, with the number of contacts queued.
application/jsonid?integername?stringstatus?string"draft""scheduled""in_progress""paused""completed""failed""cancelled"pause_reason?stringWhy it paused, or null. Only human waits for you; the rest resume on their own.
"human""balance""channel_down""monthly_limit"campaign_mode?string"broadcast""broadcast_reply"send_mode?string"review""on_arrival"data_source?string"csv""webhook"is_dynamic?booleanphone_number_id?integertemplate?agent_id?integerThe agent that answers replies, when one is attached.
variable_mapping?Template field to contact field or static text.
counts?receipts_reported?booleanThis number reports delivery and read receipts, so the rates are real.
delivery_rate?numberDelivered as a percentage of sent. Null when receipts are not reported.
read_rate?numberRead as a percentage of delivered. Null when receipts are not reported.
reply_rate?numberReplied as a percentage of sent.
spend?What the campaign cost so far. Null without billing access.
created_at?stringenqueued?integerAdd campaign contacts
Add one contact, or up to 500 at once. On a draft they are stored for launch. On a running campaign they are sent now. A contact already in the campaign is skipped, so a retry is safe. Each contact needs a phone_number; every other key is kept and can fill a template parameter through variable_mapping.
Pause a campaign
Stop sending until you resume. Only a running campaign can be paused. A pause you make by hand is never resumed automatically.
