Survey A/B Testing
Professional workspaces can run A/B tests across two to five survey variants through the API, with traffic allocation, variant assignment, and results carrying a p-value from a two-proportion z-test against a configurable confidence level.
API-only — there is no dashboard UI, and the claim must say so. Two further limits to respect: test definitions live in survey.settings JSON rather than their own table (the same debt as the expert subsystem), and the endpoints have no test module. Do not describe A/B testing as a builder feature, and do not imply a results dashboard.
How the test is defined
The whole lifecycle, from the API
Create, start, stop, assign a respondent to a variant, read results, and delete. An API key scoped to surveys is all it needs.
# Create a test
curl -X POST "$BASE/api/v1/surveys/$SURVEY_ID/ab-tests" \
-H "Authorization: Bearer $API_KEY" \
-H "Content-Type: application/json" \
-d '{
"name": "Intro wording",
"target_confidence": 0.95,
"variants": [
{"id": "a", "name": "Control", "is_control": true, "traffic_percentage": 50},
{"id": "b", "name": "Shorter", "is_control": false, "traffic_percentage": 50}
]
}'
# Start it, then read results
curl -X POST "$BASE/api/v1/surveys/$SURVEY_ID/ab-tests/$TEST_ID/start" -H "Authorization: Bearer $API_KEY"
curl "$BASE/api/v1/surveys/$SURVEY_ID/ab-tests/$TEST_ID/results" -H "Authorization: Bearer $API_KEY"When A/B is the wrong tool
Related Resources
Ready to run decision-grade research?
Set up your first study in minutes, or talk through your research goals with our team.