Queries
Last updated
Was this helpful?
Last updated
Was this helpful?
GraphQL is a powerful query language that allows you to request data from a GraphQL server like Shopify's APIs. Queries are capable from requesting specific fields of single resources, nested resources, and lists of resources.
A GraphQL API models data as nodes connected by edges. A node is an object that has a global ID, such as an Order object or Product object. You can fetch data about an individual node, or you can follow the edges to fetch data about a collection of related nodes. At each node, you specify the fields that you want to retrieve. - https://shopify.dev/concepts/graphql/queries
query {
product(id: "gid://shopify/Product/1925886804024") {
title
description
onlineStoreUrl
}
}
query {
products(first:3) {
edges {
node {
id
handle
variants(first:3) {
edges {
node {
id
displayName
}
}
}
}
}
}
}
query {
orders(first:2, query:"fulfillment_status:shipped") {
edges {
node {
id
name
displayFulfillmentStatus
}
}
}
}