Updates an existing
[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.
> Note:
> To update code discounts, use the
[`discountCodeBxgyUpdate`](https://shopify.dev/docs/api/admin-graphql/latest/mutations/discountCodeBxgyUpdate)
mutation instead.
Access Scopes
Apps must have `write_discounts` access scope.
Arguments
automaticBxgyDiscount:
DiscountAutomaticBxgyInput! -
The input data used to update the automatic BXGY discount.
id:
ID! -
The ID of the automatic BXGY discount to update.
Returns
automaticDiscountNode:
DiscountAutomaticNode
The automatic discount that was updated.
userErrors:
DiscountUserError!
The list of errors that occurred from executing the mutation.