iAdvizeDocs

Get a site's holdout test

Returns the site's holdout test, as the Holdout tab of the site's settings shows it: the running test, otherwise the most recent ended one. A holdout serves half of the sessions no assistant (a fixed 50/50 split, chosen by browser session) and compares the share of sessions with an add-to-cart between the two groups, counting an add-to-cart from the assistant's panel or from the merchant's page. No verdict is returned before both groups reach the traffic floor, and an inconclusive result gives the smallest gap the test could confirm (`detectionLimitPoints`), never a claim of no difference. While a test runs, reading it checks that its split is still even and ends it as invalid when it is not. `404` when the site has never had a holdout.

GET
/api/v1/sites/{siteId}/holdout

Authorization

ApiKeyAuth
AuthorizationBearer <token>

A WorkOS org-scoped API key, created from the dashboard's organization settings page. Identifies the tenant every read and write is scoped to. Missing, malformed, unknown, revoked, expired, or non-organization-owned keys all return 401 (no distinction, so the response can't be used to probe which keys or org ids exist).

In: header

Path Parameters

siteId*string

The site id (prefixed site_). A site id that isn't yours is a 404, same as any other cross-tenant id.

Response Body

application/json

application/problem+json

application/problem+json

application/problem+json

application/problem+json

curl -X GET "https://example.com/api/v1/sites/string/holdout"
{  "data": {    "id": "hold_01kvnwmagvf27rc9cze5rm9e1r",    "siteId": "site_01kvnwmagvf27rc9cze5rm9e1r",    "status": "running",    "state": "conclusive",    "endedReason": null,    "startedAt": "2026-10-22T08:00:00.000Z",    "endedAt": null,    "controlPercent": 50,    "trafficFloor": 5000,    "control": {      "assignedSessions": 5200,      "convertedSessions": 430,      "rate": 0.0827,      "addToCartEvents": 1505,      "eventsWithoutAmount": 0,      "valueAdded": [],      "valuePerAssignedSession": []    },    "treatment": {      "assignedSessions": 5100,      "convertedSessions": 490,      "rate": 0.0961,      "addToCartEvents": 1715,      "eventsWithoutAmount": 0,      "valueAdded": [        {          "currency": "EUR",          "amountMinor": 3920000,          "addToCartsWithAmount": 1715        }      ],      "valuePerAssignedSession": [        {          "currency": "EUR",          "amountMinor": 768.63        }      ]    },    "progress": 1,    "effectPoints": 1.3,    "winner": "treatment",    "detectionLimitPoints": null,    "lastStorefrontAddAt": "2026-10-26T09:41:00.000Z",    "plannedEndAt": "2026-11-05T08:00:00.000Z",    "forecastGapPoints": null,    "earlyResult": true,    "engagementShare": 0.04,    "effectPerEngagedPoints": 32.5  }}

Get a site's add-to-cart insights

Returns what the add-to-cart counts do not give. First, the sessions that added to the cart: of the sessions that had a conversation, and of the sessions where the assistant was shown and no conversation started, how many there were and how many added to the cart (counts only; divide to get a rate). A session with a conversation counts as having added when it made an add in the panel, or an add on the merchant's pages that the server received after its first conversation started. Second, the median cart value per currency, for the carts with a conversation and for the others: a cart is the set of add-to-carts that carry the same cart token, valued by the sum of its lines' amounts in the currency, and with a conversation when one of its lines is. Medians are in the currency's minor unit, never summed across currencies. Third, the add-to-carts by device (highest first), by hour of the day in the time zone asked (24 counts, zero-filled) and by unit price per currency (the amount divided by the quantity added, in five bands: under 25, 25 to 49, 50 to 99, 100 to 199 and 200 and over, in major units of the currency). Fourth, the dates from which amounts and cart tokens are recorded. The groups are of sessions and carts that had a conversation, not of what the assistant added: shoppers who start a conversation are not a random sample. A figure is `null`, never zero, while it could not have been recorded. No event, session or cart id is returned. Shopify stores only. Read-only.

Start a holdout test

Starts a holdout test on the site: from now on half of its sessions, chosen by session, are served no assistant, until the planned end, when every session is offered the assistant again. The split is always 50/50 and a body that names a share is refused with `400`. `durationDays` is the planned duration, 3, 7, 14 or 28; without it the recommendation of `GET /holdout/start-options` is used, else 14. Exposure counts in reports drop by the same share while the test runs, and a conversation in progress can lose the assistant at its next page view. The storefront must not open the assistant from its own code (`iadvize('open')` or a `data-iadvize-open` attribute): confirm it with the merchant before calling. A test starts only when the site's add-to-cart counting is on and the Shopify pixel recorded a storefront add-to-cart in the last 7 days (`holdout_measurement_unavailable` otherwise), when no widget experiment runs on the site (`holdout_experiment_running`), and a second one cannot start while one runs (`holdout_already_running`). Records an audit entry (`site.holdout_started`) attributed to the API key.