---
title: Shopify tips and examples
slug: shopify-tips-and-examples
image: https://make-cxp-documentation.ams3.cdn.digitaloceanspaces.com/apps-center-icons/PREVIEW_DEFAULT.png
docTags: 
createdAt: 2025-06-23T14:17:20.576Z
---

Explore the following tips and examples to help you manage API limits, avoid errors, and correctly configure the Watch events (advanced) module.

::::ExpandableHeading{isOpen="true"}
# Shopify API rate limits

The Shopify app in Make follows Shopify’s API credit system to manage how many operations you can perform over time. Shopify doesn’t limit the number of requests you send, but each request uses credits based on how much data you retrieve or how complex the request is. If your available credits run out, Shopify blocks new requests with a rate limit error. This system helps prevent overload and ensures fair use for all Shopify users.

:::hint{type="info"}
API limits are set by Shopify and depend on your Shopify plan. Your Make plan has no impact on these limits.
:::

## How it works?

Every request you send to Shopify uses API credits. Different types of operations use different amounts of credits. Actions like **creating**, **updating**, or **deleting** use 10 credits per request. For example, when you create an order, 10 credits are deducted from your available pool. The same applies to webhooks: creating a webhook costs 10 credits, but triggering it later doesn't consume any credits.

When you request information from Shopify using queries, such as **Get**, **List**, **Search**, or **Watch**, the number of credits depends on how much data you ask for. The more complex the query, the higher the cost.

:::hint{type="info"}
For more details on how Shopify's credit system and GraphQL query complexity work, see [Shopify Complexity Guide](https://shopify.engineering/rate-limiting-graphql-apis-calculating-query-complexity).
:::

For example, in the **Get an order** module, you can control how much information is retrieved by adjusting the available settings. You decide how many line items to include in the output (up to 250) and whether to include product variants for each line item, with a limit of up to 250 variants per item.

::Image[]{src="https://api.archbee.com/api/optimize/oAyFj2GHlBeBVWF5OAir2/LdLsilPGn5yeWwoz979dO_image.png" size="82" width="1594" height="1218" position="center" showCaption="false"}

The more data you request, the higher the credit usage. In this example:

- We set a limit of 250 line items per order.
- We also chose to include product variants, with a limit of 5 variants per line item.

As a result, if the order has 1 line item, Shopify queries 5 variants. If the order has 10 line items, then Shopify queries 50 variants, which increases the overall credit cost.

:::hint{type="info"}
Shopify reserves API credits based on the limits you set in Make, but only deducts credits for the actual amount of data retrieved. For more information, see the **Quota details** section below.
:::

## Quota details

After running a Shopify module in your scenario, you can check the quota details in the output to see how your API credits were used.

For example, imagine you use the **Get an order** module and set a high limit for line items or variants. Shopify needs to reserve enough credits to cover the maximum possible result — even if the actual data returned is smaller.

::Image[]{src="https://lh7-rt.googleusercontent.com/docsz/AD_4nXcYQZ5W7xqzHK1de_xVgV3DMseUmnlQsEtwQQ7T4PBRLO5P75H5Z84TIlWcWFa4YiLTcFpuDz7roWl-iloACWZPIjh3pcf9A2HLZJXmDMyqZ8X8zTkVEXvxH_paICncMa9dZv6FaQ?key=hZ3U_T2MuAc-NxCODKPBZQ" size="50" width="338" height="232" position="center" showCaption="false"}

In the example output above:

- The **Requested query cost** shows 100 credits, meaning Shopify reserves that amount based on the potential size of the response. You must have at least 100 credits available to even run the request.
- After the query requested, the **Actual query cost** shows 20 credits, based on the real amount of data retrieved — so only 20 credits are deducted from the available limit.

You’ll also see your current credit status under **Throttle status.&#x20;**&#x49;n this example, the maximum available credits are set to 2000, which is the highest Shopify plan allows. After running the request, the currently available credits drop to 1980, reflecting how many credits left. The restore rate shows how quickly your credit pool makes space for new requests — similar to how water drains from a bucket to make room for more.

It is recommended to run your module after setting it up and review the quota details in the output. Check the **Requested query** cost shown in the output and compare it to your **Restore rate**. If your scenario is set to run frequently, or if you manage a large number of scenarios with Shopify modules, refining your module mappings is an effective way to reduce your API credit consumption.

