From 8252e826a25535de032fc3cbc685d9476e4474ce Mon Sep 17 00:00:00 2001 From: Philippe Serhal Date: Thu, 2 Jan 2025 07:07:44 -0500 Subject: [PATCH] feat!(gatsby-source-shopify): upgrade from Shopify API version 2022-04 to 2024-04 (#39082) * chore!(gatsby-source-shopify): upgrade to api version 2024-04 See breaking changes in: - https://shopify.dev/docs/api/release-notes/previous-versions/2022-07 - https://shopify.dev/docs/api/release-notes/previous-versions/2022-10 - https://shopify.dev/docs/api/release-notes/previous-versions/2023-01 - https://shopify.dev/docs/api/release-notes/previous-versions/2023-04 * test: fix fixture syntax and update snapshots * chore: handle Count type * fix: handle intentory level * test: update snapshots and mocks * test: update variants fixture * test: update inventory level mock * fix: minimize breaking changes by keeping Int type for count fields * fix: mark productBased as deprecated * address review comments * test: update snapshots --------- Co-authored-by: pieh --- .../__snapshots__/create-operations.ts.snap | 120 ++- .../create-schema-customization.ts.snap | 68 +- .../source-from-operation.ts.snap | 862 +++++++++++++++--- .../fixtures/bulk-results/collections.jsonl | 2 +- .../fixtures/bulk-results/products.jsonl | 4 +- .../fixtures/bulk-results/variants.jsonl | 24 +- .../__tests__/fixtures/ids.json | 40 +- .../__tests__/fixtures/index.ts | 1 + .../shopify-nodes/ShopifyCollection.json | 52 +- .../shopify-nodes/ShopifyExternalVideo.json | 2 +- .../shopify-nodes/ShopifyInventoryItem.json | 2 +- .../shopify-nodes/ShopifyInventoryLevel.json | 279 +++++- .../shopify-nodes/ShopifyLineItem.json | 19 +- .../shopify-nodes/ShopifyLocation.json | 46 +- .../shopify-nodes/ShopifyMediaImage.json | 45 +- .../shopify-nodes/ShopifyMetafield.json | 49 +- .../shopify-nodes/ShopifyModel3d.json | 2 +- .../fixtures/shopify-nodes/ShopifyOrder.json | 22 +- .../shopify-nodes/ShopifyProduct.json | 203 ++++- .../shopify-nodes/ShopifyProductVariant.json | 555 ++++++++++- .../ShopifyProductVariantPricePair.json | 2 +- .../fixtures/shopify-nodes/ShopifyVideo.json | 2 +- .../src/create-schema-customization.ts | 22 + .../src/plugin-options-schema.ts | 2 +- .../src/query-builders/collections-query.ts | 5 +- .../query-builders/product-variants-query.ts | 15 +- .../src/query-builders/products-query.ts | 10 +- .../src/type-builders/collection-type.ts | 2 +- .../src/type-builders/location-type.ts | 20 +- .../src/type-builders/product-type.ts | 4 +- .../src/type-builders/product-variant-type.ts | 2 +- 31 files changed, 2264 insertions(+), 219 deletions(-) diff --git a/packages/gatsby-source-shopify/__tests__/__snapshots__/create-operations.ts.snap b/packages/gatsby-source-shopify/__tests__/__snapshots__/create-operations.ts.snap index 55d27ce7df5be..f4aa1881bca84 100644 --- a/packages/gatsby-source-shopify/__tests__/__snapshots__/create-operations.ts.snap +++ b/packages/gatsby-source-shopify/__tests__/__snapshots__/create-operations.ts.snap @@ -147,7 +147,10 @@ Array [ } } } - mediaCount + mediaCount { + count + precision + } metafields { edges { node { @@ -196,7 +199,10 @@ Array [ productType publishedAt requiresSellingPlan - sellingPlanGroupCount + sellingPlanGroupsCount { + count + precision + } seo { description title @@ -276,7 +282,10 @@ Array [ inventoryLevels { edges { node { - available + quantities(names: [\\"incoming\\", \\"available\\", \\"committed\\", \\"reserved\\", \\"damaged\\", \\"safety_stock\\", \\"quality_control\\"]) { + name + quantity + } id location { id @@ -285,7 +294,10 @@ Array [ } } legacyResourceId - locationsCount + locationsCount { + count + precision + } provinceCodeOfOrigin requiresShipping sku @@ -340,7 +352,10 @@ Array [ name value } - sellingPlanGroupCount + sellingPlanGroupsCount { + count + precision + } sku storefrontId taxCode @@ -503,7 +518,10 @@ Array [ } } } - productsCount + productsCount { + count + precision + } ruleSet { appliedDisjunctively rules { @@ -793,7 +811,10 @@ Array [ } } } - mediaCount + mediaCount { + count + precision + } metafields { edges { node { @@ -842,7 +863,10 @@ Array [ productType publishedAt requiresSellingPlan - sellingPlanGroupCount + sellingPlanGroupsCount { + count + precision + } seo { description title @@ -922,7 +946,10 @@ Array [ inventoryLevels { edges { node { - available + quantities(names: [\\"incoming\\", \\"available\\", \\"committed\\", \\"reserved\\", \\"damaged\\", \\"safety_stock\\", \\"quality_control\\"]) { + name + quantity + } id location { id @@ -931,7 +958,10 @@ Array [ } } legacyResourceId - locationsCount + locationsCount { + count + precision + } provinceCodeOfOrigin requiresShipping sku @@ -986,7 +1016,10 @@ Array [ name value } - sellingPlanGroupCount + sellingPlanGroupsCount { + count + precision + } sku storefrontId taxCode @@ -1149,7 +1182,10 @@ Array [ } } } - productsCount + productsCount { + count + precision + } ruleSet { appliedDisjunctively rules { @@ -1439,7 +1475,10 @@ Array [ } } } - mediaCount + mediaCount { + count + precision + } metafields { edges { node { @@ -1488,7 +1527,10 @@ Array [ productType publishedAt requiresSellingPlan - sellingPlanGroupCount + sellingPlanGroupsCount { + count + precision + } seo { description title @@ -1568,7 +1610,10 @@ Array [ inventoryLevels { edges { node { - available + quantities(names: [\\"incoming\\", \\"available\\", \\"committed\\", \\"reserved\\", \\"damaged\\", \\"safety_stock\\", \\"quality_control\\"]) { + name + quantity + } id location { id @@ -1577,7 +1622,10 @@ Array [ } } legacyResourceId - locationsCount + locationsCount { + count + precision + } provinceCodeOfOrigin requiresShipping sku @@ -1632,7 +1680,10 @@ Array [ name value } - sellingPlanGroupCount + sellingPlanGroupsCount { + count + precision + } sku storefrontId taxCode @@ -1795,7 +1846,10 @@ Array [ } } } - productsCount + productsCount { + count + precision + } ruleSet { appliedDisjunctively rules { @@ -2085,7 +2139,10 @@ Array [ } } } - mediaCount + mediaCount { + count + precision + } metafields { edges { node { @@ -2134,7 +2191,10 @@ Array [ productType publishedAt requiresSellingPlan - sellingPlanGroupCount + sellingPlanGroupsCount { + count + precision + } seo { description title @@ -2214,7 +2274,10 @@ Array [ inventoryLevels { edges { node { - available + quantities(names: [\\"incoming\\", \\"available\\", \\"committed\\", \\"reserved\\", \\"damaged\\", \\"safety_stock\\", \\"quality_control\\"]) { + name + quantity + } id location { id @@ -2223,7 +2286,10 @@ Array [ } } legacyResourceId - locationsCount + locationsCount { + count + precision + } provinceCodeOfOrigin requiresShipping sku @@ -2278,7 +2344,10 @@ Array [ name value } - sellingPlanGroupCount + sellingPlanGroupsCount { + count + precision + } sku storefrontId taxCode @@ -2441,7 +2510,10 @@ Array [ } } } - productsCount + productsCount { + count + precision + } ruleSet { appliedDisjunctively rules { diff --git a/packages/gatsby-source-shopify/__tests__/__snapshots__/create-schema-customization.ts.snap b/packages/gatsby-source-shopify/__tests__/__snapshots__/create-schema-customization.ts.snap index 883b214cf2479..0f1f80abe52ab 100644 --- a/packages/gatsby-source-shopify/__tests__/__snapshots__/create-schema-customization.ts.snap +++ b/packages/gatsby-source-shopify/__tests__/__snapshots__/create-schema-customization.ts.snap @@ -713,7 +713,7 @@ Array [ isGiftCard: Boolean! legacyResourceId: String! media: [__PREFIX__ShopifyMedia!]! @link(from: \\"media___NODE\\", by: \\"id\\") - mediaCount: Int! + mediaCount: Int! @proxy(from: \\"mediaCount.count\\") metafield(namespace: String! key: String!): __PREFIX__ShopifyMetafield metafields: [__PREFIX__ShopifyMetafield!]! @link(from: \\"metafields___NODE\\", by: \\"id\\") onlineStorePreviewUrl: String @@ -724,7 +724,7 @@ Array [ productType: String! publishedAt: Date @dateformat requiresSellingPlan: Boolean! - sellingPlanGroupCount: Int! + sellingPlanGroupCount: Int! @proxy(from: \\"sellingPlanGroupsCount.count\\") seo: __PREFIX__ShopifySEO! shopifyId: String! status: __PREFIX__ShopifyProductStatus! @@ -785,7 +785,7 @@ Array [ product: __PREFIX__ShopifyProduct! @link(from: \\"_product\\", by: \\"id\\") requiresShipping: Boolean! @deprecated(reason: \\"Use \`InventoryItem.requiresShipping\` instead.\\") selectedOptions: [__PREFIX__ShopifySelectedOption!]! - sellingPlanGroupCount: Int! + sellingPlanGroupCount: Int! @proxy(from: \\"sellingPlanGroupsCount.count\\") sku: String shopifyId: String! storefrontId: String! @@ -824,7 +824,7 @@ Array [ metafield(namespace: String! key: String!): __PREFIX__ShopifyMetafield metafields: [__PREFIX__ShopifyMetafield!]! @link(from: \\"metafields___NODE\\", by: \\"id\\") products: [__PREFIX__ShopifyProduct!]! @link(from: \\"products___NODE\\", by: \\"id\\") - productsCount: Int! + productsCount: Int! @proxy(from: \\"productsCount.count\\") ruleSet: __PREFIX__ShopifyCollectionRuleSet seo: __PREFIX__ShopifySEO! shopifyId: String! @@ -893,7 +893,7 @@ Array [ fulfillmentOrdersOptIn: Boolean! handle: String! inventoryManagement: Boolean! - productBased: Boolean! + productBased: Boolean! @deprecated(reason: \\"\`productBased\` will be removed in version 2024-07, non-product based fulfillment services are no longer supported\\") serviceName: String! shippingMethods: [__PREFIX__ShopifyShippingMethod!]! shopifyId: String! @@ -912,9 +912,9 @@ Array [ duplicateSkuCount: Int! harmonizedSystemCode: String inventoryHistoryUrl: String - inventoryLevels: [__PREFIX__ShopifyInventoryLevel!]! @link(from: \\"inventoryLevels___NODE\\", by: \\"id\\") + inventoryLevels: [__PREFIX__ShopifyInventoryLevel!]! @link(by: \\"id\\") @proxy(from: \\"inventoryLevels___NODE\\", fromNode: true) legacyResourceId: String! - locationsCount: Int! + locationsCount: Int! @proxy(from: \\"locationsCount.count\\") provinceCodeOfOrigin: String requiresShipping: Boolean! shopifyId: String! @@ -926,9 +926,21 @@ Array [ variant: __PREFIX__ShopifyProductVariantConnection! } + type __PREFIX__ShopifyInventoryQuantity { + name: String! + quantity: Int! + } + type __PREFIX__ShopifyInventoryLevel implements Node @dontInfer { _location: String! # Temporary field so we don't break existing users - available: Int! + quantities: [__PREFIX__ShopifyInventoryQuantity!]! + available: Int! @proxy(from: \\"quantities\\") @selectQuantityByName(name: \\"available\\") + incoming: Int! @proxy(from: \\"quantities\\") @selectQuantityByName(name: \\"incoming\\") + committed: Int! @proxy(from: \\"quantities\\") @selectQuantityByName(name: \\"committed\\") + reserved: Int! @proxy(from: \\"quantities\\") @selectQuantityByName(name: \\"reserved\\") + damaged: Int! @proxy(from: \\"quantities\\") @selectQuantityByName(name: \\"damaged\\") + safety_stock: Int! @proxy(from: \\"quantities\\") @selectQuantityByName(name: \\"safety_stock\\") + quality_control: Int! @proxy(from: \\"quantities\\") @selectQuantityByName(name: \\"quality_control\\") id: ID! location: __PREFIX__ShopifyLocation! @link(from: \\"_location\\", by: \\"id\\") shopifyId: String! @@ -1723,7 +1735,7 @@ Array [ isGiftCard: Boolean! legacyResourceId: String! media: [__PREFIX__ShopifyMedia!]! @link(from: \\"media___NODE\\", by: \\"id\\") - mediaCount: Int! + mediaCount: Int! @proxy(from: \\"mediaCount.count\\") metafield(namespace: String! key: String!): __PREFIX__ShopifyMetafield metafields: [__PREFIX__ShopifyMetafield!]! @link(from: \\"metafields___NODE\\", by: \\"id\\") onlineStorePreviewUrl: String @@ -1734,7 +1746,7 @@ Array [ productType: String! publishedAt: Date @dateformat requiresSellingPlan: Boolean! - sellingPlanGroupCount: Int! + sellingPlanGroupCount: Int! @proxy(from: \\"sellingPlanGroupsCount.count\\") seo: __PREFIX__ShopifySEO! shopifyId: String! status: __PREFIX__ShopifyProductStatus! @@ -1795,7 +1807,7 @@ Array [ product: __PREFIX__ShopifyProduct! @link(from: \\"_product\\", by: \\"id\\") requiresShipping: Boolean! @deprecated(reason: \\"Use \`InventoryItem.requiresShipping\` instead.\\") selectedOptions: [__PREFIX__ShopifySelectedOption!]! - sellingPlanGroupCount: Int! + sellingPlanGroupCount: Int! @proxy(from: \\"sellingPlanGroupsCount.count\\") sku: String shopifyId: String! storefrontId: String! @@ -2545,7 +2557,7 @@ Array [ isGiftCard: Boolean! legacyResourceId: String! media: [__PREFIX__ShopifyMedia!]! @link(from: \\"media___NODE\\", by: \\"id\\") - mediaCount: Int! + mediaCount: Int! @proxy(from: \\"mediaCount.count\\") metafield(namespace: String! key: String!): __PREFIX__ShopifyMetafield metafields: [__PREFIX__ShopifyMetafield!]! @link(from: \\"metafields___NODE\\", by: \\"id\\") onlineStorePreviewUrl: String @@ -2556,7 +2568,7 @@ Array [ productType: String! publishedAt: Date @dateformat requiresSellingPlan: Boolean! - sellingPlanGroupCount: Int! + sellingPlanGroupCount: Int! @proxy(from: \\"sellingPlanGroupsCount.count\\") seo: __PREFIX__ShopifySEO! shopifyId: String! status: __PREFIX__ShopifyProductStatus! @@ -2617,7 +2629,7 @@ Array [ product: __PREFIX__ShopifyProduct! @link(from: \\"_product\\", by: \\"id\\") requiresShipping: Boolean! @deprecated(reason: \\"Use \`InventoryItem.requiresShipping\` instead.\\") selectedOptions: [__PREFIX__ShopifySelectedOption!]! - sellingPlanGroupCount: Int! + sellingPlanGroupCount: Int! @proxy(from: \\"sellingPlanGroupsCount.count\\") sku: String shopifyId: String! storefrontId: String! @@ -2656,7 +2668,7 @@ Array [ metafield(namespace: String! key: String!): __PREFIX__ShopifyMetafield metafields: [__PREFIX__ShopifyMetafield!]! @link(from: \\"metafields___NODE\\", by: \\"id\\") products: [__PREFIX__ShopifyProduct!]! @link(from: \\"products___NODE\\", by: \\"id\\") - productsCount: Int! + productsCount: Int! @proxy(from: \\"productsCount.count\\") ruleSet: __PREFIX__ShopifyCollectionRuleSet seo: __PREFIX__ShopifySEO! shopifyId: String! @@ -2725,7 +2737,7 @@ Array [ fulfillmentOrdersOptIn: Boolean! handle: String! inventoryManagement: Boolean! - productBased: Boolean! + productBased: Boolean! @deprecated(reason: \\"\`productBased\` will be removed in version 2024-07, non-product based fulfillment services are no longer supported\\") serviceName: String! shippingMethods: [__PREFIX__ShopifyShippingMethod!]! shopifyId: String! @@ -2744,9 +2756,9 @@ Array [ duplicateSkuCount: Int! harmonizedSystemCode: String inventoryHistoryUrl: String - inventoryLevels: [__PREFIX__ShopifyInventoryLevel!]! @link(from: \\"inventoryLevels___NODE\\", by: \\"id\\") + inventoryLevels: [__PREFIX__ShopifyInventoryLevel!]! @link(by: \\"id\\") @proxy(from: \\"inventoryLevels___NODE\\", fromNode: true) legacyResourceId: String! - locationsCount: Int! + locationsCount: Int! @proxy(from: \\"locationsCount.count\\") provinceCodeOfOrigin: String requiresShipping: Boolean! shopifyId: String! @@ -2758,9 +2770,21 @@ Array [ variant: __PREFIX__ShopifyProductVariantConnection! } + type __PREFIX__ShopifyInventoryQuantity { + name: String! + quantity: Int! + } + type __PREFIX__ShopifyInventoryLevel implements Node @dontInfer { _location: String! # Temporary field so we don't break existing users - available: Int! + quantities: [__PREFIX__ShopifyInventoryQuantity!]! + available: Int! @proxy(from: \\"quantities\\") @selectQuantityByName(name: \\"available\\") + incoming: Int! @proxy(from: \\"quantities\\") @selectQuantityByName(name: \\"incoming\\") + committed: Int! @proxy(from: \\"quantities\\") @selectQuantityByName(name: \\"committed\\") + reserved: Int! @proxy(from: \\"quantities\\") @selectQuantityByName(name: \\"reserved\\") + damaged: Int! @proxy(from: \\"quantities\\") @selectQuantityByName(name: \\"damaged\\") + safety_stock: Int! @proxy(from: \\"quantities\\") @selectQuantityByName(name: \\"safety_stock\\") + quality_control: Int! @proxy(from: \\"quantities\\") @selectQuantityByName(name: \\"quality_control\\") id: ID! location: __PREFIX__ShopifyLocation! @link(from: \\"_location\\", by: \\"id\\") shopifyId: String! @@ -3550,7 +3574,7 @@ Array [ isGiftCard: Boolean! legacyResourceId: String! media: [__PREFIX__ShopifyMedia!]! @link(from: \\"media___NODE\\", by: \\"id\\") - mediaCount: Int! + mediaCount: Int! @proxy(from: \\"mediaCount.count\\") metafield(namespace: String! key: String!): __PREFIX__ShopifyMetafield metafields: [__PREFIX__ShopifyMetafield!]! @link(from: \\"metafields___NODE\\", by: \\"id\\") onlineStorePreviewUrl: String @@ -3561,7 +3585,7 @@ Array [ productType: String! publishedAt: Date @dateformat requiresSellingPlan: Boolean! - sellingPlanGroupCount: Int! + sellingPlanGroupCount: Int! @proxy(from: \\"sellingPlanGroupsCount.count\\") seo: __PREFIX__ShopifySEO! shopifyId: String! status: __PREFIX__ShopifyProductStatus! @@ -3622,7 +3646,7 @@ Array [ product: __PREFIX__ShopifyProduct! @link(from: \\"_product\\", by: \\"id\\") requiresShipping: Boolean! @deprecated(reason: \\"Use \`InventoryItem.requiresShipping\` instead.\\") selectedOptions: [__PREFIX__ShopifySelectedOption!]! - sellingPlanGroupCount: Int! + sellingPlanGroupCount: Int! @proxy(from: \\"sellingPlanGroupsCount.count\\") sku: String shopifyId: String! storefrontId: String! diff --git a/packages/gatsby-source-shopify/__tests__/__snapshots__/source-from-operation.ts.snap b/packages/gatsby-source-shopify/__tests__/__snapshots__/source-from-operation.ts.snap index 4f14b1f94081e..fa15496727af0 100644 --- a/packages/gatsby-source-shopify/__tests__/__snapshots__/source-from-operation.ts.snap +++ b/packages/gatsby-source-shopify/__tests__/__snapshots__/source-from-operation.ts.snap @@ -29,7 +29,10 @@ Array [ "id": "gid://shopify/Product/6950279086286", "isGiftCard": false, "legacyResourceId": "6950279086286", - "mediaCount": 1, + "mediaCount": Object { + "count": 1, + "precision": "EXACT", + }, "onlineStorePreviewUrl": "https://atomic-digital-studio-test.myshopify.com/products/test-product", "onlineStoreUrl": null, "options": Array [ @@ -67,7 +70,10 @@ Array [ "productType": "Test Type", "publishedAt": "2022-03-14T21:26:01Z", "requiresSellingPlan": false, - "sellingPlanGroupCount": 0, + "sellingPlanGroupsCount": Object { + "count": 0, + "precision": "EXACT", + }, "seo": Object { "description": null, "title": null, @@ -149,7 +155,10 @@ Array [ "id": "gid://shopify/Product/6966721052878", "isGiftCard": false, "legacyResourceId": "6966721052878", - "mediaCount": 0, + "mediaCount": Object { + "count": 0, + "precision": "EXACT", + }, "onlineStorePreviewUrl": "https://atomic-digital-studio-test.myshopify.com/products/copy-of-test-product", "onlineStoreUrl": null, "options": Array [ @@ -187,7 +196,10 @@ Array [ "productType": "Test Type", "publishedAt": "2022-03-14T22:38:58Z", "requiresSellingPlan": false, - "sellingPlanGroupCount": 0, + "sellingPlanGroupsCount": Object { + "count": 0, + "precision": "EXACT", + }, "seo": Object { "description": null, "title": null, @@ -236,12 +248,15 @@ Array [ "id": "5e2d818c-9edd-5d9a-9b8b-a87b59518efc", "image": null, "internal": Object { - "contentDigest": "beb270066b5a208a02aba997c30883c2", + "contentDigest": "57b8b2dad5372eae55550ccf5d4920c9", "type": "ShopifyCollection", }, "legacyResourceId": "278407151822", "metafields___NODE": Array [], - "productsCount": 2, + "productsCount": Object { + "count": 2, + "precision": "EXACT", + }, "products___NODE": Array [], "ruleSet": Object { "appliedDisjunctively": false, @@ -297,7 +312,10 @@ Array [ "id": "gid://shopify/Product/6950279086286", "isGiftCard": false, "legacyResourceId": "6950279086286", - "mediaCount": 1, + "mediaCount": Object { + "count": 1, + "precision": "EXACT", + }, "onlineStorePreviewUrl": "https://atomic-digital-studio-test.myshopify.com/products/test-product", "onlineStoreUrl": null, "options": Array [ @@ -335,7 +353,10 @@ Array [ "productType": "Test Type", "publishedAt": "2022-03-14T21:26:01Z", "requiresSellingPlan": false, - "sellingPlanGroupCount": 0, + "sellingPlanGroupsCount": Object { + "count": 0, + "precision": "EXACT", + }, "seo": Object { "description": null, "title": null, @@ -417,7 +438,10 @@ Array [ "id": "gid://shopify/Product/6966721052878", "isGiftCard": false, "legacyResourceId": "6966721052878", - "mediaCount": 0, + "mediaCount": Object { + "count": 0, + "precision": "EXACT", + }, "onlineStorePreviewUrl": "https://atomic-digital-studio-test.myshopify.com/products/copy-of-test-product", "onlineStoreUrl": null, "options": Array [ @@ -455,7 +479,10 @@ Array [ "productType": "Test Type", "publishedAt": "2022-03-14T22:38:58Z", "requiresSellingPlan": false, - "sellingPlanGroupCount": 0, + "sellingPlanGroupsCount": Object { + "count": 0, + "precision": "EXACT", + }, "seo": Object { "description": null, "title": null, @@ -504,12 +531,15 @@ Array [ "id": "5e2d818c-9edd-5d9a-9b8b-a87b59518efc", "image": null, "internal": Object { - "contentDigest": "beb270066b5a208a02aba997c30883c2", + "contentDigest": "57b8b2dad5372eae55550ccf5d4920c9", "type": "ShopifyCollection", }, "legacyResourceId": "278407151822", "metafields___NODE": Array [], - "productsCount": 2, + "productsCount": Object { + "count": 2, + "precision": "EXACT", + }, "products___NODE": Array [], "ruleSet": Object { "appliedDisjunctively": false, @@ -565,7 +595,10 @@ Array [ "id": "gid://shopify/Product/6950279086286", "isGiftCard": false, "legacyResourceId": "6950279086286", - "mediaCount": 1, + "mediaCount": Object { + "count": 1, + "precision": "EXACT", + }, "onlineStorePreviewUrl": "https://atomic-digital-studio-test.myshopify.com/products/test-product", "onlineStoreUrl": null, "options": Array [ @@ -603,7 +636,10 @@ Array [ "productType": "Test Type", "publishedAt": "2022-03-14T21:26:01Z", "requiresSellingPlan": false, - "sellingPlanGroupCount": 0, + "sellingPlanGroupsCount": Object { + "count": 0, + "precision": "EXACT", + }, "seo": Object { "description": null, "title": null, @@ -685,7 +721,10 @@ Array [ "id": "gid://shopify/Product/6966721052878", "isGiftCard": false, "legacyResourceId": "6966721052878", - "mediaCount": 0, + "mediaCount": Object { + "count": 0, + "precision": "EXACT", + }, "onlineStorePreviewUrl": "https://atomic-digital-studio-test.myshopify.com/products/copy-of-test-product", "onlineStoreUrl": null, "options": Array [ @@ -723,7 +762,10 @@ Array [ "productType": "Test Type", "publishedAt": "2022-03-14T22:38:58Z", "requiresSellingPlan": false, - "sellingPlanGroupCount": 0, + "sellingPlanGroupsCount": Object { + "count": 0, + "precision": "EXACT", + }, "seo": Object { "description": null, "title": null, @@ -833,7 +875,10 @@ Array [ "id": "gid://shopify/Product/6950279086286", "isGiftCard": false, "legacyResourceId": "6950279086286", - "mediaCount": 1, + "mediaCount": Object { + "count": 1, + "precision": "EXACT", + }, "onlineStorePreviewUrl": "https://atomic-digital-studio-test.myshopify.com/products/test-product", "onlineStoreUrl": null, "options": Array [ @@ -871,7 +916,10 @@ Array [ "productType": "Test Type", "publishedAt": "2022-03-14T21:26:01Z", "requiresSellingPlan": false, - "sellingPlanGroupCount": 0, + "sellingPlanGroupsCount": Object { + "count": 0, + "precision": "EXACT", + }, "seo": Object { "description": null, "title": null, @@ -953,7 +1001,10 @@ Array [ "id": "gid://shopify/Product/6966721052878", "isGiftCard": false, "legacyResourceId": "6966721052878", - "mediaCount": 0, + "mediaCount": Object { + "count": 0, + "precision": "EXACT", + }, "onlineStorePreviewUrl": "https://atomic-digital-studio-test.myshopify.com/products/copy-of-test-product", "onlineStoreUrl": null, "options": Array [ @@ -991,7 +1042,10 @@ Array [ "productType": "Test Type", "publishedAt": "2022-03-14T22:38:58Z", "requiresSellingPlan": false, - "sellingPlanGroupCount": 0, + "sellingPlanGroupsCount": Object { + "count": 0, + "precision": "EXACT", + }, "seo": Object { "description": null, "title": null, @@ -1101,7 +1155,10 @@ Array [ "id": "gid://shopify/Product/6950279086286", "isGiftCard": false, "legacyResourceId": "6950279086286", - "mediaCount": 1, + "mediaCount": Object { + "count": 1, + "precision": "EXACT", + }, "onlineStorePreviewUrl": "https://atomic-digital-studio-test.myshopify.com/products/test-product", "onlineStoreUrl": null, "options": Array [ @@ -1139,7 +1196,10 @@ Array [ "productType": "Test Type", "publishedAt": "2022-03-14T21:26:01Z", "requiresSellingPlan": false, - "sellingPlanGroupCount": 0, + "sellingPlanGroupsCount": Object { + "count": 0, + "precision": "EXACT", + }, "seo": Object { "description": null, "title": null, @@ -1221,7 +1281,10 @@ Array [ "id": "gid://shopify/Product/6966721052878", "isGiftCard": false, "legacyResourceId": "6966721052878", - "mediaCount": 0, + "mediaCount": Object { + "count": 0, + "precision": "EXACT", + }, "onlineStorePreviewUrl": "https://atomic-digital-studio-test.myshopify.com/products/copy-of-test-product", "onlineStoreUrl": null, "options": Array [ @@ -1259,7 +1322,10 @@ Array [ "productType": "Test Type", "publishedAt": "2022-03-14T22:38:58Z", "requiresSellingPlan": false, - "sellingPlanGroupCount": 0, + "sellingPlanGroupsCount": Object { + "count": 0, + "precision": "EXACT", + }, "seo": Object { "description": null, "title": null, @@ -1360,7 +1426,10 @@ Array [ "id": "gid://shopify/Product/6950279086286", "isGiftCard": false, "legacyResourceId": "6950279086286", - "mediaCount": 1, + "mediaCount": Object { + "count": 1, + "precision": "EXACT", + }, "onlineStorePreviewUrl": "https://atomic-digital-studio-test.myshopify.com/products/test-product", "onlineStoreUrl": null, "options": Array [ @@ -1398,7 +1467,10 @@ Array [ "productType": "Test Type", "publishedAt": "2022-03-14T21:26:01Z", "requiresSellingPlan": false, - "sellingPlanGroupCount": 0, + "sellingPlanGroupsCount": Object { + "count": 0, + "precision": "EXACT", + }, "seo": Object { "description": null, "title": null, @@ -1480,7 +1552,10 @@ Array [ "id": "gid://shopify/Product/6966721052878", "isGiftCard": false, "legacyResourceId": "6966721052878", - "mediaCount": 0, + "mediaCount": Object { + "count": 0, + "precision": "EXACT", + }, "onlineStorePreviewUrl": "https://atomic-digital-studio-test.myshopify.com/products/copy-of-test-product", "onlineStoreUrl": null, "options": Array [ @@ -1518,7 +1593,10 @@ Array [ "productType": "Test Type", "publishedAt": "2022-03-14T22:38:58Z", "requiresSellingPlan": false, - "sellingPlanGroupCount": 0, + "sellingPlanGroupsCount": Object { + "count": 0, + "precision": "EXACT", + }, "seo": Object { "description": null, "title": null, @@ -1619,7 +1697,10 @@ Array [ "id": "gid://shopify/Product/6950279086286", "isGiftCard": false, "legacyResourceId": "6950279086286", - "mediaCount": 1, + "mediaCount": Object { + "count": 1, + "precision": "EXACT", + }, "onlineStorePreviewUrl": "https://atomic-digital-studio-test.myshopify.com/products/test-product", "onlineStoreUrl": null, "options": Array [ @@ -1657,7 +1738,10 @@ Array [ "productType": "Test Type", "publishedAt": "2022-03-14T21:26:01Z", "requiresSellingPlan": false, - "sellingPlanGroupCount": 0, + "sellingPlanGroupsCount": Object { + "count": 0, + "precision": "EXACT", + }, "seo": Object { "description": null, "title": null, @@ -1739,7 +1823,10 @@ Array [ "id": "gid://shopify/Product/6966721052878", "isGiftCard": false, "legacyResourceId": "6966721052878", - "mediaCount": 0, + "mediaCount": Object { + "count": 0, + "precision": "EXACT", + }, "onlineStorePreviewUrl": "https://atomic-digital-studio-test.myshopify.com/products/copy-of-test-product", "onlineStoreUrl": null, "options": Array [ @@ -1777,7 +1864,10 @@ Array [ "productType": "Test Type", "publishedAt": "2022-03-14T22:38:58Z", "requiresSellingPlan": false, - "sellingPlanGroupCount": 0, + "sellingPlanGroupsCount": Object { + "count": 0, + "precision": "EXACT", + }, "seo": Object { "description": null, "title": null, @@ -1853,12 +1943,15 @@ Array [ "hasOutOfStockVariants": true, "id": "1386d0f3-354b-584c-a6bb-d11936c8f6fb", "internal": Object { - "contentDigest": "a41f9430e873b83c81f6e5b6d9bd10e6", + "contentDigest": "551a7887f6e65502ba6b8895bac273e8", "type": "ShopifyProduct", }, "isGiftCard": false, "legacyResourceId": "6966721052878", - "mediaCount": 0, + "mediaCount": Object { + "count": 0, + "precision": "EXACT", + }, "media___NODE": Array [], "metafields___NODE": Array [ "e3bdda06-d619-5445-8b4a-d1155678928c", @@ -1900,7 +1993,10 @@ Array [ "productType": "Test Type", "publishedAt": "2022-03-14T22:38:58Z", "requiresSellingPlan": false, - "sellingPlanGroupCount": 0, + "sellingPlanGroupsCount": Object { + "count": 0, + "precision": "EXACT", + }, "seo": Object { "description": null, "title": null, @@ -2011,12 +2107,15 @@ Array [ "hasOutOfStockVariants": false, "id": "87b524a6-a707-5eb9-b193-059b3fcf96e5", "internal": Object { - "contentDigest": "87b12a51632f4ce873d5342bbf8232b2", + "contentDigest": "5ff2f61556bdaacc8cd5baa0ed5bfd8f", "type": "ShopifyProduct", }, "isGiftCard": false, "legacyResourceId": "6950279086286", - "mediaCount": 1, + "mediaCount": Object { + "count": 1, + "precision": "EXACT", + }, "media___NODE": Array [ "8fc15b46-8400-5778-b85c-05db5c009326", ], @@ -2060,7 +2159,10 @@ Array [ "productType": "Test Type", "publishedAt": "2022-03-14T21:26:01Z", "requiresSellingPlan": false, - "sellingPlanGroupCount": 0, + "sellingPlanGroupsCount": Object { + "count": 0, + "precision": "EXACT", + }, "seo": Object { "description": null, "title": null, @@ -2113,7 +2215,10 @@ Array [ "id": "gid://shopify/Product/6950279086286", "isGiftCard": false, "legacyResourceId": "6950279086286", - "mediaCount": 1, + "mediaCount": Object { + "count": 1, + "precision": "EXACT", + }, "onlineStorePreviewUrl": "https://atomic-digital-studio-test.myshopify.com/products/test-product", "onlineStoreUrl": null, "options": Array [ @@ -2151,7 +2256,10 @@ Array [ "productType": "Test Type", "publishedAt": "2022-03-14T21:26:01Z", "requiresSellingPlan": false, - "sellingPlanGroupCount": 0, + "sellingPlanGroupsCount": Object { + "count": 0, + "precision": "EXACT", + }, "seo": Object { "description": null, "title": null, @@ -2233,7 +2341,10 @@ Array [ "id": "gid://shopify/Product/6966721052878", "isGiftCard": false, "legacyResourceId": "6966721052878", - "mediaCount": 0, + "mediaCount": Object { + "count": 0, + "precision": "EXACT", + }, "onlineStorePreviewUrl": "https://atomic-digital-studio-test.myshopify.com/products/copy-of-test-product", "onlineStoreUrl": null, "options": Array [ @@ -2271,7 +2382,10 @@ Array [ "productType": "Test Type", "publishedAt": "2022-03-14T22:38:58Z", "requiresSellingPlan": false, - "sellingPlanGroupCount": 0, + "sellingPlanGroupsCount": Object { + "count": 0, + "precision": "EXACT", + }, "seo": Object { "description": null, "title": null, @@ -2347,12 +2461,15 @@ Array [ "hasOutOfStockVariants": true, "id": "1386d0f3-354b-584c-a6bb-d11936c8f6fb", "internal": Object { - "contentDigest": "a41f9430e873b83c81f6e5b6d9bd10e6", + "contentDigest": "551a7887f6e65502ba6b8895bac273e8", "type": "ShopifyProduct", }, "isGiftCard": false, "legacyResourceId": "6966721052878", - "mediaCount": 0, + "mediaCount": Object { + "count": 0, + "precision": "EXACT", + }, "media___NODE": Array [], "metafields___NODE": Array [ "e3bdda06-d619-5445-8b4a-d1155678928c", @@ -2394,7 +2511,10 @@ Array [ "productType": "Test Type", "publishedAt": "2022-03-14T22:38:58Z", "requiresSellingPlan": false, - "sellingPlanGroupCount": 0, + "sellingPlanGroupsCount": Object { + "count": 0, + "precision": "EXACT", + }, "seo": Object { "description": null, "title": null, @@ -2505,12 +2625,15 @@ Array [ "hasOutOfStockVariants": false, "id": "87b524a6-a707-5eb9-b193-059b3fcf96e5", "internal": Object { - "contentDigest": "87b12a51632f4ce873d5342bbf8232b2", + "contentDigest": "5ff2f61556bdaacc8cd5baa0ed5bfd8f", "type": "ShopifyProduct", }, "isGiftCard": false, "legacyResourceId": "6950279086286", - "mediaCount": 1, + "mediaCount": Object { + "count": 1, + "precision": "EXACT", + }, "media___NODE": Array [ "8fc15b46-8400-5778-b85c-05db5c009326", ], @@ -2554,7 +2677,10 @@ Array [ "productType": "Test Type", "publishedAt": "2022-03-14T21:26:01Z", "requiresSellingPlan": false, - "sellingPlanGroupCount": 0, + "sellingPlanGroupsCount": Object { + "count": 0, + "precision": "EXACT", + }, "seo": Object { "description": null, "title": null, @@ -2607,7 +2733,10 @@ Array [ "id": "gid://shopify/Product/6950279086286", "isGiftCard": false, "legacyResourceId": "6950279086286", - "mediaCount": 1, + "mediaCount": Object { + "count": 1, + "precision": "EXACT", + }, "onlineStorePreviewUrl": "https://atomic-digital-studio-test.myshopify.com/products/test-product", "onlineStoreUrl": null, "options": Array [ @@ -2645,7 +2774,10 @@ Array [ "productType": "Test Type", "publishedAt": "2022-03-14T21:26:01Z", "requiresSellingPlan": false, - "sellingPlanGroupCount": 0, + "sellingPlanGroupsCount": Object { + "count": 0, + "precision": "EXACT", + }, "seo": Object { "description": null, "title": null, @@ -2727,7 +2859,10 @@ Array [ "id": "gid://shopify/Product/6966721052878", "isGiftCard": false, "legacyResourceId": "6966721052878", - "mediaCount": 0, + "mediaCount": Object { + "count": 0, + "precision": "EXACT", + }, "onlineStorePreviewUrl": "https://atomic-digital-studio-test.myshopify.com/products/copy-of-test-product", "onlineStoreUrl": null, "options": Array [ @@ -2765,7 +2900,10 @@ Array [ "productType": "Test Type", "publishedAt": "2022-03-14T22:38:58Z", "requiresSellingPlan": false, - "sellingPlanGroupCount": 0, + "sellingPlanGroupsCount": Object { + "count": 0, + "precision": "EXACT", + }, "seo": Object { "description": null, "title": null, @@ -2806,15 +2944,44 @@ Array [ Object { "__parentId": "gid://shopify/ProductVariant/41009157308622", "_location": "e3e3dfac-3cbd-5cef-b3d6-3fd214f93ab8", - "available": 0, "id": "cedae3ee-f225-5c34-9dd8-f1a25f8d810c", "internal": Object { - "contentDigest": "452845f46b6d785b2a2b79f1c19cf91b", + "contentDigest": "66722f007ac1579519fbb7a397fddaed", "type": "ShopifyInventoryLevel", }, "location": Object { "shopifyId": "gid://shopify/Location/57173475534", }, + "quantities": Array [ + Object { + "name": "incoming", + "quantity": 0, + }, + Object { + "name": "available", + "quantity": 0, + }, + Object { + "name": "committed", + "quantity": 0, + }, + Object { + "name": "reserved", + "quantity": 0, + }, + Object { + "name": "damaged", + "quantity": 0, + }, + Object { + "name": "safety_stock", + "quantity": 0, + }, + Object { + "name": "quality_control", + "quantity": 0, + }, + ], "shopifyId": "gid://shopify/InventoryLevel/91371143374?inventory_item_id=43101443326158", }, ], @@ -2829,18 +2996,24 @@ Array [ "id": "cba433a6-1513-576f-97c0-80b36fb8afa6", "image": null, "internal": Object { - "contentDigest": "6153d74ac94feac2cf2a9e198017ae0e", + "contentDigest": "9931abd3f939451b136f77e7c573bc26", "type": "ShopifyProductVariant", }, "inventoryItem": Object { "_variant": "cba433a6-1513-576f-97c0-80b36fb8afa6", "countryCodeOfOrigin": null, "createdAt": "2022-03-14T22:38:58Z", - "duplicateSkuCount": 0, + "duplicateSkuCount": Object { + "count": 0, + "precision": "EXACT", + }, "harmonizedSystemCode": null, "inventoryHistoryUrl": "https://atomic-digital-studio-test.myshopify.com/admin/products/6966721052878/variants/41009157308622/inventory_history", "legacyResourceId": "43101443326158", - "locationsCount": 1, + "locationsCount": Object { + "count": 1, + "precision": "EXACT", + }, "provinceCodeOfOrigin": null, "requiresShipping": true, "shopifyId": "gid://shopify/InventoryItem/43101443326158", @@ -2876,7 +3049,10 @@ Array [ "value": "Large", }, ], - "sellingPlanGroupCount": 0, + "sellingPlanGroupsCount": Object { + "count": 0, + "precision": "EXACT", + }, "shopifyId": "gid://shopify/ProductVariant/41009157308622", "sku": null, "storefrontId": "Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0VmFyaWFudC80MTAwOTE1NzMwODYyMg==", @@ -2892,15 +3068,44 @@ Array [ Object { "__parentId": "gid://shopify/ProductVariant/41009157275854", "_location": "e3e3dfac-3cbd-5cef-b3d6-3fd214f93ab8", - "available": 0, "id": "8970ecd9-9a83-5e55-915b-682cfff58699", "internal": Object { - "contentDigest": "900b607c641a129fc9b314be805064ac", + "contentDigest": "3ee56ed994b624cb1de780d06a481f37", "type": "ShopifyInventoryLevel", }, "location": Object { "shopifyId": "gid://shopify/Location/57173475534", }, + "quantities": Array [ + Object { + "name": "incoming", + "quantity": 0, + }, + Object { + "name": "available", + "quantity": 0, + }, + Object { + "name": "committed", + "quantity": 0, + }, + Object { + "name": "reserved", + "quantity": 0, + }, + Object { + "name": "damaged", + "quantity": 0, + }, + Object { + "name": "safety_stock", + "quantity": 0, + }, + Object { + "name": "quality_control", + "quantity": 0, + }, + ], "shopifyId": "gid://shopify/InventoryLevel/91371143374?inventory_item_id=43101443293390", }, ], @@ -2915,18 +3120,24 @@ Array [ "id": "a0191127-d288-510d-94e5-14f7a6404454", "image": null, "internal": Object { - "contentDigest": "88ceea90890315ebbd90fa608fe8fc87", + "contentDigest": "f241fc91a88ebf40d208b9e798bf3b71", "type": "ShopifyProductVariant", }, "inventoryItem": Object { "_variant": "a0191127-d288-510d-94e5-14f7a6404454", "countryCodeOfOrigin": null, "createdAt": "2022-03-14T22:38:58Z", - "duplicateSkuCount": 0, + "duplicateSkuCount": Object { + "count": 0, + "precision": "EXACT", + }, "harmonizedSystemCode": null, "inventoryHistoryUrl": "https://atomic-digital-studio-test.myshopify.com/admin/products/6966721052878/variants/41009157275854/inventory_history", "legacyResourceId": "43101443293390", - "locationsCount": 1, + "locationsCount": Object { + "count": 1, + "precision": "EXACT", + }, "provinceCodeOfOrigin": null, "requiresShipping": true, "shopifyId": "gid://shopify/InventoryItem/43101443293390", @@ -2962,7 +3173,10 @@ Array [ "value": "Medium", }, ], - "sellingPlanGroupCount": 0, + "sellingPlanGroupsCount": Object { + "count": 0, + "precision": "EXACT", + }, "shopifyId": "gid://shopify/ProductVariant/41009157275854", "sku": null, "storefrontId": "Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0VmFyaWFudC80MTAwOTE1NzI3NTg1NA==", @@ -2978,15 +3192,44 @@ Array [ Object { "__parentId": "gid://shopify/ProductVariant/41009157243086", "_location": "e3e3dfac-3cbd-5cef-b3d6-3fd214f93ab8", - "available": 0, "id": "6eeb7894-1eb4-5556-a797-396fdf229a63", "internal": Object { - "contentDigest": "ecd7ff4a931ca7f110d9da8e085c69ed", + "contentDigest": "07f7fb2e63f13bb1a969f2e58d3612b3", "type": "ShopifyInventoryLevel", }, "location": Object { "shopifyId": "gid://shopify/Location/57173475534", }, + "quantities": Array [ + Object { + "name": "incoming", + "quantity": 0, + }, + Object { + "name": "available", + "quantity": 0, + }, + Object { + "name": "committed", + "quantity": 0, + }, + Object { + "name": "reserved", + "quantity": 0, + }, + Object { + "name": "damaged", + "quantity": 0, + }, + Object { + "name": "safety_stock", + "quantity": 0, + }, + Object { + "name": "quality_control", + "quantity": 0, + }, + ], "shopifyId": "gid://shopify/InventoryLevel/91371143374?inventory_item_id=43101443260622", }, ], @@ -3001,18 +3244,24 @@ Array [ "id": "435874ba-a8b0-5b29-a96a-8691e694bf3a", "image": null, "internal": Object { - "contentDigest": "ac479013a12b548eb17f918738d4507b", + "contentDigest": "1b9814e33e275046588c2a2f7f54ebca", "type": "ShopifyProductVariant", }, "inventoryItem": Object { "_variant": "435874ba-a8b0-5b29-a96a-8691e694bf3a", "countryCodeOfOrigin": null, "createdAt": "2022-03-14T22:38:58Z", - "duplicateSkuCount": 0, + "duplicateSkuCount": Object { + "count": 0, + "precision": "EXACT", + }, "harmonizedSystemCode": null, "inventoryHistoryUrl": "https://atomic-digital-studio-test.myshopify.com/admin/products/6966721052878/variants/41009157243086/inventory_history", "legacyResourceId": "43101443260622", - "locationsCount": 1, + "locationsCount": Object { + "count": 1, + "precision": "EXACT", + }, "provinceCodeOfOrigin": null, "requiresShipping": true, "shopifyId": "gid://shopify/InventoryItem/43101443260622", @@ -3048,7 +3297,10 @@ Array [ "value": "Small", }, ], - "sellingPlanGroupCount": 0, + "sellingPlanGroupsCount": Object { + "count": 0, + "precision": "EXACT", + }, "shopifyId": "gid://shopify/ProductVariant/41009157243086", "sku": null, "storefrontId": "Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0VmFyaWFudC80MTAwOTE1NzI0MzA4Ng==", @@ -3064,15 +3316,44 @@ Array [ Object { "__parentId": "gid://shopify/ProductVariant/41007759655118", "_location": "e3e3dfac-3cbd-5cef-b3d6-3fd214f93ab8", - "available": 1, "id": "e8f4985b-ed74-5a19-836d-b5d310c277e5", "internal": Object { - "contentDigest": "9d3d2135ce505be5bb10cb49481048fa", + "contentDigest": "51397f4cd40bd4e008b002b73797c3b8", "type": "ShopifyInventoryLevel", }, "location": Object { "shopifyId": "gid://shopify/Location/57173475534", }, + "quantities": Array [ + Object { + "name": "incoming", + "quantity": 0, + }, + Object { + "name": "available", + "quantity": 1, + }, + Object { + "name": "committed", + "quantity": 0, + }, + Object { + "name": "reserved", + "quantity": 0, + }, + Object { + "name": "damaged", + "quantity": 0, + }, + Object { + "name": "safety_stock", + "quantity": 0, + }, + Object { + "name": "quality_control", + "quantity": 0, + }, + ], "shopifyId": "gid://shopify/InventoryLevel/91371143374?inventory_item_id=43100044460238", }, ], @@ -3095,18 +3376,24 @@ Array [ "width": 1920, }, "internal": Object { - "contentDigest": "cb4f9b7f7aa04ed5f938999889d1a7be", + "contentDigest": "07222beb2c0e34a4602665d83d0b0c21", "type": "ShopifyProductVariant", }, "inventoryItem": Object { "_variant": "480d2d09-c1b1-5f7c-94a2-635e73e50ef4", "countryCodeOfOrigin": null, "createdAt": "2022-03-14T13:53:31Z", - "duplicateSkuCount": 0, + "duplicateSkuCount": Object { + "count": 0, + "precision": "EXACT", + }, "harmonizedSystemCode": null, "inventoryHistoryUrl": "https://atomic-digital-studio-test.myshopify.com/admin/products/6950279086286/variants/41007759655118/inventory_history", "legacyResourceId": "43100044460238", - "locationsCount": 1, + "locationsCount": Object { + "count": 1, + "precision": "EXACT", + }, "provinceCodeOfOrigin": null, "requiresShipping": true, "shopifyId": "gid://shopify/InventoryItem/43100044460238", @@ -3142,7 +3429,10 @@ Array [ "value": "Large", }, ], - "sellingPlanGroupCount": 0, + "sellingPlanGroupsCount": Object { + "count": 0, + "precision": "EXACT", + }, "shopifyId": "gid://shopify/ProductVariant/41007759655118", "sku": "", "storefrontId": "Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0VmFyaWFudC80MTAwNzc1OTY1NTExOA==", @@ -3158,15 +3448,44 @@ Array [ Object { "__parentId": "gid://shopify/ProductVariant/41007759622350", "_location": "e3e3dfac-3cbd-5cef-b3d6-3fd214f93ab8", - "available": 1, "id": "453dda5f-1323-5aa3-8e75-9a0dd08025c2", "internal": Object { - "contentDigest": "1d0ee94937b283d852538b020a63a1c7", + "contentDigest": "bd4f5897a47f9c8912acd6d3da46fcfb", "type": "ShopifyInventoryLevel", }, "location": Object { "shopifyId": "gid://shopify/Location/57173475534", }, + "quantities": Array [ + Object { + "name": "incoming", + "quantity": 0, + }, + Object { + "name": "available", + "quantity": 1, + }, + Object { + "name": "committed", + "quantity": 0, + }, + Object { + "name": "reserved", + "quantity": 0, + }, + Object { + "name": "damaged", + "quantity": 0, + }, + Object { + "name": "safety_stock", + "quantity": 0, + }, + Object { + "name": "quality_control", + "quantity": 0, + }, + ], "shopifyId": "gid://shopify/InventoryLevel/91371143374?inventory_item_id=43100044427470", }, ], @@ -3189,18 +3508,24 @@ Array [ "width": 1920, }, "internal": Object { - "contentDigest": "9c925f92d1e4581f17799fc3101ccd5d", + "contentDigest": "b39113e46e31a3e2d5a02e7e605b5bd4", "type": "ShopifyProductVariant", }, "inventoryItem": Object { "_variant": "266c6a92-078a-519d-8c03-257b4ed15b84", "countryCodeOfOrigin": null, "createdAt": "2022-03-14T13:53:31Z", - "duplicateSkuCount": 0, + "duplicateSkuCount": Object { + "count": 0, + "precision": "EXACT", + }, "harmonizedSystemCode": null, "inventoryHistoryUrl": "https://atomic-digital-studio-test.myshopify.com/admin/products/6950279086286/variants/41007759622350/inventory_history", "legacyResourceId": "43100044427470", - "locationsCount": 1, + "locationsCount": Object { + "count": 1, + "precision": "EXACT", + }, "provinceCodeOfOrigin": null, "requiresShipping": true, "shopifyId": "gid://shopify/InventoryItem/43100044427470", @@ -3236,7 +3561,10 @@ Array [ "value": "Medium", }, ], - "sellingPlanGroupCount": 0, + "sellingPlanGroupsCount": Object { + "count": 0, + "precision": "EXACT", + }, "shopifyId": "gid://shopify/ProductVariant/41007759622350", "sku": "", "storefrontId": "Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0VmFyaWFudC80MTAwNzc1OTYyMjM1MA==", @@ -3252,15 +3580,44 @@ Array [ Object { "__parentId": "gid://shopify/ProductVariant/41007759589582", "_location": "e3e3dfac-3cbd-5cef-b3d6-3fd214f93ab8", - "available": 1, "id": "2261ddf5-7c64-5934-a990-7dc64fe17040", "internal": Object { - "contentDigest": "662364c3f80cabf5fdad46fe50fe71eb", + "contentDigest": "23d2d35e04ff3fa2f5b43c1d3f2c0f28", "type": "ShopifyInventoryLevel", }, "location": Object { "shopifyId": "gid://shopify/Location/57173475534", }, + "quantities": Array [ + Object { + "name": "incoming", + "quantity": 0, + }, + Object { + "name": "available", + "quantity": 1, + }, + Object { + "name": "committed", + "quantity": 0, + }, + Object { + "name": "reserved", + "quantity": 0, + }, + Object { + "name": "damaged", + "quantity": 0, + }, + Object { + "name": "safety_stock", + "quantity": 0, + }, + Object { + "name": "quality_control", + "quantity": 0, + }, + ], "shopifyId": "gid://shopify/InventoryLevel/91371143374?inventory_item_id=43100044394702", }, ], @@ -3283,18 +3640,24 @@ Array [ "width": 1920, }, "internal": Object { - "contentDigest": "d7275dcc7296046a96102da46bd7254a", + "contentDigest": "aa3a57189a31a6e77cabb7bc99f4c8f0", "type": "ShopifyProductVariant", }, "inventoryItem": Object { "_variant": "232cdd32-2de5-5bdd-a327-08d539ecd51e", "countryCodeOfOrigin": null, "createdAt": "2022-03-14T13:53:31Z", - "duplicateSkuCount": 0, + "duplicateSkuCount": Object { + "count": 0, + "precision": "EXACT", + }, "harmonizedSystemCode": null, "inventoryHistoryUrl": "https://atomic-digital-studio-test.myshopify.com/admin/products/6950279086286/variants/41007759589582/inventory_history", "legacyResourceId": "43100044394702", - "locationsCount": 1, + "locationsCount": Object { + "count": 1, + "precision": "EXACT", + }, "provinceCodeOfOrigin": null, "requiresShipping": true, "shopifyId": "gid://shopify/InventoryItem/43100044394702", @@ -3330,7 +3693,10 @@ Array [ "value": "Small", }, ], - "sellingPlanGroupCount": 0, + "sellingPlanGroupsCount": Object { + "count": 0, + "precision": "EXACT", + }, "shopifyId": "gid://shopify/ProductVariant/41007759589582", "sku": "", "storefrontId": "Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0VmFyaWFudC80MTAwNzc1OTU4OTU4Mg==", @@ -3374,7 +3740,10 @@ Array [ "id": "gid://shopify/Product/6950279086286", "isGiftCard": false, "legacyResourceId": "6950279086286", - "mediaCount": 1, + "mediaCount": Object { + "count": 1, + "precision": "EXACT", + }, "onlineStorePreviewUrl": "https://atomic-digital-studio-test.myshopify.com/products/test-product", "onlineStoreUrl": null, "options": Array [ @@ -3412,7 +3781,10 @@ Array [ "productType": "Test Type", "publishedAt": "2022-03-14T21:26:01Z", "requiresSellingPlan": false, - "sellingPlanGroupCount": 0, + "sellingPlanGroupsCount": Object { + "count": 0, + "precision": "EXACT", + }, "seo": Object { "description": null, "title": null, @@ -3494,7 +3866,10 @@ Array [ "id": "gid://shopify/Product/6966721052878", "isGiftCard": false, "legacyResourceId": "6966721052878", - "mediaCount": 0, + "mediaCount": Object { + "count": 0, + "precision": "EXACT", + }, "onlineStorePreviewUrl": "https://atomic-digital-studio-test.myshopify.com/products/copy-of-test-product", "onlineStoreUrl": null, "options": Array [ @@ -3532,7 +3907,10 @@ Array [ "productType": "Test Type", "publishedAt": "2022-03-14T22:38:58Z", "requiresSellingPlan": false, - "sellingPlanGroupCount": 0, + "sellingPlanGroupsCount": Object { + "count": 0, + "precision": "EXACT", + }, "seo": Object { "description": null, "title": null, @@ -3573,15 +3951,44 @@ Array [ Object { "__parentId": "gid://shopify/ProductVariant/41009157308622", "_location": "e3e3dfac-3cbd-5cef-b3d6-3fd214f93ab8", - "available": 0, "id": "cedae3ee-f225-5c34-9dd8-f1a25f8d810c", "internal": Object { - "contentDigest": "452845f46b6d785b2a2b79f1c19cf91b", + "contentDigest": "66722f007ac1579519fbb7a397fddaed", "type": "ShopifyInventoryLevel", }, "location": Object { "shopifyId": "gid://shopify/Location/57173475534", }, + "quantities": Array [ + Object { + "name": "incoming", + "quantity": 0, + }, + Object { + "name": "available", + "quantity": 0, + }, + Object { + "name": "committed", + "quantity": 0, + }, + Object { + "name": "reserved", + "quantity": 0, + }, + Object { + "name": "damaged", + "quantity": 0, + }, + Object { + "name": "safety_stock", + "quantity": 0, + }, + Object { + "name": "quality_control", + "quantity": 0, + }, + ], "shopifyId": "gid://shopify/InventoryLevel/91371143374?inventory_item_id=43101443326158", }, ], @@ -3596,18 +4003,24 @@ Array [ "id": "cba433a6-1513-576f-97c0-80b36fb8afa6", "image": null, "internal": Object { - "contentDigest": "6153d74ac94feac2cf2a9e198017ae0e", + "contentDigest": "9931abd3f939451b136f77e7c573bc26", "type": "ShopifyProductVariant", }, "inventoryItem": Object { "_variant": "cba433a6-1513-576f-97c0-80b36fb8afa6", "countryCodeOfOrigin": null, "createdAt": "2022-03-14T22:38:58Z", - "duplicateSkuCount": 0, + "duplicateSkuCount": Object { + "count": 0, + "precision": "EXACT", + }, "harmonizedSystemCode": null, "inventoryHistoryUrl": "https://atomic-digital-studio-test.myshopify.com/admin/products/6966721052878/variants/41009157308622/inventory_history", "legacyResourceId": "43101443326158", - "locationsCount": 1, + "locationsCount": Object { + "count": 1, + "precision": "EXACT", + }, "provinceCodeOfOrigin": null, "requiresShipping": true, "shopifyId": "gid://shopify/InventoryItem/43101443326158", @@ -3643,7 +4056,10 @@ Array [ "value": "Large", }, ], - "sellingPlanGroupCount": 0, + "sellingPlanGroupsCount": Object { + "count": 0, + "precision": "EXACT", + }, "shopifyId": "gid://shopify/ProductVariant/41009157308622", "sku": null, "storefrontId": "Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0VmFyaWFudC80MTAwOTE1NzMwODYyMg==", @@ -3659,15 +4075,44 @@ Array [ Object { "__parentId": "gid://shopify/ProductVariant/41009157275854", "_location": "e3e3dfac-3cbd-5cef-b3d6-3fd214f93ab8", - "available": 0, "id": "8970ecd9-9a83-5e55-915b-682cfff58699", "internal": Object { - "contentDigest": "900b607c641a129fc9b314be805064ac", + "contentDigest": "3ee56ed994b624cb1de780d06a481f37", "type": "ShopifyInventoryLevel", }, "location": Object { "shopifyId": "gid://shopify/Location/57173475534", }, + "quantities": Array [ + Object { + "name": "incoming", + "quantity": 0, + }, + Object { + "name": "available", + "quantity": 0, + }, + Object { + "name": "committed", + "quantity": 0, + }, + Object { + "name": "reserved", + "quantity": 0, + }, + Object { + "name": "damaged", + "quantity": 0, + }, + Object { + "name": "safety_stock", + "quantity": 0, + }, + Object { + "name": "quality_control", + "quantity": 0, + }, + ], "shopifyId": "gid://shopify/InventoryLevel/91371143374?inventory_item_id=43101443293390", }, ], @@ -3682,18 +4127,24 @@ Array [ "id": "a0191127-d288-510d-94e5-14f7a6404454", "image": null, "internal": Object { - "contentDigest": "88ceea90890315ebbd90fa608fe8fc87", + "contentDigest": "f241fc91a88ebf40d208b9e798bf3b71", "type": "ShopifyProductVariant", }, "inventoryItem": Object { "_variant": "a0191127-d288-510d-94e5-14f7a6404454", "countryCodeOfOrigin": null, "createdAt": "2022-03-14T22:38:58Z", - "duplicateSkuCount": 0, + "duplicateSkuCount": Object { + "count": 0, + "precision": "EXACT", + }, "harmonizedSystemCode": null, "inventoryHistoryUrl": "https://atomic-digital-studio-test.myshopify.com/admin/products/6966721052878/variants/41009157275854/inventory_history", "legacyResourceId": "43101443293390", - "locationsCount": 1, + "locationsCount": Object { + "count": 1, + "precision": "EXACT", + }, "provinceCodeOfOrigin": null, "requiresShipping": true, "shopifyId": "gid://shopify/InventoryItem/43101443293390", @@ -3729,7 +4180,10 @@ Array [ "value": "Medium", }, ], - "sellingPlanGroupCount": 0, + "sellingPlanGroupsCount": Object { + "count": 0, + "precision": "EXACT", + }, "shopifyId": "gid://shopify/ProductVariant/41009157275854", "sku": null, "storefrontId": "Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0VmFyaWFudC80MTAwOTE1NzI3NTg1NA==", @@ -3745,15 +4199,44 @@ Array [ Object { "__parentId": "gid://shopify/ProductVariant/41009157243086", "_location": "e3e3dfac-3cbd-5cef-b3d6-3fd214f93ab8", - "available": 0, "id": "6eeb7894-1eb4-5556-a797-396fdf229a63", "internal": Object { - "contentDigest": "ecd7ff4a931ca7f110d9da8e085c69ed", + "contentDigest": "07f7fb2e63f13bb1a969f2e58d3612b3", "type": "ShopifyInventoryLevel", }, "location": Object { "shopifyId": "gid://shopify/Location/57173475534", }, + "quantities": Array [ + Object { + "name": "incoming", + "quantity": 0, + }, + Object { + "name": "available", + "quantity": 0, + }, + Object { + "name": "committed", + "quantity": 0, + }, + Object { + "name": "reserved", + "quantity": 0, + }, + Object { + "name": "damaged", + "quantity": 0, + }, + Object { + "name": "safety_stock", + "quantity": 0, + }, + Object { + "name": "quality_control", + "quantity": 0, + }, + ], "shopifyId": "gid://shopify/InventoryLevel/91371143374?inventory_item_id=43101443260622", }, ], @@ -3768,18 +4251,24 @@ Array [ "id": "435874ba-a8b0-5b29-a96a-8691e694bf3a", "image": null, "internal": Object { - "contentDigest": "ac479013a12b548eb17f918738d4507b", + "contentDigest": "1b9814e33e275046588c2a2f7f54ebca", "type": "ShopifyProductVariant", }, "inventoryItem": Object { "_variant": "435874ba-a8b0-5b29-a96a-8691e694bf3a", "countryCodeOfOrigin": null, "createdAt": "2022-03-14T22:38:58Z", - "duplicateSkuCount": 0, + "duplicateSkuCount": Object { + "count": 0, + "precision": "EXACT", + }, "harmonizedSystemCode": null, "inventoryHistoryUrl": "https://atomic-digital-studio-test.myshopify.com/admin/products/6966721052878/variants/41009157243086/inventory_history", "legacyResourceId": "43101443260622", - "locationsCount": 1, + "locationsCount": Object { + "count": 1, + "precision": "EXACT", + }, "provinceCodeOfOrigin": null, "requiresShipping": true, "shopifyId": "gid://shopify/InventoryItem/43101443260622", @@ -3815,7 +4304,10 @@ Array [ "value": "Small", }, ], - "sellingPlanGroupCount": 0, + "sellingPlanGroupsCount": Object { + "count": 0, + "precision": "EXACT", + }, "shopifyId": "gid://shopify/ProductVariant/41009157243086", "sku": null, "storefrontId": "Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0VmFyaWFudC80MTAwOTE1NzI0MzA4Ng==", @@ -3831,15 +4323,44 @@ Array [ Object { "__parentId": "gid://shopify/ProductVariant/41007759655118", "_location": "e3e3dfac-3cbd-5cef-b3d6-3fd214f93ab8", - "available": 1, "id": "e8f4985b-ed74-5a19-836d-b5d310c277e5", "internal": Object { - "contentDigest": "9d3d2135ce505be5bb10cb49481048fa", + "contentDigest": "51397f4cd40bd4e008b002b73797c3b8", "type": "ShopifyInventoryLevel", }, "location": Object { "shopifyId": "gid://shopify/Location/57173475534", }, + "quantities": Array [ + Object { + "name": "incoming", + "quantity": 0, + }, + Object { + "name": "available", + "quantity": 1, + }, + Object { + "name": "committed", + "quantity": 0, + }, + Object { + "name": "reserved", + "quantity": 0, + }, + Object { + "name": "damaged", + "quantity": 0, + }, + Object { + "name": "safety_stock", + "quantity": 0, + }, + Object { + "name": "quality_control", + "quantity": 0, + }, + ], "shopifyId": "gid://shopify/InventoryLevel/91371143374?inventory_item_id=43100044460238", }, ], @@ -3862,18 +4383,24 @@ Array [ "width": 1920, }, "internal": Object { - "contentDigest": "cb4f9b7f7aa04ed5f938999889d1a7be", + "contentDigest": "07222beb2c0e34a4602665d83d0b0c21", "type": "ShopifyProductVariant", }, "inventoryItem": Object { "_variant": "480d2d09-c1b1-5f7c-94a2-635e73e50ef4", "countryCodeOfOrigin": null, "createdAt": "2022-03-14T13:53:31Z", - "duplicateSkuCount": 0, + "duplicateSkuCount": Object { + "count": 0, + "precision": "EXACT", + }, "harmonizedSystemCode": null, "inventoryHistoryUrl": "https://atomic-digital-studio-test.myshopify.com/admin/products/6950279086286/variants/41007759655118/inventory_history", "legacyResourceId": "43100044460238", - "locationsCount": 1, + "locationsCount": Object { + "count": 1, + "precision": "EXACT", + }, "provinceCodeOfOrigin": null, "requiresShipping": true, "shopifyId": "gid://shopify/InventoryItem/43100044460238", @@ -3909,7 +4436,10 @@ Array [ "value": "Large", }, ], - "sellingPlanGroupCount": 0, + "sellingPlanGroupsCount": Object { + "count": 0, + "precision": "EXACT", + }, "shopifyId": "gid://shopify/ProductVariant/41007759655118", "sku": "", "storefrontId": "Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0VmFyaWFudC80MTAwNzc1OTY1NTExOA==", @@ -3925,15 +4455,44 @@ Array [ Object { "__parentId": "gid://shopify/ProductVariant/41007759622350", "_location": "e3e3dfac-3cbd-5cef-b3d6-3fd214f93ab8", - "available": 1, "id": "453dda5f-1323-5aa3-8e75-9a0dd08025c2", "internal": Object { - "contentDigest": "1d0ee94937b283d852538b020a63a1c7", + "contentDigest": "bd4f5897a47f9c8912acd6d3da46fcfb", "type": "ShopifyInventoryLevel", }, "location": Object { "shopifyId": "gid://shopify/Location/57173475534", }, + "quantities": Array [ + Object { + "name": "incoming", + "quantity": 0, + }, + Object { + "name": "available", + "quantity": 1, + }, + Object { + "name": "committed", + "quantity": 0, + }, + Object { + "name": "reserved", + "quantity": 0, + }, + Object { + "name": "damaged", + "quantity": 0, + }, + Object { + "name": "safety_stock", + "quantity": 0, + }, + Object { + "name": "quality_control", + "quantity": 0, + }, + ], "shopifyId": "gid://shopify/InventoryLevel/91371143374?inventory_item_id=43100044427470", }, ], @@ -3956,18 +4515,24 @@ Array [ "width": 1920, }, "internal": Object { - "contentDigest": "9c925f92d1e4581f17799fc3101ccd5d", + "contentDigest": "b39113e46e31a3e2d5a02e7e605b5bd4", "type": "ShopifyProductVariant", }, "inventoryItem": Object { "_variant": "266c6a92-078a-519d-8c03-257b4ed15b84", "countryCodeOfOrigin": null, "createdAt": "2022-03-14T13:53:31Z", - "duplicateSkuCount": 0, + "duplicateSkuCount": Object { + "count": 0, + "precision": "EXACT", + }, "harmonizedSystemCode": null, "inventoryHistoryUrl": "https://atomic-digital-studio-test.myshopify.com/admin/products/6950279086286/variants/41007759622350/inventory_history", "legacyResourceId": "43100044427470", - "locationsCount": 1, + "locationsCount": Object { + "count": 1, + "precision": "EXACT", + }, "provinceCodeOfOrigin": null, "requiresShipping": true, "shopifyId": "gid://shopify/InventoryItem/43100044427470", @@ -4003,7 +4568,10 @@ Array [ "value": "Medium", }, ], - "sellingPlanGroupCount": 0, + "sellingPlanGroupsCount": Object { + "count": 0, + "precision": "EXACT", + }, "shopifyId": "gid://shopify/ProductVariant/41007759622350", "sku": "", "storefrontId": "Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0VmFyaWFudC80MTAwNzc1OTYyMjM1MA==", @@ -4019,15 +4587,44 @@ Array [ Object { "__parentId": "gid://shopify/ProductVariant/41007759589582", "_location": "e3e3dfac-3cbd-5cef-b3d6-3fd214f93ab8", - "available": 1, "id": "2261ddf5-7c64-5934-a990-7dc64fe17040", "internal": Object { - "contentDigest": "662364c3f80cabf5fdad46fe50fe71eb", + "contentDigest": "23d2d35e04ff3fa2f5b43c1d3f2c0f28", "type": "ShopifyInventoryLevel", }, "location": Object { "shopifyId": "gid://shopify/Location/57173475534", }, + "quantities": Array [ + Object { + "name": "incoming", + "quantity": 0, + }, + Object { + "name": "available", + "quantity": 1, + }, + Object { + "name": "committed", + "quantity": 0, + }, + Object { + "name": "reserved", + "quantity": 0, + }, + Object { + "name": "damaged", + "quantity": 0, + }, + Object { + "name": "safety_stock", + "quantity": 0, + }, + Object { + "name": "quality_control", + "quantity": 0, + }, + ], "shopifyId": "gid://shopify/InventoryLevel/91371143374?inventory_item_id=43100044394702", }, ], @@ -4050,18 +4647,24 @@ Array [ "width": 1920, }, "internal": Object { - "contentDigest": "d7275dcc7296046a96102da46bd7254a", + "contentDigest": "aa3a57189a31a6e77cabb7bc99f4c8f0", "type": "ShopifyProductVariant", }, "inventoryItem": Object { "_variant": "232cdd32-2de5-5bdd-a327-08d539ecd51e", "countryCodeOfOrigin": null, "createdAt": "2022-03-14T13:53:31Z", - "duplicateSkuCount": 0, + "duplicateSkuCount": Object { + "count": 0, + "precision": "EXACT", + }, "harmonizedSystemCode": null, "inventoryHistoryUrl": "https://atomic-digital-studio-test.myshopify.com/admin/products/6950279086286/variants/41007759589582/inventory_history", "legacyResourceId": "43100044394702", - "locationsCount": 1, + "locationsCount": Object { + "count": 1, + "precision": "EXACT", + }, "provinceCodeOfOrigin": null, "requiresShipping": true, "shopifyId": "gid://shopify/InventoryItem/43100044394702", @@ -4097,7 +4700,10 @@ Array [ "value": "Small", }, ], - "sellingPlanGroupCount": 0, + "sellingPlanGroupsCount": Object { + "count": 0, + "precision": "EXACT", + }, "shopifyId": "gid://shopify/ProductVariant/41007759589582", "sku": "", "storefrontId": "Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0VmFyaWFudC80MTAwNzc1OTU4OTU4Mg==", diff --git a/packages/gatsby-source-shopify/__tests__/fixtures/bulk-results/collections.jsonl b/packages/gatsby-source-shopify/__tests__/fixtures/bulk-results/collections.jsonl index 6fee49b8f0d3d..5db19673932f1 100644 --- a/packages/gatsby-source-shopify/__tests__/fixtures/bulk-results/collections.jsonl +++ b/packages/gatsby-source-shopify/__tests__/fixtures/bulk-results/collections.jsonl @@ -1 +1 @@ -{"description":"Test Collection Description","descriptionHtml":"Test Collection Description","feedback":{"details":[],"summary":"This collection couldn’t be published to Google"},"handle":"test-collection","id":"gid:\/\/shopify\/Collection\/278407151822","image":null,"legacyResourceId":"278407151822","productsCount":2,"ruleSet":{"appliedDisjunctively":false,"rules":[{"column":"IS_PRICE_REDUCED","condition":"","relation":"IS_NOT_SET"}]},"seo":{"description":null,"title":null},"sortOrder":"BEST_SELLING","storefrontId":"Z2lkOi8vc2hvcGlmeS9Db2xsZWN0aW9uLzI3ODQwNzE1MTgyMg==","templateSuffix":"","title":"Test Collection","updatedAt":"2022-03-14T22:39:00Z"} +{"description":"Test Collection Description","descriptionHtml":"Test Collection Description","feedback":{"details":[],"summary":"This collection couldn’t be published to Google"},"handle":"test-collection","id":"gid:\/\/shopify\/Collection\/278407151822","image":null,"legacyResourceId":"278407151822","productsCount":{"count": 2, "precision": "EXACT"},"ruleSet":{"appliedDisjunctively":false,"rules":[{"column":"IS_PRICE_REDUCED","condition":"","relation":"IS_NOT_SET"}]},"seo":{"description":null,"title":null},"sortOrder":"BEST_SELLING","storefrontId":"Z2lkOi8vc2hvcGlmeS9Db2xsZWN0aW9uLzI3ODQwNzE1MTgyMg==","templateSuffix":"","title":"Test Collection","updatedAt":"2022-03-14T22:39:00Z"} diff --git a/packages/gatsby-source-shopify/__tests__/fixtures/bulk-results/products.jsonl b/packages/gatsby-source-shopify/__tests__/fixtures/bulk-results/products.jsonl index 10187cdb17ee0..5641bb647dbce 100644 --- a/packages/gatsby-source-shopify/__tests__/fixtures/bulk-results/products.jsonl +++ b/packages/gatsby-source-shopify/__tests__/fixtures/bulk-results/products.jsonl @@ -1,5 +1,5 @@ -{"createdAt":"2022-02-15T22:22:42Z","description":"Test Description","descriptionHtml":"Test Description","featuredImage":{"altText":null,"height":1280,"id":"gid:\/\/shopify\/ProductImage\/30403196551374","originalSrc":"https:\/\/cdn.shopify.com\/s\/files\/1\/0506\/3521\/0958\/products\/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","src":"https:\/\/cdn.shopify.com\/s\/files\/1\/0506\/3521\/0958\/products\/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","transformedSrc":"https:\/\/cdn.shopify.com\/s\/files\/1\/0506\/3521\/0958\/products\/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","width":1920},"featuredMedia":{"id":"gid:\/\/shopify\/MediaImage\/22755647652046"},"feedback":{"details":[],"summary":"This product couldn’t be published to Google"},"giftCardTemplateSuffix":"","handle":"test-product","hasOnlyDefaultVariant":false,"hasOutOfStockVariants":false,"id":"gid:\/\/shopify\/Product\/6950279086286","isGiftCard":false,"legacyResourceId":"6950279086286","mediaCount":1,"onlineStorePreviewUrl":"https:\/\/atomic-digital-studio-test.myshopify.com\/products\/test-product","onlineStoreUrl":null,"options":[{"id":"gid:\/\/shopify\/ProductOption\/8894327619790","name":"Size","position":1,"values":["Small","Medium","Large"]}],"priceRange":{"maxVariantPrice":{"amount":"300.0","currencyCode":"CAD"},"minVariantPrice":{"amount":"100.0","currencyCode":"CAD"}},"priceRangeV2":{"maxVariantPrice":{"amount":"3.0","currencyCode":"CAD"},"minVariantPrice":{"amount":"1.0","currencyCode":"CAD"}},"productType":"Test Type","publishedAt":"2022-03-14T21:26:01Z","requiresSellingPlan":false,"sellingPlanGroupCount":0,"seo":{"description":null,"title":null},"status":"ACTIVE","storefrontId":"Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0LzY5NTAyNzkwODYyODY=","tags":["test-tag"],"templateSuffix":"","title":"Test Product","totalInventory":3,"totalVariants":3,"tracksInventory":true,"updatedAt":"2022-03-14T21:26:01Z","vendor":"Gatsby"} +{"createdAt":"2022-02-15T22:22:42Z","description":"Test Description","descriptionHtml":"Test Description","featuredImage":{"altText":null,"height":1280,"id":"gid:\/\/shopify\/ProductImage\/30403196551374","originalSrc":"https:\/\/cdn.shopify.com\/s\/files\/1\/0506\/3521\/0958\/products\/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","src":"https:\/\/cdn.shopify.com\/s\/files\/1\/0506\/3521\/0958\/products\/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","transformedSrc":"https:\/\/cdn.shopify.com\/s\/files\/1\/0506\/3521\/0958\/products\/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","width":1920},"featuredMedia":{"id":"gid:\/\/shopify\/MediaImage\/22755647652046"},"feedback":{"details":[],"summary":"This product couldn’t be published to Google"},"giftCardTemplateSuffix":"","handle":"test-product","hasOnlyDefaultVariant":false,"hasOutOfStockVariants":false,"id":"gid:\/\/shopify\/Product\/6950279086286","isGiftCard":false,"legacyResourceId":"6950279086286","mediaCount":{"count": 1, "precision": "EXACT"},"onlineStorePreviewUrl":"https:\/\/atomic-digital-studio-test.myshopify.com\/products\/test-product","onlineStoreUrl":null,"options":[{"id":"gid:\/\/shopify\/ProductOption\/8894327619790","name":"Size","position":1,"values":["Small","Medium","Large"]}],"priceRange":{"maxVariantPrice":{"amount":"300.0","currencyCode":"CAD"},"minVariantPrice":{"amount":"100.0","currencyCode":"CAD"}},"priceRangeV2":{"maxVariantPrice":{"amount":"3.0","currencyCode":"CAD"},"minVariantPrice":{"amount":"1.0","currencyCode":"CAD"}},"productType":"Test Type","publishedAt":"2022-03-14T21:26:01Z","requiresSellingPlan":false,"sellingPlanGroupsCount":{"count": 0, "precision": "EXACT"},"seo":{"description":null,"title":null},"status":"ACTIVE","storefrontId":"Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0LzY5NTAyNzkwODYyODY=","tags":["test-tag"],"templateSuffix":"","title":"Test Product","totalInventory":3,"totalVariants":3,"tracksInventory":true,"updatedAt":"2022-03-14T21:26:01Z","vendor":"Gatsby"} {"alt":"","mediaContentType":"IMAGE","mediaErrors":[],"preview":{"image":{"altText":"","height":1280,"id":"gid:\/\/shopify\/ImageSource\/22758479855822","originalSrc":"https:\/\/cdn.shopify.com\/s\/files\/1\/0506\/3521\/0958\/products\/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","src":"https:\/\/cdn.shopify.com\/s\/files\/1\/0506\/3521\/0958\/products\/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","transformedSrc":"https:\/\/cdn.shopify.com\/s\/files\/1\/0506\/3521\/0958\/products\/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","width":1920},"status":"READY"},"status":"READY","createdAt":"2022-02-15T22:22:44Z","fileErrors":[],"fileStatus":"READY","id":"gid:\/\/shopify\/MediaImage\/22755647652046","image":{"altText":"","height":1280,"id":"gid:\/\/shopify\/ImageSource\/22758479855822","originalSrc":"https:\/\/cdn.shopify.com\/s\/files\/1\/0506\/3521\/0958\/products\/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","src":"https:\/\/cdn.shopify.com\/s\/files\/1\/0506\/3521\/0958\/products\/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","transformedSrc":"https:\/\/cdn.shopify.com\/s\/files\/1\/0506\/3521\/0958\/products\/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","width":1920},"mimeType":"image\/png","__parentId":"gid:\/\/shopify\/Product\/6950279086286"} {"createdAt":"2022-03-14T14:03:25Z","description":null,"id":"gid:\/\/shopify\/Metafield\/21077562228942","key":"subtitle","legacyResourceId":"21077562228942","namespace":"descriptors","ownerType":"PRODUCT","type":"single_line_text_field","updatedAt":"2022-03-14T14:03:25Z","value":"Test Subtitle","valueType":"single_line_text_field","__parentId":"gid:\/\/shopify\/Product\/6950279086286"} -{"createdAt":"2022-03-14T22:38:58Z","description":"Test Description","descriptionHtml":"Test Description","featuredImage":null,"featuredMedia":null,"feedback":{"details":[],"summary":"This product couldn’t be published to Google"},"giftCardTemplateSuffix":"","handle":"copy-of-test-product","hasOnlyDefaultVariant":false,"hasOutOfStockVariants":true,"id":"gid:\/\/shopify\/Product\/6966721052878","isGiftCard":false,"legacyResourceId":"6966721052878","mediaCount":0,"onlineStorePreviewUrl":"https:\/\/atomic-digital-studio-test.myshopify.com\/products\/copy-of-test-product","onlineStoreUrl":null,"options":[{"id":"gid:\/\/shopify\/ProductOption\/8914986795214","name":"Size","position":1,"values":["Small","Medium","Large"]}],"priceRange":{"maxVariantPrice":{"amount":"300.0","currencyCode":"CAD"},"minVariantPrice":{"amount":"100.0","currencyCode":"CAD"}},"priceRangeV2":{"maxVariantPrice":{"amount":"3.0","currencyCode":"CAD"},"minVariantPrice":{"amount":"1.0","currencyCode":"CAD"}},"productType":"Test Type","publishedAt":"2022-03-14T22:38:58Z","requiresSellingPlan":false,"sellingPlanGroupCount":0,"seo":{"description":null,"title":null},"status":"ACTIVE","storefrontId":"Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0LzY5NjY3MjEwNTI4Nzg=","tags":["test-tag"],"templateSuffix":"","title":"Copy of Test Product","totalInventory":0,"totalVariants":3,"tracksInventory":true,"updatedAt":"2022-03-14T22:38:58Z","vendor":"Gatsby"} +{"createdAt":"2022-03-14T22:38:58Z","description":"Test Description","descriptionHtml":"Test Description","featuredImage":null,"featuredMedia":null,"feedback":{"details":[],"summary":"This product couldn’t be published to Google"},"giftCardTemplateSuffix":"","handle":"copy-of-test-product","hasOnlyDefaultVariant":false,"hasOutOfStockVariants":true,"id":"gid:\/\/shopify\/Product\/6966721052878","isGiftCard":false,"legacyResourceId":"6966721052878","mediaCount":{"count": 0, "precision": "EXACT"},"onlineStorePreviewUrl":"https:\/\/atomic-digital-studio-test.myshopify.com\/products\/copy-of-test-product","onlineStoreUrl":null,"options":[{"id":"gid:\/\/shopify\/ProductOption\/8914986795214","name":"Size","position":1,"values":["Small","Medium","Large"]}],"priceRange":{"maxVariantPrice":{"amount":"300.0","currencyCode":"CAD"},"minVariantPrice":{"amount":"100.0","currencyCode":"CAD"}},"priceRangeV2":{"maxVariantPrice":{"amount":"3.0","currencyCode":"CAD"},"minVariantPrice":{"amount":"1.0","currencyCode":"CAD"}},"productType":"Test Type","publishedAt":"2022-03-14T22:38:58Z","requiresSellingPlan":false,"sellingPlanGroupsCount":{"count": 0, "precision": "EXACT"},"seo":{"description":null,"title":null},"status":"ACTIVE","storefrontId":"Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0LzY5NjY3MjEwNTI4Nzg=","tags":["test-tag"],"templateSuffix":"","title":"Copy of Test Product","totalInventory":0,"totalVariants":3,"tracksInventory":true,"updatedAt":"2022-03-14T22:38:58Z","vendor":"Gatsby"} {"createdAt":"2022-03-14T22:38:58Z","description":null,"id":"gid:\/\/shopify\/Metafield\/21078060335310","key":"subtitle","legacyResourceId":"21078060335310","namespace":"descriptors","ownerType":"PRODUCT","type":"single_line_text_field","updatedAt":"2022-03-14T22:38:58Z","value":"Test Subtitle","valueType":"single_line_text_field","__parentId":"gid:\/\/shopify\/Product\/6966721052878"} diff --git a/packages/gatsby-source-shopify/__tests__/fixtures/bulk-results/variants.jsonl b/packages/gatsby-source-shopify/__tests__/fixtures/bulk-results/variants.jsonl index a1f024d1b6a21..b9276e469b3f0 100644 --- a/packages/gatsby-source-shopify/__tests__/fixtures/bulk-results/variants.jsonl +++ b/packages/gatsby-source-shopify/__tests__/fixtures/bulk-results/variants.jsonl @@ -1,12 +1,12 @@ -{"availableForSale":true,"barcode":"","compareAtPrice":null,"createdAt":"2022-03-14T13:53:31Z","displayName":"Test Product - Small","id":"gid:\/\/shopify\/ProductVariant\/41007759589582","image":{"altText":null,"height":1280,"id":"gid:\/\/shopify\/ProductImage\/30403196551374","originalSrc":"https:\/\/cdn.shopify.com\/s\/files\/1\/0506\/3521\/0958\/products\/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","src":"https:\/\/cdn.shopify.com\/s\/files\/1\/0506\/3521\/0958\/products\/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","transformedSrc":"https:\/\/cdn.shopify.com\/s\/files\/1\/0506\/3521\/0958\/products\/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","width":1920},"inventoryItem":{"countryCodeOfOrigin":null,"createdAt":"2022-03-14T13:53:31Z","duplicateSkuCount":0,"harmonizedSystemCode":null,"id":"gid:\/\/shopify\/InventoryItem\/43100044394702","inventoryHistoryUrl":"https:\/\/atomic-digital-studio-test.myshopify.com\/admin\/products\/6950279086286\/variants\/41007759589582\/inventory_history","legacyResourceId":"43100044394702","locationsCount":1,"provinceCodeOfOrigin":null,"requiresShipping":true,"sku":"","tracked":true,"trackedEditable":{"locked":false,"reason":null},"unitCost":null,"updatedAt":"2022-03-14T13:53:31Z","variant":{"id":"gid:\/\/shopify\/ProductVariant\/41007759589582"}},"inventoryPolicy":"DENY","inventoryQuantity":1,"legacyResourceId":"41007759589582","position":1,"price":"1.00","product":{"id":"gid:\/\/shopify\/Product\/6950279086286"},"requiresShipping":true,"selectedOptions":[{"name":"Size","value":"Small"}],"sellingPlanGroupCount":0,"sku":"","storefrontId":"Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0VmFyaWFudC80MTAwNzc1OTU4OTU4Mg==","taxCode":null,"taxable":true,"title":"Small","updatedAt":"2022-03-14T14:00:01Z","weight":0.0,"weightUnit":"KILOGRAMS"} -{"available":1,"id":"gid:\/\/shopify\/InventoryLevel\/91371143374?inventory_item_id=43100044394702","location":{"id":"gid:\/\/shopify\/Location\/57173475534"},"__parentId":"gid:\/\/shopify\/ProductVariant\/41007759589582"} -{"availableForSale":true,"barcode":"","compareAtPrice":null,"createdAt":"2022-03-14T13:53:31Z","displayName":"Test Product - Medium","id":"gid:\/\/shopify\/ProductVariant\/41007759622350","image":{"altText":null,"height":1280,"id":"gid:\/\/shopify\/ProductImage\/30403196551374","originalSrc":"https:\/\/cdn.shopify.com\/s\/files\/1\/0506\/3521\/0958\/products\/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","src":"https:\/\/cdn.shopify.com\/s\/files\/1\/0506\/3521\/0958\/products\/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","transformedSrc":"https:\/\/cdn.shopify.com\/s\/files\/1\/0506\/3521\/0958\/products\/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","width":1920},"inventoryItem":{"countryCodeOfOrigin":null,"createdAt":"2022-03-14T13:53:31Z","duplicateSkuCount":0,"harmonizedSystemCode":null,"id":"gid:\/\/shopify\/InventoryItem\/43100044427470","inventoryHistoryUrl":"https:\/\/atomic-digital-studio-test.myshopify.com\/admin\/products\/6950279086286\/variants\/41007759622350\/inventory_history","legacyResourceId":"43100044427470","locationsCount":1,"provinceCodeOfOrigin":null,"requiresShipping":true,"sku":"","tracked":true,"trackedEditable":{"locked":false,"reason":null},"unitCost":null,"updatedAt":"2022-03-14T13:53:31Z","variant":{"id":"gid:\/\/shopify\/ProductVariant\/41007759622350"}},"inventoryPolicy":"DENY","inventoryQuantity":1,"legacyResourceId":"41007759622350","position":2,"price":"2.00","product":{"id":"gid:\/\/shopify\/Product\/6950279086286"},"requiresShipping":true,"selectedOptions":[{"name":"Size","value":"Medium"}],"sellingPlanGroupCount":0,"sku":"","storefrontId":"Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0VmFyaWFudC80MTAwNzc1OTYyMjM1MA==","taxCode":null,"taxable":true,"title":"Medium","updatedAt":"2022-03-14T14:00:01Z","weight":0.0,"weightUnit":"KILOGRAMS"} -{"available":1,"id":"gid:\/\/shopify\/InventoryLevel\/91371143374?inventory_item_id=43100044427470","location":{"id":"gid:\/\/shopify\/Location\/57173475534"},"__parentId":"gid:\/\/shopify\/ProductVariant\/41007759622350"} -{"availableForSale":true,"barcode":"","compareAtPrice":null,"createdAt":"2022-03-14T13:53:31Z","displayName":"Test Product - Large","id":"gid:\/\/shopify\/ProductVariant\/41007759655118","image":{"altText":null,"height":1280,"id":"gid:\/\/shopify\/ProductImage\/30403196551374","originalSrc":"https:\/\/cdn.shopify.com\/s\/files\/1\/0506\/3521\/0958\/products\/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","src":"https:\/\/cdn.shopify.com\/s\/files\/1\/0506\/3521\/0958\/products\/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","transformedSrc":"https:\/\/cdn.shopify.com\/s\/files\/1\/0506\/3521\/0958\/products\/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","width":1920},"inventoryItem":{"countryCodeOfOrigin":null,"createdAt":"2022-03-14T13:53:31Z","duplicateSkuCount":0,"harmonizedSystemCode":null,"id":"gid:\/\/shopify\/InventoryItem\/43100044460238","inventoryHistoryUrl":"https:\/\/atomic-digital-studio-test.myshopify.com\/admin\/products\/6950279086286\/variants\/41007759655118\/inventory_history","legacyResourceId":"43100044460238","locationsCount":1,"provinceCodeOfOrigin":null,"requiresShipping":true,"sku":"","tracked":true,"trackedEditable":{"locked":false,"reason":null},"unitCost":null,"updatedAt":"2022-03-14T13:53:31Z","variant":{"id":"gid:\/\/shopify\/ProductVariant\/41007759655118"}},"inventoryPolicy":"DENY","inventoryQuantity":1,"legacyResourceId":"41007759655118","position":3,"price":"3.00","product":{"id":"gid:\/\/shopify\/Product\/6950279086286"},"requiresShipping":true,"selectedOptions":[{"name":"Size","value":"Large"}],"sellingPlanGroupCount":0,"sku":"","storefrontId":"Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0VmFyaWFudC80MTAwNzc1OTY1NTExOA==","taxCode":null,"taxable":true,"title":"Large","updatedAt":"2022-03-14T14:00:01Z","weight":0.0,"weightUnit":"KILOGRAMS"} -{"available":1,"id":"gid:\/\/shopify\/InventoryLevel\/91371143374?inventory_item_id=43100044460238","location":{"id":"gid:\/\/shopify\/Location\/57173475534"},"__parentId":"gid:\/\/shopify\/ProductVariant\/41007759655118"} -{"availableForSale":false,"barcode":null,"compareAtPrice":null,"createdAt":"2022-03-14T22:38:58Z","displayName":"Copy of Test Product - Small","id":"gid:\/\/shopify\/ProductVariant\/41009157243086","image":null,"inventoryItem":{"countryCodeOfOrigin":null,"createdAt":"2022-03-14T22:38:58Z","duplicateSkuCount":0,"harmonizedSystemCode":null,"id":"gid:\/\/shopify\/InventoryItem\/43101443260622","inventoryHistoryUrl":"https:\/\/atomic-digital-studio-test.myshopify.com\/admin\/products\/6966721052878\/variants\/41009157243086\/inventory_history","legacyResourceId":"43101443260622","locationsCount":1,"provinceCodeOfOrigin":null,"requiresShipping":true,"sku":null,"tracked":true,"trackedEditable":{"locked":false,"reason":null},"unitCost":null,"updatedAt":"2022-03-14T22:38:58Z","variant":{"id":"gid:\/\/shopify\/ProductVariant\/41009157243086"}},"inventoryPolicy":"DENY","inventoryQuantity":0,"legacyResourceId":"41009157243086","position":1,"price":"1.00","product":{"id":"gid:\/\/shopify\/Product\/6966721052878"},"requiresShipping":true,"selectedOptions":[{"name":"Size","value":"Small"}],"sellingPlanGroupCount":0,"sku":null,"storefrontId":"Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0VmFyaWFudC80MTAwOTE1NzI0MzA4Ng==","taxCode":null,"taxable":true,"title":"Small","updatedAt":"2022-03-14T22:38:58Z","weight":0.0,"weightUnit":"KILOGRAMS"} -{"available":0,"id":"gid:\/\/shopify\/InventoryLevel\/91371143374?inventory_item_id=43101443260622","location":{"id":"gid:\/\/shopify\/Location\/57173475534"},"__parentId":"gid:\/\/shopify\/ProductVariant\/41009157243086"} -{"availableForSale":false,"barcode":null,"compareAtPrice":null,"createdAt":"2022-03-14T22:38:58Z","displayName":"Copy of Test Product - Medium","id":"gid:\/\/shopify\/ProductVariant\/41009157275854","image":null,"inventoryItem":{"countryCodeOfOrigin":null,"createdAt":"2022-03-14T22:38:58Z","duplicateSkuCount":0,"harmonizedSystemCode":null,"id":"gid:\/\/shopify\/InventoryItem\/43101443293390","inventoryHistoryUrl":"https:\/\/atomic-digital-studio-test.myshopify.com\/admin\/products\/6966721052878\/variants\/41009157275854\/inventory_history","legacyResourceId":"43101443293390","locationsCount":1,"provinceCodeOfOrigin":null,"requiresShipping":true,"sku":null,"tracked":true,"trackedEditable":{"locked":false,"reason":null},"unitCost":null,"updatedAt":"2022-03-14T22:38:58Z","variant":{"id":"gid:\/\/shopify\/ProductVariant\/41009157275854"}},"inventoryPolicy":"DENY","inventoryQuantity":0,"legacyResourceId":"41009157275854","position":2,"price":"2.00","product":{"id":"gid:\/\/shopify\/Product\/6966721052878"},"requiresShipping":true,"selectedOptions":[{"name":"Size","value":"Medium"}],"sellingPlanGroupCount":0,"sku":null,"storefrontId":"Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0VmFyaWFudC80MTAwOTE1NzI3NTg1NA==","taxCode":null,"taxable":true,"title":"Medium","updatedAt":"2022-03-14T22:38:58Z","weight":0.0,"weightUnit":"KILOGRAMS"} -{"available":0,"id":"gid:\/\/shopify\/InventoryLevel\/91371143374?inventory_item_id=43101443293390","location":{"id":"gid:\/\/shopify\/Location\/57173475534"},"__parentId":"gid:\/\/shopify\/ProductVariant\/41009157275854"} -{"availableForSale":false,"barcode":null,"compareAtPrice":null,"createdAt":"2022-03-14T22:38:58Z","displayName":"Copy of Test Product - Large","id":"gid:\/\/shopify\/ProductVariant\/41009157308622","image":null,"inventoryItem":{"countryCodeOfOrigin":null,"createdAt":"2022-03-14T22:38:58Z","duplicateSkuCount":0,"harmonizedSystemCode":null,"id":"gid:\/\/shopify\/InventoryItem\/43101443326158","inventoryHistoryUrl":"https:\/\/atomic-digital-studio-test.myshopify.com\/admin\/products\/6966721052878\/variants\/41009157308622\/inventory_history","legacyResourceId":"43101443326158","locationsCount":1,"provinceCodeOfOrigin":null,"requiresShipping":true,"sku":null,"tracked":true,"trackedEditable":{"locked":false,"reason":null},"unitCost":null,"updatedAt":"2022-03-14T22:38:58Z","variant":{"id":"gid:\/\/shopify\/ProductVariant\/41009157308622"}},"inventoryPolicy":"DENY","inventoryQuantity":0,"legacyResourceId":"41009157308622","position":3,"price":"3.00","product":{"id":"gid:\/\/shopify\/Product\/6966721052878"},"requiresShipping":true,"selectedOptions":[{"name":"Size","value":"Large"}],"sellingPlanGroupCount":0,"sku":null,"storefrontId":"Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0VmFyaWFudC80MTAwOTE1NzMwODYyMg==","taxCode":null,"taxable":true,"title":"Large","updatedAt":"2022-03-14T22:38:58Z","weight":0.0,"weightUnit":"KILOGRAMS"} -{"available":0,"id":"gid:\/\/shopify\/InventoryLevel\/91371143374?inventory_item_id=43101443326158","location":{"id":"gid:\/\/shopify\/Location\/57173475534"},"__parentId":"gid:\/\/shopify\/ProductVariant\/41009157308622"} +{"availableForSale":true,"barcode":"","compareAtPrice":null,"createdAt":"2022-03-14T13:53:31Z","displayName":"Test Product - Small","id":"gid:\/\/shopify\/ProductVariant\/41007759589582","image":{"altText":null,"height":1280,"id":"gid:\/\/shopify\/ProductImage\/30403196551374","originalSrc":"https:\/\/cdn.shopify.com\/s\/files\/1\/0506\/3521\/0958\/products\/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","src":"https:\/\/cdn.shopify.com\/s\/files\/1\/0506\/3521\/0958\/products\/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","transformedSrc":"https:\/\/cdn.shopify.com\/s\/files\/1\/0506\/3521\/0958\/products\/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","width":1920},"inventoryItem":{"countryCodeOfOrigin":null,"createdAt":"2022-03-14T13:53:31Z","duplicateSkuCount":{"count": 0, "precision": "EXACT"},"harmonizedSystemCode":null,"id":"gid:\/\/shopify\/InventoryItem\/43100044394702","inventoryHistoryUrl":"https:\/\/atomic-digital-studio-test.myshopify.com\/admin\/products\/6950279086286\/variants\/41007759589582\/inventory_history","legacyResourceId":"43100044394702","locationsCount":{"count": 1, "precision": "EXACT"},"provinceCodeOfOrigin":null,"requiresShipping":true,"sku":"","tracked":true,"trackedEditable":{"locked":false,"reason":null},"unitCost":null,"updatedAt":"2022-03-14T13:53:31Z","variant":{"id":"gid:\/\/shopify\/ProductVariant\/41007759589582"}},"inventoryPolicy":"DENY","inventoryQuantity":1,"legacyResourceId":"41007759589582","position":1,"price":"1.00","product":{"id":"gid:\/\/shopify\/Product\/6950279086286"},"requiresShipping":true,"selectedOptions":[{"name":"Size","value":"Small"}],"sellingPlanGroupsCount":{"count": 0, "precision": "EXACT"},"sku":"","storefrontId":"Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0VmFyaWFudC80MTAwNzc1OTU4OTU4Mg==","taxCode":null,"taxable":true,"title":"Small","updatedAt":"2022-03-14T14:00:01Z","weight":0.0,"weightUnit":"KILOGRAMS"} +{"quantities": [{"name":"incoming","quantity":0},{"name":"available","quantity":1},{"name":"committed","quantity":0},{"name":"reserved","quantity":0},{"name":"damaged","quantity":0},{"name":"safety_stock","quantity":0},{"name":"quality_control","quantity":0}],"id":"gid:\/\/shopify\/InventoryLevel\/91371143374?inventory_item_id=43100044394702","location":{"id":"gid:\/\/shopify\/Location\/57173475534"},"__parentId":"gid:\/\/shopify\/ProductVariant\/41007759589582"} +{"availableForSale":true,"barcode":"","compareAtPrice":null,"createdAt":"2022-03-14T13:53:31Z","displayName":"Test Product - Medium","id":"gid:\/\/shopify\/ProductVariant\/41007759622350","image":{"altText":null,"height":1280,"id":"gid:\/\/shopify\/ProductImage\/30403196551374","originalSrc":"https:\/\/cdn.shopify.com\/s\/files\/1\/0506\/3521\/0958\/products\/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","src":"https:\/\/cdn.shopify.com\/s\/files\/1\/0506\/3521\/0958\/products\/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","transformedSrc":"https:\/\/cdn.shopify.com\/s\/files\/1\/0506\/3521\/0958\/products\/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","width":1920},"inventoryItem":{"countryCodeOfOrigin":null,"createdAt":"2022-03-14T13:53:31Z","duplicateSkuCount":{"count": 0, "precision": "EXACT"},"harmonizedSystemCode":null,"id":"gid:\/\/shopify\/InventoryItem\/43100044427470","inventoryHistoryUrl":"https:\/\/atomic-digital-studio-test.myshopify.com\/admin\/products\/6950279086286\/variants\/41007759622350\/inventory_history","legacyResourceId":"43100044427470","locationsCount":{"count": 1, "precision": "EXACT"},"provinceCodeOfOrigin":null,"requiresShipping":true,"sku":"","tracked":true,"trackedEditable":{"locked":false,"reason":null},"unitCost":null,"updatedAt":"2022-03-14T13:53:31Z","variant":{"id":"gid:\/\/shopify\/ProductVariant\/41007759622350"}},"inventoryPolicy":"DENY","inventoryQuantity":1,"legacyResourceId":"41007759622350","position":2,"price":"2.00","product":{"id":"gid:\/\/shopify\/Product\/6950279086286"},"requiresShipping":true,"selectedOptions":[{"name":"Size","value":"Medium"}],"sellingPlanGroupsCount":{"count": 0, "precision": "EXACT"},"sku":"","storefrontId":"Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0VmFyaWFudC80MTAwNzc1OTYyMjM1MA==","taxCode":null,"taxable":true,"title":"Medium","updatedAt":"2022-03-14T14:00:01Z","weight":0.0,"weightUnit":"KILOGRAMS"} +{"quantities": [{"name":"incoming","quantity":0},{"name":"available","quantity":1},{"name":"committed","quantity":0},{"name":"reserved","quantity":0},{"name":"damaged","quantity":0},{"name":"safety_stock","quantity":0},{"name":"quality_control","quantity":0}],"id":"gid:\/\/shopify\/InventoryLevel\/91371143374?inventory_item_id=43100044427470","location":{"id":"gid:\/\/shopify\/Location\/57173475534"},"__parentId":"gid:\/\/shopify\/ProductVariant\/41007759622350"} +{"availableForSale":true,"barcode":"","compareAtPrice":null,"createdAt":"2022-03-14T13:53:31Z","displayName":"Test Product - Large","id":"gid:\/\/shopify\/ProductVariant\/41007759655118","image":{"altText":null,"height":1280,"id":"gid:\/\/shopify\/ProductImage\/30403196551374","originalSrc":"https:\/\/cdn.shopify.com\/s\/files\/1\/0506\/3521\/0958\/products\/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","src":"https:\/\/cdn.shopify.com\/s\/files\/1\/0506\/3521\/0958\/products\/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","transformedSrc":"https:\/\/cdn.shopify.com\/s\/files\/1\/0506\/3521\/0958\/products\/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","width":1920},"inventoryItem":{"countryCodeOfOrigin":null,"createdAt":"2022-03-14T13:53:31Z","duplicateSkuCount":{"count": 0, "precision": "EXACT"},"harmonizedSystemCode":null,"id":"gid:\/\/shopify\/InventoryItem\/43100044460238","inventoryHistoryUrl":"https:\/\/atomic-digital-studio-test.myshopify.com\/admin\/products\/6950279086286\/variants\/41007759655118\/inventory_history","legacyResourceId":"43100044460238","locationsCount":{"count": 1, "precision": "EXACT"},"provinceCodeOfOrigin":null,"requiresShipping":true,"sku":"","tracked":true,"trackedEditable":{"locked":false,"reason":null},"unitCost":null,"updatedAt":"2022-03-14T13:53:31Z","variant":{"id":"gid:\/\/shopify\/ProductVariant\/41007759655118"}},"inventoryPolicy":"DENY","inventoryQuantity":1,"legacyResourceId":"41007759655118","position":3,"price":"3.00","product":{"id":"gid:\/\/shopify\/Product\/6950279086286"},"requiresShipping":true,"selectedOptions":[{"name":"Size","value":"Large"}],"sellingPlanGroupsCount":{"count": 0, "precision": "EXACT"},"sku":"","storefrontId":"Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0VmFyaWFudC80MTAwNzc1OTY1NTExOA==","taxCode":null,"taxable":true,"title":"Large","updatedAt":"2022-03-14T14:00:01Z","weight":0.0,"weightUnit":"KILOGRAMS"} +{"quantities": [{"name":"incoming","quantity":0},{"name":"available","quantity":1},{"name":"committed","quantity":0},{"name":"reserved","quantity":0},{"name":"damaged","quantity":0},{"name":"safety_stock","quantity":0},{"name":"quality_control","quantity":0}],"id":"gid:\/\/shopify\/InventoryLevel\/91371143374?inventory_item_id=43100044460238","location":{"id":"gid:\/\/shopify\/Location\/57173475534"},"__parentId":"gid:\/\/shopify\/ProductVariant\/41007759655118"} +{"availableForSale":false,"barcode":null,"compareAtPrice":null,"createdAt":"2022-03-14T22:38:58Z","displayName":"Copy of Test Product - Small","id":"gid:\/\/shopify\/ProductVariant\/41009157243086","image":null,"inventoryItem":{"countryCodeOfOrigin":null,"createdAt":"2022-03-14T22:38:58Z","duplicateSkuCount":{"count": 0, "precision": "EXACT"},"harmonizedSystemCode":null,"id":"gid:\/\/shopify\/InventoryItem\/43101443260622","inventoryHistoryUrl":"https:\/\/atomic-digital-studio-test.myshopify.com\/admin\/products\/6966721052878\/variants\/41009157243086\/inventory_history","legacyResourceId":"43101443260622","locationsCount":{"count": 1, "precision": "EXACT"},"provinceCodeOfOrigin":null,"requiresShipping":true,"sku":null,"tracked":true,"trackedEditable":{"locked":false,"reason":null},"unitCost":null,"updatedAt":"2022-03-14T22:38:58Z","variant":{"id":"gid:\/\/shopify\/ProductVariant\/41009157243086"}},"inventoryPolicy":"DENY","inventoryQuantity":0,"legacyResourceId":"41009157243086","position":1,"price":"1.00","product":{"id":"gid:\/\/shopify\/Product\/6966721052878"},"requiresShipping":true,"selectedOptions":[{"name":"Size","value":"Small"}],"sellingPlanGroupsCount":{"count": 0, "precision": "EXACT"},"sku":null,"storefrontId":"Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0VmFyaWFudC80MTAwOTE1NzI0MzA4Ng==","taxCode":null,"taxable":true,"title":"Small","updatedAt":"2022-03-14T22:38:58Z","weight":0.0,"weightUnit":"KILOGRAMS"} +{"quantities": [{"name":"incoming","quantity":0},{"name":"available","quantity":0},{"name":"committed","quantity":0},{"name":"reserved","quantity":0},{"name":"damaged","quantity":0},{"name":"safety_stock","quantity":0},{"name":"quality_control","quantity":0}],"id":"gid:\/\/shopify\/InventoryLevel\/91371143374?inventory_item_id=43101443260622","location":{"id":"gid:\/\/shopify\/Location\/57173475534"},"__parentId":"gid:\/\/shopify\/ProductVariant\/41009157243086"} +{"availableForSale":false,"barcode":null,"compareAtPrice":null,"createdAt":"2022-03-14T22:38:58Z","displayName":"Copy of Test Product - Medium","id":"gid:\/\/shopify\/ProductVariant\/41009157275854","image":null,"inventoryItem":{"countryCodeOfOrigin":null,"createdAt":"2022-03-14T22:38:58Z","duplicateSkuCount":{"count": 0, "precision": "EXACT"},"harmonizedSystemCode":null,"id":"gid:\/\/shopify\/InventoryItem\/43101443293390","inventoryHistoryUrl":"https:\/\/atomic-digital-studio-test.myshopify.com\/admin\/products\/6966721052878\/variants\/41009157275854\/inventory_history","legacyResourceId":"43101443293390","locationsCount":{"count": 1, "precision": "EXACT"},"provinceCodeOfOrigin":null,"requiresShipping":true,"sku":null,"tracked":true,"trackedEditable":{"locked":false,"reason":null},"unitCost":null,"updatedAt":"2022-03-14T22:38:58Z","variant":{"id":"gid:\/\/shopify\/ProductVariant\/41009157275854"}},"inventoryPolicy":"DENY","inventoryQuantity":0,"legacyResourceId":"41009157275854","position":2,"price":"2.00","product":{"id":"gid:\/\/shopify\/Product\/6966721052878"},"requiresShipping":true,"selectedOptions":[{"name":"Size","value":"Medium"}],"sellingPlanGroupsCount":{"count": 0, "precision": "EXACT"},"sku":null,"storefrontId":"Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0VmFyaWFudC80MTAwOTE1NzI3NTg1NA==","taxCode":null,"taxable":true,"title":"Medium","updatedAt":"2022-03-14T22:38:58Z","weight":0.0,"weightUnit":"KILOGRAMS"} +{"quantities": [{"name":"incoming","quantity":0},{"name":"available","quantity":0},{"name":"committed","quantity":0},{"name":"reserved","quantity":0},{"name":"damaged","quantity":0},{"name":"safety_stock","quantity":0},{"name":"quality_control","quantity":0}],"id":"gid:\/\/shopify\/InventoryLevel\/91371143374?inventory_item_id=43101443293390","location":{"id":"gid:\/\/shopify\/Location\/57173475534"},"__parentId":"gid:\/\/shopify\/ProductVariant\/41009157275854"} +{"availableForSale":false,"barcode":null,"compareAtPrice":null,"createdAt":"2022-03-14T22:38:58Z","displayName":"Copy of Test Product - Large","id":"gid:\/\/shopify\/ProductVariant\/41009157308622","image":null,"inventoryItem":{"countryCodeOfOrigin":null,"createdAt":"2022-03-14T22:38:58Z","duplicateSkuCount":{"count": 0, "precision": "EXACT"},"harmonizedSystemCode":null,"id":"gid:\/\/shopify\/InventoryItem\/43101443326158","inventoryHistoryUrl":"https:\/\/atomic-digital-studio-test.myshopify.com\/admin\/products\/6966721052878\/variants\/41009157308622\/inventory_history","legacyResourceId":"43101443326158","locationsCount":{"count": 1, "precision": "EXACT"},"provinceCodeOfOrigin":null,"requiresShipping":true,"sku":null,"tracked":true,"trackedEditable":{"locked":false,"reason":null},"unitCost":null,"updatedAt":"2022-03-14T22:38:58Z","variant":{"id":"gid:\/\/shopify\/ProductVariant\/41009157308622"}},"inventoryPolicy":"DENY","inventoryQuantity":0,"legacyResourceId":"41009157308622","position":3,"price":"3.00","product":{"id":"gid:\/\/shopify\/Product\/6966721052878"},"requiresShipping":true,"selectedOptions":[{"name":"Size","value":"Large"}],"sellingPlanGroupsCount":{"count": 0, "precision": "EXACT"},"sku":null,"storefrontId":"Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0VmFyaWFudC80MTAwOTE1NzMwODYyMg==","taxCode":null,"taxable":true,"title":"Large","updatedAt":"2022-03-14T22:38:58Z","weight":0.0,"weightUnit":"KILOGRAMS"} +{"quantities": [{"name":"incoming","quantity":0},{"name":"available","quantity":0},{"name":"committed","quantity":0},{"name":"reserved","quantity":0},{"name":"damaged","quantity":0},{"name":"safety_stock","quantity":0},{"name":"quality_control","quantity":0}],"id":"gid:\/\/shopify\/InventoryLevel\/91371143374?inventory_item_id=43101443326158","location":{"id":"gid:\/\/shopify\/Location\/57173475534"},"__parentId":"gid:\/\/shopify\/ProductVariant\/41009157308622"} diff --git a/packages/gatsby-source-shopify/__tests__/fixtures/ids.json b/packages/gatsby-source-shopify/__tests__/fixtures/ids.json index 922c067ed1fa0..9f57a6b765e22 100644 --- a/packages/gatsby-source-shopify/__tests__/fixtures/ids.json +++ b/packages/gatsby-source-shopify/__tests__/fixtures/ids.json @@ -1 +1,39 @@ -{"gid://shopify/Collection/278407151822":"5e2d818c-9edd-5d9a-9b8b-a87b59518efc","gid://shopify/InventoryLevel/91371143374?inventory_item_id=43100044394702":"2261ddf5-7c64-5934-a990-7dc64fe17040","gid://shopify/InventoryLevel/91371143374?inventory_item_id=43100044427470":"453dda5f-1323-5aa3-8e75-9a0dd08025c2","gid://shopify/InventoryLevel/91371143374?inventory_item_id=43101511090382":"5e8cd605-e547-5d1d-81ed-943904bd8489","gid://shopify/InventoryLevel/91371143374?inventory_item_id=43101443260622":"6eeb7894-1eb4-5556-a797-396fdf229a63","gid://shopify/InventoryLevel/91371143374?inventory_item_id=43101498114254":"6f0ad494-596c-5baa-98e2-cd1b1cbc3ef9","gid://shopify/InventoryLevel/91371143374?inventory_item_id=43101498147022":"70456f30-75b1-507a-9b27-d5a44ade13fa","gid://shopify/InventoryLevel/91371143374?inventory_item_id=43101443293390":"8970ecd9-9a83-5e55-915b-682cfff58699","gid://shopify/InventoryLevel/91371143374?inventory_item_id=43101511057614":"9258a182-adfa-5571-b460-4efb31235637","gid://shopify/InventoryLevel/91371143374?inventory_item_id=43101498081486":"af11227b-ac0f-5089-bea5-7d991ace9cab","gid://shopify/InventoryLevel/91371143374?inventory_item_id=43101443326158":"cedae3ee-f225-5c34-9dd8-f1a25f8d810c","gid://shopify/InventoryLevel/91371143374?inventory_item_id=43101511123150":"e3a0bce1-e7f2-5387-a400-5941ee1fd4aa","gid://shopify/InventoryLevel/91371143374?inventory_item_id=43100044460238":"e8f4985b-ed74-5a19-836d-b5d310c277e5","gid://shopify/LineItem/9995073585358":"9932036d-8c94-5314-a07b-c28d1cf8a8d0","gid://shopify/Location/57173475534":"e3e3dfac-3cbd-5cef-b3d6-3fd214f93ab8","gid://shopify/MediaImage/22755647652046":"8fc15b46-8400-5778-b85c-05db5c009326","gid://shopify/Metafield/21077562228942":"0f64cc58-bb8b-5173-851a-34fd9a5137a3","gid://shopify/Metafield/21078063972558":"88d7939a-693e-5b2e-b989-bf1a70c5515d","gid://shopify/Metafield/21078064955598":"a120de2c-89ef-5d3e-918e-db6a800f1372","gid://shopify/Metafield/21078060335310":"e3bdda06-d619-5445-8b4a-d1155678928c","gid://shopify/Order/3838572757198":"eacb5d29-be9c-5d08-8469-317015bcf802","gid://shopify/Product/6966726000846":"05983ef6-13e3-58d4-8ca5-659416d87d81","gid://shopify/Product/6966721052878":"1386d0f3-354b-584c-a6bb-d11936c8f6fb","gid://shopify/Product/6966726721742":"3a64e071-d892-5bb3-8541-4d919b08cfed","gid://shopify/Product/6950279086286":"87b524a6-a707-5eb9-b193-059b3fcf96e5","gid://shopify/ProductVariant/41007759589582":"232cdd32-2de5-5bdd-a327-08d539ecd51e","gid://shopify/ProductVariant/41007759622350":"266c6a92-078a-519d-8c03-257b4ed15b84","gid://shopify/ProductVariant/41009212096718":"3cf1b5f1-1415-5202-ad28-45ae9526c441","gid://shopify/ProductVariant/41009157243086":"435874ba-a8b0-5b29-a96a-8691e694bf3a","gid://shopify/ProductVariant/41007759655118":"480d2d09-c1b1-5f7c-94a2-635e73e50ef4","gid://shopify/ProductVariant/41009225040078":"4fa8b138-8f6b-5476-9299-b6f924a43873","gid://shopify/ProductVariant/41009157275854":"a0191127-d288-510d-94e5-14f7a6404454","gid://shopify/ProductVariant/41009212129486":"b827e081-a445-5e2e-a007-108b0a2376a2","gid://shopify/ProductVariant/41009157308622":"cba433a6-1513-576f-97c0-80b36fb8afa6","gid://shopify/ProductVariant/41009225105614":"dd352973-0003-5ea8-8a7c-faf51a3b5654","gid://shopify/ProductVariant/41009225072846":"eee0cd15-d40a-59fd-afec-517020716642","gid://shopify/ProductVariant/41009212063950":"f819072d-571c-5e13-a308-b3e7ce75152f"} \ No newline at end of file +{ + "gid://shopify/Collection/278407151822": "5e2d818c-9edd-5d9a-9b8b-a87b59518efc", + "gid://shopify/InventoryLevel/91371143374?inventory_item_id=43100044394702": "2261ddf5-7c64-5934-a990-7dc64fe17040", + "gid://shopify/InventoryLevel/91371143374?inventory_item_id=43100044427470": "453dda5f-1323-5aa3-8e75-9a0dd08025c2", + "gid://shopify/InventoryLevel/91371143374?inventory_item_id=43101511090382": "5e8cd605-e547-5d1d-81ed-943904bd8489", + "gid://shopify/InventoryLevel/91371143374?inventory_item_id=43101443260622": "6eeb7894-1eb4-5556-a797-396fdf229a63", + "gid://shopify/InventoryLevel/91371143374?inventory_item_id=43101498114254": "6f0ad494-596c-5baa-98e2-cd1b1cbc3ef9", + "gid://shopify/InventoryLevel/91371143374?inventory_item_id=43101498147022": "70456f30-75b1-507a-9b27-d5a44ade13fa", + "gid://shopify/InventoryLevel/91371143374?inventory_item_id=43101443293390": "8970ecd9-9a83-5e55-915b-682cfff58699", + "gid://shopify/InventoryLevel/91371143374?inventory_item_id=43101511057614": "9258a182-adfa-5571-b460-4efb31235637", + "gid://shopify/InventoryLevel/91371143374?inventory_item_id=43101498081486": "af11227b-ac0f-5089-bea5-7d991ace9cab", + "gid://shopify/InventoryLevel/91371143374?inventory_item_id=43101443326158": "cedae3ee-f225-5c34-9dd8-f1a25f8d810c", + "gid://shopify/InventoryLevel/91371143374?inventory_item_id=43101511123150": "e3a0bce1-e7f2-5387-a400-5941ee1fd4aa", + "gid://shopify/InventoryLevel/91371143374?inventory_item_id=43100044460238": "e8f4985b-ed74-5a19-836d-b5d310c277e5", + "gid://shopify/LineItem/9995073585358": "9932036d-8c94-5314-a07b-c28d1cf8a8d0", + "gid://shopify/Location/57173475534": "e3e3dfac-3cbd-5cef-b3d6-3fd214f93ab8", + "gid://shopify/MediaImage/22755647652046": "8fc15b46-8400-5778-b85c-05db5c009326", + "gid://shopify/Metafield/21077562228942": "0f64cc58-bb8b-5173-851a-34fd9a5137a3", + "gid://shopify/Metafield/21078063972558": "88d7939a-693e-5b2e-b989-bf1a70c5515d", + "gid://shopify/Metafield/21078064955598": "a120de2c-89ef-5d3e-918e-db6a800f1372", + "gid://shopify/Metafield/21078060335310": "e3bdda06-d619-5445-8b4a-d1155678928c", + "gid://shopify/Order/3838572757198": "eacb5d29-be9c-5d08-8469-317015bcf802", + "gid://shopify/Product/6966726000846": "05983ef6-13e3-58d4-8ca5-659416d87d81", + "gid://shopify/Product/6966721052878": "1386d0f3-354b-584c-a6bb-d11936c8f6fb", + "gid://shopify/Product/6966726721742": "3a64e071-d892-5bb3-8541-4d919b08cfed", + "gid://shopify/Product/6950279086286": "87b524a6-a707-5eb9-b193-059b3fcf96e5", + "gid://shopify/ProductVariant/41007759589582": "232cdd32-2de5-5bdd-a327-08d539ecd51e", + "gid://shopify/ProductVariant/41007759622350": "266c6a92-078a-519d-8c03-257b4ed15b84", + "gid://shopify/ProductVariant/41009212096718": "3cf1b5f1-1415-5202-ad28-45ae9526c441", + "gid://shopify/ProductVariant/41009157243086": "435874ba-a8b0-5b29-a96a-8691e694bf3a", + "gid://shopify/ProductVariant/41007759655118": "480d2d09-c1b1-5f7c-94a2-635e73e50ef4", + "gid://shopify/ProductVariant/41009225040078": "4fa8b138-8f6b-5476-9299-b6f924a43873", + "gid://shopify/ProductVariant/41009157275854": "a0191127-d288-510d-94e5-14f7a6404454", + "gid://shopify/ProductVariant/41009212129486": "b827e081-a445-5e2e-a007-108b0a2376a2", + "gid://shopify/ProductVariant/41009157308622": "cba433a6-1513-576f-97c0-80b36fb8afa6", + "gid://shopify/ProductVariant/41009225105614": "dd352973-0003-5ea8-8a7c-faf51a3b5654", + "gid://shopify/ProductVariant/41009225072846": "eee0cd15-d40a-59fd-afec-517020716642", + "gid://shopify/ProductVariant/41009212063950": "f819072d-571c-5e13-a308-b3e7ce75152f" +} diff --git a/packages/gatsby-source-shopify/__tests__/fixtures/index.ts b/packages/gatsby-source-shopify/__tests__/fixtures/index.ts index dcca63b088a29..e5de175f453db 100644 --- a/packages/gatsby-source-shopify/__tests__/fixtures/index.ts +++ b/packages/gatsby-source-shopify/__tests__/fixtures/index.ts @@ -9,6 +9,7 @@ import ids from "./ids.json" export function mockGatsbyApi(): NodePluginArgs { return { actions: { + createFieldExtension: jest.fn(), createTypes: jest.fn(), createNode: jest.fn(), touchNode: jest.fn(), diff --git a/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyCollection.json b/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyCollection.json index 65bd231dddafe..40a3d4c7fce5b 100644 --- a/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyCollection.json +++ b/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyCollection.json @@ -1 +1,51 @@ -[{"description":"Test Collection Description","descriptionHtml":"Test Collection Description","feedback":{"details":[],"summary":"This collection couldn’t be published to Google"},"handle":"test-collection","image":null,"legacyResourceId":"278407151822","productsCount":2,"ruleSet":{"appliedDisjunctively":false,"rules":[{"column":"IS_PRICE_REDUCED","condition":"","relation":"IS_NOT_SET"}]},"seo":{"description":null,"title":null},"sortOrder":"BEST_SELLING","storefrontId":"Z2lkOi8vc2hvcGlmeS9Db2xsZWN0aW9uLzI3ODQwNzE1MTgyMg==","templateSuffix":"","title":"Test Collection","updatedAt":"2022-03-14T22:39:00Z","shopifyId":"gid://shopify/Collection/278407151822","products___NODE":["87b524a6-a707-5eb9-b193-059b3fcf96e5","1386d0f3-354b-584c-a6bb-d11936c8f6fb"],"metafields___NODE":[],"id":"5e2d818c-9edd-5d9a-9b8b-a87b59518efc","internal":{"type":"ShopifyCollection","contentDigest":"097e80a6bd493fd407351894b026070f","owner":"gatsby-source-shopify","counter":47},"children":[],"parent":null}] \ No newline at end of file +[ + { + "description": "Test Collection Description", + "descriptionHtml": "Test Collection Description", + "feedback": { + "details": [], + "summary": "This collection couldn’t be published to Google" + }, + "handle": "test-collection", + "image": null, + "legacyResourceId": "278407151822", + "productsCount": { + "count": 2, + "precision": "EXACT" + }, + "ruleSet": { + "appliedDisjunctively": false, + "rules": [ + { + "column": "IS_PRICE_REDUCED", + "condition": "", + "relation": "IS_NOT_SET" + } + ] + }, + "seo": { + "description": null, + "title": null + }, + "sortOrder": "BEST_SELLING", + "storefrontId": "Z2lkOi8vc2hvcGlmeS9Db2xsZWN0aW9uLzI3ODQwNzE1MTgyMg==", + "templateSuffix": "", + "title": "Test Collection", + "updatedAt": "2022-03-14T22:39:00Z", + "shopifyId": "gid://shopify/Collection/278407151822", + "products___NODE": [ + "87b524a6-a707-5eb9-b193-059b3fcf96e5", + "1386d0f3-354b-584c-a6bb-d11936c8f6fb" + ], + "metafields___NODE": [], + "id": "5e2d818c-9edd-5d9a-9b8b-a87b59518efc", + "internal": { + "type": "ShopifyCollection", + "contentDigest": "097e80a6bd493fd407351894b026070f", + "owner": "gatsby-source-shopify", + "counter": 47 + }, + "children": [], + "parent": null + } +] diff --git a/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyExternalVideo.json b/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyExternalVideo.json index 0637a088a01e8..fe51488c7066f 100644 --- a/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyExternalVideo.json +++ b/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyExternalVideo.json @@ -1 +1 @@ -[] \ No newline at end of file +[] diff --git a/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyInventoryItem.json b/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyInventoryItem.json index 0637a088a01e8..fe51488c7066f 100644 --- a/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyInventoryItem.json +++ b/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyInventoryItem.json @@ -1 +1 @@ -[] \ No newline at end of file +[] diff --git a/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyInventoryLevel.json b/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyInventoryLevel.json index 175f316031d30..51fabbed526a5 100644 --- a/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyInventoryLevel.json +++ b/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyInventoryLevel.json @@ -1 +1,278 @@ -[{"available":1,"location":{"shopifyId":"gid://shopify/Location/57173475534"},"__parentId":"gid://shopify/ProductVariant/41007759589582","shopifyId":"gid://shopify/InventoryLevel/91371143374?inventory_item_id=43100044394702","id":"2261ddf5-7c64-5934-a990-7dc64fe17040","internal":{"type":"ShopifyInventoryLevel","contentDigest":"49766e299f7c1185b12100197cf22289","owner":"gatsby-source-shopify","counter":43},"children":[],"parent":null},{"available":1,"location":{"shopifyId":"gid://shopify/Location/57173475534"},"__parentId":"gid://shopify/ProductVariant/41007759622350","shopifyId":"gid://shopify/InventoryLevel/91371143374?inventory_item_id=43100044427470","id":"453dda5f-1323-5aa3-8e75-9a0dd08025c2","internal":{"type":"ShopifyInventoryLevel","contentDigest":"65646031ede60f67d5cfb68bd885a993","owner":"gatsby-source-shopify","counter":41},"children":[],"parent":null},{"available":0,"location":{"shopifyId":"gid://shopify/Location/57173475534"},"__parentId":"gid://shopify/ProductVariant/41009157243086","shopifyId":"gid://shopify/InventoryLevel/91371143374?inventory_item_id=43101443260622","id":"6eeb7894-1eb4-5556-a797-396fdf229a63","internal":{"type":"ShopifyInventoryLevel","contentDigest":"7330b3b265ff5cd9c919d17c8b1f2738","owner":"gatsby-source-shopify","counter":37},"children":[],"parent":null},{"available":0,"location":{"shopifyId":"gid://shopify/Location/57173475534"},"__parentId":"gid://shopify/ProductVariant/41009157275854","shopifyId":"gid://shopify/InventoryLevel/91371143374?inventory_item_id=43101443293390","id":"8970ecd9-9a83-5e55-915b-682cfff58699","internal":{"type":"ShopifyInventoryLevel","contentDigest":"53a8f523b8c13f83aa3fe5e691f4fb05","owner":"gatsby-source-shopify","counter":35},"children":[],"parent":null},{"available":0,"location":{"shopifyId":"gid://shopify/Location/57173475534"},"__parentId":"gid://shopify/ProductVariant/41009157308622","shopifyId":"gid://shopify/InventoryLevel/91371143374?inventory_item_id=43101443326158","id":"cedae3ee-f225-5c34-9dd8-f1a25f8d810c","internal":{"type":"ShopifyInventoryLevel","contentDigest":"1fff8771ebc89cb33b23f9707784164f","owner":"gatsby-source-shopify","counter":33},"children":[],"parent":null},{"available":1,"location":{"shopifyId":"gid://shopify/Location/57173475534"},"__parentId":"gid://shopify/ProductVariant/41007759655118","shopifyId":"gid://shopify/InventoryLevel/91371143374?inventory_item_id=43100044460238","id":"e8f4985b-ed74-5a19-836d-b5d310c277e5","internal":{"type":"ShopifyInventoryLevel","contentDigest":"1213164ee47eb1e013bc51a08f113f51","owner":"gatsby-source-shopify","counter":39},"children":[],"parent":null}] \ No newline at end of file +[ + { + "quantities": [ + { + "name": "incoming", + "quantity": 0 + }, + { + "name": "available", + "quantity": 1 + }, + { + "name": "committed", + "quantity": 0 + }, + { + "name": "reserved", + "quantity": 0 + }, + { + "name": "damaged", + "quantity": 0 + }, + { + "name": "safety_stock", + "quantity": 0 + }, + { + "name": "quality_control", + "quantity": 0 + } + ], + "location": { + "shopifyId": "gid://shopify/Location/57173475534" + }, + "__parentId": "gid://shopify/ProductVariant/41007759589582", + "shopifyId": "gid://shopify/InventoryLevel/91371143374?inventory_item_id=43100044394702", + "id": "2261ddf5-7c64-5934-a990-7dc64fe17040", + "internal": { + "type": "ShopifyInventoryLevel", + "contentDigest": "49766e299f7c1185b12100197cf22289", + "owner": "gatsby-source-shopify", + "counter": 43 + }, + "children": [], + "parent": null + }, + { + "quantities": [ + { + "name": "incoming", + "quantity": 0 + }, + { + "name": "available", + "quantity": 1 + }, + { + "name": "committed", + "quantity": 0 + }, + { + "name": "reserved", + "quantity": 0 + }, + { + "name": "damaged", + "quantity": 0 + }, + { + "name": "safety_stock", + "quantity": 0 + }, + { + "name": "quality_control", + "quantity": 0 + } + ], + "location": { + "shopifyId": "gid://shopify/Location/57173475534" + }, + "__parentId": "gid://shopify/ProductVariant/41007759622350", + "shopifyId": "gid://shopify/InventoryLevel/91371143374?inventory_item_id=43100044427470", + "id": "453dda5f-1323-5aa3-8e75-9a0dd08025c2", + "internal": { + "type": "ShopifyInventoryLevel", + "contentDigest": "65646031ede60f67d5cfb68bd885a993", + "owner": "gatsby-source-shopify", + "counter": 41 + }, + "children": [], + "parent": null + }, + { + "quantities": [ + { + "name": "incoming", + "quantity": 0 + }, + { + "name": "available", + "quantity": 0 + }, + { + "name": "committed", + "quantity": 0 + }, + { + "name": "reserved", + "quantity": 0 + }, + { + "name": "damaged", + "quantity": 0 + }, + { + "name": "safety_stock", + "quantity": 0 + }, + { + "name": "quality_control", + "quantity": 0 + } + ], + "location": { + "shopifyId": "gid://shopify/Location/57173475534" + }, + "__parentId": "gid://shopify/ProductVariant/41009157243086", + "shopifyId": "gid://shopify/InventoryLevel/91371143374?inventory_item_id=43101443260622", + "id": "6eeb7894-1eb4-5556-a797-396fdf229a63", + "internal": { + "type": "ShopifyInventoryLevel", + "contentDigest": "7330b3b265ff5cd9c919d17c8b1f2738", + "owner": "gatsby-source-shopify", + "counter": 37 + }, + "children": [], + "parent": null + }, + { + "quantities": [ + { + "name": "incoming", + "quantity": 0 + }, + { + "name": "available", + "quantity": 0 + }, + { + "name": "committed", + "quantity": 0 + }, + { + "name": "reserved", + "quantity": 0 + }, + { + "name": "damaged", + "quantity": 0 + }, + { + "name": "safety_stock", + "quantity": 0 + }, + { + "name": "quality_control", + "quantity": 0 + } + ], + "location": { + "shopifyId": "gid://shopify/Location/57173475534" + }, + "__parentId": "gid://shopify/ProductVariant/41009157275854", + "shopifyId": "gid://shopify/InventoryLevel/91371143374?inventory_item_id=43101443293390", + "id": "8970ecd9-9a83-5e55-915b-682cfff58699", + "internal": { + "type": "ShopifyInventoryLevel", + "contentDigest": "53a8f523b8c13f83aa3fe5e691f4fb05", + "owner": "gatsby-source-shopify", + "counter": 35 + }, + "children": [], + "parent": null + }, + { + "quantities": [ + { + "name": "incoming", + "quantity": 0 + }, + { + "name": "available", + "quantity": 0 + }, + { + "name": "committed", + "quantity": 0 + }, + { + "name": "reserved", + "quantity": 0 + }, + { + "name": "damaged", + "quantity": 0 + }, + { + "name": "safety_stock", + "quantity": 0 + }, + { + "name": "quality_control", + "quantity": 0 + } + ], + "location": { + "shopifyId": "gid://shopify/Location/57173475534" + }, + "__parentId": "gid://shopify/ProductVariant/41009157308622", + "shopifyId": "gid://shopify/InventoryLevel/91371143374?inventory_item_id=43101443326158", + "id": "cedae3ee-f225-5c34-9dd8-f1a25f8d810c", + "internal": { + "type": "ShopifyInventoryLevel", + "contentDigest": "1fff8771ebc89cb33b23f9707784164f", + "owner": "gatsby-source-shopify", + "counter": 33 + }, + "children": [], + "parent": null + }, + { + "quantities": [ + { + "name": "incoming", + "quantity": 0 + }, + { + "name": "available", + "quantity": 1 + }, + { + "name": "committed", + "quantity": 0 + }, + { + "name": "reserved", + "quantity": 0 + }, + { + "name": "damaged", + "quantity": 0 + }, + { + "name": "safety_stock", + "quantity": 0 + }, + { + "name": "quality_control", + "quantity": 0 + } + ], + "location": { + "shopifyId": "gid://shopify/Location/57173475534" + }, + "__parentId": "gid://shopify/ProductVariant/41007759655118", + "shopifyId": "gid://shopify/InventoryLevel/91371143374?inventory_item_id=43100044460238", + "id": "e8f4985b-ed74-5a19-836d-b5d310c277e5", + "internal": { + "type": "ShopifyInventoryLevel", + "contentDigest": "1213164ee47eb1e013bc51a08f113f51", + "owner": "gatsby-source-shopify", + "counter": 39 + }, + "children": [], + "parent": null + } +] diff --git a/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyLineItem.json b/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyLineItem.json index 883598a295d9d..712301bee4b84 100644 --- a/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyLineItem.json +++ b/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyLineItem.json @@ -1 +1,18 @@ -[{"product":{"shopifyId":"gid://shopify/Product/6950279086286"},"__parentId":"gid://shopify/Order/3838572757198","shopifyId":"gid://shopify/LineItem/9995073585358","id":"9932036d-8c94-5314-a07b-c28d1cf8a8d0","internal":{"type":"ShopifyLineItem","contentDigest":"aac61e83a93a97a7a9abf72f4ad38a6d","owner":"gatsby-source-shopify","counter":45},"children":[],"parent":null}] \ No newline at end of file +[ + { + "product": { + "shopifyId": "gid://shopify/Product/6950279086286" + }, + "__parentId": "gid://shopify/Order/3838572757198", + "shopifyId": "gid://shopify/LineItem/9995073585358", + "id": "9932036d-8c94-5314-a07b-c28d1cf8a8d0", + "internal": { + "type": "ShopifyLineItem", + "contentDigest": "aac61e83a93a97a7a9abf72f4ad38a6d", + "owner": "gatsby-source-shopify", + "counter": 45 + }, + "children": [], + "parent": null + } +] diff --git a/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyLocation.json b/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyLocation.json index a6271b8babe6a..9d4834c96e4d2 100644 --- a/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyLocation.json +++ b/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyLocation.json @@ -1 +1,45 @@ -[{"activatable":true,"address":{"address1":"548 Market St #36791","address2":"","city":"San Francisco","country":"United States","countryCode":"US","formatted":["548 Market St #36791","San Francisco CA 36791","United States"],"latitude":null,"longitude":null,"phone":"","province":"California","provinceCode":"CA","zip":"36791"},"addressVerified":false,"deactivatable":false,"deactivatedAt":null,"deletable":false,"fulfillmentService":null,"fulfillsOnlineOrders":true,"hasActiveInventory":true,"hasUnfulfilledOrders":false,"isActive":true,"legacyResourceId":"57173475534","name":"Gatsby Headquarters","shipsInventory":true,"shopifyId":"gid://shopify/Location/57173475534","id":"e3e3dfac-3cbd-5cef-b3d6-3fd214f93ab8","internal":{"type":"ShopifyLocation","contentDigest":"5776f5e06841c1592a70c6bbb07bc391","owner":"gatsby-source-shopify","counter":48},"children":[],"parent":null}] \ No newline at end of file +[ + { + "activatable": true, + "address": { + "address1": "548 Market St #36791", + "address2": "", + "city": "San Francisco", + "country": "United States", + "countryCode": "US", + "formatted": [ + "548 Market St #36791", + "San Francisco CA 36791", + "United States" + ], + "latitude": null, + "longitude": null, + "phone": "", + "province": "California", + "provinceCode": "CA", + "zip": "36791" + }, + "addressVerified": false, + "deactivatable": false, + "deactivatedAt": null, + "deletable": false, + "fulfillmentService": null, + "fulfillsOnlineOrders": true, + "hasActiveInventory": true, + "hasUnfulfilledOrders": false, + "isActive": true, + "legacyResourceId": "57173475534", + "name": "Gatsby Headquarters", + "shipsInventory": true, + "shopifyId": "gid://shopify/Location/57173475534", + "id": "e3e3dfac-3cbd-5cef-b3d6-3fd214f93ab8", + "internal": { + "type": "ShopifyLocation", + "contentDigest": "5776f5e06841c1592a70c6bbb07bc391", + "owner": "gatsby-source-shopify", + "counter": 48 + }, + "children": [], + "parent": null + } +] diff --git a/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyMediaImage.json b/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyMediaImage.json index e40dd7b2e9661..26d217bbf2aab 100644 --- a/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyMediaImage.json +++ b/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyMediaImage.json @@ -1 +1,44 @@ -[{"alt":"","mediaContentType":"IMAGE","mediaErrors":[],"preview":{"image":{"altText":"","height":1280,"originalSrc":"https://cdn.shopify.com/s/files/1/0506/3521/0958/products/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","src":"https://cdn.shopify.com/s/files/1/0506/3521/0958/products/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","transformedSrc":"https://cdn.shopify.com/s/files/1/0506/3521/0958/products/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","width":1920,"shopifyId":"gid://shopify/ImageSource/22758479855822"},"status":"READY"},"status":"READY","createdAt":"2022-02-15T22:22:44Z","fileErrors":[],"fileStatus":"READY","image":{"altText":"","height":1280,"originalSrc":"https://cdn.shopify.com/s/files/1/0506/3521/0958/products/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","src":"https://cdn.shopify.com/s/files/1/0506/3521/0958/products/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","transformedSrc":"https://cdn.shopify.com/s/files/1/0506/3521/0958/products/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","width":1920,"shopifyId":"gid://shopify/ImageSource/22758479855822"},"mimeType":"image/png","__parentId":"gid://shopify/Product/6950279086286","shopifyId":"gid://shopify/MediaImage/22755647652046","id":"8fc15b46-8400-5778-b85c-05db5c009326","internal":{"type":"ShopifyMediaImage","contentDigest":"d77dbcefeae3462e7d049f1ae12c3c43","owner":"gatsby-source-shopify","counter":31},"children":[],"parent":null}] \ No newline at end of file +[ + { + "alt": "", + "mediaContentType": "IMAGE", + "mediaErrors": [], + "preview": { + "image": { + "altText": "", + "height": 1280, + "originalSrc": "https://cdn.shopify.com/s/files/1/0506/3521/0958/products/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764", + "src": "https://cdn.shopify.com/s/files/1/0506/3521/0958/products/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764", + "transformedSrc": "https://cdn.shopify.com/s/files/1/0506/3521/0958/products/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764", + "width": 1920, + "shopifyId": "gid://shopify/ImageSource/22758479855822" + }, + "status": "READY" + }, + "status": "READY", + "createdAt": "2022-02-15T22:22:44Z", + "fileErrors": [], + "fileStatus": "READY", + "image": { + "altText": "", + "height": 1280, + "originalSrc": "https://cdn.shopify.com/s/files/1/0506/3521/0958/products/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764", + "src": "https://cdn.shopify.com/s/files/1/0506/3521/0958/products/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764", + "transformedSrc": "https://cdn.shopify.com/s/files/1/0506/3521/0958/products/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764", + "width": 1920, + "shopifyId": "gid://shopify/ImageSource/22758479855822" + }, + "mimeType": "image/png", + "__parentId": "gid://shopify/Product/6950279086286", + "shopifyId": "gid://shopify/MediaImage/22755647652046", + "id": "8fc15b46-8400-5778-b85c-05db5c009326", + "internal": { + "type": "ShopifyMediaImage", + "contentDigest": "d77dbcefeae3462e7d049f1ae12c3c43", + "owner": "gatsby-source-shopify", + "counter": 31 + }, + "children": [], + "parent": null + } +] diff --git a/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyMetafield.json b/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyMetafield.json index 143afb88d287c..273b7b7c588cb 100644 --- a/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyMetafield.json +++ b/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyMetafield.json @@ -1 +1,48 @@ -[{"createdAt":"2022-03-14T14:03:25Z","description":null,"key":"subtitle","legacyResourceId":"21077562228942","namespace":"descriptors","ownerType":"PRODUCT","type":"single_line_text_field","updatedAt":"2022-03-14T14:03:25Z","value":"Test Subtitle","valueType":"single_line_text_field","__parentId":"gid://shopify/Product/6950279086286","shopifyId":"gid://shopify/Metafield/21077562228942","id":"0f64cc58-bb8b-5173-851a-34fd9a5137a3","internal":{"type":"ShopifyMetafield","contentDigest":"c0aea0ba11d2fb95f6fb514d65649aac","owner":"gatsby-source-shopify","counter":30},"children":[],"parent":null},{"createdAt":"2022-03-14T22:38:58Z","description":null,"key":"subtitle","legacyResourceId":"21078060335310","namespace":"descriptors","ownerType":"PRODUCT","type":"single_line_text_field","updatedAt":"2022-03-14T22:38:58Z","value":"Test Subtitle","valueType":"single_line_text_field","__parentId":"gid://shopify/Product/6966721052878","shopifyId":"gid://shopify/Metafield/21078060335310","id":"e3bdda06-d619-5445-8b4a-d1155678928c","internal":{"type":"ShopifyMetafield","contentDigest":"10b3020a572a27029a0d278df21b8999","owner":"gatsby-source-shopify","counter":28},"children":[],"parent":null}] \ No newline at end of file +[ + { + "createdAt": "2022-03-14T14:03:25Z", + "description": null, + "key": "subtitle", + "legacyResourceId": "21077562228942", + "namespace": "descriptors", + "ownerType": "PRODUCT", + "type": "single_line_text_field", + "updatedAt": "2022-03-14T14:03:25Z", + "value": "Test Subtitle", + "valueType": "single_line_text_field", + "__parentId": "gid://shopify/Product/6950279086286", + "shopifyId": "gid://shopify/Metafield/21077562228942", + "id": "0f64cc58-bb8b-5173-851a-34fd9a5137a3", + "internal": { + "type": "ShopifyMetafield", + "contentDigest": "c0aea0ba11d2fb95f6fb514d65649aac", + "owner": "gatsby-source-shopify", + "counter": 30 + }, + "children": [], + "parent": null + }, + { + "createdAt": "2022-03-14T22:38:58Z", + "description": null, + "key": "subtitle", + "legacyResourceId": "21078060335310", + "namespace": "descriptors", + "ownerType": "PRODUCT", + "type": "single_line_text_field", + "updatedAt": "2022-03-14T22:38:58Z", + "value": "Test Subtitle", + "valueType": "single_line_text_field", + "__parentId": "gid://shopify/Product/6966721052878", + "shopifyId": "gid://shopify/Metafield/21078060335310", + "id": "e3bdda06-d619-5445-8b4a-d1155678928c", + "internal": { + "type": "ShopifyMetafield", + "contentDigest": "10b3020a572a27029a0d278df21b8999", + "owner": "gatsby-source-shopify", + "counter": 28 + }, + "children": [], + "parent": null + } +] diff --git a/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyModel3d.json b/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyModel3d.json index 0637a088a01e8..fe51488c7066f 100644 --- a/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyModel3d.json +++ b/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyModel3d.json @@ -1 +1 @@ -[] \ No newline at end of file +[] diff --git a/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyOrder.json b/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyOrder.json index f9dcc0270b928..ddbba1dd3798b 100644 --- a/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyOrder.json +++ b/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyOrder.json @@ -1 +1,21 @@ -[{"closed":true,"closedAt":"2022-03-14T13:58:21Z","edited":false,"refunds":[],"shopifyId":"gid://shopify/Order/3838572757198","lineItems___NODE":["9932036d-8c94-5314-a07b-c28d1cf8a8d0"],"id":"eacb5d29-be9c-5d08-8469-317015bcf802","internal":{"type":"ShopifyOrder","contentDigest":"b9cf964ccbbd46dfe1580f0ece10c5c9","owner":"gatsby-source-shopify","counter":46},"children":[],"parent":null}] \ No newline at end of file +[ + { + "closed": true, + "closedAt": "2022-03-14T13:58:21Z", + "edited": false, + "refunds": [], + "shopifyId": "gid://shopify/Order/3838572757198", + "lineItems___NODE": [ + "9932036d-8c94-5314-a07b-c28d1cf8a8d0" + ], + "id": "eacb5d29-be9c-5d08-8469-317015bcf802", + "internal": { + "type": "ShopifyOrder", + "contentDigest": "b9cf964ccbbd46dfe1580f0ece10c5c9", + "owner": "gatsby-source-shopify", + "counter": 46 + }, + "children": [], + "parent": null + } +] diff --git a/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyProduct.json b/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyProduct.json index db3e897855a8e..c86830bc59ab1 100644 --- a/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyProduct.json +++ b/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyProduct.json @@ -1 +1,202 @@ -[{"createdAt":"2022-03-14T22:38:58Z","description":"Test Description","descriptionHtml":"Test Description","featuredImage":null,"featuredMedia":null,"feedback":{"details":[],"summary":"This product couldn’t be published to Google"},"giftCardTemplateSuffix":"","handle":"copy-of-test-product","hasOnlyDefaultVariant":false,"hasOutOfStockVariants":true,"isGiftCard":false,"legacyResourceId":"6966721052878","mediaCount":0,"onlineStorePreviewUrl":"https://atomic-digital-studio-test.myshopify.com/products/copy-of-test-product","onlineStoreUrl":null,"options":[{"name":"Size","position":1,"values":["Small","Medium","Large"],"shopifyId":"gid://shopify/ProductOption/8914986795214"}],"priceRange":{"maxVariantPrice":{"amount":"300.0","currencyCode":"CAD"},"minVariantPrice":{"amount":"100.0","currencyCode":"CAD"}},"priceRangeV2":{"maxVariantPrice":{"amount":"3.0","currencyCode":"CAD"},"minVariantPrice":{"amount":"1.0","currencyCode":"CAD"}},"productType":"Test Type","publishedAt":"2022-03-14T22:38:58Z","requiresSellingPlan":false,"sellingPlanGroupCount":0,"seo":{"description":null,"title":null},"status":"ACTIVE","storefrontId":"Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0LzY5NjY3MjEwNTI4Nzg=","tags":["test-tag"],"templateSuffix":"","title":"Copy of Test Product","totalInventory":0,"totalVariants":3,"tracksInventory":true,"updatedAt":"2022-03-14T22:38:58Z","vendor":"Gatsby","shopifyId":"gid://shopify/Product/6966721052878","media___NODE":[],"variants___NODE":["435874ba-a8b0-5b29-a96a-8691e694bf3a","a0191127-d288-510d-94e5-14f7a6404454","cba433a6-1513-576f-97c0-80b36fb8afa6"],"metafields___NODE":["e3bdda06-d619-5445-8b4a-d1155678928c"],"collections___NODE":["5e2d818c-9edd-5d9a-9b8b-a87b59518efc"],"id":"1386d0f3-354b-584c-a6bb-d11936c8f6fb","internal":{"type":"ShopifyProduct","contentDigest":"c768cf13de234c3723e300b640e15c46","owner":"gatsby-source-shopify","counter":29},"children":[],"parent":null},{"createdAt":"2022-02-15T22:22:42Z","description":"Test Description","descriptionHtml":"Test Description","featuredImage":{"altText":null,"height":1280,"originalSrc":"https://cdn.shopify.com/s/files/1/0506/3521/0958/products/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","src":"https://cdn.shopify.com/s/files/1/0506/3521/0958/products/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","transformedSrc":"https://cdn.shopify.com/s/files/1/0506/3521/0958/products/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","width":1920,"shopifyId":"gid://shopify/ProductImage/30403196551374"},"featuredMedia":{"shopifyId":"gid://shopify/MediaImage/22755647652046"},"feedback":{"details":[],"summary":"This product couldn’t be published to Google"},"giftCardTemplateSuffix":"","handle":"test-product","hasOnlyDefaultVariant":false,"hasOutOfStockVariants":false,"isGiftCard":false,"legacyResourceId":"6950279086286","mediaCount":1,"onlineStorePreviewUrl":"https://atomic-digital-studio-test.myshopify.com/products/test-product","onlineStoreUrl":null,"options":[{"name":"Size","position":1,"values":["Small","Medium","Large"],"shopifyId":"gid://shopify/ProductOption/8894327619790"}],"priceRange":{"maxVariantPrice":{"amount":"300.0","currencyCode":"CAD"},"minVariantPrice":{"amount":"100.0","currencyCode":"CAD"}},"priceRangeV2":{"maxVariantPrice":{"amount":"3.0","currencyCode":"CAD"},"minVariantPrice":{"amount":"1.0","currencyCode":"CAD"}},"productType":"Test Type","publishedAt":"2022-03-14T21:26:01Z","requiresSellingPlan":false,"sellingPlanGroupCount":0,"seo":{"description":null,"title":null},"status":"ACTIVE","storefrontId":"Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0LzY5NTAyNzkwODYyODY=","tags":["test-tag"],"templateSuffix":"","title":"Test Product","totalInventory":3,"totalVariants":3,"tracksInventory":true,"updatedAt":"2022-03-14T21:26:01Z","vendor":"Gatsby","shopifyId":"gid://shopify/Product/6950279086286","media___NODE":["8fc15b46-8400-5778-b85c-05db5c009326"],"variants___NODE":["232cdd32-2de5-5bdd-a327-08d539ecd51e","266c6a92-078a-519d-8c03-257b4ed15b84","480d2d09-c1b1-5f7c-94a2-635e73e50ef4"],"metafields___NODE":["0f64cc58-bb8b-5173-851a-34fd9a5137a3"],"collections___NODE":["5e2d818c-9edd-5d9a-9b8b-a87b59518efc"],"id":"87b524a6-a707-5eb9-b193-059b3fcf96e5","internal":{"type":"ShopifyProduct","contentDigest":"469984af6fa3e64850c1cccc32d072b7","owner":"gatsby-source-shopify","counter":32},"children":[],"parent":null}] \ No newline at end of file +[ + { + "createdAt": "2022-03-14T22:38:58Z", + "description": "Test Description", + "descriptionHtml": "Test Description", + "featuredImage": null, + "featuredMedia": null, + "feedback": { + "details": [], + "summary": "This product couldn’t be published to Google" + }, + "giftCardTemplateSuffix": "", + "handle": "copy-of-test-product", + "hasOnlyDefaultVariant": false, + "hasOutOfStockVariants": true, + "isGiftCard": false, + "legacyResourceId": "6966721052878", + "mediaCount": 0, + "onlineStorePreviewUrl": "https://atomic-digital-studio-test.myshopify.com/products/copy-of-test-product", + "onlineStoreUrl": null, + "options": [ + { + "name": "Size", + "position": 1, + "values": [ + "Small", + "Medium", + "Large" + ], + "shopifyId": "gid://shopify/ProductOption/8914986795214" + } + ], + "priceRange": { + "maxVariantPrice": { + "amount": "300.0", + "currencyCode": "CAD" + }, + "minVariantPrice": { + "amount": "100.0", + "currencyCode": "CAD" + } + }, + "priceRangeV2": { + "maxVariantPrice": { + "amount": "3.0", + "currencyCode": "CAD" + }, + "minVariantPrice": { + "amount": "1.0", + "currencyCode": "CAD" + } + }, + "productType": "Test Type", + "publishedAt": "2022-03-14T22:38:58Z", + "requiresSellingPlan": false, + "sellingPlanGroupsCount": 0, + "seo": { + "description": null, + "title": null + }, + "status": "ACTIVE", + "storefrontId": "Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0LzY5NjY3MjEwNTI4Nzg=", + "tags": [ + "test-tag" + ], + "templateSuffix": "", + "title": "Copy of Test Product", + "totalInventory": 0, + "totalVariants": 3, + "tracksInventory": true, + "updatedAt": "2022-03-14T22:38:58Z", + "vendor": "Gatsby", + "shopifyId": "gid://shopify/Product/6966721052878", + "media___NODE": [], + "variants___NODE": [ + "435874ba-a8b0-5b29-a96a-8691e694bf3a", + "a0191127-d288-510d-94e5-14f7a6404454", + "cba433a6-1513-576f-97c0-80b36fb8afa6" + ], + "metafields___NODE": [ + "e3bdda06-d619-5445-8b4a-d1155678928c" + ], + "collections___NODE": [ + "5e2d818c-9edd-5d9a-9b8b-a87b59518efc" + ], + "id": "1386d0f3-354b-584c-a6bb-d11936c8f6fb", + "internal": { + "type": "ShopifyProduct", + "contentDigest": "c768cf13de234c3723e300b640e15c46", + "owner": "gatsby-source-shopify", + "counter": 29 + }, + "children": [], + "parent": null + }, + { + "createdAt": "2022-02-15T22:22:42Z", + "description": "Test Description", + "descriptionHtml": "Test Description", + "featuredImage": { + "altText": null, + "height": 1280, + "originalSrc": "https://cdn.shopify.com/s/files/1/0506/3521/0958/products/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764", + "src": "https://cdn.shopify.com/s/files/1/0506/3521/0958/products/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764", + "transformedSrc": "https://cdn.shopify.com/s/files/1/0506/3521/0958/products/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764", + "width": 1920, + "shopifyId": "gid://shopify/ProductImage/30403196551374" + }, + "featuredMedia": { + "shopifyId": "gid://shopify/MediaImage/22755647652046" + }, + "feedback": { + "details": [], + "summary": "This product couldn’t be published to Google" + }, + "giftCardTemplateSuffix": "", + "handle": "test-product", + "hasOnlyDefaultVariant": false, + "hasOutOfStockVariants": false, + "isGiftCard": false, + "legacyResourceId": "6950279086286", + "mediaCount": 1, + "onlineStorePreviewUrl": "https://atomic-digital-studio-test.myshopify.com/products/test-product", + "onlineStoreUrl": null, + "options": [ + { + "name": "Size", + "position": 1, + "values": [ + "Small", + "Medium", + "Large" + ], + "shopifyId": "gid://shopify/ProductOption/8894327619790" + } + ], + "priceRange": { + "maxVariantPrice": { + "amount": "300.0", + "currencyCode": "CAD" + }, + "minVariantPrice": { + "amount": "100.0", + "currencyCode": "CAD" + } + }, + "priceRangeV2": { + "maxVariantPrice": { + "amount": "3.0", + "currencyCode": "CAD" + }, + "minVariantPrice": { + "amount": "1.0", + "currencyCode": "CAD" + } + }, + "productType": "Test Type", + "publishedAt": "2022-03-14T21:26:01Z", + "requiresSellingPlan": false, + "sellingPlanGroupsCount": 0, + "seo": { + "description": null, + "title": null + }, + "status": "ACTIVE", + "storefrontId": "Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0LzY5NTAyNzkwODYyODY=", + "tags": [ + "test-tag" + ], + "templateSuffix": "", + "title": "Test Product", + "totalInventory": 3, + "totalVariants": 3, + "tracksInventory": true, + "updatedAt": "2022-03-14T21:26:01Z", + "vendor": "Gatsby", + "shopifyId": "gid://shopify/Product/6950279086286", + "media___NODE": [ + "8fc15b46-8400-5778-b85c-05db5c009326" + ], + "variants___NODE": [ + "232cdd32-2de5-5bdd-a327-08d539ecd51e", + "266c6a92-078a-519d-8c03-257b4ed15b84", + "480d2d09-c1b1-5f7c-94a2-635e73e50ef4" + ], + "metafields___NODE": [ + "0f64cc58-bb8b-5173-851a-34fd9a5137a3" + ], + "collections___NODE": [ + "5e2d818c-9edd-5d9a-9b8b-a87b59518efc" + ], + "id": "87b524a6-a707-5eb9-b193-059b3fcf96e5", + "internal": { + "type": "ShopifyProduct", + "contentDigest": "469984af6fa3e64850c1cccc32d072b7", + "owner": "gatsby-source-shopify", + "counter": 32 + }, + "children": [], + "parent": null + } +] diff --git a/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyProductVariant.json b/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyProductVariant.json index f1639287d3696..e16b8284a882d 100644 --- a/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyProductVariant.json +++ b/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyProductVariant.json @@ -1 +1,554 @@ -[{"availableForSale":true,"barcode":"","compareAtPrice":null,"createdAt":"2022-03-14T13:53:31Z","displayName":"Test Product - Small","image":{"altText":null,"height":1280,"originalSrc":"https://cdn.shopify.com/s/files/1/0506/3521/0958/products/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","src":"https://cdn.shopify.com/s/files/1/0506/3521/0958/products/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","transformedSrc":"https://cdn.shopify.com/s/files/1/0506/3521/0958/products/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","width":1920,"shopifyId":"gid://shopify/ProductImage/30403196551374"},"inventoryItem":{"countryCodeOfOrigin":null,"createdAt":"2022-03-14T13:53:31Z","duplicateSkuCount":0,"harmonizedSystemCode":null,"inventoryHistoryUrl":"https://atomic-digital-studio-test.myshopify.com/admin/products/6950279086286/variants/41007759589582/inventory_history","legacyResourceId":"43100044394702","locationsCount":1,"provinceCodeOfOrigin":null,"requiresShipping":true,"sku":"","tracked":true,"trackedEditable":{"locked":false,"reason":null},"unitCost":null,"updatedAt":"2022-03-14T13:53:31Z","variant":{"shopifyId":"gid://shopify/ProductVariant/41007759589582"},"shopifyId":"gid://shopify/InventoryItem/43100044394702"},"inventoryPolicy":"DENY","inventoryQuantity":1,"legacyResourceId":"41007759589582","position":1,"price":"1.00","product":{"shopifyId":"gid://shopify/Product/6950279086286"},"requiresShipping":true,"selectedOptions":[{"name":"Size","value":"Small"}],"sellingPlanGroupCount":0,"sku":"","storefrontId":"Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0VmFyaWFudC80MTAwNzc1OTU4OTU4Mg==","taxCode":null,"taxable":true,"title":"Small","updatedAt":"2022-03-14T14:00:01Z","weight":0,"weightUnit":"KILOGRAMS","shopifyId":"gid://shopify/ProductVariant/41007759589582","inventoryLevels___NODE":["2261ddf5-7c64-5934-a990-7dc64fe17040"],"metafields___NODE":[],"media___NODE":["8fc15b46-8400-5778-b85c-05db5c009326"],"presentmentPrices":[{"compareAtPrice":null,"price":{"amount":"1.0","currencyCode":"CAD"},"__typename":"ProductVariantPricePair","__parentId":"gid://shopify/ProductVariant/41007759589582"}],"id":"232cdd32-2de5-5bdd-a327-08d539ecd51e","internal":{"type":"ShopifyProductVariant","contentDigest":"d78ab3f729dd2153d7b164c6188879bf","owner":"gatsby-source-shopify","counter":44},"children":[],"parent":null},{"availableForSale":true,"barcode":"","compareAtPrice":null,"createdAt":"2022-03-14T13:53:31Z","displayName":"Test Product - Medium","image":{"altText":null,"height":1280,"originalSrc":"https://cdn.shopify.com/s/files/1/0506/3521/0958/products/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","src":"https://cdn.shopify.com/s/files/1/0506/3521/0958/products/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","transformedSrc":"https://cdn.shopify.com/s/files/1/0506/3521/0958/products/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","width":1920,"shopifyId":"gid://shopify/ProductImage/30403196551374"},"inventoryItem":{"countryCodeOfOrigin":null,"createdAt":"2022-03-14T13:53:31Z","duplicateSkuCount":0,"harmonizedSystemCode":null,"inventoryHistoryUrl":"https://atomic-digital-studio-test.myshopify.com/admin/products/6950279086286/variants/41007759622350/inventory_history","legacyResourceId":"43100044427470","locationsCount":1,"provinceCodeOfOrigin":null,"requiresShipping":true,"sku":"","tracked":true,"trackedEditable":{"locked":false,"reason":null},"unitCost":null,"updatedAt":"2022-03-14T13:53:31Z","variant":{"shopifyId":"gid://shopify/ProductVariant/41007759622350"},"shopifyId":"gid://shopify/InventoryItem/43100044427470"},"inventoryPolicy":"DENY","inventoryQuantity":1,"legacyResourceId":"41007759622350","position":2,"price":"2.00","product":{"shopifyId":"gid://shopify/Product/6950279086286"},"requiresShipping":true,"selectedOptions":[{"name":"Size","value":"Medium"}],"sellingPlanGroupCount":0,"sku":"","storefrontId":"Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0VmFyaWFudC80MTAwNzc1OTYyMjM1MA==","taxCode":null,"taxable":true,"title":"Medium","updatedAt":"2022-03-14T14:00:01Z","weight":0,"weightUnit":"KILOGRAMS","shopifyId":"gid://shopify/ProductVariant/41007759622350","inventoryLevels___NODE":["453dda5f-1323-5aa3-8e75-9a0dd08025c2"],"metafields___NODE":[],"media___NODE":["8fc15b46-8400-5778-b85c-05db5c009326"],"presentmentPrices":[{"compareAtPrice":null,"price":{"amount":"2.0","currencyCode":"CAD"},"__typename":"ProductVariantPricePair","__parentId":"gid://shopify/ProductVariant/41007759622350"}],"id":"266c6a92-078a-519d-8c03-257b4ed15b84","internal":{"type":"ShopifyProductVariant","contentDigest":"339e3ac99e27b1bd00f7982162ae65c0","owner":"gatsby-source-shopify","counter":42},"children":[],"parent":null},{"availableForSale":false,"barcode":null,"compareAtPrice":null,"createdAt":"2022-03-14T22:38:58Z","displayName":"Copy of Test Product - Small","image":null,"inventoryItem":{"countryCodeOfOrigin":null,"createdAt":"2022-03-14T22:38:58Z","duplicateSkuCount":0,"harmonizedSystemCode":null,"inventoryHistoryUrl":"https://atomic-digital-studio-test.myshopify.com/admin/products/6966721052878/variants/41009157243086/inventory_history","legacyResourceId":"43101443260622","locationsCount":1,"provinceCodeOfOrigin":null,"requiresShipping":true,"sku":null,"tracked":true,"trackedEditable":{"locked":false,"reason":null},"unitCost":null,"updatedAt":"2022-03-14T22:38:58Z","variant":{"shopifyId":"gid://shopify/ProductVariant/41009157243086"},"shopifyId":"gid://shopify/InventoryItem/43101443260622"},"inventoryPolicy":"DENY","inventoryQuantity":0,"legacyResourceId":"41009157243086","position":1,"price":"1.00","product":{"shopifyId":"gid://shopify/Product/6966721052878"},"requiresShipping":true,"selectedOptions":[{"name":"Size","value":"Small"}],"sellingPlanGroupCount":0,"sku":null,"storefrontId":"Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0VmFyaWFudC80MTAwOTE1NzI0MzA4Ng==","taxCode":null,"taxable":true,"title":"Small","updatedAt":"2022-03-14T22:38:58Z","weight":0,"weightUnit":"KILOGRAMS","shopifyId":"gid://shopify/ProductVariant/41009157243086","inventoryLevels___NODE":["6eeb7894-1eb4-5556-a797-396fdf229a63"],"metafields___NODE":[],"media___NODE":[],"presentmentPrices":[{"compareAtPrice":null,"price":{"amount":"1.0","currencyCode":"CAD"},"__typename":"ProductVariantPricePair","__parentId":"gid://shopify/ProductVariant/41009157243086"}],"id":"435874ba-a8b0-5b29-a96a-8691e694bf3a","internal":{"type":"ShopifyProductVariant","contentDigest":"816cec6b9e17e17c77e2c6a7e2607041","owner":"gatsby-source-shopify","counter":38},"children":[],"parent":null},{"availableForSale":true,"barcode":"","compareAtPrice":null,"createdAt":"2022-03-14T13:53:31Z","displayName":"Test Product - Large","image":{"altText":null,"height":1280,"originalSrc":"https://cdn.shopify.com/s/files/1/0506/3521/0958/products/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","src":"https://cdn.shopify.com/s/files/1/0506/3521/0958/products/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","transformedSrc":"https://cdn.shopify.com/s/files/1/0506/3521/0958/products/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764","width":1920,"shopifyId":"gid://shopify/ProductImage/30403196551374"},"inventoryItem":{"countryCodeOfOrigin":null,"createdAt":"2022-03-14T13:53:31Z","duplicateSkuCount":0,"harmonizedSystemCode":null,"inventoryHistoryUrl":"https://atomic-digital-studio-test.myshopify.com/admin/products/6950279086286/variants/41007759655118/inventory_history","legacyResourceId":"43100044460238","locationsCount":1,"provinceCodeOfOrigin":null,"requiresShipping":true,"sku":"","tracked":true,"trackedEditable":{"locked":false,"reason":null},"unitCost":null,"updatedAt":"2022-03-14T13:53:31Z","variant":{"shopifyId":"gid://shopify/ProductVariant/41007759655118"},"shopifyId":"gid://shopify/InventoryItem/43100044460238"},"inventoryPolicy":"DENY","inventoryQuantity":1,"legacyResourceId":"41007759655118","position":3,"price":"3.00","product":{"shopifyId":"gid://shopify/Product/6950279086286"},"requiresShipping":true,"selectedOptions":[{"name":"Size","value":"Large"}],"sellingPlanGroupCount":0,"sku":"","storefrontId":"Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0VmFyaWFudC80MTAwNzc1OTY1NTExOA==","taxCode":null,"taxable":true,"title":"Large","updatedAt":"2022-03-14T14:00:01Z","weight":0,"weightUnit":"KILOGRAMS","shopifyId":"gid://shopify/ProductVariant/41007759655118","inventoryLevels___NODE":["e8f4985b-ed74-5a19-836d-b5d310c277e5"],"metafields___NODE":[],"media___NODE":["8fc15b46-8400-5778-b85c-05db5c009326"],"presentmentPrices":[{"compareAtPrice":null,"price":{"amount":"3.0","currencyCode":"CAD"},"__typename":"ProductVariantPricePair","__parentId":"gid://shopify/ProductVariant/41007759655118"}],"id":"480d2d09-c1b1-5f7c-94a2-635e73e50ef4","internal":{"type":"ShopifyProductVariant","contentDigest":"ab757138bf54f19c6d959f292a291db8","owner":"gatsby-source-shopify","counter":40},"children":[],"parent":null},{"availableForSale":false,"barcode":null,"compareAtPrice":null,"createdAt":"2022-03-14T22:38:58Z","displayName":"Copy of Test Product - Medium","image":null,"inventoryItem":{"countryCodeOfOrigin":null,"createdAt":"2022-03-14T22:38:58Z","duplicateSkuCount":0,"harmonizedSystemCode":null,"inventoryHistoryUrl":"https://atomic-digital-studio-test.myshopify.com/admin/products/6966721052878/variants/41009157275854/inventory_history","legacyResourceId":"43101443293390","locationsCount":1,"provinceCodeOfOrigin":null,"requiresShipping":true,"sku":null,"tracked":true,"trackedEditable":{"locked":false,"reason":null},"unitCost":null,"updatedAt":"2022-03-14T22:38:58Z","variant":{"shopifyId":"gid://shopify/ProductVariant/41009157275854"},"shopifyId":"gid://shopify/InventoryItem/43101443293390"},"inventoryPolicy":"DENY","inventoryQuantity":0,"legacyResourceId":"41009157275854","position":2,"price":"2.00","product":{"shopifyId":"gid://shopify/Product/6966721052878"},"requiresShipping":true,"selectedOptions":[{"name":"Size","value":"Medium"}],"sellingPlanGroupCount":0,"sku":null,"storefrontId":"Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0VmFyaWFudC80MTAwOTE1NzI3NTg1NA==","taxCode":null,"taxable":true,"title":"Medium","updatedAt":"2022-03-14T22:38:58Z","weight":0,"weightUnit":"KILOGRAMS","shopifyId":"gid://shopify/ProductVariant/41009157275854","inventoryLevels___NODE":["8970ecd9-9a83-5e55-915b-682cfff58699"],"metafields___NODE":[],"media___NODE":[],"presentmentPrices":[{"compareAtPrice":null,"price":{"amount":"2.0","currencyCode":"CAD"},"__typename":"ProductVariantPricePair","__parentId":"gid://shopify/ProductVariant/41009157275854"}],"id":"a0191127-d288-510d-94e5-14f7a6404454","internal":{"type":"ShopifyProductVariant","contentDigest":"2614ce60a45c9ba2ed54f63511e74419","owner":"gatsby-source-shopify","counter":36},"children":[],"parent":null},{"availableForSale":false,"barcode":null,"compareAtPrice":null,"createdAt":"2022-03-14T22:38:58Z","displayName":"Copy of Test Product - Large","image":null,"inventoryItem":{"countryCodeOfOrigin":null,"createdAt":"2022-03-14T22:38:58Z","duplicateSkuCount":0,"harmonizedSystemCode":null,"inventoryHistoryUrl":"https://atomic-digital-studio-test.myshopify.com/admin/products/6966721052878/variants/41009157308622/inventory_history","legacyResourceId":"43101443326158","locationsCount":1,"provinceCodeOfOrigin":null,"requiresShipping":true,"sku":null,"tracked":true,"trackedEditable":{"locked":false,"reason":null},"unitCost":null,"updatedAt":"2022-03-14T22:38:58Z","variant":{"shopifyId":"gid://shopify/ProductVariant/41009157308622"},"shopifyId":"gid://shopify/InventoryItem/43101443326158"},"inventoryPolicy":"DENY","inventoryQuantity":0,"legacyResourceId":"41009157308622","position":3,"price":"3.00","product":{"shopifyId":"gid://shopify/Product/6966721052878"},"requiresShipping":true,"selectedOptions":[{"name":"Size","value":"Large"}],"sellingPlanGroupCount":0,"sku":null,"storefrontId":"Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0VmFyaWFudC80MTAwOTE1NzMwODYyMg==","taxCode":null,"taxable":true,"title":"Large","updatedAt":"2022-03-14T22:38:58Z","weight":0,"weightUnit":"KILOGRAMS","shopifyId":"gid://shopify/ProductVariant/41009157308622","inventoryLevels___NODE":["cedae3ee-f225-5c34-9dd8-f1a25f8d810c"],"metafields___NODE":[],"media___NODE":[],"presentmentPrices":[{"compareAtPrice":null,"price":{"amount":"3.0","currencyCode":"CAD"},"__typename":"ProductVariantPricePair","__parentId":"gid://shopify/ProductVariant/41009157308622"}],"id":"cba433a6-1513-576f-97c0-80b36fb8afa6","internal":{"type":"ShopifyProductVariant","contentDigest":"2e466fdbf7ec8501841aaa5a85b48259","owner":"gatsby-source-shopify","counter":34},"children":[],"parent":null}] \ No newline at end of file +[ + { + "availableForSale": true, + "barcode": "", + "compareAtPrice": null, + "createdAt": "2022-03-14T13:53:31Z", + "displayName": "Test Product - Small", + "image": { + "altText": null, + "height": 1280, + "originalSrc": "https://cdn.shopify.com/s/files/1/0506/3521/0958/products/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764", + "src": "https://cdn.shopify.com/s/files/1/0506/3521/0958/products/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764", + "transformedSrc": "https://cdn.shopify.com/s/files/1/0506/3521/0958/products/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764", + "width": 1920, + "shopifyId": "gid://shopify/ProductImage/30403196551374" + }, + "inventoryItem": { + "countryCodeOfOrigin": null, + "createdAt": "2022-03-14T13:53:31Z", + "duplicateSkuCount": 0, + "harmonizedSystemCode": null, + "inventoryHistoryUrl": "https://atomic-digital-studio-test.myshopify.com/admin/products/6950279086286/variants/41007759589582/inventory_history", + "legacyResourceId": "43100044394702", + "locationsCount": { + "count": 1, + "precision": "EXACT" + }, + "provinceCodeOfOrigin": null, + "requiresShipping": true, + "sku": "", + "tracked": true, + "trackedEditable": { + "locked": false, + "reason": null + }, + "unitCost": null, + "updatedAt": "2022-03-14T13:53:31Z", + "variant": { + "shopifyId": "gid://shopify/ProductVariant/41007759589582" + }, + "shopifyId": "gid://shopify/InventoryItem/43100044394702" + }, + "inventoryPolicy": "DENY", + "inventoryQuantity": 1, + "legacyResourceId": "41007759589582", + "position": 1, + "price": "1.00", + "product": { + "shopifyId": "gid://shopify/Product/6950279086286" + }, + "requiresShipping": true, + "selectedOptions": [ + { + "name": "Size", + "value": "Small" + } + ], + "sellingPlanGroupsCount": { + "count": 0, + "precision": "EXACT" + }, + "sku": "", + "storefrontId": "Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0VmFyaWFudC80MTAwNzc1OTU4OTU4Mg==", + "taxCode": null, + "taxable": true, + "title": "Small", + "updatedAt": "2022-03-14T14:00:01Z", + "weight": 0, + "weightUnit": "KILOGRAMS", + "shopifyId": "gid://shopify/ProductVariant/41007759589582", + "inventoryLevels___NODE": [ + "2261ddf5-7c64-5934-a990-7dc64fe17040" + ], + "metafields___NODE": [], + "media___NODE": [ + "8fc15b46-8400-5778-b85c-05db5c009326" + ], + "presentmentPrices": [ + { + "compareAtPrice": null, + "price": { + "amount": "1.0", + "currencyCode": "CAD" + }, + "__typename": "ProductVariantPricePair", + "__parentId": "gid://shopify/ProductVariant/41007759589582" + } + ], + "id": "232cdd32-2de5-5bdd-a327-08d539ecd51e", + "internal": { + "type": "ShopifyProductVariant", + "contentDigest": "d78ab3f729dd2153d7b164c6188879bf", + "owner": "gatsby-source-shopify", + "counter": 44 + }, + "children": [], + "parent": null + }, + { + "availableForSale": true, + "barcode": "", + "compareAtPrice": null, + "createdAt": "2022-03-14T13:53:31Z", + "displayName": "Test Product - Medium", + "image": { + "altText": null, + "height": 1280, + "originalSrc": "https://cdn.shopify.com/s/files/1/0506/3521/0958/products/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764", + "src": "https://cdn.shopify.com/s/files/1/0506/3521/0958/products/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764", + "transformedSrc": "https://cdn.shopify.com/s/files/1/0506/3521/0958/products/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764", + "width": 1920, + "shopifyId": "gid://shopify/ProductImage/30403196551374" + }, + "inventoryItem": { + "countryCodeOfOrigin": null, + "createdAt": "2022-03-14T13:53:31Z", + "duplicateSkuCount": 0, + "harmonizedSystemCode": null, + "inventoryHistoryUrl": "https://atomic-digital-studio-test.myshopify.com/admin/products/6950279086286/variants/41007759622350/inventory_history", + "legacyResourceId": "43100044427470", + "locationsCount": { + "count": 1, + "precision": "EXACT" + }, + "provinceCodeOfOrigin": null, + "requiresShipping": true, + "sku": "", + "tracked": true, + "trackedEditable": { + "locked": false, + "reason": null + }, + "unitCost": null, + "updatedAt": "2022-03-14T13:53:31Z", + "variant": { + "shopifyId": "gid://shopify/ProductVariant/41007759622350" + }, + "shopifyId": "gid://shopify/InventoryItem/43100044427470" + }, + "inventoryPolicy": "DENY", + "inventoryQuantity": 1, + "legacyResourceId": "41007759622350", + "position": 2, + "price": "2.00", + "product": { + "shopifyId": "gid://shopify/Product/6950279086286" + }, + "requiresShipping": true, + "selectedOptions": [ + { + "name": "Size", + "value": "Medium" + } + ], + "sellingPlanGroupsCount": { + "count": 0, + "precision": "EXACT" + }, + "sku": "", + "storefrontId": "Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0VmFyaWFudC80MTAwNzc1OTYyMjM1MA==", + "taxCode": null, + "taxable": true, + "title": "Medium", + "updatedAt": "2022-03-14T14:00:01Z", + "weight": 0, + "weightUnit": "KILOGRAMS", + "shopifyId": "gid://shopify/ProductVariant/41007759622350", + "inventoryLevels___NODE": [ + "453dda5f-1323-5aa3-8e75-9a0dd08025c2" + ], + "metafields___NODE": [], + "media___NODE": [ + "8fc15b46-8400-5778-b85c-05db5c009326" + ], + "presentmentPrices": [ + { + "compareAtPrice": null, + "price": { + "amount": "2.0", + "currencyCode": "CAD" + }, + "__typename": "ProductVariantPricePair", + "__parentId": "gid://shopify/ProductVariant/41007759622350" + } + ], + "id": "266c6a92-078a-519d-8c03-257b4ed15b84", + "internal": { + "type": "ShopifyProductVariant", + "contentDigest": "339e3ac99e27b1bd00f7982162ae65c0", + "owner": "gatsby-source-shopify", + "counter": 42 + }, + "children": [], + "parent": null + }, + { + "availableForSale": false, + "barcode": null, + "compareAtPrice": null, + "createdAt": "2022-03-14T22:38:58Z", + "displayName": "Copy of Test Product - Small", + "image": null, + "inventoryItem": { + "countryCodeOfOrigin": null, + "createdAt": "2022-03-14T22:38:58Z", + "duplicateSkuCount": 0, + "harmonizedSystemCode": null, + "inventoryHistoryUrl": "https://atomic-digital-studio-test.myshopify.com/admin/products/6966721052878/variants/41009157243086/inventory_history", + "legacyResourceId": "43101443260622", + "locationsCount": { + "count": 1, + "precision": "EXACT" + }, + "provinceCodeOfOrigin": null, + "requiresShipping": true, + "sku": null, + "tracked": true, + "trackedEditable": { + "locked": false, + "reason": null + }, + "unitCost": null, + "updatedAt": "2022-03-14T22:38:58Z", + "variant": { + "shopifyId": "gid://shopify/ProductVariant/41009157243086" + }, + "shopifyId": "gid://shopify/InventoryItem/43101443260622" + }, + "inventoryPolicy": "DENY", + "inventoryQuantity": 0, + "legacyResourceId": "41009157243086", + "position": 1, + "price": "1.00", + "product": { + "shopifyId": "gid://shopify/Product/6966721052878" + }, + "requiresShipping": true, + "selectedOptions": [ + { + "name": "Size", + "value": "Small" + } + ], + "sellingPlanGroupsCount": { + "count": 0, + "precision": "EXACT" + }, + "sku": null, + "storefrontId": "Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0VmFyaWFudC80MTAwOTE1NzI0MzA4Ng==", + "taxCode": null, + "taxable": true, + "title": "Small", + "updatedAt": "2022-03-14T22:38:58Z", + "weight": 0, + "weightUnit": "KILOGRAMS", + "shopifyId": "gid://shopify/ProductVariant/41009157243086", + "inventoryLevels___NODE": [ + "6eeb7894-1eb4-5556-a797-396fdf229a63" + ], + "metafields___NODE": [], + "media___NODE": [], + "presentmentPrices": [ + { + "compareAtPrice": null, + "price": { + "amount": "1.0", + "currencyCode": "CAD" + }, + "__typename": "ProductVariantPricePair", + "__parentId": "gid://shopify/ProductVariant/41009157243086" + } + ], + "id": "435874ba-a8b0-5b29-a96a-8691e694bf3a", + "internal": { + "type": "ShopifyProductVariant", + "contentDigest": "816cec6b9e17e17c77e2c6a7e2607041", + "owner": "gatsby-source-shopify", + "counter": 38 + }, + "children": [], + "parent": null + }, + { + "availableForSale": true, + "barcode": "", + "compareAtPrice": null, + "createdAt": "2022-03-14T13:53:31Z", + "displayName": "Test Product - Large", + "image": { + "altText": null, + "height": 1280, + "originalSrc": "https://cdn.shopify.com/s/files/1/0506/3521/0958/products/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764", + "src": "https://cdn.shopify.com/s/files/1/0506/3521/0958/products/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764", + "transformedSrc": "https://cdn.shopify.com/s/files/1/0506/3521/0958/products/placeholder_aa389e41-a6d1-453e-ba2a-dae56c3993eb.png?v=1644963764", + "width": 1920, + "shopifyId": "gid://shopify/ProductImage/30403196551374" + }, + "inventoryItem": { + "countryCodeOfOrigin": null, + "createdAt": "2022-03-14T13:53:31Z", + "duplicateSkuCount": 0, + "harmonizedSystemCode": null, + "inventoryHistoryUrl": "https://atomic-digital-studio-test.myshopify.com/admin/products/6950279086286/variants/41007759655118/inventory_history", + "legacyResourceId": "43100044460238", + "locationsCount": { + "count": 1, + "precision": "EXACT" + }, + "provinceCodeOfOrigin": null, + "requiresShipping": true, + "sku": "", + "tracked": true, + "trackedEditable": { + "locked": false, + "reason": null + }, + "unitCost": null, + "updatedAt": "2022-03-14T13:53:31Z", + "variant": { + "shopifyId": "gid://shopify/ProductVariant/41007759655118" + }, + "shopifyId": "gid://shopify/InventoryItem/43100044460238" + }, + "inventoryPolicy": "DENY", + "inventoryQuantity": 1, + "legacyResourceId": "41007759655118", + "position": 3, + "price": "3.00", + "product": { + "shopifyId": "gid://shopify/Product/6950279086286" + }, + "requiresShipping": true, + "selectedOptions": [ + { + "name": "Size", + "value": "Large" + } + ], + "sellingPlanGroupsCount": { + "count": 0, + "precision": "EXACT" + }, + "sku": "", + "storefrontId": "Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0VmFyaWFudC80MTAwNzc1OTY1NTExOA==", + "taxCode": null, + "taxable": true, + "title": "Large", + "updatedAt": "2022-03-14T14:00:01Z", + "weight": 0, + "weightUnit": "KILOGRAMS", + "shopifyId": "gid://shopify/ProductVariant/41007759655118", + "inventoryLevels___NODE": [ + "e8f4985b-ed74-5a19-836d-b5d310c277e5" + ], + "metafields___NODE": [], + "media___NODE": [ + "8fc15b46-8400-5778-b85c-05db5c009326" + ], + "presentmentPrices": [ + { + "compareAtPrice": null, + "price": { + "amount": "3.0", + "currencyCode": "CAD" + }, + "__typename": "ProductVariantPricePair", + "__parentId": "gid://shopify/ProductVariant/41007759655118" + } + ], + "id": "480d2d09-c1b1-5f7c-94a2-635e73e50ef4", + "internal": { + "type": "ShopifyProductVariant", + "contentDigest": "ab757138bf54f19c6d959f292a291db8", + "owner": "gatsby-source-shopify", + "counter": 40 + }, + "children": [], + "parent": null + }, + { + "availableForSale": false, + "barcode": null, + "compareAtPrice": null, + "createdAt": "2022-03-14T22:38:58Z", + "displayName": "Copy of Test Product - Medium", + "image": null, + "inventoryItem": { + "countryCodeOfOrigin": null, + "createdAt": "2022-03-14T22:38:58Z", + "duplicateSkuCount": 0, + "harmonizedSystemCode": null, + "inventoryHistoryUrl": "https://atomic-digital-studio-test.myshopify.com/admin/products/6966721052878/variants/41009157275854/inventory_history", + "legacyResourceId": "43101443293390", + "locationsCount": { + "count": 1, + "precision": "EXACT" + }, + "provinceCodeOfOrigin": null, + "requiresShipping": true, + "sku": null, + "tracked": true, + "trackedEditable": { + "locked": false, + "reason": null + }, + "unitCost": null, + "updatedAt": "2022-03-14T22:38:58Z", + "variant": { + "shopifyId": "gid://shopify/ProductVariant/41009157275854" + }, + "shopifyId": "gid://shopify/InventoryItem/43101443293390" + }, + "inventoryPolicy": "DENY", + "inventoryQuantity": 0, + "legacyResourceId": "41009157275854", + "position": 2, + "price": "2.00", + "product": { + "shopifyId": "gid://shopify/Product/6966721052878" + }, + "requiresShipping": true, + "selectedOptions": [ + { + "name": "Size", + "value": "Medium" + } + ], + "sellingPlanGroupsCount": { + "count": 0, + "precision": "EXACT" + }, + "sku": null, + "storefrontId": "Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0VmFyaWFudC80MTAwOTE1NzI3NTg1NA==", + "taxCode": null, + "taxable": true, + "title": "Medium", + "updatedAt": "2022-03-14T22:38:58Z", + "weight": 0, + "weightUnit": "KILOGRAMS", + "shopifyId": "gid://shopify/ProductVariant/41009157275854", + "inventoryLevels___NODE": [ + "8970ecd9-9a83-5e55-915b-682cfff58699" + ], + "metafields___NODE": [], + "media___NODE": [], + "presentmentPrices": [ + { + "compareAtPrice": null, + "price": { + "amount": "2.0", + "currencyCode": "CAD" + }, + "__typename": "ProductVariantPricePair", + "__parentId": "gid://shopify/ProductVariant/41009157275854" + } + ], + "id": "a0191127-d288-510d-94e5-14f7a6404454", + "internal": { + "type": "ShopifyProductVariant", + "contentDigest": "2614ce60a45c9ba2ed54f63511e74419", + "owner": "gatsby-source-shopify", + "counter": 36 + }, + "children": [], + "parent": null + }, + { + "availableForSale": false, + "barcode": null, + "compareAtPrice": null, + "createdAt": "2022-03-14T22:38:58Z", + "displayName": "Copy of Test Product - Large", + "image": null, + "inventoryItem": { + "countryCodeOfOrigin": null, + "createdAt": "2022-03-14T22:38:58Z", + "duplicateSkuCount": 0, + "harmonizedSystemCode": null, + "inventoryHistoryUrl": "https://atomic-digital-studio-test.myshopify.com/admin/products/6966721052878/variants/41009157308622/inventory_history", + "legacyResourceId": "43101443326158", + "locationsCount": { + "count": 1, + "precision": "EXACT" + }, + "provinceCodeOfOrigin": null, + "requiresShipping": true, + "sku": null, + "tracked": true, + "trackedEditable": { + "locked": false, + "reason": null + }, + "unitCost": null, + "updatedAt": "2022-03-14T22:38:58Z", + "variant": { + "shopifyId": "gid://shopify/ProductVariant/41009157308622" + }, + "shopifyId": "gid://shopify/InventoryItem/43101443326158" + }, + "inventoryPolicy": "DENY", + "inventoryQuantity": 0, + "legacyResourceId": "41009157308622", + "position": 3, + "price": "3.00", + "product": { + "shopifyId": "gid://shopify/Product/6966721052878" + }, + "requiresShipping": true, + "selectedOptions": [ + { + "name": "Size", + "value": "Large" + } + ], + "sellingPlanGroupsCount": { + "count": 0, + "precision": "EXACT" + }, + "sku": null, + "storefrontId": "Z2lkOi8vc2hvcGlmeS9Qcm9kdWN0VmFyaWFudC80MTAwOTE1NzMwODYyMg==", + "taxCode": null, + "taxable": true, + "title": "Large", + "updatedAt": "2022-03-14T22:38:58Z", + "weight": 0, + "weightUnit": "KILOGRAMS", + "shopifyId": "gid://shopify/ProductVariant/41009157308622", + "inventoryLevels___NODE": [ + "cedae3ee-f225-5c34-9dd8-f1a25f8d810c" + ], + "metafields___NODE": [], + "media___NODE": [], + "presentmentPrices": [ + { + "compareAtPrice": null, + "price": { + "amount": "3.0", + "currencyCode": "CAD" + }, + "__typename": "ProductVariantPricePair", + "__parentId": "gid://shopify/ProductVariant/41009157308622" + } + ], + "id": "cba433a6-1513-576f-97c0-80b36fb8afa6", + "internal": { + "type": "ShopifyProductVariant", + "contentDigest": "2e466fdbf7ec8501841aaa5a85b48259", + "owner": "gatsby-source-shopify", + "counter": 34 + }, + "children": [], + "parent": null + } +] diff --git a/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyProductVariantPricePair.json b/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyProductVariantPricePair.json index 0637a088a01e8..fe51488c7066f 100644 --- a/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyProductVariantPricePair.json +++ b/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyProductVariantPricePair.json @@ -1 +1 @@ -[] \ No newline at end of file +[] diff --git a/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyVideo.json b/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyVideo.json index 0637a088a01e8..fe51488c7066f 100644 --- a/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyVideo.json +++ b/packages/gatsby-source-shopify/__tests__/fixtures/shopify-nodes/ShopifyVideo.json @@ -1 +1 @@ -[] \ No newline at end of file +[] diff --git a/packages/gatsby-source-shopify/src/create-schema-customization.ts b/packages/gatsby-source-shopify/src/create-schema-customization.ts index b92270d6ef2b6..dedae42b9e753 100644 --- a/packages/gatsby-source-shopify/src/create-schema-customization.ts +++ b/packages/gatsby-source-shopify/src/create-schema-customization.ts @@ -49,6 +49,28 @@ export function createSchemaCustomization( } `) } + actions.createFieldExtension({ + name: `selectQuantityByName`, + args: { + name: `String!`, + }, + extend({ name }, fieldConfig) { + return { + async resolve(source, args, context, info): Promise { + const resolver = fieldConfig.resolve || context.defaultFieldResolver + const quantities = await resolver(source, args, context, info) + if (quantities && Array.isArray(quantities)) { + return ( + quantities.find(quantity => quantity?.name === name)?.quantity ?? + 0 + ) + } + + return 0 + }, + } + }, + }) actions.createTypes(typeDefs) } diff --git a/packages/gatsby-source-shopify/src/plugin-options-schema.ts b/packages/gatsby-source-shopify/src/plugin-options-schema.ts index 278c29022db3d..008f3aca51f41 100644 --- a/packages/gatsby-source-shopify/src/plugin-options-schema.ts +++ b/packages/gatsby-source-shopify/src/plugin-options-schema.ts @@ -43,7 +43,7 @@ export function pluginOptionsSchema({ Joi }: PluginOptionsSchemaArgs): unknown { `Not set by default. If set to a string (example \`MyStore\`) node names will be \`allMyStoreShopifyProducts\` instead of \`allShopifyProducts\`` ), apiVersion: Joi.string() - .default(`2022-04`) + .default(`2024-04`) .description( `The API version that should be used. More information: https://shopify.dev/docs/api/usage/versioning` ), diff --git a/packages/gatsby-source-shopify/src/query-builders/collections-query.ts b/packages/gatsby-source-shopify/src/query-builders/collections-query.ts index 7207be6377d19..abf77341fd2c1 100644 --- a/packages/gatsby-source-shopify/src/query-builders/collections-query.ts +++ b/packages/gatsby-source-shopify/src/query-builders/collections-query.ts @@ -73,7 +73,10 @@ export class CollectionsQuery extends BulkQuery { } } } - productsCount + productsCount { + count + precision + } ruleSet { appliedDisjunctively rules { diff --git a/packages/gatsby-source-shopify/src/query-builders/product-variants-query.ts b/packages/gatsby-source-shopify/src/query-builders/product-variants-query.ts index e07dd6c48a498..b6635d5090712 100644 --- a/packages/gatsby-source-shopify/src/query-builders/product-variants-query.ts +++ b/packages/gatsby-source-shopify/src/query-builders/product-variants-query.ts @@ -47,7 +47,10 @@ export class ProductVariantsQuery extends BulkQuery { inventoryLevels { edges { node { - available + quantities(names: ["incoming", "available", "committed", "reserved", "damaged", "safety_stock", "quality_control"]) { + name + quantity + } id location { id @@ -56,7 +59,10 @@ export class ProductVariantsQuery extends BulkQuery { } } legacyResourceId - locationsCount + locationsCount { + count + precision + } provinceCodeOfOrigin requiresShipping sku @@ -111,7 +117,10 @@ export class ProductVariantsQuery extends BulkQuery { name value } - sellingPlanGroupCount + sellingPlanGroupsCount { + count + precision + } sku storefrontId taxCode diff --git a/packages/gatsby-source-shopify/src/query-builders/products-query.ts b/packages/gatsby-source-shopify/src/query-builders/products-query.ts index 189f7087744ce..5408678af4bfd 100644 --- a/packages/gatsby-source-shopify/src/query-builders/products-query.ts +++ b/packages/gatsby-source-shopify/src/query-builders/products-query.ts @@ -151,7 +151,10 @@ export class ProductsQuery extends BulkQuery { } } } - mediaCount + mediaCount { + count + precision + } metafields { edges { node { @@ -200,7 +203,10 @@ export class ProductsQuery extends BulkQuery { productType publishedAt requiresSellingPlan - sellingPlanGroupCount + sellingPlanGroupsCount { + count + precision + } seo { description title diff --git a/packages/gatsby-source-shopify/src/type-builders/collection-type.ts b/packages/gatsby-source-shopify/src/type-builders/collection-type.ts index f90eee446aecb..6535c909f0a38 100644 --- a/packages/gatsby-source-shopify/src/type-builders/collection-type.ts +++ b/packages/gatsby-source-shopify/src/type-builders/collection-type.ts @@ -11,7 +11,7 @@ export function collectionTypeBuilder(prefix: string): string { metafield(namespace: String! key: String!): ${prefix}Metafield metafields: [${prefix}Metafield!]! @link(from: "metafields___NODE", by: "id") products: [${prefix}Product!]! @link(from: "products___NODE", by: "id") - productsCount: Int! + productsCount: Int! @proxy(from: "productsCount.count") ruleSet: ${prefix}CollectionRuleSet seo: ${prefix}SEO! shopifyId: String! diff --git a/packages/gatsby-source-shopify/src/type-builders/location-type.ts b/packages/gatsby-source-shopify/src/type-builders/location-type.ts index 2cdd78fba8d3b..90db0adda0e7f 100644 --- a/packages/gatsby-source-shopify/src/type-builders/location-type.ts +++ b/packages/gatsby-source-shopify/src/type-builders/location-type.ts @@ -5,7 +5,7 @@ export function locationTypeBuilder(prefix: string): string { fulfillmentOrdersOptIn: Boolean! handle: String! inventoryManagement: Boolean! - productBased: Boolean! + productBased: Boolean! @deprecated(reason: "\`productBased\` will be removed in version 2024-07, non-product based fulfillment services are no longer supported") serviceName: String! shippingMethods: [${prefix}ShippingMethod!]! shopifyId: String! @@ -24,9 +24,9 @@ export function locationTypeBuilder(prefix: string): string { duplicateSkuCount: Int! harmonizedSystemCode: String inventoryHistoryUrl: String - inventoryLevels: [${prefix}InventoryLevel!]! @link(from: "inventoryLevels___NODE", by: "id") + inventoryLevels: [${prefix}InventoryLevel!]! @link(by: "id") @proxy(from: "inventoryLevels___NODE", fromNode: true) legacyResourceId: String! - locationsCount: Int! + locationsCount: Int! @proxy(from: "locationsCount.count") provinceCodeOfOrigin: String requiresShipping: Boolean! shopifyId: String! @@ -38,9 +38,21 @@ export function locationTypeBuilder(prefix: string): string { variant: ${prefix}ProductVariantConnection! } + type ${prefix}InventoryQuantity { + name: String! + quantity: Int! + } + type ${prefix}InventoryLevel implements Node @dontInfer { _location: String! # Temporary field so we don't break existing users - available: Int! + quantities: [${prefix}InventoryQuantity!]! + available: Int! @proxy(from: "quantities") @selectQuantityByName(name: "available") + incoming: Int! @proxy(from: "quantities") @selectQuantityByName(name: "incoming") + committed: Int! @proxy(from: "quantities") @selectQuantityByName(name: "committed") + reserved: Int! @proxy(from: "quantities") @selectQuantityByName(name: "reserved") + damaged: Int! @proxy(from: "quantities") @selectQuantityByName(name: "damaged") + safety_stock: Int! @proxy(from: "quantities") @selectQuantityByName(name: "safety_stock") + quality_control: Int! @proxy(from: "quantities") @selectQuantityByName(name: "quality_control") id: ID! location: ${prefix}Location! @link(from: "_location", by: "id") shopifyId: String! diff --git a/packages/gatsby-source-shopify/src/type-builders/product-type.ts b/packages/gatsby-source-shopify/src/type-builders/product-type.ts index e4c4372e78aa0..1e4b7d1db9ace 100644 --- a/packages/gatsby-source-shopify/src/type-builders/product-type.ts +++ b/packages/gatsby-source-shopify/src/type-builders/product-type.ts @@ -16,7 +16,7 @@ export function productTypeBuilder(prefix: string): string { isGiftCard: Boolean! legacyResourceId: String! media: [${prefix}Media!]! @link(from: "media___NODE", by: "id") - mediaCount: Int! + mediaCount: Int! @proxy(from: "mediaCount.count") metafield(namespace: String! key: String!): ${prefix}Metafield metafields: [${prefix}Metafield!]! @link(from: "metafields___NODE", by: "id") onlineStorePreviewUrl: String @@ -27,7 +27,7 @@ export function productTypeBuilder(prefix: string): string { productType: String! publishedAt: Date @dateformat requiresSellingPlan: Boolean! - sellingPlanGroupCount: Int! + sellingPlanGroupCount: Int! @proxy(from: "sellingPlanGroupsCount.count") seo: ${prefix}SEO! shopifyId: String! status: ${prefix}ProductStatus! diff --git a/packages/gatsby-source-shopify/src/type-builders/product-variant-type.ts b/packages/gatsby-source-shopify/src/type-builders/product-variant-type.ts index f66f0d2254725..b55f2b2103b92 100644 --- a/packages/gatsby-source-shopify/src/type-builders/product-variant-type.ts +++ b/packages/gatsby-source-shopify/src/type-builders/product-variant-type.ts @@ -21,7 +21,7 @@ export function productVariantTypeBuilder(prefix: string): string { product: ${prefix}Product! @link(from: "_product", by: "id") requiresShipping: Boolean! @deprecated(reason: "Use \`InventoryItem.requiresShipping\` instead.") selectedOptions: [${prefix}SelectedOption!]! - sellingPlanGroupCount: Int! + sellingPlanGroupCount: Int! @proxy(from: "sellingPlanGroupsCount.count") sku: String shopifyId: String! storefrontId: String!