Skip to content
This repository was archived by the owner on Nov 19, 2024. It is now read-only.

Commit 70e1fca

Browse files
authored
Merge pull request #7441 from magento/kh_gift-message-order
GraphQL: Add gift message attributes to Cart
2 parents 4784a5f + e0ad03d commit 70e1fca

24 files changed

+62
-24
lines changed
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
Attribute | Data Type | Description
2+
--- | --- | ---
3+
`applied_coupon` | [`AppliedCoupon`][AppliedCoupon] | Deprecated. Use `applied_coupons` instead
4+
`applied_coupons` | [[`AppliedCoupon`]][AppliedCoupon] | An array of `AppliedCoupon` objects. Each object contains the `code` text attribute, which specifies the coupon code
5+
`applied_gift_cards` | [[`AppliedGiftCard`]][AppliedGiftCard] | An array of `AppliedGiftCard` objects. An `AppliedGiftCard` object contains the `code` text attribute, which specifies the gift card code. `applied_gift_cards` is a Commerce-only attribute, defined in the GiftCardAccountGraphQl module
6+
`applied_store_credit` | [`AppliedStoreCredit`][AppliedStoreCredit] | Contains store credit information applied to the cart. `applied_store_credit` is a Commerce-only attribute, defined in the CustomerBalanceGraphQl module
7+
`available_payment_methods` | [[AvailablePaymentMethod]][AvailablePaymentMethod] | Available payment methods
8+
`billing_address` | [BillingCartAddress][BillingCartAddress] | Contains the billing address specified in the customer's cart
9+
`email` | String | The customer's email address
10+
`gift_message` | [GiftMessage][GiftMessage] | A gift message added to the cart
11+
`id` | ID! | The ID of the cart
12+
`is_virtual` | Boolean! | Indicates whether the cart contains only virtual products
13+
`items` | [[CartItemInterface]][CartItemInterface] | Contains the items in the customer's cart
14+
`prices` | [CartPrices][CartPrices] | Contains subtotals and totals
15+
`selected_payment_method` | [SelectedPaymentMethod][SelectedPaymentMethod] | Selected payment method
16+
`shipping_addresses` | [[ShippingCartAddress]][ShippingCartAddress]! | Contains one or more shipping addresses
17+
`total_quantity` | Float! | Total Quantity of products in the cart
18+
19+
[AppliedCoupon]: {{page.baseurl}}/graphql/queries/cart.html#AppliedCoupon
20+
[AppliedGiftCard]: {{page.baseurl}}/graphql/queries/cart.html#AppliedGiftCard
21+
[AppliedStoreCredit]: {{page.baseurl}}/graphql/queries/cart.html#AppliedStoreCredit
22+
[AvailablePaymentMethod]: {{page.baseurl}}/graphql/queries/cart.html#AvailablePaymentMethod
23+
[BillingCartAddress]: {{page.baseurl}}/graphql/queries/cart.html#BillingCartAddress
24+
[CartItemInterface]: {{page.baseurl}}/graphql/queries/cart.html#CartItemInterface
25+
[CartPrices]: {{page.baseurl}}/graphql/queries/cart.html#CartPrices
26+
[GiftMessage]: {{page.baseurl}}/graphql/queries/cart.html#GiftMessage
27+
[SelectedPaymentMethod]: {{page.baseurl}}/graphql/queries/cart.html#SelectedPaymentMethod
28+
[ShippingCartAddress]: {{page.baseurl}}/graphql/queries/cart.html#ShippingCartAddress

src/guides/v2.4/graphql/mutations/add-bundle-products.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -231,7 +231,7 @@ Attribute | Data Type | Description
231231

232232
### Cart object {#CartObject}
233233

234-
{% include graphql/cart-object.md %}
234+
{% include graphql/cart-object-24.md %}
235235

