# DiscountAutomaticBxgyInput - admin-graphql - INPUT_OBJECT Version: 2024-10 ## Description The input fields for creating or updating a [buy X get Y discount (BXGY)](https://help.shopify.com/manual/discounts/discount-types/buy-x-get-y) that's automatically applied on a cart and at checkout. ### Access Scopes ## Fields * [combinesWith](/docs/api/admin-graphql/2024-10/input-objects/DiscountCombinesWithInput): DiscountCombinesWithInput - The [discount class](https://help.shopify.com/manual/discounts/combining-discounts/discount-combinations) that you can use in combination with [Shopify discount types](https://help.shopify.com/manual/discounts/discount-types). * [customerBuys](/docs/api/admin-graphql/2024-10/input-objects/DiscountCustomerBuysInput): DiscountCustomerBuysInput - The items eligible for the discount and the required quantity of each to receive the discount. * [customerGets](/docs/api/admin-graphql/2024-10/input-objects/DiscountCustomerGetsInput): DiscountCustomerGetsInput - The items in the order that qualify for the discount, their quantities, and the total value of the discount. * [endsAt](/docs/api/admin-graphql/2024-10/scalars/DateTime): DateTime - The date and time when the discount expires and is no longer available to customers. For discounts without a fixed expiration date, specify `null`. * [startsAt](/docs/api/admin-graphql/2024-10/scalars/DateTime): DateTime - The date and time when the discount becomes active and is available to customers. * [title](/docs/api/admin-graphql/2024-10/scalars/String): String - The discount's name that displays to merchants in the Shopify admin and to customers. * [usesPerOrderLimit](/docs/api/admin-graphql/2024-10/scalars/UnsignedInt64): UnsignedInt64 - The maximum number of times that the discount can be applied to an order. ## Input objects with this input object * [discountAutomaticBxgyCreate](/docs/api/admin-graphql/2024-10/mutations/discountAutomaticBxgyCreate) * [discountAutomaticBxgyUpdate](/docs/api/admin-graphql/2024-10/mutations/discountAutomaticBxgyUpdate) ## Examples