sendRemainingDelay, evaluates the selected engagement metric, and sends the remaining audience to the winning variant.testGroupRatio is the percentage of the test sample assigned to variant A; variant B receives the remainder. The same ratio is used for the remaining audience when no statistically significant winner can be determined.condition selects the engagement metric and accepts only:open — evaluate unique email opens.click — evaluate unique email clicks.na and nb be the number of emails sent to variants A and B, and xa and xb the corresponding number of opens or clicks. The formulas compare engagement rates and account for unequal group sizes through 1/na + 1/nb:xa >= na * (xb / nb) + Z * na * sqrt((xb / nb) * (1 - xb / nb) * (1 / nb + 1 / na)).xb >= nb * (xa / na) + Z * nb * sqrt((xa / na) * (1 - xa / na) * (1 / na + 1 / nb)).xa and xb is at least 50. Z is 3 when the smaller engagement count is between 50 and 99, and 2 when it is at least 100. If neither formula identifies a winner, the response uses winner: "UNDETERMINED" and the remaining audience may be sent to both variants in the configured ratio.curl --location --request PUT '/smartflows//actions/abtest/' \
--header 'Authorization: Bearer JWT' \
--header 'Content-Type: application/json' \
--data '{
"name": "Custom activity name",
"testGroupRatio": 40,
"condition": "click",
"sendRemainingDelay": {
"value": 24,
"unit": "minute"
},
"variantA": {
"campaignUuid": "500507ea-7e8b-4c1f-87c4-87fa7a0cb4e0",
"subject": "Save 10% today"
},
"variantB": {
"campaignUuid": "67010573-d552-498f-be4e-2f95158fda0b",
"subject": "Your exclusive discount"
}
}'{
"data": {
"activityId": "4a06896c-81b3-44f4-b493-2057bef951a2",
"smartflowId": "4a06896c-81b3-44f4-b493-2057bef951a2",
"ancestorId": "4a06896c-81b3-44f4-b493-2057bef951a2",
"campaignId": "4a06896c-81b3-44f4-b493-2057bef951a2",
"testGroupRatio": 40,
"condition": "clicks",
"metrics": {
"groupA": 123,
"groupB": 60
},
"sendRemainingDelay": {
"value": 24,
"unit": "minute"
},
"campaignUuidA": "500507ea-7e8b-4c1f-87c4-87fa7a0cb4e0",
"campaignUuidB": "67010573-d552-498f-be4e-2f95158fda0b",
"subjectA": "Save 10% today",
"subjectB": "Your exclusive discount"
},
"validation": {
"severity": "warn",
"message": "Missing something",
"fields": {
"campaignUuidA": {
"severity": "warn",
"message": "Missing"
},
"campaignUuidB": {
"severity": "warn",
"message": "Missing"
}
}
}
}