:::hint{type="info"}
For more details, see [Shopify API usage limits](https://shopify.dev/docs/api/usage/limits).
:::
::::

:::ExpandableHeading{isOpen="true"}
# Shopify page size

The **Page size** controls how many orders are retrieved per page when using **Search** modules in the Shopify app. This setting helps prevent issues with Shopify's GraphQL complexity limits, especially when you need to retrieve large amounts of data.

Shopify limits how many items you can request based on the complexity of the query. If the request is too large or contains too many fields, it may fail. By setting a page size, you can split your request into smaller parts that run one after another, helping you retrieve more orders without exceeding limits.

To use the **Page size** field, switch on the **Show advanced settings** option.

::Image[]{src="https://api.archbee.com/api/optimize/oAyFj2GHlBeBVWF5OAir2/Qs5si083ECBIIpC5me_ii_image.png" size="82" width="2558" height="1736" position="center" showCaption="false"}

**Example usage**

Let’s say you set the **Page size** to 10 and the **Order limit** to 100. This retrieves 10 pages with 10 orders each, for a total of 100 orders. Shopify processes these smaller pages one by one, reducing the chance of errors.

For comparison, if you leave the **Page size** empty and set the **Order limit** to 100, Shopify tries to retrieve all 100 orders at once, which might exceed complexity limits and block your request.

**Limitations**

- The maximum number of orders per page is 250, based on Shopify’s API limits.
- The **Page size** defaults to the lowest value between your mapped **Order limit** and 250.
- The maximum number of pages that can be retrieved is 31.
:::

:::::ExpandableHeading{isOpen="true"}
# Watch events (advanced) module

When using the **Watch events (advanced)** module in the Shopify app, you can monitor specific Shopify events and include relevant metafields in the output. Here's how to configure these fields:

## Event topic

In the **Event topic** field, you need to map which event the module listens to, such as order updates or product changes. To find the correct event value:

::::WorkflowBlock
:::WorkflowBlockItem
Refer to the [Shopify webhook topic enum values documentation.](https://shopify.dev/docs/api/admin-graphql/latest/enums/WebhookSubscriptionTopic)
:::

:::WorkflowBlockItem
Enter the copied event topic into the **Event Topic** field.
:::
::::

You successfully configured the event, so the module triggers when this event occurs in your Shopify store.

:::hint{type="warning"}
If you receive a missing scope error while setting up the webhook, [edit your connection](https://help.make.com/connect-an-application#tN2pJ) and add the required scope shown in the [Shopify documentation](https://shopify.dev/docs/api/admin-graphql/latest/mutations/webhooksubscriptioncreate).
:::

## Metafield namespaces

If you want to include metafields in the output, add one or more Metafield namespaces. To find the namespace:

::::WorkflowBlock
:::WorkflowBlockItem
Log in to your Shopify admin account.
:::

:::WorkflowBlockItem
In the left sidebar, click **Settings&#x20;**>**&#x20;Metafields and metaobjects**.
:::

:::WorkflowBlockItem
In the **Metafield definitions** section, click on the part of the store you want to use.

![](https://api.archbee.com/api/optimize/oAyFj2GHlBeBVWF5OAir2/VNvUUvfuvWOTvR9OF_xFI_image.png)
:::

:::WorkflowBlockItem
Click on the metafield definition you want to use.
:::

:::WorkflowBlockItem
In the **Namespace and key** field, copy the namespace written before the period only.

For example, if the namespace and key shows `custom.datafield`, you will need to enter `custom` in the **Metafield namespace** field.



![](https://api.archbee.com/api/optimize/oAyFj2GHlBeBVWF5OAir2/zSDbSj0P4tdOQYTI05-W1_image.png)
:::

:::WorkflowBlockItem
In the **Watch events (advanced)** module, click **+Add namespace** and enter the namespace copied from your Shopify admin account.

![](https://api.archbee.com/api/optimize/oAyFj2GHlBeBVWF5OAir2/JXbFY2Bcfg8KqmyZX8cST_image.png)
:::
::::

You’ve added the namespace—metafields from this namespace will now be included in the module output if they have assigned values.
:::::

::::::ExpandableHeading{isOpen="true"}
# Make a GraphQL API call module

Starting from October 1, 2024, Shopify switched from the REST Admin API to GraphQL Admin API. The REST Admin API is a legacy API, and all apps and integrations should be built using GraphQL. 

Let’s suppose you want to retrieve a list of in-stock products with their variants in your Shopify store and add this data to Google Sheets. Here’s an example of how to use the **Make a GraphQL API call&#x20;**&#x6D;odule in Make for that.

## Add 'Make a GraphQL API call' module

:::::WorkflowBlock
:::WorkflowBlockItem
Add the **Make a GraphQL API call&#x20;**&#x6D;odule in Make.
:::

:::WorkflowBlockItem
In the ​**Connection**​​ field, select a connection for your Shopify account. If you haven't created a Shopify connection yet, refer to the [Connect Shopify and Make ](https://apps.make.com/shopify#vHyR5)section.
:::

::::WorkflowBlockItem
To retrieve the inventory stock for multiple products, including their titles and prices, you can use the **products** query from [Shopify GraphQL API documentation](https://shopify.dev/docs/api/admin-graphql/latest/queries/products), adding some relevant variables and pasting them into the **Query** field:

:::BlockQuote
query GetProducts \{
&#x20; products (first: 10) \{
&#x20;   edges \{
&#x20;      node \{&#x20;
&#x20;           id
&#x20;           title
&#x20;           variants (first: 10) \{
&#x20;              edges \{
&#x20;                  node  \{
&#x20;                    id
&#x20;                    title&#x20;
&#x20;                    price
&#x20;                    inventoryQuantity
&#x20;                 }
&#x20;              }
&#x20;           }
&#x20;         }
&#x20;      }
&#x20;  }
}
:::

:::hint{type="info"}
Query breakdown:

- `products (first: 10)` limits the response to the first 10 products in the store from Shopify. You can increase or decrease it.&#x20;
- `edge` in GraphQL represents the product, and `node` represents the actual product objects.
- `variants` represent different categories (e.g., sizes: XS, S, M, L) and are also limited to the first 10 variants per product.
- &#x20;`nodes` inside `variants` provide the actual info: `title`, `price` and `inventoryQuantity` that you pull in from the store.
:::

:::hint{type="success"}
By default, all requests are treated as queries, so you don't need to specify them explicitly. You can start directly with 'products'.&#x20;

For **mutations** or other non-query requests, be sure to define the request type in your call.&#x20;
:::
::::

:::WorkflowBlockItem
Optional: Switch on the **Show advanced settings** toggle for additional configurations: &#x20;

::Image[]{src="https://api.archbee.com/api/optimize/PL8X94efBsjvhfQV3wyyj-3sGD06VJR5jEQQSFT271f-20250710-083944.png" size="50" width="708" height="976" position="center" showCaption="false"}



- **API version**: specify the API version to use for the query. This is useful if you need to target an older API version.
- **Variables input format**: choose the format for your query variables:
  - &#x20;Array - recommended for mapping.
  - &#x20;JSON - standard key-value structure.
- **Variables**: add your query variables based on the format selected above.&#x20;
- **Simplify response**: define response format. By default, GraphQL responses include nested structures such as nodes and edges. Check:
  - **Yes** to get a simplified response as a more structured, flattened object.&#x20;
  - **No** to maintain the original response with all nested objects.
- **Handle errors**: define how error handling will work. By default, all GraphQL responses are returned with a 200 status code, but the body can contain errors. Check:
  - **Yes&#x20;**&#x74;o enable module-level error handling. &#x20;
  - **No&#x20;**&#x69;f you're implementing some custom error-handling logic.
:::

:::WorkflowBlockItem
Click **Save**. 
:::
:::::

This is the output you'll get:

::Image[]{src="https://api.archbee.com/api/optimize/PL8X94efBsjvhfQV3wyyj-W0d3qsMdTseeKGaQ5Xw5I-20250708-094000.png" size="50" width="710" height="1288" position="center" showCaption="false"}

## Add Iterator 1

To get the title and variants array for each product:&#x20;

::::WorkflowBlock
:::WorkflowBlockItem
Add an **Iterator&#x20;**&#x74;o your scenario. 
:::

:::WorkflowBlockItem
Map `body: data: [products]` from the **Make a GraphQL API call** module.

![](https://api.archbee.com/api/optimize/PL8X94efBsjvhfQV3wyyj-EtBYC3eVNYcnZ4LGid8vB-20250708-084640.png)
:::

:::WorkflowBlockItem
Click **Save**.
:::
::::

This is the output you will get:

::Image[]{src="https://api.archbee.com/api/optimize/PL8X94efBsjvhfQV3wyyj-7KJDGWDRFCbjBiqn7ibp0-20250708-084911.png" size="50" width="598" height="1088" position="center" showCaption="false"}

## Add Iterator 2

To iterate each variant directly (title, price, and quantity):

::::WorkflowBlock
:::WorkflowBlockItem
Add another **Iterator&#x20;**&#x74;o your scenario. 
:::

:::WorkflowBlockItem
Map `variants []` from the Iterator 1.

![](https://api.archbee.com/api/optimize/PL8X94efBsjvhfQV3wyyj-xsw0OfmWkAw2se7gSdi3x-20250708-090420.png)
:::

:::WorkflowBlockItem
Click **Save**.
:::
::::

This is the output you'll get:

::Image[]{src="https://api.archbee.com/api/optimize/PL8X94efBsjvhfQV3wyyj-15T-ibsQsUSb0YcnIwoz8-20250708-090511.png" size="50" width="712" height="1428" position="center" showCaption="false"}

## Add a Google Sheets - Add a Row module

To add data to Google Sheets:

::::WorkflowBlock
:::WorkflowBlockItem
Create a sheet with the corresponding fields. 

::Image[]{src="https://api.archbee.com/api/optimize/PL8X94efBsjvhfQV3wyyj-adTpoklP1yUvv2hSKrmBy-20250708-091422.png" size="50" width="1004" height="652" position="center" showCaption="false"}
:::

:::WorkflowBlockItem
Add a **Google Sheets - Add a Row&#x20;**&#x6D;odule in Make.
:::

:::WorkflowBlockItem
Configure the fields within your Google Sheets connection (Drive, Spreadsheet ID, Sheet Name) and map the values.

- For the **Product** **name** field map `title` from the Iterator 1
- For the **Variant** field map `title` from Iterator 2.
- For the **Price** field map`price` from the Iterator 2.
- For the **Inventory Quantity** field map`inventoryQuantity` from the Iterator 2.&#x20;



  ![](https://api.archbee.com/api/optimize/PL8X94efBsjvhfQV3wyyj-lA11GXMQSiZB2mK38ilcK-20250708-091605.png)
:::

:::WorkflowBlockItem
Click **Save**.&#x20;
:::
::::

Click the **Run once button&#x20;**&#x6F;n the toolbar to test the scenario. Check your Google Sheets file. You should get a table like this:&#x20;

::Image[]{src="https://api.archbee.com/api/optimize/PL8X94efBsjvhfQV3wyyj-uNj93ECW_-tAW9BmeGTPH-20250708-091852.png" size="50" width="846" height="750" position="center" showCaption="false"}

## Other examples of queries for the Make a GraphQL API call module

This is how a query for searching articles by title with metafields could look:

:::BlockQuote
query \{
&#x20; articles(first: 10, query: "title\:Picture") \{
&#x20;   nodes \{
&#x20;     id
&#x20;     title
&#x20;     body
&#x20;     summary
&#x20;     handle
&#x20;     isPublished
&#x20;     publishedAt
&#x20;     tags
&#x20;     createdAt
&#x20;     updatedAt
&#x20;     author \{
&#x20;       name
&#x20;     }
&#x20;     blog \{
&#x20;       id
&#x20;     }
&#x20;     image \{
&#x20;       altText
&#x20;       url
&#x20;     }
&#x20;     metafields(first: 10) \{
&#x20;       nodes \{
&#x20;         id
&#x20;         namespace
&#x20;         legacyResourceId
&#x20;         key
&#x20;         value
&#x20;         jsonValue
&#x20;         type
&#x20;       }
&#x20;     }
&#x20;   }
&#x20; }
}
:::

The output would look like this:

::Image[]{src="https://api.archbee.com/api/optimize/PL8X94efBsjvhfQV3wyyj-1-FeDrB68dozvwgPqepUe-20250708-152237.png" size="50" width="710" height="1366" position="center" showCaption="false"}

This is how a query for getting customer data could look:

:::BlockQuote
query \{
&#x20; customer(id: "gid://shopify/Customer/3057986535526") \{
&#x20;   id
&#x20;   email
&#x20;   phone
&#x20;   taxExempt
&#x20;   firstName
&#x20;   lastName
&#x20;   amountSpent \{
&#x20;     amount
&#x20;     currencyCode
&#x20;   }
&#x20;   smsMarketingConsent \{
&#x20;     marketingState
&#x20;     marketingOptInLevel
&#x20;     consentUpdatedAt
&#x20;   }
&#x20; }
}
:::

The output would look like this:

::Image[]{src="https://api.archbee.com/api/optimize/PL8X94efBsjvhfQV3wyyj-osn23i0U6oEwb6Nm3dmXv-20250709-073231.png" size="50" width="710" height="1154" position="center" showCaption="false"}


::::::

