@coveo/relay-event-types 16.2.3 → 17.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@coveo/relay-event-types",
3
- "version": "16.2.3",
3
+ "version": "17.0.1",
4
4
  "description": "Typescript types for Coveo Events, intended to be used with the Relay package.",
5
5
  "types": "./relay-event-types.d.ts",
6
6
  "author": "Coveo",
@@ -83,13 +83,32 @@ interface Product {
83
83
  }
84
84
 
85
85
  interface ProductQuantity {
86
- product: Product;
86
+ product: ProductVariant;
87
87
  /**
88
88
  * Purchased product quantity. Can be decimal. Must be greater than 0.
89
89
  */
90
90
  quantity: number;
91
91
  }
92
92
 
93
+ interface ProductVariant {
94
+ /**
95
+ * The unique identifier of the product. The value must match exactly, including case, the values of the link:{site-baseurl}/n73f0502#define-a-unique-product-identifier[product identifier] and `permanentid` fields configured in the catalog.
96
+ */
97
+ productId: string;
98
+ /**
99
+ * The product name.
100
+ */
101
+ name: string;
102
+ /**
103
+ * The product price. If the price is not available, set the value to 0.
104
+ */
105
+ price: number;
106
+ /**
107
+ * The unique identifier for the specific variant of the product, if applicable. The identifier should correspond to a variant in your Coveo catalog.
108
+ */
109
+ variantId?: string;
110
+ }
111
+
93
112
  /**
94
113
  * A support ticket.
95
114
  */
@@ -213,7 +232,7 @@ export namespace Ec {
213
232
  */
214
233
  action: "add" | "remove";
215
234
  currency: CurrencyCodeISO4217;
216
- product: Product;
235
+ product: ProductVariant;
217
236
  /**
218
237
  * Represents the change in product quantity, not the total quantity. Can be decimal. Must be greater than 0.
219
238
  */