Test send campaign
Requires campaigns:manage and campaigns:read because the test can use stored recipient samples. Sends one copy of a draft campaign’s content to a seed recipient, through the same rendering, sending and BanSafe checks as a launched campaign. The seed recipient must be a number connected to your team. The sending number must be connected, on a plan that includes Campaigns and, when the campaign selects numbers, one of them. A test is not a campaign recipient and is not counted in the campaign’s statistics or webhooks. A team can send 20 tests an hour, and at most 5 an hour to one seed recipient. 429 means one of these limits was reached or BanSafe is pacing the sending number; follow Retry-After. 409 bansafe_cold_held means the seed recipient has never written to the sending number and the campaign holds first messages. 409 state_conflict means the campaign is not a draft or has A/B or weighted content alternatives, the sending number is a Hybrid Link number, or the seed recipient opted out. 504 result_unknown means the outcome was not received in time and the test may still arrive. Send projectId in the body when using a team API key. 422 campaign_variables_missing means the test’s sample values, the mapped recipient value and the fallback all leave a variable in the campaign content empty.
Requires campaigns:manage and campaigns:read. Project tokens only access resources in their own project.
Authorizations
Send your team API key or project token as Authorization: Bearer <token>. The credential must have the required permissions. Project tokens can access only their own project.
Headers
Optional unique key, 1 to 255 bytes, that makes this request safe to retry for 24 hours. A retry with the same key, credential, Polymorfa-Version and request never runs it again: it returns 409 idempotency_completed when the original succeeded, or the original server error. Reusing the key for a different request returns 409 idempotency_conflict; a retry while the original is still running returns 409 idempotency_in_progress, and a retry after an unrecorded outcome returns 409 idempotency_outcome_unknown.
Value constraints
1 - 255Path Parameters
Identifier for the campaign.
Body
The number to send the test from. It must be connected, on a plan that includes Campaigns and, when the campaign selects numbers, one of them.
Value constraints
The seed recipient in international format. It must be the phone of a number connected to your team.
Value constraints
1 - 32"+5511999990000"
Required when using a team API key. Project tokens derive the project from the credential.
Value constraints
A recipient of this campaign whose variables fill the content. Without it and without variables, the campaign's first recipient, or its audience's first member, is the sample.
Value constraints
Variable values for the test. They override the sample recipient's values; without sampleRecipientId, only these values are used.
Value constraints
Response
Success
Structured data carried by this object.