CreditMemoItemInterface attributes and implementations
CreditMemoItemInterface
provides details about items in a customer’s order history that were refunded. It has the following implementations:
Attributes
The CreditMemoItemInterface
describes a specific credit memo.
Attribute | Data type | Description |
---|---|---|
discounts |
[Discount] | Contains information about the final discount amount for the base product, including discounts on options |
id |
ID! | The unique ID of the credit memo item |
order_item |
OrderItemInterface | The order item the credit memo is applied to |
product_name |
String | The name of the base product |
product_sale_price |
Money! | The sale price for the base product, including selected options |
product_sku |
String! | The SKU of the base product |
quantity_refunded |
Float | The number of refunded items |
Implementations
BundleCreditMemoItem attributes
The BundleCreditMemoItem
object defines the following attribute:
Attribute | Data type | Description |
---|---|---|
bundle_options |
[ItemSelectedBundleOption] | A list of bundle options that are assigned to the bundle product |
ItemSelectedBundleOption attributes
The ItemSelectedBundleOption object contains a list of bundle options that are assigned to the bundle product.
Attribute | Data type | Description |
---|---|---|
id |
ID! | The unique identifier of the option |
label |
String! | The label of the option |
values |
[ItemSelectedBundleOptionValue] | A list of products that represent the values of the parent option |
ItemSelectedBundleOptionValue attributes
Attribute | Data type | Description |
---|---|---|
id |
ID! | The unique identifier of the option |
price |
Money! | The price of the child bundle product |
product_name |
String! | The name of the child bundle product |
product_sku |
String! | The SKU of the child bundle product |
quantity |
Float! | Indicates how many of this bundle product were ordered |
CreditMemoItem attributes
The CreditMemoItem
object does not introduce any additional attributes to CreditMemoItemInterface
.
DownloadableCreditMemoItem attributes
The DownloadableCreditMemoItem
object defines the following attribute:
Attribute | Data type | Description |
---|---|---|
downloadable_links |
[DownloadableItemsLinks] | A list of downloadable links that were refunded from the downloadable product |
DownloadableItemsLinks attributes
The DownloadableItemsLinks
object defines characteristics of a downloadable product.
Attribute | Data type | Description |
---|---|---|
sort_order |
Int | A number indicating the sort order |
title |
String | The display name of the link |
uid |
ID! | A string that encodes option details |
GiftCardCreditMemoItem attributes
The GiftCardCreditMemoItem
object defines the following attribute:
Attribute | Data type | Description |
---|---|---|
gift_card |
GiftCardItem | Selected gift card properties for an order item |
GiftCardItem attributes
The GiftCardItem
object contains selected buyer-entered gift card properties for an order item.
Attribute | Data type | Description |
---|---|---|
message |
String | A message provided by the sender to the recipient |
recipient_email |
String | The email provided for the recipient of a virtual gift card |
recipient_name |
String | The name provided for the recipient of a physical or virtual gift card |
sender_email |
String | The sender email provided for a virtual gift card |
sender_name |
String | The sender name provided for a physical or virtual gift card |
Example usage
The following query returns items that were refunded in order ID 000000005
. The BundleOrderItem
and DownloadableOrderItem
fragments can contain item-specific information, but the only refunded item is a configurable product.
Request:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
{
customer {
firstname
lastname
email
orders(
filter: {
number: {
match: "000000005"
}
}) {
items {
id
credit_memos {
id
items {
id
product_sku
product_name
order_item {
product_type
}
quantity_refunded
... on BundleCreditMemoItem {
bundle_options {
id
values {
id
product_name
product_sku
quantity
price {
value
currency
}
}
}
}
... on DownloadableCreditMemoItem {
downloadable_links {
uid
title
}
}
}
}
}
}
}
}
Response:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
{
"data": {
"customer": {
"firstname": "Roni",
"lastname": "Costello",
"email": "roni_cost@example.com",
"orders": {
"items": [
{
"id": "NQ==",
"credit_memos": [
{
"id": "Mg==",
"items": [
{
"id": "Mg==",
"product_sku": "WS12-XS-Orange",
"product_name": "Radiant Tee",
"order_item": {
"product_type": "configurable"
},
"quantity_refunded": 1
}
]
}
]
}
]
}
}
}
}