Skip to main content
POST
Error

Authorizations

Authorization
string
header
required

Shopify App Bridge session token of the embedded Depict: Search & Merchandising app. The shop in the token determines the merchant; merchant_id parameters must belong to that shop.

Path Parameters

collection_id
string
required

Numeric Shopify collection id.

Query Parameters

merchant_id
string
required

Lite merchant id, e.g. shopify-<shop id>.

Body

application/json
variant_a_version_uuid
string
required
Minimum string length: 1
variant_b_version_uuid
string
required
Minimum string length: 1
scope_type
enum<string>
required
Available options:
all,
market_groups
traffic_split
integer
required

Percent of traffic routed to variant B.

Required range: 10 <= x <= 90
start_date
string<date-time>
required

ISO 8601; without an offset it is read as UTC.

end_date
string<date-time>
required

ISO 8601; without an offset it is read as UTC.

market_group_ids
string[]

Required (non-empty) when scope_type is market_groups.

name
string | null
Maximum string length: 80

Response

The created test.

test_id
string
required
collection_id
string
required
name
string
required
variant_a_version_uuid
string
required
variant_b_version_uuid
string
required
scope_type
enum<string>
required
Available options:
all,
market_groups
market_group_ids
string[]
required
applies_to_market_ids
string[]
required

The scope resolved to numeric Shopify market ids, sorted; two running tests on a collection never share one.

traffic_split
integer
required

Percent of traffic routed to variant B (10–90).

start_date
string<date-time>
required
end_date
string<date-time>
required
status
enum<string>
required
Available options:
running,
ended,
winner_promoted
promoted_variant
enum<string> | null
required
Available options:
A,
B,
null
created_at
string<date-time>
required
created_by_email
string
required

Always empty: the test is storefront-readable.