Skip to main content
POST
Create A/B Test
Create a draft A/B test for a campaign in draft or rejected status, or convert a sequence email node into an A/B test step. Provide exactly one of campaignId or automationNodeId. Variant A (the control) is copied from the current email. A campaign or sequence node can have only one A/B test.

Request

campaignId
string
Campaign to attach the test to. Must be in draft or rejected status. Mutually exclusive with automationNodeId.
automationNodeId
string
Sequence action_email node to convert into an action_ab_test step. Mutually exclusive with campaignId. Requires at least one variants entry.
confirmLiveChange
boolean
Required as true when automationNodeId belongs to an active sequence. This acknowledges that the live sequence graph will change immediately.
name
string
Test name. Defaults to A/B Test for <campaign name>.
testPercentage
number
Share of the audience that receives test sends. Must be from 5 to 50. Defaults to 20.
testDurationMinutes
number
How long the test phase runs before a winner is selected. Must be from 15 to 1440. Defaults to 240.
winnerCriteria
string
Metric used to pick the winner: open_rate or click_rate. Defaults to open_rate.
testType
string
Sequence test type: subject or content. Subject tests use open_rate; content tests use click_rate. Defaults to content. Sequence tests only.
winnerThreshold
number
Number of sequence recipients in the test sample, from 10 to 1000. Defaults to 100. Sequence tests only.
variants
array
Extra variants beyond the control. Each item takes subject (required), previewText, and blocks. Total variants cannot exceed 5. Variants without blocks reuse the current email body. Optional for campaign tests; sequence conversions require at least one entry.

Responses