Skip to main content
PATCH
Update Experiment

Authorizations

Authorization
string
header
required

An Account API key, account-scoped JWT, App API key, or user OAuth token. Prepend the key or token with Bearer, for example Bearer ***************************.

Headers

Api-Version-Date
string

Pins the request to a dated API version.

Example:

"2026-09-11"

Path Parameters

id
string
required

The experiment identifier — the expt_ id or the flag_key handle.

Query Parameters

account_id
string

Owning account or internal. Required when id is a flag key; optional for an expt_ ID.

Body

application/json
control
object
hypothesis
string | null

Omit to leave unchanged. Send an empty string to clear it. Not accepted on feature flags. When setting it, structure it as "If we [change] for [cohort], then [measurable behavior] will [increase/decrease], resulting in [business outcome], because [evidence]. Created by [name]." same as on create.

Example:

"If we send a blueprint nudge email 30 minutes after business creation, then GTV within 10 hours will increase among newly created businesses, resulting in more new business operators generating GTV within 10 hours, because operators currently land on an empty dashboard with no concrete next step. Created by Jane Doe."

targeting_rules
object[]

Replace the targeting rules with this set. Omit to leave unchanged.

variants
object[]

Grow treatment allocation. Pass every existing treatment with an equal-or-higher weight; append new names to add arms. Weights never decrease and arms are never removed. Omit to leave unchanged.

Response

metrics added

account_id
string
required

Owning account ID, or internal for Whop platform experiments.

Example:

"internal"

assignment_seed
string
required

Assignment hashes UTF-8 seed + subject ID with CRC32 modulo 100 and selects the stored end-exclusive range.

Example:

"verb_end_exp1768435200"

configuration_revision
integer
required

Revision of the serving configuration. Does not change the assignment seed.

Example:

2

control
object
required
flag_key
string
required

Developer-chosen handle referenced from code. Anywhere the API takes an experiment identifier, the expt_ id and the flag_key are interchangeable.

Example:

"verb_end_exp"

id
string
required

Unique identifier for the experiment, prefixed expt_.

Example:

"expt_xxxxxxxxxxxxxx"

name
string
required

Human-readable display name.

Example:

"Verb End"

status
enum<string>
required

Lifecycle state. draft — not yet live; active — currently running; paused — traffic paused; ended — concluded.

Available options:
draft,
active,
paused,
ended
Example:

"ended"

targeting_rules
object[]
required

Rules gating who is in the experiment at all. Conditions within a rule are AND-ed, rules are OR-ed, and exclude rules always win. Empty means everyone qualifies.

updated_at
string<date_time> | null
required
Example:

"2026-01-01T12:00:00.000Z"

variants
object[]
required

Treatment arms. Users outside every arm's allocation form the implicit control group. Weights only ever grow and arms are never removed, so a user moves from control into a treatment at most once.

bucket_by
enum<string> | null

Randomization unit — user buckets each user independently, account buckets whole accounts (every user of an account gets the same arm). null for feature flags.

Available options:
user,
account,
anonymous
Example:

"user"

created_at
string | null

When the experiment was created, as an ISO 8601 timestamp.

Example:

"2026-01-01T12:00:00.000Z"

created_by
string | null

ID of the user who created the experiment, prefixed user_. null for experiments created before creators were recorded.

Example:

"user_xxxxxxxxxxxxxx"

ended_at
string | null

When the experiment stopped collecting data, as an ISO 8601 timestamp. null while still running.

Example:

"2026-01-01T12:00:00.000Z"

feature_flag_only
boolean | null

true when this was created as a feature flag rather than a full experiment. Feature flags share the same evaluation API but do not collect metric results.

Example:

false

findings
string | null

What was learned and why this outcome, recorded when the experiment was ended. null until then.

Example:

"Treatment lifted conversion 8%"

hypothesis
string | null

Hypothesis for this experiment. null when none is set, and always null for feature flags.

Example:

"Users will convert more"

started_at
string | null

When the experiment began collecting data, as an ISO 8601 timestamp. null for drafts.

Example:

"2026-01-01T12:00:00.000Z"

winning_arm
string | null

The treatment that won, set when the experiment was ended. Once set, every evaluation returns this arm to every caller regardless of targeting or allocation, and no further exposures are recorded. null means control won — an ended experiment with no winning arm evaluates to control for everyone. Always null for feature flags, which simply evaluate to disabled once ended.

Example:

"treatment"