Question about products/update webhook after increasing product variants to 2048

I have a question regarding the recent announcement that products will soon support up to 2048 variants.

In our application, we use the products/update webhook to track changes in variant fields. Currently, the webhook includes all 100 variants, so we don’t need to make any additional requests to fetch variant data.

Could you please clarify what the webhook payload will look like after this change? Will it contain all 2048 variants, or still only 100 variants as before? If it remains 100 variants, will they be sorted by the updatedAt field so that the webhook includes only the most recently updated variants?

Hey,

Its documented under the new product model in the docs.

  • A variant_gids field will be retroactively added to all webhook versions. The field will list all variant GIDs in the format variant_gids: [{admin_graphql_api_id: ID!}].

  • Product webhooks will return a full variants payload for the first 100 records. For variants 101+, the payload won’t include the full variant details, but the variant_gids field will still be included for these variants.

Hi @JordanFinners,

Thank you for your answer!

I have a followup question on this: We also use the products/update webhook to track changes to variants and the webhook payloads we’re seeing don’t match the documentation.

We have tested this with products with up to 183 variants so far and we get: full variant data for all 183 variants in the variantsarray and also entries for all 183 variants in the variant_gids array.

To make matters more confusing, we can’t reproduce this behaviour in our staging Shopify shop.

Hey Alex,

Do you mean you don’t see the data for all 183 variants in your staging store?

Yeah, so:

  • Staging: The webhook includes full payload for up to 100 variants (expected based on what’s stated in the docs).
  • Production: The webhook includes full payload for up to 250 variants (did more testing to see what the upper limit is and it’s 250).