Shopper API reference

Endpoints, parameters and response shapes: context, catalog, content, blog and comments, custom content, search, shopper sessions, events and checkout sessions.

All paths are under https://<store domain>/api/shop/2026-11. Catalog and content objects have the same fields and rules as the theme context themes read (see the CTX reference), so a product here is a product there.

Context#

Endpoint

Returns

GET /context

countries[] (code, currency, languages, default_language, country_url, consent.banner_required, consent.purposes), store, caller (surface headless or agent, key, headless_storefront, agent), limits

Catalog#

Endpoint

Parameters

Returns

GET /products

country, language, q (search), collection, category, vendor, brand (handles), sort, filter.<key>=<value> (the storefront's filters; a vendor, brand or category value takes its slug in any language), page or cursor, limit (1–50, default 24)

products[] (each with url and absolute_url), pagination (next_cursor, has_next, total_count…), sort, filters, and the collection/category/vendor/brand named, with its links (below)

GET /products?ids=1,2,3

Up to 50 product IDs

products[] in the order asked; unpublished or off-channel products are left out

GET /products/{handle}

country, language

product: variants, options, prices in the shown tax display, availability, images, metafields shown on the storefront, requires_customisation, and its links (below)

GET /collections, /categories, /vendors, /brands

page

The list with pagination; each item has url and absolute_url

GET /collections/{handle} (and categories, vendors, brands)

As /products

The entity, with its links (below), and its products

requires_customisation: true marks a product an app must personalise before it is bought: checkout sessions refuse it with its product page link.

Every url is a path on the hosted storefront for the request's country and language (a country with its own domain is addressed there), and absolute_url beside it is the same page as a full URL: use it for a canonical link. Products in lists, entity list items and search results carry both.

Field

On

Meaning

alternates

product, and the collection, category, vendor or brand of a listing

The page in each language the hosted storefront serves in the request's country: language → absolute_url, with the slug of that language. Use it for hreflang links.

canonical_handle

The same

The resource's slug in the request's language: what to route and link by.

redirect

The same, only when the handle asked for was another language's slug or an old one whose change kept its redirect

from_handle, handle (= canonical_handle), url, absolute_url and status (301): the resource is returned, and a headless storefront should answer its own route with this permanent redirect, as the hosted storefront does.

Filters take a vendor, brand or category by its slug in any language (filter.vendor=<slug>), or by a slug it had before a slug change that kept its redirect, so a slug read from a product's vendor_ref builds a working link. Every link the API returns for a filter state (filter values' url, filters.inputs, paging and sort links) carries the slug in the request's language, so one filter state has one URL. Tag slugs are the same in every language.

Content#

Endpoint

Returns

GET /pages, GET /pages/{slug}

Published pages: title, content, SEO fields, template_handle, metafields

GET /menus/{handle}

The menu tree themes get: items with title, url (a storefront path), type and children

GET /policies, GET /policies/{type}

Published policies in the shopper's language

GET /blog

