Skip to main content

abTestAddVariants

Appends variants to a DRAFT or RUNNING test; use abTestUpdateVariants to edit existing ones. On PATCH tests each new non-control variant needs a valid editorPatch. Screenshots of the new variants are queued, and RUNNING PATCH tests saved with createSnapshots also get per-variant snapshots. Requires A/B testing create access.

abTestAddVariants(
id: Int!
variants: [AbTestVariantInput!]!
): AbTest!

Arguments​

abTestAddVariants.id ● Int! non-null scalar​

Test id from abTestList, abTestRefList, or abTestCreate.

abTestAddVariants.variants ● [AbTestVariantInput!]! non-null input​

New variants appended in input order; the first variant of a test is assigned CONTROL, later ones VARIANT.

Type​

AbTest object​

A/B test settings and lifecycle returned by test lists, detail queries, and create/update operations. Metrics are populated by list queries; use abTestResultCounts for goal/date-scoped results.