ShopifyQL with the GraphQL Admin API
You can send ShopifyQL queries via the GraphQL Admin API, allowing you to build reporting directly into your apps or programmatically extract data for further analysis.
Build apps that query analytics data programmatically using the shopifyqlQuery endpoint:
GraphQL query
Anchor to Required access scopesRequired access scopes
To use the ShopifyQL API, your app requires the following access scopes:
| Scope | Purpose |
|---|---|
read_reports | Access to analytics and reporting data. |
read_customers | Access to customer data in queries. |
ShopifyQL queries require level 2 access to protected customer data. Your app must meet Shopify's protected customer data requirements.
ShopifyQL queries require level 2 access to protected customer data. Your app must meet Shopify's protected customer data requirements.
Anchor to API response formatAPI response format
The API returns data in a structured JSON format:
JSON response
Anchor to Rate limitingRate limiting
The ShopifyQL API uses complexity-based rate limiting rather than fixed queries-per-second. Query complexity is determined by factors including:
- Number of metrics requested
- Number of dimensions in
GROUP BY - Date range size
- Use of comparisons and modifiers