Getting started
Pagination and search
Relay connections and the query: search syntax.
Connections#
Lists are Relay connections named <Type>Connection, with both edges (with cursors) and nodes. Page with first + after (or last + before) and pageInfo.
query Products($after: String) {
products(first: 50, after: $after, query: "status:active") {
nodes { id title handle }
pageInfo { hasNextPage endCursor }
}
}Search syntax#
Arguments named query take Shopify's search syntax. Each field documents which filters it supports.
| Example | Meaning |
|---|---|
status:active | Field equals value |
title:shirt* | Starts with; *shirt* = contains |
vendor:"Dar Lina" | Quoted value with spaces |
-status:archived | Not |
created_at:>2026-10-01 | Comparisons: > < >= <= |
caftan | Free words match the main text fields |
source:online_store,whatsapp | Comma = either value (orders) |
Up to 20 terms; terms are combined with AND.