blog (title, url, feed_urls, seo: the blog page's title, description, social fields and noindex as set in Store Admin), the first page of posts[] and pagination. Takes page, limit (1–50), q, sort (published_at, the default, or title)

GET /blog/posts

Published posts, newest first, with pagination. Filter by at most one of category, tag, author (slugs) or month (YYYY-MM), plus q (search), sort, page, limit (1–50). Each post: title, slug, url, excerpt, featured and social image, author, categories, tags, published dates, comment_count, SEO fields and metafields

GET /blog/posts/{slug}

post: the list fields plus content, related_posts, previous_post, next_post, feed_urls, comments_enabled, comments_login_required, comments_name_required, the first page of approved comments (id, author_name, content, created_at, created_at_iso), comments_total, comments_pagination and comment_form (each field's required and max_length)

GET /blog/posts/{slug}/comments

A page of approved comments, oldest first: comments[], comments_enabled, pagination (current_page, total_pages, total_count, per_page). Takes page and limit (1–50; the store's comment page size by default)

GET /blog/categories, GET /blog/tags

The blog's categories (with post_count, SEO fields and metafields) or tags, and has_more

GET /blog/categories/{slug}, GET /blog/tags/{slug}, GET /blog/authors/{slug}

The category, tag or author and its posts[], paged like /blog/posts

GET /content/{type}

The list page of a custom content type that has web pages (by type handle): content_type (handle, name, url), seo, its active entries[] and pagination. Takes page, limit (1–50, default 24)

GET /content/{type}/{handle}

entry: id, handle, type, display_name, url, seo (title, description, social_image), updated_at_iso, fields[] and each field by its key

Only published posts, approved comments and active entries of custom content types with web pages are returned; drafts never are. Custom data (metafields and entry fields) that points at custom content entries returns those entries, resolved as themes see them: in one batched read per request, at most 3 levels deep.

Blog comments#

POST /blog/posts/{slug}/comments with {"author_name", "author_email", "content"} posts a comment. It needs a storefront or server key and a shopper session (Tringify-Shop-Session). Send submission_id in the body or an Idempotency-Key header (up to 128 characters): a retry with the same value and session returns the first answer instead of a second comment.

The comment goes through the same checks as the store's own comment form: the store's comment settings and moderation, blocked words, the block list, and the comment limits per shopper address, per network and per store (a server key's forwarded Tringify-Shop-Client-IP is the shopper's address). The merchant is notified and blog_comments/create webhooks fire as for any comment. The answer is 201 with status (approved, or pending while it waits for review) and, when approved, comment.

Code

When

SHOP_API_COMMENTS_KEY_REQUIRED (403)

No key: AI agents read comments but cannot post them

SHOP_API_SESSION_REQUIRED (401)

No live shopper session

SHOP_API_COMMENTS_DISABLED (403)

The store has comments turned off

SHOP_API_COMMENTS_SIGN_IN_REQUIRED (403)

The blog takes comments from signed-in customers only; the API has no customer sign-in yet

SHOP_API_COMMENTS_BUSY (429)

The store is getting so many comments that its storefront asks for a human check; retry after Retry-After

SHOP_API_RATE_LIMITED (429)

A comment limit was reached; retry after Retry-After

SHOP_API_NOT_FOUND (404)

No published post with that slug in the request's language

BLOG_COMMENT_*

The comment itself: missing or too long content, author_name or author_email, an invalid email; field names it

Endpoint

Parameters

Returns

GET /search

q (required), country, language, type (comma-separated result types), page, limit (1–50, for products), sort, filter.<key>=<value>

query, results and totals per result type (products with items and pagination; other types up to 10 each with id, handle, title, excerpt, image, url, absolute_url), filters

GET /search/suggest

q (required), country, language

query, groups[] (type, has_more, items[] with title, url, image; products add product_id, price, compare_at_price, available_for_sale, rating, vendor)

Search is the store's own storefront search: its search settings (whether search and search suggestions are on, and which result types it shows: products, collections, categories, vendors, brands, pages, blog_posts, blog_categories, policies, custom_content), its synonyms in the request's language, the same ranking and the same filter rules. Results are titled and linked in the request's language: handle is the result's slug in that language, as in its url. A vendor, brand, category or collection result's excerpt is the first sentence of its description in that language (plain text, at most 200 characters, cut at a word); blog posts, pages, policies and custom content keep the start of their text. Products are limited to the caller's channel. SHOP_API_SEARCH_DISABLED answers while search is off, SHOP_API_PREDICTIVE_SEARCH_DISABLED asks for suggestions while they are off, and SHOP_API_SEARCH_TYPE_INVALID refuses an unknown type.

Shopper sessions#

POST /sessions starts a session for analytics and attribution. Send landing_url (with its click IDs and UTM tags), referrer, country and consent (given, purposes: analytics, advertising, advertising_data, personalized_advertising, personalization). It answers session.id, session.token, session.browser_id, session.consent and session.expires_at (30 days). Keep the token in your own first-party cookie and send it as Tringify-Shop-Session on every call.

  • Click IDs (gclid, gbraid, wbraid, fbclid, ttclid, msclkid and the parameters installed apps declared) and UTM tags become the session's first and last touch when advertising consent allows.

  • PUT /sessions/{id}/consent with given and purposes changes the choice from then on.

  • With a server key, the session records the shopper's forwarded address, user agent and declared app cookies.

Events#

POST /events with {"events": [{"type", "url", "payload"}]} (at most 20) records what the shopper saw. Types: page_view (page_type, slug, resource_id), product_viewed (product_id, variant_id), search (query, results_total), rec_impression (placement, product_ids), rec_click (placement, product_id), newsletter_signup, contact_submitted. Products must exist and be published; product details come from the catalog. Each event comes back with its event_id, so a pixel you run can send the same ID. Cart, checkout and purchase are never sent here: they come from checkout sessions and the order. Needs a live session; each session and store has an allowance (SHOP_API_EVENT_LIMIT_REACHED).

Checkout sessions#

Endpoint

Does

POST /checkout-sessions

Creates a session: country, language, lines[] (product_id, variant_id, quantity; at most 100), email, phone, shipping_address, shipping_option_id, discount_code

GET /checkout-sessions/{id}

Prices it again and answers it

PATCH /checkout-sessions/{id}

Changes any of the create fields; a shipping address in another country moves the session there

POST /checkout-sessions/{id}/cancel

Cancels it

See Checkout sessions and hand-off for statuses, messages and the checkout_url.