Campaigns
Send Campaigns
Trigger one or more campaign flows to multiple recipients with variables, versioning, and per-entry status reporting π©
POST
Send Campaigns
Endpoint
Request body
entries array (required)
Each object in entries represents one recipient. You can mix entries for different campaigns in the same request.
options object (optional)
sender string (optional)
The business channel to send from: your WhatsApp number in E.164 format or its phone number ID, or your RCS sender name to send over RCS. Omit it to use your default channel: a campaign whose flow is for RCS only sends from your RCS sender, and any other campaign sends on WhatsApp.
Campaigns with an A/B Split
You send a campaign that starts with an A/B Split the same way as any other campaign. The request has no variant field.- Connectly picks the variant. Each customer is assigned to a variant by the weights set on the split in the Flow Builder.
- The same customer always gets the same variant. The assignment is based on the customer, so sending again, in the same request or a later one, never moves them to another variant.
- Send the variables of every variant. Every entry must include all the variables used by any variant, because you donβt know in advance which variant the customer will get. If variant A uses
nameand variant B usesnameandcoupon, send both for every customer. - A missing or empty variable rejects the entry. That customer is not sent anything. The entry is counted in
rejectedCount, anderror.messagenames the variable (for exampleMissing required value for variable coupon). The other entries in the request still go out. - Variable values are strings. Send numbers and dates as strings, for example
"10", not10.
Campaigns that start with an A/B Split send on WhatsApp and on RCS alike.
Examples
Minimal entry β no variables
Minimal entry β no variables
The smallest valid entry. Use this for campaigns that have no variable placeholders.
Entry with variables
Entry with variables
Variables are defined in the campaign flow in the Connectly UI. Pass the same key names here.
Multiple campaigns in one request
Multiple campaigns in one request
Connectly creates a separate sendout for each unique
campaignName + campaignVersion combination. This request produces three sendouts: campaign_A at v1.0, campaign_A at its latest active version, and campaign_B at v1.0.Campaign with an A/B Split
Campaign with an A/B Split
promo_ab_test starts with an A/B Split. Variant A uses name, and variant B uses name and coupon. Every entry sends both, whichever variant the customer gets.Allow duplicate sends
Allow duplicate sends
By default, the API prevents sending the same campaign to the same customer twice. Override with
allow_multiple for use cases like recurring alerts.Response
The API always returns HTTP200 with a data array. Each element corresponds to a unique campaignName + campaignVersion sendout generated by the request.
If you call the API again for the same campaign and recipient group,
status returns "updated" rather than "created" β no duplicate sendout is created.Error responses
Entry-level errors appear inside thedata array with status: "error" β they donβt cause the whole request to fail. HTTP-level errors indicate request-wide failures.
Campaign not found
Campaign not found
Campaign version not found
Campaign version not found
Missing or invalid variables
Missing or invalid variables
Triggered when required flow variables are absent or the entry payload is otherwise invalid.
Rate limiting
This endpoint is limited to 200 requests per second. Exceeding this returns HTTP429 Too Many Requests. Use exponential backoff in your client if you expect high-volume sendouts.