DiscountAutomaticBxgy object
An automatic BXGY discount.
Required access
Apps must have read_discounts access scope.
On this page
Connections
- events (
[EventConnection!](https://shopify.dev/docs/admin-api/graphql/reference/events/eventconnection))
The paginated list of events associated with the host subject.
| Argument | Description |
|---|---|
after( [String](https://shopify.dev/docs/admin-api/graphql/reference/scalar#string-2021-01)) |
Returns the elements that come after the specified cursor. |
before( [String](https://shopify.dev/docs/admin-api/graphql/reference/scalar#string-2021-01)) |
Returns the elements that come before the specified cursor. |
first( [Int](https://shopify.dev/docs/admin-api/graphql/reference/scalar#int-2021-01)) |
Returns up to the first n elements from the list. |
last( [Int](https://shopify.dev/docs/admin-api/graphql/reference/scalar#int-2021-01)) |
Returns up to the last n elements from the list. |
query( [String](https://shopify.dev/docs/admin-api/graphql/reference/scalar#string-2021-01)) |
Supported filter parameters: + comments+ created_at+ subject_type+ verbSee the detailed search syntax for more information about using filters. |
reverse( [Boolean](https://shopify.dev/docs/admin-api/graphql/reference/scalar#boolean-2021-01)) |
Reverse the order of the underlying list. Default value: false |
sortKey( [EventSortKeys](https://shopify.dev/docs/admin-api/graphql/reference/events/eventsortkeys)) |
Sort the underlying list by the given key. Default value: ID |
Fields
- asyncUsageCount (
[Int!](https://shopify.dev/docs/admin-api/graphql/reference/scalar#int-2021-01))
The number of times the discount has been used. This value is updated asynchronously and can be different than the actual usage count. - createdAt (
[DateTime!](https://shopify.dev/docs/admin-api/graphql/reference/scalar#datetime-2021-01))
The date and time when the discount was created. - customerBuys (
[DiscountCustomerBuys!](https://shopify.dev/docs/admin-api/graphql/reference/discounts-and-marketing/discountcustomerbuys))
The qualifying items and the quantity of each one that the customer has to buy to be eligible for the discount. - customerGets (
[DiscountCustomerGets!](https://shopify.dev/docs/admin-api/graphql/reference/discounts-and-marketing/discountcustomergets))
The qualifying items in an order, the quantity of each one, and the total value of the discount. - endsAt (
[DateTime](https://shopify.dev/docs/admin-api/graphql/reference/scalar#datetime-2021-01))
The date and time when the discount ends. For open-ended discounts, usenull. - startsAt (
[DateTime!](https://shopify.dev/docs/admin-api/graphql/reference/scalar#datetime-2021-01))
The date and time when the discount starts. - status (
[DiscountStatus!](https://shopify.dev/docs/admin-api/graphql/reference/discounts-and-marketing/discountstatus))
The status of the discount. - summary (
[String!](https://shopify.dev/docs/admin-api/graphql/reference/scalar#string-2021-01))
A detailed summary of the discount. - title (
[String!](https://shopify.dev/docs/admin-api/graphql/reference/scalar#string-2021-01))
The title of the discount. - usesPerOrderLimit (
[Int](https://shopify.dev/docs/admin-api/graphql/reference/scalar#int-2021-01))
The maximum number of times that the discount can be applied to an order.
Mutations for DiscountAutomaticBxgy
- discountAutomaticBxgyCreate
Creates a BXGY automatic discount. - discountAutomaticBxgyUpdate
Updates a BXGY automatic discount using its ID and input.
Implements
[HasEvents](https://shopify.dev/docs/admin-api/graphql/reference/events/hasevents)[Node](https://shopify.dev/docs/admin-api/graphql/reference/common-objects/node)
Deprecated fields
- id (
[ID!](https://shopify.dev/docs/admin-api/graphql/reference/scalar#id-2021-01)) DEPRECATED
A legacy unique identifier for the discount.
Deprecation warning
Use DiscountAutomaticNode.id instead. - usageCount (
[Int!](https://shopify.dev/docs/admin-api/graphql/reference/scalar#int-2021-01)) DEPRECATED
The number of times that the discount has been used.
Deprecation warning
UseasyncUsageCountinstead
