Skip to content

Instantly share code, notes, and snippets.

@kmclaugh
Created August 23, 2021 16:07
Show Gist options
  • Save kmclaugh/a8709e80feabe99dfb680864a29c41cf to your computer and use it in GitHub Desktop.
Save kmclaugh/a8709e80feabe99dfb680864a29c41cf to your computer and use it in GitHub Desktop.
Sample graphql orders query for Shopify
POST https://slideruletech-test.myshopify.com/admin/api/2020-10/graphql.json
Content-Type: application/json
X-Shopify-Access-Token: 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
X-REQUEST-TYPE: GraphQL
query {
orders(first: 10) {
edges {
node {
id
tags
name
createdAt
currencyCode
customer {
id
createdAt
email
firstName
lastName
defaultAddress {
id
address1
address2
city
country
countryCodeV2
province
provinceCode
zip
}
}
customerJourneySummary {
customerOrderIndex
daysToConversion
momentsCount
firstVisit {
id
landingPage
}
lastVisit {
id
landingPage
}
}
lineItems(first: 1) {
edges {
node {
id
product {
id
}
quantity
}
}
}
}
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment