Skip to main content
POST
cURL

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Headers

x-shop
string
required

Shopify store URL. Resolves the shop for the request (headless does not accept ?shop=).

Example:

"shop.myshopify.com"

Body

application/json

Request body

Storefront / personalization event ingestion. Shop is taken from the x-shop header (not the body). Requires channel and at least one of visitor_id / client_id.

channel
enum<string>
required

Originating storefront channel.

Available options:
HYDROGEN,
HEADLESS,
MOBILE
event
object
required

The event envelope.

session_id
string

Browsing-session id (the unit of funnel + attribution analytics). Optional; the server generates a uuid when absent, but send a stable one per visit for accurate analytics.

visitor_id
string

Anonymous persistent visitor UID. At least one of visitor_id / client_id is required.

client_id
string

Client/device id (persists across sessions). At least one of visitor_id / client_id is required.

customer_id
string

Shopify customer id when logged in.

page_type
string

Page type the event fired from.

page_url
string

URL the event fired from.

cart_identifier
string

Cart token/key identifier.

cart
object

Cart state at event time.

customer
object

Customer info at event time.

customer_privacy
object

Customer consent flags.

Response

Event accepted

Event ingestion acknowledgement.

ok
enum<boolean>

Indicates the event was accepted.

Available options:
true