Skip to content

Variant

A Variant is one value an Experiment can assign, such as a revision, a Price on a sibling Offer, or a prompt, with its lineage.

Properties

PropertyTypeRequiredDescription
keystringrequiredThe name the Flag returns for it.
valuejsonrequiredWhat it changes: copy, behavior, a definition Version, or a Thing.
controlbooleanTrue for the current definition every challenger is judged against.
followsVariantThe Variant it was drafted from by a learn step.

Object

JSON
{
  "$id": "https://api.sb/shiftnote.app/variants/variant_1",
  "$type": "Variant",
  "key": "Example key",
  "value": {},
  "control": true,
  "follows": "variant_1"
}

Relationships

  • A Variant has many Exposures: the Variant the Flag assigned to this unit. exposures, inverse meets.
  • A Variant is offered by one Experiment: the Variants the Experiment can assign, the control among them. offeredBy, inverse offers.
  • A Variant is scored by many Readouts: the Variant the number describes. scoredBy, inverse scores.

Verbs

  1. createCreates a Variant.
    POST /{namespace}/variantsdoVariant.created
  2. getReturns one Variant by id.
    GET /{namespace}/variants/{id}readNo Event
  3. listReturns Variants, newest first, one page at a time.
    GET /{namespace}/variantsreadNo Event
  4. updateChanges the given properties of a Variant.
    PATCH /{namespace}/variants/{id}doVariant.updated
  5. deleteDeletes a Variant; its history is kept.
    DELETE /{namespace}/variants/{id}doVariant.deleted

Permissions

Which Access level may call each Verb. One-way Verbs wait their delay window.

Operationowneradminmemberviewer
Variant.createYesYesYesNo
Variant.getYesYesYesYes
Variant.listYesYesYesYes
Variant.updateYesYesYesNo
Variant.deleteYesYesYesNo

Call it

Text
Add a variant to RouteWise.

Example

A bakery tests two Variants of its pickup button behind one Flag: the control reads Pick up today, and the challenger reads Hold my loaf. The challenger follows the control.