From 6ee908dcf1150d3b0d22de976c62a72bfaaf3c07 Mon Sep 17 00:00:00 2001 From: David Cameron Date: Fri, 31 Jul 2026 10:02:14 -0400 Subject: [PATCH] chore(functions): update stable APIs to 2026-07 Update the 30 stable Shopify Function templates and generated schemas to API version 2026-07. Keep discounts allocator and the pickup delivery-option generator APIs on unstable because Shopify does not expose those targets in 2026-07. Align Rust fixtures with the current omission of absent nullable output fields. Assisted-By: devx/e697a511-d172-4fd3-8157-9c07b6fa6b10 --- .../schema.graphql | 71 ++++++++++++++++++- .../shopify.extension.toml.liquid | 2 +- .../schema.graphql | 71 ++++++++++++++++++- .../shopify.extension.toml.liquid | 2 +- .../schema.graphql | 71 ++++++++++++++++++- .../shopify.extension.toml.liquid | 2 +- functions-cart-transform-js/schema.graphql | 71 ++++++++++++++++++- .../shopify.extension.toml.liquid | 2 +- functions-cart-transform-rs/schema.graphql | 71 ++++++++++++++++++- .../shopify.extension.toml.liquid | 2 +- functions-cart-transform-wasm/schema.graphql | 71 ++++++++++++++++++- .../shopify.extension.toml.liquid | 2 +- .../schema.graphql | 71 ++++++++++++++++++- .../shopify.extension.toml.liquid | 2 +- .../schema.graphql | 71 ++++++++++++++++++- .../shopify.extension.toml.liquid | 2 +- .../schema.graphql | 71 ++++++++++++++++++- .../shopify.extension.toml.liquid | 2 +- functions-discount-js/schema.graphql | 71 ++++++++++++++++++- .../shopify.extension.toml.liquid | 2 +- functions-discount-rs/schema.graphql | 71 ++++++++++++++++++- .../shopify.extension.toml.liquid | 2 +- .../fixtures/cart-lines-both-discounts.json | 7 +- .../delivery-options-shipping-discount.json | 3 +- functions-discount-wasm/schema.graphql | 71 ++++++++++++++++++- .../shopify.extension.toml.liquid | 2 +- .../schema.graphql | 71 ++++++++++++++++++- .../shopify.extension.toml.liquid | 2 +- .../schema.graphql | 71 ++++++++++++++++++- .../shopify.extension.toml.liquid | 2 +- .../schema.graphql | 71 ++++++++++++++++++- .../shopify.extension.toml.liquid | 2 +- .../fixtures/returns-delivery-option.json | 3 +- .../shopify.extension.toml.liquid | 2 +- functions-location-rules-js/schema.graphql | 71 ++++++++++++++++++- .../shopify.extension.toml.liquid | 2 +- functions-location-rules-rs/schema.graphql | 71 ++++++++++++++++++- .../shopify.extension.toml.liquid | 2 +- functions-location-rules-wasm/schema.graphql | 71 ++++++++++++++++++- .../shopify.extension.toml.liquid | 2 +- functions-order-discounts-js/schema.graphql | 71 ++++++++++++++++++- .../shopify.extension.toml.liquid | 2 +- functions-order-discounts-rs/schema.graphql | 71 ++++++++++++++++++- .../shopify.extension.toml.liquid | 2 +- functions-order-discounts-wasm/schema.graphql | 71 ++++++++++++++++++- .../shopify.extension.toml.liquid | 2 +- .../schema.graphql | 71 ++++++++++++++++++- .../shopify.extension.toml.liquid | 2 +- .../schema.graphql | 71 ++++++++++++++++++- .../shopify.extension.toml.liquid | 2 +- .../schema.graphql | 71 ++++++++++++++++++- .../shopify.extension.toml.liquid | 2 +- .../tests/fixtures/fetch-canada-request.json | 2 - .../fixtures/fetch-non-canada-no-request.json | 4 +- .../fixtures/run-null-opening-hours.json | 4 -- .../tests/fixtures/run-successful-fetch.json | 3 - functions-product-discounts-js/schema.graphql | 71 ++++++++++++++++++- .../shopify.extension.toml.liquid | 2 +- functions-product-discounts-rs/schema.graphql | 71 ++++++++++++++++++- .../shopify.extension.toml.liquid | 2 +- .../schema.graphql | 71 ++++++++++++++++++- .../shopify.extension.toml.liquid | 2 +- .../schema.graphql | 71 ++++++++++++++++++- .../shopify.extension.toml.liquid | 2 +- .../schema.graphql | 71 ++++++++++++++++++- .../shopify.extension.toml.liquid | 2 +- .../schema.graphql | 71 ++++++++++++++++++- .../shopify.extension.toml.liquid | 2 +- 68 files changed, 2135 insertions(+), 83 deletions(-) diff --git a/functions-cart-checkout-validation-js/schema.graphql b/functions-cart-checkout-validation-js/schema.graphql index 4e01064b..526b693f 100644 --- a/functions-cart-checkout-validation-js/schema.graphql +++ b/functions-cart-checkout-validation-js/schema.graphql @@ -1,4 +1,4 @@ -# api_version: 2026-04 +# api_version: 2026-07 schema { query: Input @@ -74,6 +74,13 @@ type BuyerIdentity { Used to manage and track purchases made by businesses rather than individual customers. """ purchasingCompany: PurchasingCompany + + """ + Represents the [Shop User](https://help.shopify.com/en/manual/online-sales-channels/shop/sign-in-features) + corresponding to the customer within the shop, if the buyer is a Shop User. Can be used to request [Shop User + metafields](https://shopify.dev/docs/api/shop-user-custom-data). + """ + shopUser: ShopUser } type BuyerJourney { @@ -5039,6 +5046,40 @@ type ProductVariant implements HasMetafields { """ id: ID! + """ + Whether the product variant is in any of the specified collections. The variant must be in at least one + collection from the list to return `true`. A variant is considered to be in a collection when the variant + itself is a member of the collection, or when its product is a member of the collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inAnyCollection( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): Boolean! + + """ + Whether the product variant is in each of the specified collections. A variant is considered to be in a + collection when the variant itself is a member of the collection, or when its product is a member of the + collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inCollections( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): [CollectionMembership!]! + """ A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information about a Shopify resource, such as products, orders, and @@ -5263,6 +5304,34 @@ type Shop implements HasMetafields { ): Metaobject } +""" +Represents information about the buyer that is interacting with the cart. +""" +type ShopUser implements HasMetafields { + """ + A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information + about a Shopify resource, such as products, orders, and + [many more](https://shopify.dev/docs/api/admin-graphql/latest/enums/MetafieldOwnerType). + Using [metafields with Shopify Functions](https://shopify.dev/docs/apps/build/functions/input-output/metafields-for-input-queries) + enables you to customize the checkout experience. + """ + metafield( + """ + The unique identifier for the metafield within its namespace. A metafield is composed of a + namespace and a key, in the format `namespace.key`. + """ + key: String! + + """ + A category that organizes a group of metafields. Namespaces are used to prevent naming conflicts + between different apps or different parts of the same app. If omitted, then the + [app-reserved namespace](https://shopify.dev/docs/apps/build/custom-data/ownership) + is used. + """ + namespace: String + ): Metafield +} + """ A subset of the [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format that includes the time but not the date or timezone which is determined from context. diff --git a/functions-cart-checkout-validation-js/shopify.extension.toml.liquid b/functions-cart-checkout-validation-js/shopify.extension.toml.liquid index dc0fec00..33cff44f 100644 --- a/functions-cart-checkout-validation-js/shopify.extension.toml.liquid +++ b/functions-cart-checkout-validation-js/shopify.extension.toml.liquid @@ -1,4 +1,4 @@ -api_version = "2026-04" +api_version = "2026-07" [[extensions]] name = "t:name" diff --git a/functions-cart-checkout-validation-rs/schema.graphql b/functions-cart-checkout-validation-rs/schema.graphql index 4e01064b..526b693f 100644 --- a/functions-cart-checkout-validation-rs/schema.graphql +++ b/functions-cart-checkout-validation-rs/schema.graphql @@ -1,4 +1,4 @@ -# api_version: 2026-04 +# api_version: 2026-07 schema { query: Input @@ -74,6 +74,13 @@ type BuyerIdentity { Used to manage and track purchases made by businesses rather than individual customers. """ purchasingCompany: PurchasingCompany + + """ + Represents the [Shop User](https://help.shopify.com/en/manual/online-sales-channels/shop/sign-in-features) + corresponding to the customer within the shop, if the buyer is a Shop User. Can be used to request [Shop User + metafields](https://shopify.dev/docs/api/shop-user-custom-data). + """ + shopUser: ShopUser } type BuyerJourney { @@ -5039,6 +5046,40 @@ type ProductVariant implements HasMetafields { """ id: ID! + """ + Whether the product variant is in any of the specified collections. The variant must be in at least one + collection from the list to return `true`. A variant is considered to be in a collection when the variant + itself is a member of the collection, or when its product is a member of the collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inAnyCollection( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): Boolean! + + """ + Whether the product variant is in each of the specified collections. A variant is considered to be in a + collection when the variant itself is a member of the collection, or when its product is a member of the + collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inCollections( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): [CollectionMembership!]! + """ A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information about a Shopify resource, such as products, orders, and @@ -5263,6 +5304,34 @@ type Shop implements HasMetafields { ): Metaobject } +""" +Represents information about the buyer that is interacting with the cart. +""" +type ShopUser implements HasMetafields { + """ + A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information + about a Shopify resource, such as products, orders, and + [many more](https://shopify.dev/docs/api/admin-graphql/latest/enums/MetafieldOwnerType). + Using [metafields with Shopify Functions](https://shopify.dev/docs/apps/build/functions/input-output/metafields-for-input-queries) + enables you to customize the checkout experience. + """ + metafield( + """ + The unique identifier for the metafield within its namespace. A metafield is composed of a + namespace and a key, in the format `namespace.key`. + """ + key: String! + + """ + A category that organizes a group of metafields. Namespaces are used to prevent naming conflicts + between different apps or different parts of the same app. If omitted, then the + [app-reserved namespace](https://shopify.dev/docs/apps/build/custom-data/ownership) + is used. + """ + namespace: String + ): Metafield +} + """ A subset of the [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format that includes the time but not the date or timezone which is determined from context. diff --git a/functions-cart-checkout-validation-rs/shopify.extension.toml.liquid b/functions-cart-checkout-validation-rs/shopify.extension.toml.liquid index 2de48e8c..86bbfeea 100644 --- a/functions-cart-checkout-validation-rs/shopify.extension.toml.liquid +++ b/functions-cart-checkout-validation-rs/shopify.extension.toml.liquid @@ -1,4 +1,4 @@ -api_version = "2026-04" +api_version = "2026-07" [[extensions]] name = "t:name" diff --git a/functions-cart-checkout-validation-wasm/schema.graphql b/functions-cart-checkout-validation-wasm/schema.graphql index 4e01064b..526b693f 100644 --- a/functions-cart-checkout-validation-wasm/schema.graphql +++ b/functions-cart-checkout-validation-wasm/schema.graphql @@ -1,4 +1,4 @@ -# api_version: 2026-04 +# api_version: 2026-07 schema { query: Input @@ -74,6 +74,13 @@ type BuyerIdentity { Used to manage and track purchases made by businesses rather than individual customers. """ purchasingCompany: PurchasingCompany + + """ + Represents the [Shop User](https://help.shopify.com/en/manual/online-sales-channels/shop/sign-in-features) + corresponding to the customer within the shop, if the buyer is a Shop User. Can be used to request [Shop User + metafields](https://shopify.dev/docs/api/shop-user-custom-data). + """ + shopUser: ShopUser } type BuyerJourney { @@ -5039,6 +5046,40 @@ type ProductVariant implements HasMetafields { """ id: ID! + """ + Whether the product variant is in any of the specified collections. The variant must be in at least one + collection from the list to return `true`. A variant is considered to be in a collection when the variant + itself is a member of the collection, or when its product is a member of the collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inAnyCollection( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): Boolean! + + """ + Whether the product variant is in each of the specified collections. A variant is considered to be in a + collection when the variant itself is a member of the collection, or when its product is a member of the + collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inCollections( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): [CollectionMembership!]! + """ A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information about a Shopify resource, such as products, orders, and @@ -5263,6 +5304,34 @@ type Shop implements HasMetafields { ): Metaobject } +""" +Represents information about the buyer that is interacting with the cart. +""" +type ShopUser implements HasMetafields { + """ + A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information + about a Shopify resource, such as products, orders, and + [many more](https://shopify.dev/docs/api/admin-graphql/latest/enums/MetafieldOwnerType). + Using [metafields with Shopify Functions](https://shopify.dev/docs/apps/build/functions/input-output/metafields-for-input-queries) + enables you to customize the checkout experience. + """ + metafield( + """ + The unique identifier for the metafield within its namespace. A metafield is composed of a + namespace and a key, in the format `namespace.key`. + """ + key: String! + + """ + A category that organizes a group of metafields. Namespaces are used to prevent naming conflicts + between different apps or different parts of the same app. If omitted, then the + [app-reserved namespace](https://shopify.dev/docs/apps/build/custom-data/ownership) + is used. + """ + namespace: String + ): Metafield +} + """ A subset of the [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format that includes the time but not the date or timezone which is determined from context. diff --git a/functions-cart-checkout-validation-wasm/shopify.extension.toml.liquid b/functions-cart-checkout-validation-wasm/shopify.extension.toml.liquid index 7fa3b047..02e4e914 100644 --- a/functions-cart-checkout-validation-wasm/shopify.extension.toml.liquid +++ b/functions-cart-checkout-validation-wasm/shopify.extension.toml.liquid @@ -1,4 +1,4 @@ -api_version = "2026-04" +api_version = "2026-07" [[extensions]] name = "t:name" diff --git a/functions-cart-transform-js/schema.graphql b/functions-cart-transform-js/schema.graphql index db80114f..e98d5cbf 100644 --- a/functions-cart-transform-js/schema.graphql +++ b/functions-cart-transform-js/schema.graphql @@ -1,4 +1,4 @@ -# api_version: 2026-04 +# api_version: 2026-07 schema { query: Input @@ -86,6 +86,13 @@ type BuyerIdentity { Used to manage and track purchases made by businesses rather than individual customers. """ purchasingCompany: PurchasingCompany + + """ + Represents the [Shop User](https://help.shopify.com/en/manual/online-sales-channels/shop/sign-in-features) + corresponding to the customer within the shop, if the buyer is a Shop User. Can be used to request [Shop User + metafields](https://shopify.dev/docs/api/shop-user-custom-data). + """ + shopUser: ShopUser } """ @@ -4777,6 +4784,40 @@ type ProductVariant implements HasMetafields { """ id: ID! + """ + Whether the product variant is in any of the specified collections. The variant must be in at least one + collection from the list to return `true`. A variant is considered to be in a collection when the variant + itself is a member of the collection, or when its product is a member of the collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inAnyCollection( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): Boolean! + + """ + Whether the product variant is in each of the specified collections. A variant is considered to be in a + collection when the variant itself is a member of the collection, or when its product is a member of the + collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inCollections( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): [CollectionMembership!]! + """ A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information about a Shopify resource, such as products, orders, and @@ -5001,6 +5042,34 @@ type Shop implements HasMetafields { ): Metaobject } +""" +Represents information about the buyer that is interacting with the cart. +""" +type ShopUser implements HasMetafields { + """ + A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information + about a Shopify resource, such as products, orders, and + [many more](https://shopify.dev/docs/api/admin-graphql/latest/enums/MetafieldOwnerType). + Using [metafields with Shopify Functions](https://shopify.dev/docs/apps/build/functions/input-output/metafields-for-input-queries) + enables you to customize the checkout experience. + """ + metafield( + """ + The unique identifier for the metafield within its namespace. A metafield is composed of a + namespace and a key, in the format `namespace.key`. + """ + key: String! + + """ + A category that organizes a group of metafields. Namespaces are used to prevent naming conflicts + between different apps or different parts of the same app. If omitted, then the + [app-reserved namespace](https://shopify.dev/docs/apps/build/custom-data/ownership) + is used. + """ + namespace: String + ): Metafield +} + """ A subset of the [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format that includes the time but not the date or timezone which is determined from context. diff --git a/functions-cart-transform-js/shopify.extension.toml.liquid b/functions-cart-transform-js/shopify.extension.toml.liquid index 8e6154b9..b1d10899 100644 --- a/functions-cart-transform-js/shopify.extension.toml.liquid +++ b/functions-cart-transform-js/shopify.extension.toml.liquid @@ -1,4 +1,4 @@ -api_version = "2026-04" +api_version = "2026-07" [[extensions]] name = "t:name" diff --git a/functions-cart-transform-rs/schema.graphql b/functions-cart-transform-rs/schema.graphql index db80114f..e98d5cbf 100644 --- a/functions-cart-transform-rs/schema.graphql +++ b/functions-cart-transform-rs/schema.graphql @@ -1,4 +1,4 @@ -# api_version: 2026-04 +# api_version: 2026-07 schema { query: Input @@ -86,6 +86,13 @@ type BuyerIdentity { Used to manage and track purchases made by businesses rather than individual customers. """ purchasingCompany: PurchasingCompany + + """ + Represents the [Shop User](https://help.shopify.com/en/manual/online-sales-channels/shop/sign-in-features) + corresponding to the customer within the shop, if the buyer is a Shop User. Can be used to request [Shop User + metafields](https://shopify.dev/docs/api/shop-user-custom-data). + """ + shopUser: ShopUser } """ @@ -4777,6 +4784,40 @@ type ProductVariant implements HasMetafields { """ id: ID! + """ + Whether the product variant is in any of the specified collections. The variant must be in at least one + collection from the list to return `true`. A variant is considered to be in a collection when the variant + itself is a member of the collection, or when its product is a member of the collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inAnyCollection( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): Boolean! + + """ + Whether the product variant is in each of the specified collections. A variant is considered to be in a + collection when the variant itself is a member of the collection, or when its product is a member of the + collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inCollections( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): [CollectionMembership!]! + """ A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information about a Shopify resource, such as products, orders, and @@ -5001,6 +5042,34 @@ type Shop implements HasMetafields { ): Metaobject } +""" +Represents information about the buyer that is interacting with the cart. +""" +type ShopUser implements HasMetafields { + """ + A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information + about a Shopify resource, such as products, orders, and + [many more](https://shopify.dev/docs/api/admin-graphql/latest/enums/MetafieldOwnerType). + Using [metafields with Shopify Functions](https://shopify.dev/docs/apps/build/functions/input-output/metafields-for-input-queries) + enables you to customize the checkout experience. + """ + metafield( + """ + The unique identifier for the metafield within its namespace. A metafield is composed of a + namespace and a key, in the format `namespace.key`. + """ + key: String! + + """ + A category that organizes a group of metafields. Namespaces are used to prevent naming conflicts + between different apps or different parts of the same app. If omitted, then the + [app-reserved namespace](https://shopify.dev/docs/apps/build/custom-data/ownership) + is used. + """ + namespace: String + ): Metafield +} + """ A subset of the [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format that includes the time but not the date or timezone which is determined from context. diff --git a/functions-cart-transform-rs/shopify.extension.toml.liquid b/functions-cart-transform-rs/shopify.extension.toml.liquid index 87b0fe0a..c40e1509 100644 --- a/functions-cart-transform-rs/shopify.extension.toml.liquid +++ b/functions-cart-transform-rs/shopify.extension.toml.liquid @@ -1,4 +1,4 @@ -api_version = "2026-04" +api_version = "2026-07" [[extensions]] name = "t:name" diff --git a/functions-cart-transform-wasm/schema.graphql b/functions-cart-transform-wasm/schema.graphql index db80114f..e98d5cbf 100644 --- a/functions-cart-transform-wasm/schema.graphql +++ b/functions-cart-transform-wasm/schema.graphql @@ -1,4 +1,4 @@ -# api_version: 2026-04 +# api_version: 2026-07 schema { query: Input @@ -86,6 +86,13 @@ type BuyerIdentity { Used to manage and track purchases made by businesses rather than individual customers. """ purchasingCompany: PurchasingCompany + + """ + Represents the [Shop User](https://help.shopify.com/en/manual/online-sales-channels/shop/sign-in-features) + corresponding to the customer within the shop, if the buyer is a Shop User. Can be used to request [Shop User + metafields](https://shopify.dev/docs/api/shop-user-custom-data). + """ + shopUser: ShopUser } """ @@ -4777,6 +4784,40 @@ type ProductVariant implements HasMetafields { """ id: ID! + """ + Whether the product variant is in any of the specified collections. The variant must be in at least one + collection from the list to return `true`. A variant is considered to be in a collection when the variant + itself is a member of the collection, or when its product is a member of the collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inAnyCollection( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): Boolean! + + """ + Whether the product variant is in each of the specified collections. A variant is considered to be in a + collection when the variant itself is a member of the collection, or when its product is a member of the + collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inCollections( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): [CollectionMembership!]! + """ A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information about a Shopify resource, such as products, orders, and @@ -5001,6 +5042,34 @@ type Shop implements HasMetafields { ): Metaobject } +""" +Represents information about the buyer that is interacting with the cart. +""" +type ShopUser implements HasMetafields { + """ + A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information + about a Shopify resource, such as products, orders, and + [many more](https://shopify.dev/docs/api/admin-graphql/latest/enums/MetafieldOwnerType). + Using [metafields with Shopify Functions](https://shopify.dev/docs/apps/build/functions/input-output/metafields-for-input-queries) + enables you to customize the checkout experience. + """ + metafield( + """ + The unique identifier for the metafield within its namespace. A metafield is composed of a + namespace and a key, in the format `namespace.key`. + """ + key: String! + + """ + A category that organizes a group of metafields. Namespaces are used to prevent naming conflicts + between different apps or different parts of the same app. If omitted, then the + [app-reserved namespace](https://shopify.dev/docs/apps/build/custom-data/ownership) + is used. + """ + namespace: String + ): Metafield +} + """ A subset of the [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format that includes the time but not the date or timezone which is determined from context. diff --git a/functions-cart-transform-wasm/shopify.extension.toml.liquid b/functions-cart-transform-wasm/shopify.extension.toml.liquid index d19265c9..39b817c2 100644 --- a/functions-cart-transform-wasm/shopify.extension.toml.liquid +++ b/functions-cart-transform-wasm/shopify.extension.toml.liquid @@ -1,4 +1,4 @@ -api_version = "2026-04" +api_version = "2026-07" [[extensions]] name = "t:name" diff --git a/functions-delivery-customization-js/schema.graphql b/functions-delivery-customization-js/schema.graphql index e0af177b..c40009b1 100644 --- a/functions-delivery-customization-js/schema.graphql +++ b/functions-delivery-customization-js/schema.graphql @@ -1,4 +1,4 @@ -# api_version: 2026-04 +# api_version: 2026-07 schema { query: Input @@ -69,6 +69,13 @@ type BuyerIdentity { Used to manage and track purchases made by businesses rather than individual customers. """ purchasingCompany: PurchasingCompany + + """ + Represents the [Shop User](https://help.shopify.com/en/manual/online-sales-channels/shop/sign-in-features) + corresponding to the customer within the shop, if the buyer is a Shop User. Can be used to request [Shop User + metafields](https://shopify.dev/docs/api/shop-user-custom-data). + """ + shopUser: ShopUser } """ @@ -4946,6 +4953,40 @@ type ProductVariant implements HasMetafields { """ id: ID! + """ + Whether the product variant is in any of the specified collections. The variant must be in at least one + collection from the list to return `true`. A variant is considered to be in a collection when the variant + itself is a member of the collection, or when its product is a member of the collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inAnyCollection( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): Boolean! + + """ + Whether the product variant is in each of the specified collections. A variant is considered to be in a + collection when the variant itself is a member of the collection, or when its product is a member of the + collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inCollections( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): [CollectionMembership!]! + """ A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information about a Shopify resource, such as products, orders, and @@ -5190,6 +5231,34 @@ type Shop implements HasMetafields { ): Metaobject } +""" +Represents information about the buyer that is interacting with the cart. +""" +type ShopUser implements HasMetafields { + """ + A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information + about a Shopify resource, such as products, orders, and + [many more](https://shopify.dev/docs/api/admin-graphql/latest/enums/MetafieldOwnerType). + Using [metafields with Shopify Functions](https://shopify.dev/docs/apps/build/functions/input-output/metafields-for-input-queries) + enables you to customize the checkout experience. + """ + metafield( + """ + The unique identifier for the metafield within its namespace. A metafield is composed of a + namespace and a key, in the format `namespace.key`. + """ + key: String! + + """ + A category that organizes a group of metafields. Namespaces are used to prevent naming conflicts + between different apps or different parts of the same app. If omitted, then the + [app-reserved namespace](https://shopify.dev/docs/apps/build/custom-data/ownership) + is used. + """ + namespace: String + ): Metafield +} + """ A subset of the [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format that includes the time but not the date or timezone which is determined from context. diff --git a/functions-delivery-customization-js/shopify.extension.toml.liquid b/functions-delivery-customization-js/shopify.extension.toml.liquid index 17eb887b..f7e1f8a5 100644 --- a/functions-delivery-customization-js/shopify.extension.toml.liquid +++ b/functions-delivery-customization-js/shopify.extension.toml.liquid @@ -1,4 +1,4 @@ -api_version = "2026-04" +api_version = "2026-07" [[extensions]] name = "t:name" diff --git a/functions-delivery-customization-rs/schema.graphql b/functions-delivery-customization-rs/schema.graphql index e0af177b..c40009b1 100644 --- a/functions-delivery-customization-rs/schema.graphql +++ b/functions-delivery-customization-rs/schema.graphql @@ -1,4 +1,4 @@ -# api_version: 2026-04 +# api_version: 2026-07 schema { query: Input @@ -69,6 +69,13 @@ type BuyerIdentity { Used to manage and track purchases made by businesses rather than individual customers. """ purchasingCompany: PurchasingCompany + + """ + Represents the [Shop User](https://help.shopify.com/en/manual/online-sales-channels/shop/sign-in-features) + corresponding to the customer within the shop, if the buyer is a Shop User. Can be used to request [Shop User + metafields](https://shopify.dev/docs/api/shop-user-custom-data). + """ + shopUser: ShopUser } """ @@ -4946,6 +4953,40 @@ type ProductVariant implements HasMetafields { """ id: ID! + """ + Whether the product variant is in any of the specified collections. The variant must be in at least one + collection from the list to return `true`. A variant is considered to be in a collection when the variant + itself is a member of the collection, or when its product is a member of the collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inAnyCollection( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): Boolean! + + """ + Whether the product variant is in each of the specified collections. A variant is considered to be in a + collection when the variant itself is a member of the collection, or when its product is a member of the + collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inCollections( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): [CollectionMembership!]! + """ A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information about a Shopify resource, such as products, orders, and @@ -5190,6 +5231,34 @@ type Shop implements HasMetafields { ): Metaobject } +""" +Represents information about the buyer that is interacting with the cart. +""" +type ShopUser implements HasMetafields { + """ + A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information + about a Shopify resource, such as products, orders, and + [many more](https://shopify.dev/docs/api/admin-graphql/latest/enums/MetafieldOwnerType). + Using [metafields with Shopify Functions](https://shopify.dev/docs/apps/build/functions/input-output/metafields-for-input-queries) + enables you to customize the checkout experience. + """ + metafield( + """ + The unique identifier for the metafield within its namespace. A metafield is composed of a + namespace and a key, in the format `namespace.key`. + """ + key: String! + + """ + A category that organizes a group of metafields. Namespaces are used to prevent naming conflicts + between different apps or different parts of the same app. If omitted, then the + [app-reserved namespace](https://shopify.dev/docs/apps/build/custom-data/ownership) + is used. + """ + namespace: String + ): Metafield +} + """ A subset of the [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format that includes the time but not the date or timezone which is determined from context. diff --git a/functions-delivery-customization-rs/shopify.extension.toml.liquid b/functions-delivery-customization-rs/shopify.extension.toml.liquid index 05411ed1..9a77b274 100644 --- a/functions-delivery-customization-rs/shopify.extension.toml.liquid +++ b/functions-delivery-customization-rs/shopify.extension.toml.liquid @@ -1,4 +1,4 @@ -api_version = "2026-04" +api_version = "2026-07" [[extensions]] name = "t:name" diff --git a/functions-delivery-customization-wasm/schema.graphql b/functions-delivery-customization-wasm/schema.graphql index e0af177b..c40009b1 100644 --- a/functions-delivery-customization-wasm/schema.graphql +++ b/functions-delivery-customization-wasm/schema.graphql @@ -1,4 +1,4 @@ -# api_version: 2026-04 +# api_version: 2026-07 schema { query: Input @@ -69,6 +69,13 @@ type BuyerIdentity { Used to manage and track purchases made by businesses rather than individual customers. """ purchasingCompany: PurchasingCompany + + """ + Represents the [Shop User](https://help.shopify.com/en/manual/online-sales-channels/shop/sign-in-features) + corresponding to the customer within the shop, if the buyer is a Shop User. Can be used to request [Shop User + metafields](https://shopify.dev/docs/api/shop-user-custom-data). + """ + shopUser: ShopUser } """ @@ -4946,6 +4953,40 @@ type ProductVariant implements HasMetafields { """ id: ID! + """ + Whether the product variant is in any of the specified collections. The variant must be in at least one + collection from the list to return `true`. A variant is considered to be in a collection when the variant + itself is a member of the collection, or when its product is a member of the collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inAnyCollection( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): Boolean! + + """ + Whether the product variant is in each of the specified collections. A variant is considered to be in a + collection when the variant itself is a member of the collection, or when its product is a member of the + collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inCollections( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): [CollectionMembership!]! + """ A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information about a Shopify resource, such as products, orders, and @@ -5190,6 +5231,34 @@ type Shop implements HasMetafields { ): Metaobject } +""" +Represents information about the buyer that is interacting with the cart. +""" +type ShopUser implements HasMetafields { + """ + A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information + about a Shopify resource, such as products, orders, and + [many more](https://shopify.dev/docs/api/admin-graphql/latest/enums/MetafieldOwnerType). + Using [metafields with Shopify Functions](https://shopify.dev/docs/apps/build/functions/input-output/metafields-for-input-queries) + enables you to customize the checkout experience. + """ + metafield( + """ + The unique identifier for the metafield within its namespace. A metafield is composed of a + namespace and a key, in the format `namespace.key`. + """ + key: String! + + """ + A category that organizes a group of metafields. Namespaces are used to prevent naming conflicts + between different apps or different parts of the same app. If omitted, then the + [app-reserved namespace](https://shopify.dev/docs/apps/build/custom-data/ownership) + is used. + """ + namespace: String + ): Metafield +} + """ A subset of the [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format that includes the time but not the date or timezone which is determined from context. diff --git a/functions-delivery-customization-wasm/shopify.extension.toml.liquid b/functions-delivery-customization-wasm/shopify.extension.toml.liquid index 24eaeba7..8fbf095e 100644 --- a/functions-delivery-customization-wasm/shopify.extension.toml.liquid +++ b/functions-delivery-customization-wasm/shopify.extension.toml.liquid @@ -1,4 +1,4 @@ -api_version = "2026-04" +api_version = "2026-07" [[extensions]] name = "t:name" diff --git a/functions-discount-js/schema.graphql b/functions-discount-js/schema.graphql index 6545540b..f642cfaa 100644 --- a/functions-discount-js/schema.graphql +++ b/functions-discount-js/schema.graphql @@ -1,4 +1,4 @@ -# api_version: 2026-04 +# api_version: 2026-07 schema { query: Input @@ -84,6 +84,13 @@ type BuyerIdentity { Used to manage and track purchases made by businesses rather than individual customers. """ purchasingCompany: PurchasingCompany + + """ + Represents the [Shop User](https://help.shopify.com/en/manual/online-sales-channels/shop/sign-in-features) + corresponding to the customer within the shop, if the buyer is a Shop User. Can be used to request [Shop User + metafields](https://shopify.dev/docs/api/shop-user-custom-data). + """ + shopUser: ShopUser } """ @@ -5639,6 +5646,40 @@ type ProductVariant implements HasMetafields { """ id: ID! + """ + Whether the product variant is in any of the specified collections. The variant must be in at least one + collection from the list to return `true`. A variant is considered to be in a collection when the variant + itself is a member of the collection, or when its product is a member of the collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inAnyCollection( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): Boolean! + + """ + Whether the product variant is in each of the specified collections. A variant is considered to be in a + collection when the variant itself is a member of the collection, or when its product is a member of the + collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inCollections( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): [CollectionMembership!]! + """ A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information about a Shopify resource, such as products, orders, and @@ -5873,6 +5914,34 @@ type Shop implements HasMetafields { ): Metaobject } +""" +Represents information about the buyer that is interacting with the cart. +""" +type ShopUser implements HasMetafields { + """ + A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information + about a Shopify resource, such as products, orders, and + [many more](https://shopify.dev/docs/api/admin-graphql/latest/enums/MetafieldOwnerType). + Using [metafields with Shopify Functions](https://shopify.dev/docs/apps/build/functions/input-output/metafields-for-input-queries) + enables you to customize the checkout experience. + """ + metafield( + """ + The unique identifier for the metafield within its namespace. A metafield is composed of a + namespace and a key, in the format `namespace.key`. + """ + key: String! + + """ + A category that organizes a group of metafields. Namespaces are used to prevent naming conflicts + between different apps or different parts of the same app. If omitted, then the + [app-reserved namespace](https://shopify.dev/docs/apps/build/custom-data/ownership) + is used. + """ + namespace: String + ): Metafield +} + """ A subset of the [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format that includes the time but not the date or timezone which is determined from context. diff --git a/functions-discount-js/shopify.extension.toml.liquid b/functions-discount-js/shopify.extension.toml.liquid index d4f761fd..8c120650 100644 --- a/functions-discount-js/shopify.extension.toml.liquid +++ b/functions-discount-js/shopify.extension.toml.liquid @@ -1,4 +1,4 @@ -api_version = "2026-04" +api_version = "2026-07" [[extensions]] name = "t:name" diff --git a/functions-discount-rs/schema.graphql b/functions-discount-rs/schema.graphql index 6545540b..f642cfaa 100644 --- a/functions-discount-rs/schema.graphql +++ b/functions-discount-rs/schema.graphql @@ -1,4 +1,4 @@ -# api_version: 2026-04 +# api_version: 2026-07 schema { query: Input @@ -84,6 +84,13 @@ type BuyerIdentity { Used to manage and track purchases made by businesses rather than individual customers. """ purchasingCompany: PurchasingCompany + + """ + Represents the [Shop User](https://help.shopify.com/en/manual/online-sales-channels/shop/sign-in-features) + corresponding to the customer within the shop, if the buyer is a Shop User. Can be used to request [Shop User + metafields](https://shopify.dev/docs/api/shop-user-custom-data). + """ + shopUser: ShopUser } """ @@ -5639,6 +5646,40 @@ type ProductVariant implements HasMetafields { """ id: ID! + """ + Whether the product variant is in any of the specified collections. The variant must be in at least one + collection from the list to return `true`. A variant is considered to be in a collection when the variant + itself is a member of the collection, or when its product is a member of the collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inAnyCollection( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): Boolean! + + """ + Whether the product variant is in each of the specified collections. A variant is considered to be in a + collection when the variant itself is a member of the collection, or when its product is a member of the + collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inCollections( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): [CollectionMembership!]! + """ A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information about a Shopify resource, such as products, orders, and @@ -5873,6 +5914,34 @@ type Shop implements HasMetafields { ): Metaobject } +""" +Represents information about the buyer that is interacting with the cart. +""" +type ShopUser implements HasMetafields { + """ + A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information + about a Shopify resource, such as products, orders, and + [many more](https://shopify.dev/docs/api/admin-graphql/latest/enums/MetafieldOwnerType). + Using [metafields with Shopify Functions](https://shopify.dev/docs/apps/build/functions/input-output/metafields-for-input-queries) + enables you to customize the checkout experience. + """ + metafield( + """ + The unique identifier for the metafield within its namespace. A metafield is composed of a + namespace and a key, in the format `namespace.key`. + """ + key: String! + + """ + A category that organizes a group of metafields. Namespaces are used to prevent naming conflicts + between different apps or different parts of the same app. If omitted, then the + [app-reserved namespace](https://shopify.dev/docs/apps/build/custom-data/ownership) + is used. + """ + namespace: String + ): Metafield +} + """ A subset of the [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format that includes the time but not the date or timezone which is determined from context. diff --git a/functions-discount-rs/shopify.extension.toml.liquid b/functions-discount-rs/shopify.extension.toml.liquid index 8a39dfe6..1e2e5634 100644 --- a/functions-discount-rs/shopify.extension.toml.liquid +++ b/functions-discount-rs/shopify.extension.toml.liquid @@ -1,4 +1,4 @@ -api_version = "2026-04" +api_version = "2026-07" [[extensions]] name = "t:name" diff --git a/functions-discount-rs/tests/fixtures/cart-lines-both-discounts.json b/functions-discount-rs/tests/fixtures/cart-lines-both-discounts.json index 4968d82a..ed4336ef 100644 --- a/functions-discount-rs/tests/fixtures/cart-lines-both-discounts.json +++ b/functions-discount-rs/tests/fixtures/cart-lines-both-discounts.json @@ -26,8 +26,6 @@ "orderDiscountsAdd": { "candidates": [ { - "associatedDiscountCode": null, - "conditions": null, "message": "10% OFF ORDER", "targets": [ { @@ -50,14 +48,11 @@ "productDiscountsAdd": { "candidates": [ { - "associatedDiscountCode": null, "message": "20% OFF PRODUCT", - "prerequisites": null, "targets": [ { "cartLine": { - "id": "gid://shopify/CartLine/0", - "quantity": null + "id": "gid://shopify/CartLine/0" } } ], diff --git a/functions-discount-rs/tests/fixtures/delivery-options-shipping-discount.json b/functions-discount-rs/tests/fixtures/delivery-options-shipping-discount.json index 5ee44a7e..efe561e8 100644 --- a/functions-discount-rs/tests/fixtures/delivery-options-shipping-discount.json +++ b/functions-discount-rs/tests/fixtures/delivery-options-shipping-discount.json @@ -20,7 +20,6 @@ "deliveryDiscountsAdd": { "candidates": [ { - "associatedDiscountCode": null, "message": "FREE DELIVERY", "targets": [ { @@ -42,4 +41,4 @@ ] } } -} \ No newline at end of file +} diff --git a/functions-discount-wasm/schema.graphql b/functions-discount-wasm/schema.graphql index 6545540b..f642cfaa 100644 --- a/functions-discount-wasm/schema.graphql +++ b/functions-discount-wasm/schema.graphql @@ -1,4 +1,4 @@ -# api_version: 2026-04 +# api_version: 2026-07 schema { query: Input @@ -84,6 +84,13 @@ type BuyerIdentity { Used to manage and track purchases made by businesses rather than individual customers. """ purchasingCompany: PurchasingCompany + + """ + Represents the [Shop User](https://help.shopify.com/en/manual/online-sales-channels/shop/sign-in-features) + corresponding to the customer within the shop, if the buyer is a Shop User. Can be used to request [Shop User + metafields](https://shopify.dev/docs/api/shop-user-custom-data). + """ + shopUser: ShopUser } """ @@ -5639,6 +5646,40 @@ type ProductVariant implements HasMetafields { """ id: ID! + """ + Whether the product variant is in any of the specified collections. The variant must be in at least one + collection from the list to return `true`. A variant is considered to be in a collection when the variant + itself is a member of the collection, or when its product is a member of the collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inAnyCollection( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): Boolean! + + """ + Whether the product variant is in each of the specified collections. A variant is considered to be in a + collection when the variant itself is a member of the collection, or when its product is a member of the + collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inCollections( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): [CollectionMembership!]! + """ A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information about a Shopify resource, such as products, orders, and @@ -5873,6 +5914,34 @@ type Shop implements HasMetafields { ): Metaobject } +""" +Represents information about the buyer that is interacting with the cart. +""" +type ShopUser implements HasMetafields { + """ + A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information + about a Shopify resource, such as products, orders, and + [many more](https://shopify.dev/docs/api/admin-graphql/latest/enums/MetafieldOwnerType). + Using [metafields with Shopify Functions](https://shopify.dev/docs/apps/build/functions/input-output/metafields-for-input-queries) + enables you to customize the checkout experience. + """ + metafield( + """ + The unique identifier for the metafield within its namespace. A metafield is composed of a + namespace and a key, in the format `namespace.key`. + """ + key: String! + + """ + A category that organizes a group of metafields. Namespaces are used to prevent naming conflicts + between different apps or different parts of the same app. If omitted, then the + [app-reserved namespace](https://shopify.dev/docs/apps/build/custom-data/ownership) + is used. + """ + namespace: String + ): Metafield +} + """ A subset of the [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format that includes the time but not the date or timezone which is determined from context. diff --git a/functions-discount-wasm/shopify.extension.toml.liquid b/functions-discount-wasm/shopify.extension.toml.liquid index 51fe3154..960bb821 100644 --- a/functions-discount-wasm/shopify.extension.toml.liquid +++ b/functions-discount-wasm/shopify.extension.toml.liquid @@ -1,4 +1,4 @@ -api_version = "2026-04" +api_version = "2026-07" [[extensions]] name = "t:name" diff --git a/functions-fulfillment-constraints-js/schema.graphql b/functions-fulfillment-constraints-js/schema.graphql index e7f3a10f..3273d8c7 100644 --- a/functions-fulfillment-constraints-js/schema.graphql +++ b/functions-fulfillment-constraints-js/schema.graphql @@ -1,4 +1,4 @@ -# api_version: 2026-04 +# api_version: 2026-07 schema { query: Input @@ -69,6 +69,13 @@ type BuyerIdentity { Used to manage and track purchases made by businesses rather than individual customers. """ purchasingCompany: PurchasingCompany + + """ + Represents the [Shop User](https://help.shopify.com/en/manual/online-sales-channels/shop/sign-in-features) + corresponding to the customer within the shop, if the buyer is a Shop User. Can be used to request [Shop User + metafields](https://shopify.dev/docs/api/shop-user-custom-data). + """ + shopUser: ShopUser } """ @@ -4927,6 +4934,40 @@ type ProductVariant implements HasMetafields { """ id: ID! + """ + Whether the product variant is in any of the specified collections. The variant must be in at least one + collection from the list to return `true`. A variant is considered to be in a collection when the variant + itself is a member of the collection, or when its product is a member of the collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inAnyCollection( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): Boolean! + + """ + Whether the product variant is in each of the specified collections. A variant is considered to be in a + collection when the variant itself is a member of the collection, or when its product is a member of the + collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inCollections( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): [CollectionMembership!]! + """ A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information about a Shopify resource, such as products, orders, and @@ -5151,6 +5192,34 @@ type Shop implements HasMetafields { ): Metaobject } +""" +Represents information about the buyer that is interacting with the cart. +""" +type ShopUser implements HasMetafields { + """ + A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information + about a Shopify resource, such as products, orders, and + [many more](https://shopify.dev/docs/api/admin-graphql/latest/enums/MetafieldOwnerType). + Using [metafields with Shopify Functions](https://shopify.dev/docs/apps/build/functions/input-output/metafields-for-input-queries) + enables you to customize the checkout experience. + """ + metafield( + """ + The unique identifier for the metafield within its namespace. A metafield is composed of a + namespace and a key, in the format `namespace.key`. + """ + key: String! + + """ + A category that organizes a group of metafields. Namespaces are used to prevent naming conflicts + between different apps or different parts of the same app. If omitted, then the + [app-reserved namespace](https://shopify.dev/docs/apps/build/custom-data/ownership) + is used. + """ + namespace: String + ): Metafield +} + """ A subset of the [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format that includes the time but not the date or timezone which is determined from context. diff --git a/functions-fulfillment-constraints-js/shopify.extension.toml.liquid b/functions-fulfillment-constraints-js/shopify.extension.toml.liquid index 84344039..41b8db49 100644 --- a/functions-fulfillment-constraints-js/shopify.extension.toml.liquid +++ b/functions-fulfillment-constraints-js/shopify.extension.toml.liquid @@ -1,4 +1,4 @@ -api_version = "2026-04" +api_version = "2026-07" [[extensions]] name = "t:name" diff --git a/functions-fulfillment-constraints-rs/schema.graphql b/functions-fulfillment-constraints-rs/schema.graphql index e7f3a10f..3273d8c7 100644 --- a/functions-fulfillment-constraints-rs/schema.graphql +++ b/functions-fulfillment-constraints-rs/schema.graphql @@ -1,4 +1,4 @@ -# api_version: 2026-04 +# api_version: 2026-07 schema { query: Input @@ -69,6 +69,13 @@ type BuyerIdentity { Used to manage and track purchases made by businesses rather than individual customers. """ purchasingCompany: PurchasingCompany + + """ + Represents the [Shop User](https://help.shopify.com/en/manual/online-sales-channels/shop/sign-in-features) + corresponding to the customer within the shop, if the buyer is a Shop User. Can be used to request [Shop User + metafields](https://shopify.dev/docs/api/shop-user-custom-data). + """ + shopUser: ShopUser } """ @@ -4927,6 +4934,40 @@ type ProductVariant implements HasMetafields { """ id: ID! + """ + Whether the product variant is in any of the specified collections. The variant must be in at least one + collection from the list to return `true`. A variant is considered to be in a collection when the variant + itself is a member of the collection, or when its product is a member of the collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inAnyCollection( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): Boolean! + + """ + Whether the product variant is in each of the specified collections. A variant is considered to be in a + collection when the variant itself is a member of the collection, or when its product is a member of the + collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inCollections( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): [CollectionMembership!]! + """ A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information about a Shopify resource, such as products, orders, and @@ -5151,6 +5192,34 @@ type Shop implements HasMetafields { ): Metaobject } +""" +Represents information about the buyer that is interacting with the cart. +""" +type ShopUser implements HasMetafields { + """ + A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information + about a Shopify resource, such as products, orders, and + [many more](https://shopify.dev/docs/api/admin-graphql/latest/enums/MetafieldOwnerType). + Using [metafields with Shopify Functions](https://shopify.dev/docs/apps/build/functions/input-output/metafields-for-input-queries) + enables you to customize the checkout experience. + """ + metafield( + """ + The unique identifier for the metafield within its namespace. A metafield is composed of a + namespace and a key, in the format `namespace.key`. + """ + key: String! + + """ + A category that organizes a group of metafields. Namespaces are used to prevent naming conflicts + between different apps or different parts of the same app. If omitted, then the + [app-reserved namespace](https://shopify.dev/docs/apps/build/custom-data/ownership) + is used. + """ + namespace: String + ): Metafield +} + """ A subset of the [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format that includes the time but not the date or timezone which is determined from context. diff --git a/functions-fulfillment-constraints-rs/shopify.extension.toml.liquid b/functions-fulfillment-constraints-rs/shopify.extension.toml.liquid index 9ed99492..df78170e 100644 --- a/functions-fulfillment-constraints-rs/shopify.extension.toml.liquid +++ b/functions-fulfillment-constraints-rs/shopify.extension.toml.liquid @@ -1,4 +1,4 @@ -api_version = "2026-04" +api_version = "2026-07" [[extensions]] name = "t:name" diff --git a/functions-fulfillment-constraints-wasm/schema.graphql b/functions-fulfillment-constraints-wasm/schema.graphql index e7f3a10f..3273d8c7 100644 --- a/functions-fulfillment-constraints-wasm/schema.graphql +++ b/functions-fulfillment-constraints-wasm/schema.graphql @@ -1,4 +1,4 @@ -# api_version: 2026-04 +# api_version: 2026-07 schema { query: Input @@ -69,6 +69,13 @@ type BuyerIdentity { Used to manage and track purchases made by businesses rather than individual customers. """ purchasingCompany: PurchasingCompany + + """ + Represents the [Shop User](https://help.shopify.com/en/manual/online-sales-channels/shop/sign-in-features) + corresponding to the customer within the shop, if the buyer is a Shop User. Can be used to request [Shop User + metafields](https://shopify.dev/docs/api/shop-user-custom-data). + """ + shopUser: ShopUser } """ @@ -4927,6 +4934,40 @@ type ProductVariant implements HasMetafields { """ id: ID! + """ + Whether the product variant is in any of the specified collections. The variant must be in at least one + collection from the list to return `true`. A variant is considered to be in a collection when the variant + itself is a member of the collection, or when its product is a member of the collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inAnyCollection( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): Boolean! + + """ + Whether the product variant is in each of the specified collections. A variant is considered to be in a + collection when the variant itself is a member of the collection, or when its product is a member of the + collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inCollections( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): [CollectionMembership!]! + """ A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information about a Shopify resource, such as products, orders, and @@ -5151,6 +5192,34 @@ type Shop implements HasMetafields { ): Metaobject } +""" +Represents information about the buyer that is interacting with the cart. +""" +type ShopUser implements HasMetafields { + """ + A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information + about a Shopify resource, such as products, orders, and + [many more](https://shopify.dev/docs/api/admin-graphql/latest/enums/MetafieldOwnerType). + Using [metafields with Shopify Functions](https://shopify.dev/docs/apps/build/functions/input-output/metafields-for-input-queries) + enables you to customize the checkout experience. + """ + metafield( + """ + The unique identifier for the metafield within its namespace. A metafield is composed of a + namespace and a key, in the format `namespace.key`. + """ + key: String! + + """ + A category that organizes a group of metafields. Namespaces are used to prevent naming conflicts + between different apps or different parts of the same app. If omitted, then the + [app-reserved namespace](https://shopify.dev/docs/apps/build/custom-data/ownership) + is used. + """ + namespace: String + ): Metafield +} + """ A subset of the [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format that includes the time but not the date or timezone which is determined from context. diff --git a/functions-fulfillment-constraints-wasm/shopify.extension.toml.liquid b/functions-fulfillment-constraints-wasm/shopify.extension.toml.liquid index 62996216..3faaf046 100644 --- a/functions-fulfillment-constraints-wasm/shopify.extension.toml.liquid +++ b/functions-fulfillment-constraints-wasm/shopify.extension.toml.liquid @@ -1,4 +1,4 @@ -api_version = "2026-04" +api_version = "2026-07" [[extensions]] name = "t:name" diff --git a/functions-local-pickup-delivery-option-generators-rs/tests/fixtures/returns-delivery-option.json b/functions-local-pickup-delivery-option-generators-rs/tests/fixtures/returns-delivery-option.json index ecf25136..ed828311 100644 --- a/functions-local-pickup-delivery-option-generators-rs/tests/fixtures/returns-delivery-option.json +++ b/functions-local-pickup-delivery-option-generators-rs/tests/fixtures/returns-delivery-option.json @@ -46,8 +46,7 @@ "pickupLocation": { "locationHandle": "2578303", "pickupInstruction": "Usually ready in 24 hours." - }, - "metafields": null + } } } ] diff --git a/functions-local-pickup-delivery-option-generators-wasm/shopify.extension.toml.liquid b/functions-local-pickup-delivery-option-generators-wasm/shopify.extension.toml.liquid index bdfb0782..e6737d26 100644 --- a/functions-local-pickup-delivery-option-generators-wasm/shopify.extension.toml.liquid +++ b/functions-local-pickup-delivery-option-generators-wasm/shopify.extension.toml.liquid @@ -18,4 +18,4 @@ type = "function" [extensions.ui.paths] create = "/" - details = "/" \ No newline at end of file + details = "/" diff --git a/functions-location-rules-js/schema.graphql b/functions-location-rules-js/schema.graphql index 1021cc69..2b760f0d 100644 --- a/functions-location-rules-js/schema.graphql +++ b/functions-location-rules-js/schema.graphql @@ -1,4 +1,4 @@ -# api_version: 2026-04 +# api_version: 2026-07 schema { query: Input @@ -69,6 +69,13 @@ type BuyerIdentity { Used to manage and track purchases made by businesses rather than individual customers. """ purchasingCompany: PurchasingCompany + + """ + Represents the [Shop User](https://help.shopify.com/en/manual/online-sales-channels/shop/sign-in-features) + corresponding to the customer within the shop, if the buyer is a Shop User. Can be used to request [Shop User + metafields](https://shopify.dev/docs/api/shop-user-custom-data). + """ + shopUser: ShopUser } """ @@ -4913,6 +4920,40 @@ type ProductVariant implements HasMetafields { """ id: ID! + """ + Whether the product variant is in any of the specified collections. The variant must be in at least one + collection from the list to return `true`. A variant is considered to be in a collection when the variant + itself is a member of the collection, or when its product is a member of the collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inAnyCollection( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): Boolean! + + """ + Whether the product variant is in each of the specified collections. A variant is considered to be in a + collection when the variant itself is a member of the collection, or when its product is a member of the + collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inCollections( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): [CollectionMembership!]! + """ A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information about a Shopify resource, such as products, orders, and @@ -5152,6 +5193,34 @@ type Shop implements HasMetafields { ): Metaobject } +""" +Represents information about the buyer that is interacting with the cart. +""" +type ShopUser implements HasMetafields { + """ + A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information + about a Shopify resource, such as products, orders, and + [many more](https://shopify.dev/docs/api/admin-graphql/latest/enums/MetafieldOwnerType). + Using [metafields with Shopify Functions](https://shopify.dev/docs/apps/build/functions/input-output/metafields-for-input-queries) + enables you to customize the checkout experience. + """ + metafield( + """ + The unique identifier for the metafield within its namespace. A metafield is composed of a + namespace and a key, in the format `namespace.key`. + """ + key: String! + + """ + A category that organizes a group of metafields. Namespaces are used to prevent naming conflicts + between different apps or different parts of the same app. If omitted, then the + [app-reserved namespace](https://shopify.dev/docs/apps/build/custom-data/ownership) + is used. + """ + namespace: String + ): Metafield +} + """ A subset of the [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format that includes the time but not the date or timezone which is determined from context. diff --git a/functions-location-rules-js/shopify.extension.toml.liquid b/functions-location-rules-js/shopify.extension.toml.liquid index 2d96c801..36a00e5b 100644 --- a/functions-location-rules-js/shopify.extension.toml.liquid +++ b/functions-location-rules-js/shopify.extension.toml.liquid @@ -1,4 +1,4 @@ -api_version = "2026-04" +api_version = "2026-07" [[extensions]] name = "t:name" diff --git a/functions-location-rules-rs/schema.graphql b/functions-location-rules-rs/schema.graphql index 1021cc69..2b760f0d 100644 --- a/functions-location-rules-rs/schema.graphql +++ b/functions-location-rules-rs/schema.graphql @@ -1,4 +1,4 @@ -# api_version: 2026-04 +# api_version: 2026-07 schema { query: Input @@ -69,6 +69,13 @@ type BuyerIdentity { Used to manage and track purchases made by businesses rather than individual customers. """ purchasingCompany: PurchasingCompany + + """ + Represents the [Shop User](https://help.shopify.com/en/manual/online-sales-channels/shop/sign-in-features) + corresponding to the customer within the shop, if the buyer is a Shop User. Can be used to request [Shop User + metafields](https://shopify.dev/docs/api/shop-user-custom-data). + """ + shopUser: ShopUser } """ @@ -4913,6 +4920,40 @@ type ProductVariant implements HasMetafields { """ id: ID! + """ + Whether the product variant is in any of the specified collections. The variant must be in at least one + collection from the list to return `true`. A variant is considered to be in a collection when the variant + itself is a member of the collection, or when its product is a member of the collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inAnyCollection( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): Boolean! + + """ + Whether the product variant is in each of the specified collections. A variant is considered to be in a + collection when the variant itself is a member of the collection, or when its product is a member of the + collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inCollections( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): [CollectionMembership!]! + """ A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information about a Shopify resource, such as products, orders, and @@ -5152,6 +5193,34 @@ type Shop implements HasMetafields { ): Metaobject } +""" +Represents information about the buyer that is interacting with the cart. +""" +type ShopUser implements HasMetafields { + """ + A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information + about a Shopify resource, such as products, orders, and + [many more](https://shopify.dev/docs/api/admin-graphql/latest/enums/MetafieldOwnerType). + Using [metafields with Shopify Functions](https://shopify.dev/docs/apps/build/functions/input-output/metafields-for-input-queries) + enables you to customize the checkout experience. + """ + metafield( + """ + The unique identifier for the metafield within its namespace. A metafield is composed of a + namespace and a key, in the format `namespace.key`. + """ + key: String! + + """ + A category that organizes a group of metafields. Namespaces are used to prevent naming conflicts + between different apps or different parts of the same app. If omitted, then the + [app-reserved namespace](https://shopify.dev/docs/apps/build/custom-data/ownership) + is used. + """ + namespace: String + ): Metafield +} + """ A subset of the [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format that includes the time but not the date or timezone which is determined from context. diff --git a/functions-location-rules-rs/shopify.extension.toml.liquid b/functions-location-rules-rs/shopify.extension.toml.liquid index ed4b66f1..b44e62c2 100644 --- a/functions-location-rules-rs/shopify.extension.toml.liquid +++ b/functions-location-rules-rs/shopify.extension.toml.liquid @@ -1,4 +1,4 @@ -api_version = "2026-04" +api_version = "2026-07" [[extensions]] name = "t:name" diff --git a/functions-location-rules-wasm/schema.graphql b/functions-location-rules-wasm/schema.graphql index 1021cc69..2b760f0d 100644 --- a/functions-location-rules-wasm/schema.graphql +++ b/functions-location-rules-wasm/schema.graphql @@ -1,4 +1,4 @@ -# api_version: 2026-04 +# api_version: 2026-07 schema { query: Input @@ -69,6 +69,13 @@ type BuyerIdentity { Used to manage and track purchases made by businesses rather than individual customers. """ purchasingCompany: PurchasingCompany + + """ + Represents the [Shop User](https://help.shopify.com/en/manual/online-sales-channels/shop/sign-in-features) + corresponding to the customer within the shop, if the buyer is a Shop User. Can be used to request [Shop User + metafields](https://shopify.dev/docs/api/shop-user-custom-data). + """ + shopUser: ShopUser } """ @@ -4913,6 +4920,40 @@ type ProductVariant implements HasMetafields { """ id: ID! + """ + Whether the product variant is in any of the specified collections. The variant must be in at least one + collection from the list to return `true`. A variant is considered to be in a collection when the variant + itself is a member of the collection, or when its product is a member of the collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inAnyCollection( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): Boolean! + + """ + Whether the product variant is in each of the specified collections. A variant is considered to be in a + collection when the variant itself is a member of the collection, or when its product is a member of the + collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inCollections( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): [CollectionMembership!]! + """ A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information about a Shopify resource, such as products, orders, and @@ -5152,6 +5193,34 @@ type Shop implements HasMetafields { ): Metaobject } +""" +Represents information about the buyer that is interacting with the cart. +""" +type ShopUser implements HasMetafields { + """ + A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information + about a Shopify resource, such as products, orders, and + [many more](https://shopify.dev/docs/api/admin-graphql/latest/enums/MetafieldOwnerType). + Using [metafields with Shopify Functions](https://shopify.dev/docs/apps/build/functions/input-output/metafields-for-input-queries) + enables you to customize the checkout experience. + """ + metafield( + """ + The unique identifier for the metafield within its namespace. A metafield is composed of a + namespace and a key, in the format `namespace.key`. + """ + key: String! + + """ + A category that organizes a group of metafields. Namespaces are used to prevent naming conflicts + between different apps or different parts of the same app. If omitted, then the + [app-reserved namespace](https://shopify.dev/docs/apps/build/custom-data/ownership) + is used. + """ + namespace: String + ): Metafield +} + """ A subset of the [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format that includes the time but not the date or timezone which is determined from context. diff --git a/functions-location-rules-wasm/shopify.extension.toml.liquid b/functions-location-rules-wasm/shopify.extension.toml.liquid index d4b35e3b..3e921307 100644 --- a/functions-location-rules-wasm/shopify.extension.toml.liquid +++ b/functions-location-rules-wasm/shopify.extension.toml.liquid @@ -1,4 +1,4 @@ -api_version = "2026-04" +api_version = "2026-07" [[extensions]] name = "t:name" diff --git a/functions-order-discounts-js/schema.graphql b/functions-order-discounts-js/schema.graphql index 14ad7be9..adbd7063 100644 --- a/functions-order-discounts-js/schema.graphql +++ b/functions-order-discounts-js/schema.graphql @@ -1,4 +1,4 @@ -# api_version: 2026-04 +# api_version: 2026-07 schema { query: Input @@ -69,6 +69,13 @@ type BuyerIdentity { Used to manage and track purchases made by businesses rather than individual customers. """ purchasingCompany: PurchasingCompany + + """ + Represents the [Shop User](https://help.shopify.com/en/manual/online-sales-channels/shop/sign-in-features) + corresponding to the customer within the shop, if the buyer is a Shop User. Can be used to request [Shop User + metafields](https://shopify.dev/docs/api/shop-user-custom-data). + """ + shopUser: ShopUser } """ @@ -4991,6 +4998,40 @@ type ProductVariant implements HasMetafields { """ id: ID! + """ + Whether the product variant is in any of the specified collections. The variant must be in at least one + collection from the list to return `true`. A variant is considered to be in a collection when the variant + itself is a member of the collection, or when its product is a member of the collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inAnyCollection( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): Boolean! + + """ + Whether the product variant is in each of the specified collections. A variant is considered to be in a + collection when the variant itself is a member of the collection, or when its product is a member of the + collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inCollections( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): [CollectionMembership!]! + """ A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information about a Shopify resource, such as products, orders, and @@ -5237,6 +5278,34 @@ type Shop implements HasMetafields { ): Metaobject } +""" +Represents information about the buyer that is interacting with the cart. +""" +type ShopUser implements HasMetafields { + """ + A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information + about a Shopify resource, such as products, orders, and + [many more](https://shopify.dev/docs/api/admin-graphql/latest/enums/MetafieldOwnerType). + Using [metafields with Shopify Functions](https://shopify.dev/docs/apps/build/functions/input-output/metafields-for-input-queries) + enables you to customize the checkout experience. + """ + metafield( + """ + The unique identifier for the metafield within its namespace. A metafield is composed of a + namespace and a key, in the format `namespace.key`. + """ + key: String! + + """ + A category that organizes a group of metafields. Namespaces are used to prevent naming conflicts + between different apps or different parts of the same app. If omitted, then the + [app-reserved namespace](https://shopify.dev/docs/apps/build/custom-data/ownership) + is used. + """ + namespace: String + ): Metafield +} + """ The method for applying the discount to an order. This argument accepts either a single `OrderSubtotalTarget` or one or more `ProductVariantTarget`s, but not both. diff --git a/functions-order-discounts-js/shopify.extension.toml.liquid b/functions-order-discounts-js/shopify.extension.toml.liquid index beaa93a7..62229493 100644 --- a/functions-order-discounts-js/shopify.extension.toml.liquid +++ b/functions-order-discounts-js/shopify.extension.toml.liquid @@ -1,4 +1,4 @@ -api_version = "2026-04" +api_version = "2026-07" [[extensions]] name = "t:name" diff --git a/functions-order-discounts-rs/schema.graphql b/functions-order-discounts-rs/schema.graphql index 14ad7be9..adbd7063 100644 --- a/functions-order-discounts-rs/schema.graphql +++ b/functions-order-discounts-rs/schema.graphql @@ -1,4 +1,4 @@ -# api_version: 2026-04 +# api_version: 2026-07 schema { query: Input @@ -69,6 +69,13 @@ type BuyerIdentity { Used to manage and track purchases made by businesses rather than individual customers. """ purchasingCompany: PurchasingCompany + + """ + Represents the [Shop User](https://help.shopify.com/en/manual/online-sales-channels/shop/sign-in-features) + corresponding to the customer within the shop, if the buyer is a Shop User. Can be used to request [Shop User + metafields](https://shopify.dev/docs/api/shop-user-custom-data). + """ + shopUser: ShopUser } """ @@ -4991,6 +4998,40 @@ type ProductVariant implements HasMetafields { """ id: ID! + """ + Whether the product variant is in any of the specified collections. The variant must be in at least one + collection from the list to return `true`. A variant is considered to be in a collection when the variant + itself is a member of the collection, or when its product is a member of the collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inAnyCollection( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): Boolean! + + """ + Whether the product variant is in each of the specified collections. A variant is considered to be in a + collection when the variant itself is a member of the collection, or when its product is a member of the + collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inCollections( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): [CollectionMembership!]! + """ A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information about a Shopify resource, such as products, orders, and @@ -5237,6 +5278,34 @@ type Shop implements HasMetafields { ): Metaobject } +""" +Represents information about the buyer that is interacting with the cart. +""" +type ShopUser implements HasMetafields { + """ + A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information + about a Shopify resource, such as products, orders, and + [many more](https://shopify.dev/docs/api/admin-graphql/latest/enums/MetafieldOwnerType). + Using [metafields with Shopify Functions](https://shopify.dev/docs/apps/build/functions/input-output/metafields-for-input-queries) + enables you to customize the checkout experience. + """ + metafield( + """ + The unique identifier for the metafield within its namespace. A metafield is composed of a + namespace and a key, in the format `namespace.key`. + """ + key: String! + + """ + A category that organizes a group of metafields. Namespaces are used to prevent naming conflicts + between different apps or different parts of the same app. If omitted, then the + [app-reserved namespace](https://shopify.dev/docs/apps/build/custom-data/ownership) + is used. + """ + namespace: String + ): Metafield +} + """ The method for applying the discount to an order. This argument accepts either a single `OrderSubtotalTarget` or one or more `ProductVariantTarget`s, but not both. diff --git a/functions-order-discounts-rs/shopify.extension.toml.liquid b/functions-order-discounts-rs/shopify.extension.toml.liquid index cc0b5afa..53070c24 100644 --- a/functions-order-discounts-rs/shopify.extension.toml.liquid +++ b/functions-order-discounts-rs/shopify.extension.toml.liquid @@ -1,4 +1,4 @@ -api_version = "2026-04" +api_version = "2026-07" [[extensions]] name = "t:name" diff --git a/functions-order-discounts-wasm/schema.graphql b/functions-order-discounts-wasm/schema.graphql index 14ad7be9..adbd7063 100644 --- a/functions-order-discounts-wasm/schema.graphql +++ b/functions-order-discounts-wasm/schema.graphql @@ -1,4 +1,4 @@ -# api_version: 2026-04 +# api_version: 2026-07 schema { query: Input @@ -69,6 +69,13 @@ type BuyerIdentity { Used to manage and track purchases made by businesses rather than individual customers. """ purchasingCompany: PurchasingCompany + + """ + Represents the [Shop User](https://help.shopify.com/en/manual/online-sales-channels/shop/sign-in-features) + corresponding to the customer within the shop, if the buyer is a Shop User. Can be used to request [Shop User + metafields](https://shopify.dev/docs/api/shop-user-custom-data). + """ + shopUser: ShopUser } """ @@ -4991,6 +4998,40 @@ type ProductVariant implements HasMetafields { """ id: ID! + """ + Whether the product variant is in any of the specified collections. The variant must be in at least one + collection from the list to return `true`. A variant is considered to be in a collection when the variant + itself is a member of the collection, or when its product is a member of the collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inAnyCollection( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): Boolean! + + """ + Whether the product variant is in each of the specified collections. A variant is considered to be in a + collection when the variant itself is a member of the collection, or when its product is a member of the + collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inCollections( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): [CollectionMembership!]! + """ A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information about a Shopify resource, such as products, orders, and @@ -5237,6 +5278,34 @@ type Shop implements HasMetafields { ): Metaobject } +""" +Represents information about the buyer that is interacting with the cart. +""" +type ShopUser implements HasMetafields { + """ + A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information + about a Shopify resource, such as products, orders, and + [many more](https://shopify.dev/docs/api/admin-graphql/latest/enums/MetafieldOwnerType). + Using [metafields with Shopify Functions](https://shopify.dev/docs/apps/build/functions/input-output/metafields-for-input-queries) + enables you to customize the checkout experience. + """ + metafield( + """ + The unique identifier for the metafield within its namespace. A metafield is composed of a + namespace and a key, in the format `namespace.key`. + """ + key: String! + + """ + A category that organizes a group of metafields. Namespaces are used to prevent naming conflicts + between different apps or different parts of the same app. If omitted, then the + [app-reserved namespace](https://shopify.dev/docs/apps/build/custom-data/ownership) + is used. + """ + namespace: String + ): Metafield +} + """ The method for applying the discount to an order. This argument accepts either a single `OrderSubtotalTarget` or one or more `ProductVariantTarget`s, but not both. diff --git a/functions-order-discounts-wasm/shopify.extension.toml.liquid b/functions-order-discounts-wasm/shopify.extension.toml.liquid index faa4e39c..dd06650f 100644 --- a/functions-order-discounts-wasm/shopify.extension.toml.liquid +++ b/functions-order-discounts-wasm/shopify.extension.toml.liquid @@ -1,4 +1,4 @@ -api_version = "2026-04" +api_version = "2026-07" [[extensions]] name = "t:name" diff --git a/functions-payment-customization-js/schema.graphql b/functions-payment-customization-js/schema.graphql index 03183f67..76a729f4 100644 --- a/functions-payment-customization-js/schema.graphql +++ b/functions-payment-customization-js/schema.graphql @@ -1,4 +1,4 @@ -# api_version: 2026-04 +# api_version: 2026-07 schema { query: Input @@ -69,6 +69,13 @@ type BuyerIdentity { Used to manage and track purchases made by businesses rather than individual customers. """ purchasingCompany: PurchasingCompany + + """ + Represents the [Shop User](https://help.shopify.com/en/manual/online-sales-channels/shop/sign-in-features) + corresponding to the customer within the shop, if the buyer is a Shop User. Can be used to request [Shop User + metafields](https://shopify.dev/docs/api/shop-user-custom-data). + """ + shopUser: ShopUser } """ @@ -5211,6 +5218,40 @@ type ProductVariant implements HasMetafields { """ id: ID! + """ + Whether the product variant is in any of the specified collections. The variant must be in at least one + collection from the list to return `true`. A variant is considered to be in a collection when the variant + itself is a member of the collection, or when its product is a member of the collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inAnyCollection( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): Boolean! + + """ + Whether the product variant is in each of the specified collections. A variant is considered to be in a + collection when the variant itself is a member of the collection, or when its product is a member of the + collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inCollections( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): [CollectionMembership!]! + """ A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information about a Shopify resource, such as products, orders, and @@ -5457,6 +5498,34 @@ type Shop implements HasMetafields { ): Metaobject } +""" +Represents information about the buyer that is interacting with the cart. +""" +type ShopUser implements HasMetafields { + """ + A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information + about a Shopify resource, such as products, orders, and + [many more](https://shopify.dev/docs/api/admin-graphql/latest/enums/MetafieldOwnerType). + Using [metafields with Shopify Functions](https://shopify.dev/docs/apps/build/functions/input-output/metafields-for-input-queries) + enables you to customize the checkout experience. + """ + metafield( + """ + The unique identifier for the metafield within its namespace. A metafield is composed of a + namespace and a key, in the format `namespace.key`. + """ + key: String! + + """ + A category that organizes a group of metafields. Namespaces are used to prevent naming conflicts + between different apps or different parts of the same app. If omitted, then the + [app-reserved namespace](https://shopify.dev/docs/apps/build/custom-data/ownership) + is used. + """ + namespace: String + ): Metafield +} + """ A subset of the [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format that includes the time but not the date or timezone which is determined from context. diff --git a/functions-payment-customization-js/shopify.extension.toml.liquid b/functions-payment-customization-js/shopify.extension.toml.liquid index ed1f4b26..e1630af0 100644 --- a/functions-payment-customization-js/shopify.extension.toml.liquid +++ b/functions-payment-customization-js/shopify.extension.toml.liquid @@ -1,4 +1,4 @@ -api_version = "2026-04" +api_version = "2026-07" [[extensions]] name = "t:name" diff --git a/functions-payment-customization-rs/schema.graphql b/functions-payment-customization-rs/schema.graphql index 03183f67..76a729f4 100644 --- a/functions-payment-customization-rs/schema.graphql +++ b/functions-payment-customization-rs/schema.graphql @@ -1,4 +1,4 @@ -# api_version: 2026-04 +# api_version: 2026-07 schema { query: Input @@ -69,6 +69,13 @@ type BuyerIdentity { Used to manage and track purchases made by businesses rather than individual customers. """ purchasingCompany: PurchasingCompany + + """ + Represents the [Shop User](https://help.shopify.com/en/manual/online-sales-channels/shop/sign-in-features) + corresponding to the customer within the shop, if the buyer is a Shop User. Can be used to request [Shop User + metafields](https://shopify.dev/docs/api/shop-user-custom-data). + """ + shopUser: ShopUser } """ @@ -5211,6 +5218,40 @@ type ProductVariant implements HasMetafields { """ id: ID! + """ + Whether the product variant is in any of the specified collections. The variant must be in at least one + collection from the list to return `true`. A variant is considered to be in a collection when the variant + itself is a member of the collection, or when its product is a member of the collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inAnyCollection( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): Boolean! + + """ + Whether the product variant is in each of the specified collections. A variant is considered to be in a + collection when the variant itself is a member of the collection, or when its product is a member of the + collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inCollections( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): [CollectionMembership!]! + """ A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information about a Shopify resource, such as products, orders, and @@ -5457,6 +5498,34 @@ type Shop implements HasMetafields { ): Metaobject } +""" +Represents information about the buyer that is interacting with the cart. +""" +type ShopUser implements HasMetafields { + """ + A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information + about a Shopify resource, such as products, orders, and + [many more](https://shopify.dev/docs/api/admin-graphql/latest/enums/MetafieldOwnerType). + Using [metafields with Shopify Functions](https://shopify.dev/docs/apps/build/functions/input-output/metafields-for-input-queries) + enables you to customize the checkout experience. + """ + metafield( + """ + The unique identifier for the metafield within its namespace. A metafield is composed of a + namespace and a key, in the format `namespace.key`. + """ + key: String! + + """ + A category that organizes a group of metafields. Namespaces are used to prevent naming conflicts + between different apps or different parts of the same app. If omitted, then the + [app-reserved namespace](https://shopify.dev/docs/apps/build/custom-data/ownership) + is used. + """ + namespace: String + ): Metafield +} + """ A subset of the [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format that includes the time but not the date or timezone which is determined from context. diff --git a/functions-payment-customization-rs/shopify.extension.toml.liquid b/functions-payment-customization-rs/shopify.extension.toml.liquid index 6ca18de3..f5efa200 100644 --- a/functions-payment-customization-rs/shopify.extension.toml.liquid +++ b/functions-payment-customization-rs/shopify.extension.toml.liquid @@ -1,4 +1,4 @@ -api_version = "2026-04" +api_version = "2026-07" [[extensions]] name = "t:name" diff --git a/functions-payment-customization-wasm/schema.graphql b/functions-payment-customization-wasm/schema.graphql index 03183f67..76a729f4 100644 --- a/functions-payment-customization-wasm/schema.graphql +++ b/functions-payment-customization-wasm/schema.graphql @@ -1,4 +1,4 @@ -# api_version: 2026-04 +# api_version: 2026-07 schema { query: Input @@ -69,6 +69,13 @@ type BuyerIdentity { Used to manage and track purchases made by businesses rather than individual customers. """ purchasingCompany: PurchasingCompany + + """ + Represents the [Shop User](https://help.shopify.com/en/manual/online-sales-channels/shop/sign-in-features) + corresponding to the customer within the shop, if the buyer is a Shop User. Can be used to request [Shop User + metafields](https://shopify.dev/docs/api/shop-user-custom-data). + """ + shopUser: ShopUser } """ @@ -5211,6 +5218,40 @@ type ProductVariant implements HasMetafields { """ id: ID! + """ + Whether the product variant is in any of the specified collections. The variant must be in at least one + collection from the list to return `true`. A variant is considered to be in a collection when the variant + itself is a member of the collection, or when its product is a member of the collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inAnyCollection( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): Boolean! + + """ + Whether the product variant is in each of the specified collections. A variant is considered to be in a + collection when the variant itself is a member of the collection, or when its product is a member of the + collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inCollections( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): [CollectionMembership!]! + """ A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information about a Shopify resource, such as products, orders, and @@ -5457,6 +5498,34 @@ type Shop implements HasMetafields { ): Metaobject } +""" +Represents information about the buyer that is interacting with the cart. +""" +type ShopUser implements HasMetafields { + """ + A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information + about a Shopify resource, such as products, orders, and + [many more](https://shopify.dev/docs/api/admin-graphql/latest/enums/MetafieldOwnerType). + Using [metafields with Shopify Functions](https://shopify.dev/docs/apps/build/functions/input-output/metafields-for-input-queries) + enables you to customize the checkout experience. + """ + metafield( + """ + The unique identifier for the metafield within its namespace. A metafield is composed of a + namespace and a key, in the format `namespace.key`. + """ + key: String! + + """ + A category that organizes a group of metafields. Namespaces are used to prevent naming conflicts + between different apps or different parts of the same app. If omitted, then the + [app-reserved namespace](https://shopify.dev/docs/apps/build/custom-data/ownership) + is used. + """ + namespace: String + ): Metafield +} + """ A subset of the [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format that includes the time but not the date or timezone which is determined from context. diff --git a/functions-payment-customization-wasm/shopify.extension.toml.liquid b/functions-payment-customization-wasm/shopify.extension.toml.liquid index 0db0d53f..920dadc8 100644 --- a/functions-payment-customization-wasm/shopify.extension.toml.liquid +++ b/functions-payment-customization-wasm/shopify.extension.toml.liquid @@ -1,4 +1,4 @@ -api_version = "2026-04" +api_version = "2026-07" [[extensions]] name = "t:name" diff --git a/functions-pickup-point-delivery-option-generators-rs/tests/fixtures/fetch-canada-request.json b/functions-pickup-point-delivery-option-generators-rs/tests/fixtures/fetch-canada-request.json index a62e3a4a..6ef4ad4d 100644 --- a/functions-pickup-point-delivery-option-generators-rs/tests/fixtures/fetch-canada-request.json +++ b/functions-pickup-point-delivery-option-generators-rs/tests/fixtures/fetch-canada-request.json @@ -19,8 +19,6 @@ "value": "application/json; charset=utf-8" } ], - "body": null, - "jsonBody": null, "policy": { "readTimeoutMs": 500 } diff --git a/functions-pickup-point-delivery-option-generators-rs/tests/fixtures/fetch-non-canada-no-request.json b/functions-pickup-point-delivery-option-generators-rs/tests/fixtures/fetch-non-canada-no-request.json index e616bbbb..3b607d2f 100644 --- a/functions-pickup-point-delivery-option-generators-rs/tests/fixtures/fetch-non-canada-no-request.json +++ b/functions-pickup-point-delivery-option-generators-rs/tests/fixtures/fetch-non-canada-no-request.json @@ -9,8 +9,6 @@ "latitude": -74.01 } }, - "output": { - "request": null - } + "output": {} } } diff --git a/functions-pickup-point-delivery-option-generators-rs/tests/fixtures/run-null-opening-hours.json b/functions-pickup-point-delivery-option-generators-rs/tests/fixtures/run-null-opening-hours.json index 76338bff..827c6209 100644 --- a/functions-pickup-point-delivery-option-generators-rs/tests/fixtures/run-null-opening-hours.json +++ b/functions-pickup-point-delivery-option-generators-rs/tests/fixtures/run-null-opening-hours.json @@ -12,22 +12,18 @@ "operations": [ { "add": { - "cost": null, "pickupPoint": { "address": { "address1": "620 King St W", - "address2": null, "city": "Toronto", "country": "Canada", "countryCode": "CA", "latitude": 43.644664618786685, "longitude": -79.40066267417106, - "phone": null, "province": "Ontario", "provinceCode": "ON", "zip": "M5V 1M6" }, - "businessHours": null, "provider": { "name": "Shopify Functions Demo", "logoUrl": "https://cdn.shopify.com/s/files/1/0628/3830/9033/files/shopify_icon_146101.png?v=1706120545" diff --git a/functions-pickup-point-delivery-option-generators-rs/tests/fixtures/run-successful-fetch.json b/functions-pickup-point-delivery-option-generators-rs/tests/fixtures/run-successful-fetch.json index 761d3df6..a35f59a2 100644 --- a/functions-pickup-point-delivery-option-generators-rs/tests/fixtures/run-successful-fetch.json +++ b/functions-pickup-point-delivery-option-generators-rs/tests/fixtures/run-successful-fetch.json @@ -12,17 +12,14 @@ "operations": [ { "add": { - "cost": null, "pickupPoint": { "address": { "address1": "620 King St W", - "address2": null, "city": "Toronto", "country": "Canada", "countryCode": "CA", "latitude": 43.644664618786685, "longitude": -79.40066267417106, - "phone": null, "province": "Ontario", "provinceCode": "ON", "zip": "M5V 1M6" diff --git a/functions-product-discounts-js/schema.graphql b/functions-product-discounts-js/schema.graphql index 62a5f8c9..7059d8f6 100644 --- a/functions-product-discounts-js/schema.graphql +++ b/functions-product-discounts-js/schema.graphql @@ -1,4 +1,4 @@ -# api_version: 2026-04 +# api_version: 2026-07 schema { query: Input @@ -69,6 +69,13 @@ type BuyerIdentity { Used to manage and track purchases made by businesses rather than individual customers. """ purchasingCompany: PurchasingCompany + + """ + Represents the [Shop User](https://help.shopify.com/en/manual/online-sales-channels/shop/sign-in-features) + corresponding to the customer within the shop, if the buyer is a Shop User. Can be used to request [Shop User + metafields](https://shopify.dev/docs/api/shop-user-custom-data). + """ + shopUser: ShopUser } """ @@ -4923,6 +4930,40 @@ type ProductVariant implements HasMetafields { """ id: ID! + """ + Whether the product variant is in any of the specified collections. The variant must be in at least one + collection from the list to return `true`. A variant is considered to be in a collection when the variant + itself is a member of the collection, or when its product is a member of the collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inAnyCollection( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): Boolean! + + """ + Whether the product variant is in each of the specified collections. A variant is considered to be in a + collection when the variant itself is a member of the collection, or when its product is a member of the + collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inCollections( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): [CollectionMembership!]! + """ A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information about a Shopify resource, such as products, orders, and @@ -5169,6 +5210,34 @@ type Shop implements HasMetafields { ): Metaobject } +""" +Represents information about the buyer that is interacting with the cart. +""" +type ShopUser implements HasMetafields { + """ + A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information + about a Shopify resource, such as products, orders, and + [many more](https://shopify.dev/docs/api/admin-graphql/latest/enums/MetafieldOwnerType). + Using [metafields with Shopify Functions](https://shopify.dev/docs/apps/build/functions/input-output/metafields-for-input-queries) + enables you to customize the checkout experience. + """ + metafield( + """ + The unique identifier for the metafield within its namespace. A metafield is composed of a + namespace and a key, in the format `namespace.key`. + """ + key: String! + + """ + A category that organizes a group of metafields. Namespaces are used to prevent naming conflicts + between different apps or different parts of the same app. If omitted, then the + [app-reserved namespace](https://shopify.dev/docs/apps/build/custom-data/ownership) + is used. + """ + namespace: String + ): Metafield +} + """ The method for applying the discount to products. This argument accepts a collection of either `ProductVariantTarget` or `CartLineTarget`, but not both. diff --git a/functions-product-discounts-js/shopify.extension.toml.liquid b/functions-product-discounts-js/shopify.extension.toml.liquid index f7241e58..12d662ff 100644 --- a/functions-product-discounts-js/shopify.extension.toml.liquid +++ b/functions-product-discounts-js/shopify.extension.toml.liquid @@ -1,4 +1,4 @@ -api_version = "2026-04" +api_version = "2026-07" [[extensions]] name = "t:name" diff --git a/functions-product-discounts-rs/schema.graphql b/functions-product-discounts-rs/schema.graphql index 62a5f8c9..7059d8f6 100644 --- a/functions-product-discounts-rs/schema.graphql +++ b/functions-product-discounts-rs/schema.graphql @@ -1,4 +1,4 @@ -# api_version: 2026-04 +# api_version: 2026-07 schema { query: Input @@ -69,6 +69,13 @@ type BuyerIdentity { Used to manage and track purchases made by businesses rather than individual customers. """ purchasingCompany: PurchasingCompany + + """ + Represents the [Shop User](https://help.shopify.com/en/manual/online-sales-channels/shop/sign-in-features) + corresponding to the customer within the shop, if the buyer is a Shop User. Can be used to request [Shop User + metafields](https://shopify.dev/docs/api/shop-user-custom-data). + """ + shopUser: ShopUser } """ @@ -4923,6 +4930,40 @@ type ProductVariant implements HasMetafields { """ id: ID! + """ + Whether the product variant is in any of the specified collections. The variant must be in at least one + collection from the list to return `true`. A variant is considered to be in a collection when the variant + itself is a member of the collection, or when its product is a member of the collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inAnyCollection( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): Boolean! + + """ + Whether the product variant is in each of the specified collections. A variant is considered to be in a + collection when the variant itself is a member of the collection, or when its product is a member of the + collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inCollections( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): [CollectionMembership!]! + """ A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information about a Shopify resource, such as products, orders, and @@ -5169,6 +5210,34 @@ type Shop implements HasMetafields { ): Metaobject } +""" +Represents information about the buyer that is interacting with the cart. +""" +type ShopUser implements HasMetafields { + """ + A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information + about a Shopify resource, such as products, orders, and + [many more](https://shopify.dev/docs/api/admin-graphql/latest/enums/MetafieldOwnerType). + Using [metafields with Shopify Functions](https://shopify.dev/docs/apps/build/functions/input-output/metafields-for-input-queries) + enables you to customize the checkout experience. + """ + metafield( + """ + The unique identifier for the metafield within its namespace. A metafield is composed of a + namespace and a key, in the format `namespace.key`. + """ + key: String! + + """ + A category that organizes a group of metafields. Namespaces are used to prevent naming conflicts + between different apps or different parts of the same app. If omitted, then the + [app-reserved namespace](https://shopify.dev/docs/apps/build/custom-data/ownership) + is used. + """ + namespace: String + ): Metafield +} + """ The method for applying the discount to products. This argument accepts a collection of either `ProductVariantTarget` or `CartLineTarget`, but not both. diff --git a/functions-product-discounts-rs/shopify.extension.toml.liquid b/functions-product-discounts-rs/shopify.extension.toml.liquid index 73f89a5a..3d2e8443 100644 --- a/functions-product-discounts-rs/shopify.extension.toml.liquid +++ b/functions-product-discounts-rs/shopify.extension.toml.liquid @@ -1,4 +1,4 @@ -api_version = "2026-04" +api_version = "2026-07" [[extensions]] name = "t:name" diff --git a/functions-product-discounts-wasm/schema.graphql b/functions-product-discounts-wasm/schema.graphql index 62a5f8c9..7059d8f6 100644 --- a/functions-product-discounts-wasm/schema.graphql +++ b/functions-product-discounts-wasm/schema.graphql @@ -1,4 +1,4 @@ -# api_version: 2026-04 +# api_version: 2026-07 schema { query: Input @@ -69,6 +69,13 @@ type BuyerIdentity { Used to manage and track purchases made by businesses rather than individual customers. """ purchasingCompany: PurchasingCompany + + """ + Represents the [Shop User](https://help.shopify.com/en/manual/online-sales-channels/shop/sign-in-features) + corresponding to the customer within the shop, if the buyer is a Shop User. Can be used to request [Shop User + metafields](https://shopify.dev/docs/api/shop-user-custom-data). + """ + shopUser: ShopUser } """ @@ -4923,6 +4930,40 @@ type ProductVariant implements HasMetafields { """ id: ID! + """ + Whether the product variant is in any of the specified collections. The variant must be in at least one + collection from the list to return `true`. A variant is considered to be in a collection when the variant + itself is a member of the collection, or when its product is a member of the collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inAnyCollection( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): Boolean! + + """ + Whether the product variant is in each of the specified collections. A variant is considered to be in a + collection when the variant itself is a member of the collection, or when its product is a member of the + collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inCollections( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): [CollectionMembership!]! + """ A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information about a Shopify resource, such as products, orders, and @@ -5169,6 +5210,34 @@ type Shop implements HasMetafields { ): Metaobject } +""" +Represents information about the buyer that is interacting with the cart. +""" +type ShopUser implements HasMetafields { + """ + A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information + about a Shopify resource, such as products, orders, and + [many more](https://shopify.dev/docs/api/admin-graphql/latest/enums/MetafieldOwnerType). + Using [metafields with Shopify Functions](https://shopify.dev/docs/apps/build/functions/input-output/metafields-for-input-queries) + enables you to customize the checkout experience. + """ + metafield( + """ + The unique identifier for the metafield within its namespace. A metafield is composed of a + namespace and a key, in the format `namespace.key`. + """ + key: String! + + """ + A category that organizes a group of metafields. Namespaces are used to prevent naming conflicts + between different apps or different parts of the same app. If omitted, then the + [app-reserved namespace](https://shopify.dev/docs/apps/build/custom-data/ownership) + is used. + """ + namespace: String + ): Metafield +} + """ The method for applying the discount to products. This argument accepts a collection of either `ProductVariantTarget` or `CartLineTarget`, but not both. diff --git a/functions-product-discounts-wasm/shopify.extension.toml.liquid b/functions-product-discounts-wasm/shopify.extension.toml.liquid index 347b8d0b..7a8d8caf 100644 --- a/functions-product-discounts-wasm/shopify.extension.toml.liquid +++ b/functions-product-discounts-wasm/shopify.extension.toml.liquid @@ -1,4 +1,4 @@ -api_version = "2026-04" +api_version = "2026-07" [[extensions]] name = "t:name" diff --git a/functions-shipping-discounts-js/schema.graphql b/functions-shipping-discounts-js/schema.graphql index 262b2400..ab3b8df0 100644 --- a/functions-shipping-discounts-js/schema.graphql +++ b/functions-shipping-discounts-js/schema.graphql @@ -1,4 +1,4 @@ -# api_version: 2026-04 +# api_version: 2026-07 schema { query: Input @@ -69,6 +69,13 @@ type BuyerIdentity { Used to manage and track purchases made by businesses rather than individual customers. """ purchasingCompany: PurchasingCompany + + """ + Represents the [Shop User](https://help.shopify.com/en/manual/online-sales-channels/shop/sign-in-features) + corresponding to the customer within the shop, if the buyer is a Shop User. Can be used to request [Shop User + metafields](https://shopify.dev/docs/api/shop-user-custom-data). + """ + shopUser: ShopUser } """ @@ -4872,6 +4879,40 @@ type ProductVariant implements HasMetafields { """ id: ID! + """ + Whether the product variant is in any of the specified collections. The variant must be in at least one + collection from the list to return `true`. A variant is considered to be in a collection when the variant + itself is a member of the collection, or when its product is a member of the collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inAnyCollection( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): Boolean! + + """ + Whether the product variant is in each of the specified collections. A variant is considered to be in a + collection when the variant itself is a member of the collection, or when its product is a member of the + collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inCollections( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): [CollectionMembership!]! + """ A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information about a Shopify resource, such as products, orders, and @@ -5096,6 +5137,34 @@ type Shop implements HasMetafields { ): Metaobject } +""" +Represents information about the buyer that is interacting with the cart. +""" +type ShopUser implements HasMetafields { + """ + A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information + about a Shopify resource, such as products, orders, and + [many more](https://shopify.dev/docs/api/admin-graphql/latest/enums/MetafieldOwnerType). + Using [metafields with Shopify Functions](https://shopify.dev/docs/apps/build/functions/input-output/metafields-for-input-queries) + enables you to customize the checkout experience. + """ + metafield( + """ + The unique identifier for the metafield within its namespace. A metafield is composed of a + namespace and a key, in the format `namespace.key`. + """ + key: String! + + """ + A category that organizes a group of metafields. Namespaces are used to prevent naming conflicts + between different apps or different parts of the same app. If omitted, then the + [app-reserved namespace](https://shopify.dev/docs/apps/build/custom-data/ownership) + is used. + """ + namespace: String + ): Metafield +} + """ The method for applying the discount to shipping costs. This argument accepts a collection of either `DeliveryGroupTarget` or `DeliveryOptionTarget`, but not both. diff --git a/functions-shipping-discounts-js/shopify.extension.toml.liquid b/functions-shipping-discounts-js/shopify.extension.toml.liquid index bb5cac9b..8575eb43 100644 --- a/functions-shipping-discounts-js/shopify.extension.toml.liquid +++ b/functions-shipping-discounts-js/shopify.extension.toml.liquid @@ -1,4 +1,4 @@ -api_version = "2026-04" +api_version = "2026-07" [[extensions]] name = "t:name" diff --git a/functions-shipping-discounts-rs/schema.graphql b/functions-shipping-discounts-rs/schema.graphql index 262b2400..ab3b8df0 100644 --- a/functions-shipping-discounts-rs/schema.graphql +++ b/functions-shipping-discounts-rs/schema.graphql @@ -1,4 +1,4 @@ -# api_version: 2026-04 +# api_version: 2026-07 schema { query: Input @@ -69,6 +69,13 @@ type BuyerIdentity { Used to manage and track purchases made by businesses rather than individual customers. """ purchasingCompany: PurchasingCompany + + """ + Represents the [Shop User](https://help.shopify.com/en/manual/online-sales-channels/shop/sign-in-features) + corresponding to the customer within the shop, if the buyer is a Shop User. Can be used to request [Shop User + metafields](https://shopify.dev/docs/api/shop-user-custom-data). + """ + shopUser: ShopUser } """ @@ -4872,6 +4879,40 @@ type ProductVariant implements HasMetafields { """ id: ID! + """ + Whether the product variant is in any of the specified collections. The variant must be in at least one + collection from the list to return `true`. A variant is considered to be in a collection when the variant + itself is a member of the collection, or when its product is a member of the collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inAnyCollection( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): Boolean! + + """ + Whether the product variant is in each of the specified collections. A variant is considered to be in a + collection when the variant itself is a member of the collection, or when its product is a member of the + collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inCollections( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): [CollectionMembership!]! + """ A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information about a Shopify resource, such as products, orders, and @@ -5096,6 +5137,34 @@ type Shop implements HasMetafields { ): Metaobject } +""" +Represents information about the buyer that is interacting with the cart. +""" +type ShopUser implements HasMetafields { + """ + A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information + about a Shopify resource, such as products, orders, and + [many more](https://shopify.dev/docs/api/admin-graphql/latest/enums/MetafieldOwnerType). + Using [metafields with Shopify Functions](https://shopify.dev/docs/apps/build/functions/input-output/metafields-for-input-queries) + enables you to customize the checkout experience. + """ + metafield( + """ + The unique identifier for the metafield within its namespace. A metafield is composed of a + namespace and a key, in the format `namespace.key`. + """ + key: String! + + """ + A category that organizes a group of metafields. Namespaces are used to prevent naming conflicts + between different apps or different parts of the same app. If omitted, then the + [app-reserved namespace](https://shopify.dev/docs/apps/build/custom-data/ownership) + is used. + """ + namespace: String + ): Metafield +} + """ The method for applying the discount to shipping costs. This argument accepts a collection of either `DeliveryGroupTarget` or `DeliveryOptionTarget`, but not both. diff --git a/functions-shipping-discounts-rs/shopify.extension.toml.liquid b/functions-shipping-discounts-rs/shopify.extension.toml.liquid index 1a0f3c38..599c4ffc 100644 --- a/functions-shipping-discounts-rs/shopify.extension.toml.liquid +++ b/functions-shipping-discounts-rs/shopify.extension.toml.liquid @@ -1,4 +1,4 @@ -api_version = "2026-04" +api_version = "2026-07" [[extensions]] name = "t:name" diff --git a/functions-shipping-discounts-wasm/schema.graphql b/functions-shipping-discounts-wasm/schema.graphql index 262b2400..ab3b8df0 100644 --- a/functions-shipping-discounts-wasm/schema.graphql +++ b/functions-shipping-discounts-wasm/schema.graphql @@ -1,4 +1,4 @@ -# api_version: 2026-04 +# api_version: 2026-07 schema { query: Input @@ -69,6 +69,13 @@ type BuyerIdentity { Used to manage and track purchases made by businesses rather than individual customers. """ purchasingCompany: PurchasingCompany + + """ + Represents the [Shop User](https://help.shopify.com/en/manual/online-sales-channels/shop/sign-in-features) + corresponding to the customer within the shop, if the buyer is a Shop User. Can be used to request [Shop User + metafields](https://shopify.dev/docs/api/shop-user-custom-data). + """ + shopUser: ShopUser } """ @@ -4872,6 +4879,40 @@ type ProductVariant implements HasMetafields { """ id: ID! + """ + Whether the product variant is in any of the specified collections. The variant must be in at least one + collection from the list to return `true`. A variant is considered to be in a collection when the variant + itself is a member of the collection, or when its product is a member of the collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inAnyCollection( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): Boolean! + + """ + Whether the product variant is in each of the specified collections. A variant is considered to be in a + collection when the variant itself is a member of the collection, or when its product is a member of the + collection. + + A collection is a group of products that can be displayed in online stores and other sales channels in + categories, which makes it easy for customers to find them. For example, an athletics store might create + different collections for running attire and accessories. + """ + inCollections( + """ + A list of [globally-unique collection IDs](https://shopify.dev/docs/api/usage/gids) + to check membership against. For example, `gid://shopify/Collection/123`, `gid://shopify/Collection/456`. + """ + ids: [ID!]! = [] + ): [CollectionMembership!]! + """ A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information about a Shopify resource, such as products, orders, and @@ -5096,6 +5137,34 @@ type Shop implements HasMetafields { ): Metaobject } +""" +Represents information about the buyer that is interacting with the cart. +""" +type ShopUser implements HasMetafields { + """ + A [custom field](https://shopify.dev/docs/apps/build/custom-data) that stores additional information + about a Shopify resource, such as products, orders, and + [many more](https://shopify.dev/docs/api/admin-graphql/latest/enums/MetafieldOwnerType). + Using [metafields with Shopify Functions](https://shopify.dev/docs/apps/build/functions/input-output/metafields-for-input-queries) + enables you to customize the checkout experience. + """ + metafield( + """ + The unique identifier for the metafield within its namespace. A metafield is composed of a + namespace and a key, in the format `namespace.key`. + """ + key: String! + + """ + A category that organizes a group of metafields. Namespaces are used to prevent naming conflicts + between different apps or different parts of the same app. If omitted, then the + [app-reserved namespace](https://shopify.dev/docs/apps/build/custom-data/ownership) + is used. + """ + namespace: String + ): Metafield +} + """ The method for applying the discount to shipping costs. This argument accepts a collection of either `DeliveryGroupTarget` or `DeliveryOptionTarget`, but not both. diff --git a/functions-shipping-discounts-wasm/shopify.extension.toml.liquid b/functions-shipping-discounts-wasm/shopify.extension.toml.liquid index 1516f940..d06ef701 100644 --- a/functions-shipping-discounts-wasm/shopify.extension.toml.liquid +++ b/functions-shipping-discounts-wasm/shopify.extension.toml.liquid @@ -1,4 +1,4 @@ -api_version = "2026-04" +api_version = "2026-07" [[extensions]] name = "t:name"