236236
[Cart query output]({{page.baseurl}}/graphql/queries/cart.html#cart-output) provides more information about the `Cart` object.
237237

src/guides/v2.4/graphql/mutations/add-configurable-products.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ Attribute | Data Type | Description
128128

129129
### Cart object {#CartObject}
130130

131-
{% include graphql/cart-object.md %}
131+
{% include graphql/cart-object-24.md %}
132132

133133
[Cart query output]({{page.baseurl}}/graphql/queries/cart.html#cart-output) provides more information about the `Cart` object.
134134

src/guides/v2.4/graphql/mutations/add-downloadable-products.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -252,7 +252,7 @@ Attribute | Data Type | Description
252252

253253
### Cart object {#CartObject}
254254

255-
{% include graphql/cart-object.md %}
255+
{% include graphql/cart-object-24.md %}
256256

257257
## Errors
258258

src/guides/v2.4/graphql/mutations/add-simple-products.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -266,7 +266,7 @@ Attribute | Data Type | Description
266266

267267
### Cart object {#CartObject}
268268

269-
{% include graphql/cart-object.md %}
269+
{% include graphql/cart-object-24.md %}
270270

271271
[Cart query output]({{page.baseurl}}/graphql/queries/cart.html#cart-output) provides more information about the `Cart` object.
272272

src/guides/v2.4/graphql/mutations/add-virtual-products.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,7 @@ Attribute | Data Type | Description
124124

125125
### Cart object {#CartObject}
126126

127-
{% include graphql/cart-object.md %}
127+
{% include graphql/cart-object-24.md %}
128128

129129
[Cart query output]({{page.baseurl}}/graphql/queries/cart.html#cart-output) provides more information about the `Cart` object.
130130

src/guides/v2.4/graphql/mutations/apply-coupon.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ Attribute | Data Type | Description
111111

112112
### Cart object {#CartObject}
113113

114-
{% include graphql/cart-object.md %}
114+
{% include graphql/cart-object-24.md %}
115115

116116
[Cart query output]({{page.baseurl}}/graphql/queries/cart.html#cart-output) provides more information about the `Cart` object.
117117

src/guides/v2.4/graphql/mutations/apply-giftcard.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,6 @@ Attribute | Data Type | Description
9494

9595
### Cart object {#CartObject}
9696

97-
{% include graphql/cart-object.md %}
97+
{% include graphql/cart-object-24.md %}
9898

9999
[Cart query output]({{page.baseurl}}/graphql/queries/cart.html#cart-output) provides more information about the `Cart` object.

src/guides/v2.4/graphql/mutations/apply-store-credit.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,6 +99,6 @@ Attribute | Data Type | Description
9999

100100
### Cart object {#CartObject}
101101

102-
{% include graphql/cart-object.md %}
102+
{% include graphql/cart-object-24.md %}
103103

104104
[Cart query output]({{page.baseurl}}/graphql/queries/cart.html#cart-output) provides more information about the `Cart` object.

src/guides/v2.4/graphql/mutations/handle-payflow-pro-response.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,6 @@ The PayflowProResponseOutput contains a `Cart` object.
7878

7979
### Cart object {#CartObject}
8080

81-
{% include graphql/cart-object.md %}
81+
{% include graphql/cart-object-24.md %}
8282

8383
[Cart query output]({{page.baseurl}}/graphql/queries/cart.html#cart-output) provides more information about the `Cart` object.

src/guides/v2.4/graphql/mutations/merge-carts.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ Attribute | Data Type | Description
8080

8181
### Cart object {#CartObject}
8282

83-
{% include graphql/cart-object.md %}
83+
{% include graphql/cart-object-24.md %}
8484

8585
[Cart query output]({{page.baseurl}}/graphql/queries/cart.html#cart-output) provides more information about the `Cart` object.
8686

src/guides/v2.4/graphql/mutations/remove-coupon.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ Attribute | Data Type | Description
9696

9797
### Cart object {#CartObject}
9898

99-
{% include graphql/cart-object.md %}
99+
{% include graphql/cart-object-24.md %}
100100

101101
[Cart query output]({{page.baseurl}}/graphql/queries/cart.html#cart-output) provides more information about the `Cart` object.
102102

src/guides/v2.4/graphql/mutations/remove-giftcard.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,6 @@ Attribute | Data Type | Description
6666

6767
### Cart object {#CartObject}
6868

69-
{% include graphql/cart-object.md %}
69+
{% include graphql/cart-object-24.md %}
7070

7171
[Cart query output]({{page.baseurl}}/graphql/queries/cart.html#cart-output) provides more information about the `Cart` object.

src/guides/v2.4/graphql/mutations/remove-item.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ Attribute | Data Type | Description
9494

9595
### Cart object {#CartObject}
9696

97-
{% include graphql/cart-object.md %}
97+
{% include graphql/cart-object-24.md %}
9898

9999
## Errors
100100

src/guides/v2.4/graphql/mutations/remove-store-credit.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,6 @@ Attribute | Data Type | Description
9292

9393
### Cart object {#CartObject}
9494

95-
{% include graphql/cart-object.md %}
95+
{% include graphql/cart-object-24.md %}
9696

9797
[Cart query output]({{page.baseurl}}/graphql/queries/cart.html#cart-output) provides more information about the `Cart` object.

src/guides/v2.4/graphql/mutations/reorder-items.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,7 @@ Attribute | Data Type | Description
143143

144144
### Cart object {#CartObject}
145145

146-
{% include graphql/cart-object.md %}
146+
{% include graphql/cart-object-24.md %}
147147

148148
[Cart query output]({{page.baseurl}}/graphql/queries/cart.html#cart-output) provides more information about the `Cart` object.
149149

src/guides/v2.4/graphql/mutations/set-billing-address.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -127,6 +127,6 @@ Attribute | Data Type | Description
127127

128128
### Cart object {#CartObject}
129129

130-
{% include graphql/cart-object.md %}
130+
{% include graphql/cart-object-24.md %}
131131

132132
[Cart query output]({{page.baseurl}}/graphql/queries/cart.html#cart-output) provides more information about the `Cart` object.

src/guides/v2.4/graphql/mutations/set-guest-email.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ Attribute | Data Type | Description
6565

6666
### Cart object {#CartObject}
6767

68-
{% include graphql/cart-object.md %}
68+
{% include graphql/cart-object-24.md %}
6969

7070
[Cart query output]({{page.baseurl}}/graphql/queries/cart.html#cart-output) provides more information about the `Cart` object.
7171

src/guides/v2.4/graphql/mutations/set-payment-method.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ Attribute | Data Type | Description
105105

106106
### Cart object {#CartObject}
107107

108-
{% include graphql/cart-object.md %}
108+
{% include graphql/cart-object-24.md %}
109109

110110
[Cart query output]({{page.baseurl}}/graphql/queries/cart.html#cart-output) provides more information about the `Cart` object.
111111

src/guides/v2.4/graphql/mutations/set-shipping-address.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -134,6 +134,6 @@ Attribute | Data Type | Description
134134

135135
### Cart object {#CartObject}
136136

137-
{% include graphql/cart-object.md %}
137+
{% include graphql/cart-object-24.md %}
138138

139139
[Cart query output]({{page.baseurl}}/graphql/queries/cart.html#cart-output) provides more information about the `Cart` object.

src/guides/v2.4/graphql/mutations/set-shipping-method.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,7 @@ Attribute | Data Type | Description
113113

114114
### Cart object {#CartObject}
115115

116-
{% include graphql/cart-object.md %}
116+
{% include graphql/cart-object-24.md %}
117117

118118
[Cart query output]({{page.baseurl}}/graphql/queries/cart.html#cart-output) provides more information about the `Cart` object.
119119

src/guides/v2.4/graphql/mutations/update-cart-items.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ Attribute | Data Type | Description
102102

103103
### CartItemUpdateInput object {#CartItemUpdateInput}
104104

105-
The `CartItemUpdateInput` object must contain the following attributes:
105+
The `CartItemUpdateInput` object may contain the following attributes:
106106

107107
Attribute | Data Type | Description
108108
--- | --- | ---
@@ -126,7 +126,7 @@ Attribute | Data Type | Description
126126

127127
### Cart object {#CartObject}
128128

129-
{% include graphql/cart-object.md %}
129+
{% include graphql/cart-object-24.md %}
130130

131131
[Cart query output]({{page.baseurl}}/graphql/queries/cart.html#cart-output) provides more information about the `Cart` object.
132132

src/guides/v2.4/graphql/queries/cart.md

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -574,7 +574,7 @@ The top-level `Cart` object is listed first. All interfaces and child objects ar
574574

575575
The `Cart` object can contain the following attributes.
576576

577-
{% include graphql/cart-object.md %}
577+
{% include graphql/cart-object-24.md %}
578578

579579
### AppliedCoupon object {#AppliedCoupon}
580580

@@ -748,6 +748,16 @@ Attribute | Data Type | Description
748748
`amount` | Money! | The amount of the discount applied to the cart
749749
`label` | String! | The description of the discount
750750

751+
### GiftMessage object {#GiftMessage}
752+
753+
The `GiftMessage` object must contain the following attributes.
754+
755+
Attribute | Data Type | Description
756+
--- | --- | ---
757+
`from` | String! | Identifies the sender
758+
`message` | String! | The gift message text
759+
`to` | String! | Identifies the recipient
760+
751761
### SelectedPaymentMethod object {#SelectedPaymentMethod}
752762

753763
The `SelectedPaymentMethod` object can contain the following attributes.

src/guides/v2.4/graphql/queries/customer-cart.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,6 @@ The `customerCart` query returns the `Cart` object.
7777

7878
### Cart object {#CartObject}
7979

80-
{% include graphql/cart-object.md %}
80+
{% include graphql/cart-object-24.md %}
8181

8282
[Cart query output]({{page.baseurl}}/graphql/queries/cart.html#cart-output) provides more information about the `Cart` object.

0 commit comments

Comments
 (0)