@15gifts/sdk 0.15.0 → 0.16.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/dist/index.d.ts CHANGED
@@ -6,7 +6,7 @@ import { Client as Client$1, ClientOptions, Middleware } from 'openapi-fetch';
6
6
  * Do not make direct changes to the file.
7
7
  */
8
8
  interface paths$1 {
9
- "/api/conversation/v3": {
9
+ '/api/conversation/v3': {
10
10
  parameters: {
11
11
  query?: never;
12
12
  header?: never;
@@ -17,11 +17,9 @@ interface paths$1 {
17
17
  put?: never;
18
18
  /**
19
19
  * Generate Conversation Response
20
- * @description Generates a response based on the users last message and the conversation id.
21
- * The opening message should be the message that is displayed to the user when the engine is first opened, this is currently generated by the frontend,
22
- * this message forms part of the conversation history, not that if the conversation id is not null then the opening message is ignored.
20
+ * @description Generates a response based on the users message and the conversation id.
23
21
  */
24
- post: operations["generate_conversation_response_api_conversation_v3_post"];
22
+ post: operations['generate_conversation_response_api_conversation_v3_post'];
25
23
  delete?: never;
26
24
  options?: never;
27
25
  head?: never;
@@ -41,7 +39,7 @@ interface components {
41
39
  * @default CONVERSATION_ID
42
40
  * @constant
43
41
  */
44
- type: "CONVERSATION_ID";
42
+ type: 'CONVERSATION_ID';
45
43
  /**
46
44
  * Conversationid
47
45
  * @description Unique identifier for the conversation. This will be generated once, at the start of a conversation.
@@ -58,7 +56,7 @@ interface components {
58
56
  * @default EXIT_TO_CHAT
59
57
  * @constant
60
58
  */
61
- type: "EXIT_TO_CHAT";
59
+ type: 'EXIT_TO_CHAT';
62
60
  /**
63
61
  * Fallbackmessage
64
62
  * @description What should a client render if they do not have a native renderer for this message type?
@@ -70,7 +68,7 @@ interface components {
70
68
  */
71
69
  conversationSummary: string;
72
70
  /** @description Why have we been exited to chat? */
73
- reason: components["schemas"]["ExitToHumanReason"];
71
+ reason: components['schemas']['ExitToHumanReason'];
74
72
  };
75
73
  /**
76
74
  * AssistantExitToPhoneMessage
@@ -82,14 +80,14 @@ interface components {
82
80
  * @default EXIT_TO_PHONE
83
81
  * @constant
84
82
  */
85
- type: "EXIT_TO_PHONE";
83
+ type: 'EXIT_TO_PHONE';
86
84
  /**
87
85
  * Fallbackmessage
88
86
  * @description What should a client render if they do not have a native renderer for this message type?
89
87
  */
90
88
  fallbackMessage: string;
91
89
  /** @description Why have we been exited to phone? */
92
- reason: components["schemas"]["ExitToHumanReason"];
90
+ reason: components['schemas']['ExitToHumanReason'];
93
91
  /**
94
92
  * Linktext
95
93
  * @description The text to display to the user
@@ -111,7 +109,7 @@ interface components {
111
109
  * @default EXIT_TO_PURCHASE
112
110
  * @constant
113
111
  */
114
- type: "EXIT_TO_PURCHASE";
112
+ type: 'EXIT_TO_PURCHASE';
115
113
  /**
116
114
  * Fallbackmessage
117
115
  * @description What should a client render if they do not have a native renderer for this message type?
@@ -120,19 +118,19 @@ interface components {
120
118
  /** Recommendationidforexit */
121
119
  recommendationIdForExit?: string | null;
122
120
  /** Products */
123
- products: components["schemas"]["Product"][];
121
+ products: components['schemas']['Product'][];
124
122
  /**
125
123
  * Bundles
126
124
  * @description The bundles that were recommended
127
125
  * @default []
128
126
  */
129
- bundles: components["schemas"]["Bundle"][];
127
+ bundles: components['schemas']['Bundle'][];
130
128
  /**
131
129
  * Offers
132
130
  * @description The offers that were part of the recommendation
133
131
  * @default []
134
132
  */
135
- offers: components["schemas"]["Offer"][];
133
+ offers: components['schemas']['Offer'][];
136
134
  };
137
135
  /**
138
136
  * AssistantExitToPurchaseMessageV2
@@ -144,7 +142,7 @@ interface components {
144
142
  * @default EXIT_TO_PURCHASE_V2
145
143
  * @constant
146
144
  */
147
- type: "EXIT_TO_PURCHASE_V2";
145
+ type: 'EXIT_TO_PURCHASE_V2';
148
146
  /**
149
147
  * Fallbackmessage
150
148
  * @description What should a client render if they do not have a native renderer for this message type?
@@ -153,19 +151,19 @@ interface components {
153
151
  /** Recommendationidforexit */
154
152
  recommendationIdForExit?: string | null;
155
153
  /** Products */
156
- products: components["schemas"]["ProductV2"][];
154
+ products: components['schemas']['ProductV2'][];
157
155
  /**
158
156
  * Bundles
159
157
  * @description The bundles that were recommended
160
158
  * @default []
161
159
  */
162
- bundles: components["schemas"]["BundleV2"][];
160
+ bundles: components['schemas']['BundleV2'][];
163
161
  /**
164
162
  * Offers
165
163
  * @description The offers that were part of the recommendation
166
164
  * @default []
167
165
  */
168
- offers: components["schemas"]["OfferV2"][];
166
+ offers: components['schemas']['OfferV2'][];
169
167
  };
170
168
  /**
171
169
  * AssistantMultiSelectMessage
@@ -177,7 +175,7 @@ interface components {
177
175
  * @default MULTI_SELECT
178
176
  * @constant
179
177
  */
180
- type: "MULTI_SELECT";
178
+ type: 'MULTI_SELECT';
181
179
  /**
182
180
  * Fallbackmessage
183
181
  * @description What should a client render if they do not have a native renderer for this message type?
@@ -187,7 +185,7 @@ interface components {
187
185
  * Options
188
186
  * @description What selectable options should be available?
189
187
  */
190
- options: components["schemas"]["ConversationOption"][];
188
+ options: components['schemas']['ConversationOption'][];
191
189
  /**
192
190
  * Allowfreetext
193
191
  * @description Should we expect a free text response to this message?
@@ -204,14 +202,14 @@ interface components {
204
202
  * @default RECOMMENDATION
205
203
  * @constant
206
204
  */
207
- type: "RECOMMENDATION";
205
+ type: 'RECOMMENDATION';
208
206
  /**
209
207
  * Fallbackmessage
210
208
  * @description What should a client render if they do not have a native renderer for this message type?
211
209
  */
212
210
  fallbackMessage: string;
213
211
  /** Recommendations */
214
- recommendations: components["schemas"]["Recommendation"][];
212
+ recommendations: components['schemas']['Recommendation'][];
215
213
  };
216
214
  /**
217
215
  * AssistantRecommendationMessageV2
@@ -223,14 +221,14 @@ interface components {
223
221
  * @default RECOMMENDATION_V2
224
222
  * @constant
225
223
  */
226
- type: "RECOMMENDATION_V2";
224
+ type: 'RECOMMENDATION_V2';
227
225
  /**
228
226
  * Fallbackmessage
229
227
  * @description What should a client render if they do not have a native renderer for this message type?
230
228
  */
231
229
  fallbackMessage: string;
232
230
  /** Recommendations */
233
- recommendations: components["schemas"]["RecommendationV2"][];
231
+ recommendations: components['schemas']['RecommendationV2'][];
234
232
  };
235
233
  /**
236
234
  * AssistantSingleSelectMessage
@@ -242,7 +240,7 @@ interface components {
242
240
  * @default SINGLE_SELECT
243
241
  * @constant
244
242
  */
245
- type: "SINGLE_SELECT";
243
+ type: 'SINGLE_SELECT';
246
244
  /**
247
245
  * Fallbackmessage
248
246
  * @description What should a client render if they do not have a native renderer for this message type?
@@ -252,7 +250,7 @@ interface components {
252
250
  * Options
253
251
  * @description What selectable options should be available?
254
252
  */
255
- options: components["schemas"]["ConversationOption"][];
253
+ options: components['schemas']['ConversationOption'][];
256
254
  /**
257
255
  * Allowfreetext
258
256
  * @description Should we expect a free text response to this message?
@@ -269,7 +267,7 @@ interface components {
269
267
  * @default MESSAGE
270
268
  * @constant
271
269
  */
272
- type: "MESSAGE";
270
+ type: 'MESSAGE';
273
271
  /**
274
272
  * Message
275
273
  * @description Message for the conversation.
@@ -302,7 +300,7 @@ interface components {
302
300
  * Products
303
301
  * @description The products that make up this bundle.
304
302
  */
305
- products: components["schemas"]["Product"][];
303
+ products: components['schemas']['Product'][];
306
304
  };
307
305
  /**
308
306
  * BundleV2
@@ -327,16 +325,16 @@ interface components {
327
325
  */
328
326
  previousPrice?: string | null;
329
327
  /** @description The original price of the product or bundle, only set if it's currently discounted. */
330
- previousPriceDetails?: components["schemas"]["ProductPriceDetails"] | null;
328
+ previousPriceDetails?: components['schemas']['ProductPriceDetails'] | null;
331
329
  /**
332
330
  * Price
333
331
  * @description A fallback for headless builds that don't want to use priceDetails. Should include the same info, but as a string.
334
332
  */
335
333
  price: string;
336
334
  /** @description The current price details of the product or bundle. If the product or bundle is discounted, this will hold the discounted price. */
337
- priceDetails: components["schemas"]["ProductPriceDetails"];
335
+ priceDetails: components['schemas']['ProductPriceDetails'];
338
336
  /** Products */
339
- products: components["schemas"]["ProductV2"][];
337
+ products: components['schemas']['ProductV2'][];
340
338
  };
341
339
  /** ConversationContext */
342
340
  ConversationContext: {
@@ -396,7 +394,7 @@ interface components {
396
394
  * ExitToHumanReason
397
395
  * @enum {string}
398
396
  */
399
- ExitToHumanReason: "WANT_TO_TALK_TO_HUMAN" | "OUT_OF_SCOPE_QUESTIONS" | "NOT_BEHAVING_CORRECTLY";
397
+ ExitToHumanReason: 'WANT_TO_TALK_TO_HUMAN' | 'OUT_OF_SCOPE_QUESTIONS' | 'NOT_BEHAVING_CORRECTLY';
400
398
  /**
401
399
  * Offer
402
400
  * @description Offer details
@@ -423,6 +421,11 @@ interface components {
423
421
  * @description The offer id as defined by the customer
424
422
  */
425
423
  id: string;
424
+ /**
425
+ * Name
426
+ * @description The offer name as defined by the customer
427
+ */
428
+ name?: string | null;
426
429
  /**
427
430
  * Description
428
431
  * @description Description of the offer from the feed data
@@ -474,7 +477,7 @@ interface components {
474
477
  * @description ISO 4217 Currency code - `USD`, `GBP`, `EUR` etc
475
478
  * @enum {string}
476
479
  */
477
- currency: "AED" | "AFN" | "ALL" | "AMD" | "ANG" | "AOA" | "ARS" | "AUD" | "AWG" | "AZN" | "BAM" | "BBD" | "BDT" | "BGN" | "BHD" | "BIF" | "BMD" | "BND" | "BOB" | "BRL" | "BSD" | "BTN" | "BWP" | "BYN" | "BZD" | "CAD" | "CDF" | "CHF" | "CLP" | "CNY" | "COP" | "CRC" | "CUC" | "CUP" | "CVE" | "CZK" | "DJF" | "DKK" | "DOP" | "DZD" | "EGP" | "ERN" | "ETB" | "EUR" | "FJD" | "FKP" | "GBP" | "GEL" | "GHS" | "GIP" | "GMD" | "GNF" | "GTQ" | "GYD" | "HKD" | "HNL" | "HRK" | "HTG" | "HUF" | "IDR" | "ILS" | "INR" | "IQD" | "IRR" | "ISK" | "JMD" | "JOD" | "JPY" | "KES" | "KGS" | "KHR" | "KMF" | "KPW" | "KRW" | "KWD" | "KYD" | "KZT" | "LAK" | "LBP" | "LKR" | "LRD" | "LSL" | "LYD" | "MAD" | "MDL" | "MGA" | "MKD" | "MMK" | "MNT" | "MOP" | "MRO" | "MUR" | "MVR" | "MWK" | "MXN" | "MYR" | "MZN" | "NAD" | "NGN" | "NIO" | "NOK" | "NPR" | "NZD" | "OMR" | "PAB" | "PEN" | "PGK" | "PHP" | "PKR" | "PLN" | "PYG" | "QAR" | "RON" | "RSD" | "RUB" | "RWF" | "SAR" | "SBD" | "SCR" | "SDG" | "SEK" | "SGD" | "SHP" | "SLL" | "SOS" | "SRD" | "SSP" | "STD" | "SVC" | "SYP" | "SZL" | "THB" | "TJS" | "TMT" | "TND" | "TOP" | "TRY" | "TTD" | "TWD" | "TZS" | "UAH" | "UGX" | "USD" | "UYU" | "UZS" | "VEF" | "VND" | "VUV" | "WST" | "XAF" | "XAG" | "XAU" | "XBA" | "XBB" | "XBC" | "XBD" | "XCD" | "XDR" | "XOF" | "XPD" | "XPF" | "XPT" | "XSU" | "XTS" | "XUA" | "XXX" | "YER" | "ZAR" | "ZMW" | "ZWL";
480
+ currency: 'AED' | 'AFN' | 'ALL' | 'AMD' | 'ANG' | 'AOA' | 'ARS' | 'AUD' | 'AWG' | 'AZN' | 'BAM' | 'BBD' | 'BDT' | 'BGN' | 'BHD' | 'BIF' | 'BMD' | 'BND' | 'BOB' | 'BRL' | 'BSD' | 'BTN' | 'BWP' | 'BYN' | 'BZD' | 'CAD' | 'CDF' | 'CHF' | 'CLP' | 'CNY' | 'COP' | 'CRC' | 'CUC' | 'CUP' | 'CVE' | 'CZK' | 'DJF' | 'DKK' | 'DOP' | 'DZD' | 'EGP' | 'ERN' | 'ETB' | 'EUR' | 'FJD' | 'FKP' | 'GBP' | 'GEL' | 'GHS' | 'GIP' | 'GMD' | 'GNF' | 'GTQ' | 'GYD' | 'HKD' | 'HNL' | 'HRK' | 'HTG' | 'HUF' | 'IDR' | 'ILS' | 'INR' | 'IQD' | 'IRR' | 'ISK' | 'JMD' | 'JOD' | 'JPY' | 'KES' | 'KGS' | 'KHR' | 'KMF' | 'KPW' | 'KRW' | 'KWD' | 'KYD' | 'KZT' | 'LAK' | 'LBP' | 'LKR' | 'LRD' | 'LSL' | 'LYD' | 'MAD' | 'MDL' | 'MGA' | 'MKD' | 'MMK' | 'MNT' | 'MOP' | 'MRO' | 'MUR' | 'MVR' | 'MWK' | 'MXN' | 'MYR' | 'MZN' | 'NAD' | 'NGN' | 'NIO' | 'NOK' | 'NPR' | 'NZD' | 'OMR' | 'PAB' | 'PEN' | 'PGK' | 'PHP' | 'PKR' | 'PLN' | 'PYG' | 'QAR' | 'RON' | 'RSD' | 'RUB' | 'RWF' | 'SAR' | 'SBD' | 'SCR' | 'SDG' | 'SEK' | 'SGD' | 'SHP' | 'SLL' | 'SOS' | 'SRD' | 'SSP' | 'STD' | 'SVC' | 'SYP' | 'SZL' | 'THB' | 'TJS' | 'TMT' | 'TND' | 'TOP' | 'TRY' | 'TTD' | 'TWD' | 'TZS' | 'UAH' | 'UGX' | 'USD' | 'UYU' | 'UZS' | 'VEF' | 'VND' | 'VUV' | 'WST' | 'XAF' | 'XAG' | 'XAU' | 'XBA' | 'XBB' | 'XBC' | 'XBD' | 'XCD' | 'XDR' | 'XOF' | 'XPD' | 'XPF' | 'XPT' | 'XSU' | 'XTS' | 'XUA' | 'XXX' | 'YER' | 'ZAR' | 'ZMW' | 'ZWL';
478
481
  /**
479
482
  * Suffix
480
483
  * @description e.g `/mo` or `per month for 12 months` or `including vat`
@@ -504,14 +507,14 @@ interface components {
504
507
  */
505
508
  previousPrice?: string | null;
506
509
  /** @description The original price of the product or bundle, only set if it's currently discounted. */
507
- previousPriceDetails?: components["schemas"]["ProductPriceDetails"] | null;
510
+ previousPriceDetails?: components['schemas']['ProductPriceDetails'] | null;
508
511
  /**
509
512
  * Price
510
513
  * @description A fallback for headless builds that don't want to use priceDetails. Should include the same info, but as a string.
511
514
  */
512
515
  price?: string | null;
513
516
  /** @description The current price details of the product or bundle. If the product or bundle is discounted, this will hold the discounted price. */
514
- priceDetails?: components["schemas"]["ProductPriceDetails"] | null;
517
+ priceDetails?: components['schemas']['ProductPriceDetails'] | null;
515
518
  /**
516
519
  * Category
517
520
  * @description For example, `tv`, `internet`, `phone`. It can be used to show an icon in the UI.
@@ -521,7 +524,7 @@ interface components {
521
524
  * Extras
522
525
  * @description Extras are additional products that are bundled with the main product.
523
526
  */
524
- extras?: components["schemas"]["ProductExtra"][] | null;
527
+ extras?: components['schemas']['ProductExtra'][] | null;
525
528
  /**
526
529
  * Quantity
527
530
  * @description How many of this product are there?
@@ -542,19 +545,19 @@ interface components {
542
545
  * Products
543
546
  * @description The products that make up this recommendation
544
547
  */
545
- products: components["schemas"]["Product"][];
548
+ products: components['schemas']['Product'][];
546
549
  /**
547
550
  * Bundles
548
551
  * @description The bundles that make up this recommendation
549
552
  * @default []
550
553
  */
551
- bundles: components["schemas"]["Bundle"][];
554
+ bundles: components['schemas']['Bundle'][];
552
555
  /**
553
556
  * Offers
554
557
  * @description The offers that make up this recommendation
555
558
  * @default []
556
559
  */
557
- offers: components["schemas"]["Offer"][];
560
+ offers: components['schemas']['Offer'][];
558
561
  };
559
562
  /**
560
563
  * RecommendationV2
@@ -567,19 +570,19 @@ interface components {
567
570
  * Products
568
571
  * @description The products that make up this recommendation
569
572
  */
570
- products: components["schemas"]["ProductV2"][];
573
+ products: components['schemas']['ProductV2'][];
571
574
  /**
572
575
  * Bundles
573
576
  * @description The bundles that make up this recommendation
574
577
  * @default []
575
578
  */
576
- bundles: components["schemas"]["BundleV2"][];
579
+ bundles: components['schemas']['BundleV2'][];
577
580
  /**
578
581
  * Offers
579
582
  * @description The offers that make up this recommendation
580
583
  * @default []
581
584
  */
582
- offers: components["schemas"]["OfferV2"][];
585
+ offers: components['schemas']['OfferV2'][];
583
586
  /**
584
587
  * Importantinformation
585
588
  * @description Information to include at the bottom of the recommendation card, e.g. CPI price data
@@ -596,12 +599,13 @@ interface components {
596
599
  * @default MULTI_SELECT
597
600
  * @constant
598
601
  */
599
- type: "MULTI_SELECT";
602
+ type: 'MULTI_SELECT';
600
603
  /**
601
604
  * Conversationid
605
+ * Format: uuid
602
606
  * @description The conversation id
603
607
  */
604
- conversationId?: string | null;
608
+ conversationId: string;
605
609
  /**
606
610
  * Usermessage
607
611
  * @description The user message
@@ -623,12 +627,13 @@ interface components {
623
627
  * @default SINGLE_SELECT
624
628
  * @constant
625
629
  */
626
- type: "SINGLE_SELECT";
630
+ type: 'SINGLE_SELECT';
627
631
  /**
628
632
  * Conversationid
633
+ * Format: uuid
629
634
  * @description The conversation id
630
635
  */
631
- conversationId?: string | null;
636
+ conversationId: string;
632
637
  /**
633
638
  * Usermessage
634
639
  * @description The user message
@@ -638,7 +643,7 @@ interface components {
638
643
  * Option
639
644
  * @description Which select option was picked?
640
645
  */
641
- option: string;
646
+ option?: string | null;
642
647
  };
643
648
  /**
644
649
  * UserStartConversationMessage
@@ -650,9 +655,9 @@ interface components {
650
655
  * @default START_CONVERSATION
651
656
  * @constant
652
657
  */
653
- type: "START_CONVERSATION";
658
+ type: 'START_CONVERSATION';
654
659
  /** @description Context information we'll be getting with the request */
655
- conversationContext: components["schemas"]["ConversationContext"];
660
+ conversationContext: components['schemas']['ConversationContext'];
656
661
  };
657
662
  /**
658
663
  * UserTextMessage
@@ -664,12 +669,13 @@ interface components {
664
669
  * @default MESSAGE
665
670
  * @constant
666
671
  */
667
- type: "MESSAGE";
672
+ type: 'MESSAGE';
668
673
  /**
669
674
  * Conversationid
675
+ * Format: uuid
670
676
  * @description The conversation id
671
677
  */
672
- conversationId?: string | null;
678
+ conversationId: string;
673
679
  /**
674
680
  * Usermessage
675
681
  * @description The user message
@@ -688,23 +694,23 @@ interface operations {
688
694
  parameters: {
689
695
  query?: never;
690
696
  header?: {
691
- "user-agent"?: string;
697
+ 'user-agent'?: string;
692
698
  /**
693
699
  * @description Comma-separated list of feature flags (flags might require elevated permissions)
694
700
  * @example debug,rec-message-v2
695
701
  */
696
- "x-feature-flags"?: string | null;
702
+ 'x-feature-flags'?: string | null;
697
703
  /**
698
704
  * @description The version of the SDK version that is being used
699
705
  * @example 1.0.0
700
706
  */
701
- "x-sdk-version"?: string | null;
707
+ 'x-sdk-version'?: string | null;
702
708
  /** @description A UUID marking the unique page view ID, if this request came from a web browser */
703
- "x-pageview-id"?: string | null;
709
+ 'x-pageview-id'?: string | null;
704
710
  /** @description The URL of the page that is sending requests to the conversation API */
705
- "x-page-url"?: string | null;
711
+ 'x-page-url'?: string | null;
706
712
  /** @description The user id assigned to the user by a web analytics platform, for example our customers adobe analytics. */
707
- "x-web-analytics-platform-user-id"?: string | null;
713
+ 'x-web-analytics-platform-user-id'?: string | null;
708
714
  };
709
715
  path?: never;
710
716
  cookie?: {
@@ -713,7 +719,7 @@ interface operations {
713
719
  };
714
720
  requestBody: {
715
721
  content: {
716
- "application/json": components["schemas"]["UserTextMessage"] | components["schemas"]["UserSingleSelectMessage"] | components["schemas"]["UserMultiSelectMessage"] | components["schemas"]["UserStartConversationMessage"];
722
+ 'application/json': components['schemas']['UserTextMessage'] | components['schemas']['UserSingleSelectMessage'] | components['schemas']['UserMultiSelectMessage'] | components['schemas']['UserStartConversationMessage'];
717
723
  };
718
724
  };
719
725
  responses: {
@@ -723,7 +729,7 @@ interface operations {
723
729
  [name: string]: unknown;
724
730
  };
725
731
  content: {
726
- "application/json": (components["schemas"]["AssistantTextMessage"] | components["schemas"]["AssistantSingleSelectMessage"] | components["schemas"]["AssistantMultiSelectMessage"] | components["schemas"]["AssistantExitToChatMessage"] | components["schemas"]["AssistantExitToPhoneMessage"] | components["schemas"]["AssistantRecommendationMessage"] | components["schemas"]["AssistantRecommendationMessageV2"] | components["schemas"]["AssistantConversationIdMessage"] | components["schemas"]["AssistantExitToPurchaseMessage"] | components["schemas"]["AssistantExitToPurchaseMessageV2"])[];
732
+ 'application/json': (components['schemas']['AssistantTextMessage'] | components['schemas']['AssistantSingleSelectMessage'] | components['schemas']['AssistantMultiSelectMessage'] | components['schemas']['AssistantExitToChatMessage'] | components['schemas']['AssistantExitToPhoneMessage'] | components['schemas']['AssistantRecommendationMessage'] | components['schemas']['AssistantRecommendationMessageV2'] | components['schemas']['AssistantConversationIdMessage'] | components['schemas']['AssistantExitToPurchaseMessage'] | components['schemas']['AssistantExitToPurchaseMessageV2'])[];
727
733
  };
728
734
  };
729
735
  /** @description The user is not authorized to access the requested data */
@@ -732,7 +738,7 @@ interface operations {
732
738
  [name: string]: unknown;
733
739
  };
734
740
  content: {
735
- "application/json": unknown;
741
+ 'application/json': unknown;
736
742
  };
737
743
  };
738
744
  /** @description The user does not have permission to access the requested data */
@@ -741,7 +747,7 @@ interface operations {
741
747
  [name: string]: unknown;
742
748
  };
743
749
  content: {
744
- "application/json": unknown;
750
+ 'application/json': unknown;
745
751
  };
746
752
  };
747
753
  /** @description The customer config was not found */
@@ -750,7 +756,7 @@ interface operations {
750
756
  [name: string]: unknown;
751
757
  };
752
758
  content: {
753
- "application/json": unknown;
759
+ 'application/json': unknown;
754
760
  };
755
761
  };
756
762
  /** @description Validation Error */
@@ -759,7 +765,7 @@ interface operations {
759
765
  [name: string]: unknown;
760
766
  };
761
767
  content: {
762
- "application/json": unknown;
768
+ 'application/json': unknown;
763
769
  };
764
770
  };
765
771
  };
@@ -771,7 +777,7 @@ interface operations {
771
777
  * Do not make direct changes to the file.
772
778
  */
773
779
  interface paths {
774
- "/api/tracking/identity/v2": {
780
+ '/api/tracking/identity/v2': {
775
781
  parameters: {
776
782
  query?: never;
777
783
  header?: never;
@@ -792,19 +798,19 @@ interface paths {
792
798
  * @description A 36 character hash, 5 segments, separated by dashes that uniquely identifies a page view (page-shown event)
793
799
  * @example 1a1a1a1a-1a1a-1a1a-1a1a-1a1a1a1a1a1a
794
800
  */
795
- "x-page-view-id"?: string;
801
+ 'x-page-view-id'?: string;
796
802
  /** @description Web Analytics Platform User ID */
797
- "x-web-analytics-platform-user-id"?: string;
803
+ 'x-web-analytics-platform-user-id'?: string;
798
804
  /**
799
805
  * @description The version of the frontend application that is making the request
800
806
  * @example 1.0.0
801
807
  */
802
- "x-frontend-version"?: string;
808
+ 'x-frontend-version'?: string;
803
809
  /**
804
810
  * @description The version of the SDK that is making the request
805
811
  * @example 1.0.0
806
812
  */
807
- "x-sdk-version"?: string;
813
+ 'x-sdk-version'?: string;
808
814
  };
809
815
  path?: never;
810
816
  cookie?: never;
@@ -812,7 +818,7 @@ interface paths {
812
818
  /** @description Generate tracking identifiers for a user */
813
819
  requestBody: {
814
820
  content: {
815
- "application/json": {
821
+ 'application/json': {
816
822
  /** @description The customer that the event occurred on */
817
823
  customerId: string;
818
824
  /**
@@ -839,7 +845,7 @@ interface paths {
839
845
  [name: string]: unknown;
840
846
  };
841
847
  content: {
842
- "application/json": {
848
+ 'application/json': {
843
849
  /**
844
850
  * @description A 36 character hash, 5 segments, separated by dashes that uniquely identifies a page view (page-shown event)
845
851
  * @example 1a1a1a1a-1a1a-1a1a-1a1a-1a1a1a1a1a1a
@@ -868,409 +874,7 @@ interface paths {
868
874
  patch?: never;
869
875
  trace?: never;
870
876
  };
871
- "/api/tracking/sales/v2": {
872
- parameters: {
873
- query?: never;
874
- header?: never;
875
- path?: never;
876
- cookie?: never;
877
- };
878
- get?: never;
879
- put?: never;
880
- /**
881
- * Submit sales tracking data
882
- * @description Submit sales tracking data
883
- */
884
- post: {
885
- parameters: {
886
- query?: never;
887
- header?: never;
888
- path?: never;
889
- cookie?: never;
890
- };
891
- requestBody?: {
892
- content: {
893
- "application/json": {
894
- /** @description A 36 character alphanumeric hash that uniquely identifies a user.
895
- *
896
- *
897
- * This should match the UUID V4 as specified in RFC 9652:
898
- * https://datatracker.ietf.org/doc/html/rfc9562#name-uuid-version-4
899
- *
900
- * e.g f81d4fae-7dec-41d0-a765-00a0c91e6bf6 */
901
- userId?: string;
902
- /** @description A timestamp describing the time the event occurred. This should conform to ISO 8601 standards and be in UTC. Example: "2024-07-17T10:11:16.591Z" */
903
- eventAt?: string;
904
- /** @description The page url at the time the event is fired */
905
- url?: string;
906
- /** @description What web browser the user is using e.g. chrome/firefox/safari etc. */
907
- browser?: string;
908
- /** @description The customer that the event occurred on */
909
- customerId: string;
910
- /** @description The user agent string e.g. "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.124 Safari/537.36" */
911
- userAgent?: string;
912
- /** @description A 36 character alphanumeric hash that uniquely identifies a tracking event
913
- *
914
- * This should match the UUID V4 as specified in RFC 9652:
915
- * https://datatracker.ietf.org/doc/html/rfc9562#name-uuid-version-4
916
- *
917
- * e.g f81d4fae-7dec-41d0-a765-00a0c91e6bf6 */
918
- eventId?: string;
919
- /**
920
- * @description The name of an event
921
- * @enum {string}
922
- */
923
- eventName?: "sale-completed";
924
- /** @description A 36 character alphanumeric hash that uniquely identifies a page view (page-shown event)
925
- *
926
- * This should match the UUID V4 as specified in RFC 9652:
927
- * https://datatracker.ietf.org/doc/html/rfc9562#name-uuid-version-4
928
- *
929
- * e.g f81d4fae-7dec-41d0-a765-00a0c91e6bf6 */
930
- pageviewId?: string | null;
931
- /** @description A unique user id native to our customers web analytics platforms (adobe, google analytics etc). Helps us & our customers align our data with what customers see in their platforms. */
932
- webAnalyticsPlatformUserId?: string | null;
933
- /** @description A 36 character alphanumeric hash that uniquely identifies a session.
934
- *
935
- *
936
- * This should match the UUID V4 as specified in RFC 9652:
937
- * https://datatracker.ietf.org/doc/html/rfc9562#name-uuid-version-4
938
- *
939
- * e.g f81d4fae-7dec-41d0-a765-00a0c91e6bf6
940
- * */
941
- browserSessionId?: string | null;
942
- /** @description The device screen width in pixels - window.screen.width in JS. This is a user level property that should never change. */
943
- screenWidth?: number;
944
- /** @description The device screen height in pixels - window.screen.height in JS. This is a user level property that should never change. */
945
- screenHeight?: number;
946
- /**
947
- * @description The size of the device's screen, based off the actual user experience it will generate, assuming the browser window takes up the whole screen.
948
- *
949
- * Based off https://15gifts.atlassian.net/wiki/spaces/AI/pages/3981443139/Breakpoints+for+mobile+desktop
950
- *
951
- * screen_width <= 480px = 'mobile'
952
- * screen_width > 480px = 'large'
953
- * @enum {string}
954
- */
955
- screenSize?: "large" | "mobile";
956
- /** @description The ID for the sale, a unique, non-empty value we can correlate with customer records. */
957
- saleId: string;
958
- /**
959
- * @description The type of user, for example, existing or prospect.
960
- * @enum {string}
961
- */
962
- userType: "existing" | "prospect";
963
- /**
964
- * @description A code that represents what currency the product price is listed in e.g. USD, GBP. This should match the ISO 4217 standard - see https://www.iban.com/currency-codes.
965
- * @enum {string}
966
- */
967
- currencyCode?: "AUD" | "CAD" | "EUR" | "GBP" | "MXN" | "USD";
968
- /** @description The full basket value of the sale, inclusive of any offers. */
969
- saleTotalValue?: number;
970
- /** @description A list containing separate line items for each product sold. */
971
- productsSold: {
972
- /** @description The ID or SKU of a product that is provided by the customer */
973
- siteProductId: string;
974
- /** @description The name of the product */
975
- siteProductName: string;
976
- /** @description The category of products the product belongs to. */
977
- siteProductType: string;
978
- /** @description The upfront price the user has to pay for the product. */
979
- productPriceUpfront: number;
980
- }[];
981
- /**
982
- * @description The language of the part of the site the sales data is coming from in ISO 639-1 format e.g. 'en', 'es' etc.
983
- * @enum {string}
984
- */
985
- language?: "de" | "en" | "es" | "fr" | "it";
986
- /**
987
- * @description The name of the system/service that the event originates from
988
- * @enum {string}
989
- */
990
- service?: "frontend" | "salesTrackingApi";
991
- /** @description A JSON object containing the different versions of services directly used by the service that tracks an event. The version of the service that is firing any tracking event should ALWAYS be included, for example if the conversation_api is firing an event, service_versions should include conversation_api_version. It should also ideally include the version numbers of any other services used in the generation of the event that is being tracked. */
992
- serviceVersions?: {
993
- /** @description The version number for the frontend service */
994
- frontendVersion?: string | null;
995
- /** @description The version number for the frontend api service */
996
- frontendApiVersion?: string | null;
997
- /** @description The version number for the conversation api service */
998
- conversationApiVersion?: string | null;
999
- /** @description The version number for the customer configuration service */
1000
- customerConfigurationVersion?: string | null;
1001
- /** @description The version number for the client library our customers are using */
1002
- sdkVersion?: string | null;
1003
- /** @description The version number for the product configuration data */
1004
- productConfigurationVersion?: string | null;
1005
- /** @description The version number for the sales tracking api service. *in the short term this is technically just the frontend so will match that */
1006
- salesTrackingApiVersion?: string | null;
1007
- /** @description The version number for the recommender service */
1008
- recommenderVersion?: string | null;
1009
- };
1010
- /**
1011
- * @description The environment the event originated from (production/development/testing/staging/local/uat/ephemeral)
1012
- * @enum {string}
1013
- */
1014
- environment?: "development" | "ephemeral" | "local" | "production" | "staging" | "test" | "uat";
1015
- /** @description A JWT used to identify the user in the system, can be obtained from the identity endpoint */
1016
- identityToken: string;
1017
- } | {
1018
- /**
1019
- * @description The customer that the event occurred on
1020
- * @enum {string}
1021
- */
1022
- customerId: "aidem";
1023
- /** @description The timestamp describing the time the event occurred. This should conform to ISO 8601 standards and be in UTC */
1024
- eventAt?: string;
1025
- /** @description A JWT used to identify the user in the system, can be obtained from the identity endpoint */
1026
- identityToken: string;
1027
- /** @description The ID for the sale, a unique value we can correlate with customer records. */
1028
- saleId: string;
1029
- /**
1030
- * @description The type of user, for example, existing or prospect.
1031
- * @enum {string}
1032
- */
1033
- userType: "existing" | "prospect";
1034
- /** @description The browser the user is using, e.g. Chrome, Firefox, Safari, etc. */
1035
- browser?: string;
1036
- /** @description The user agent string e.g. "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.124 Safari/537.36" */
1037
- userAgent?: string;
1038
- /** @description The device screen width in pixels - window.screen.width in JS. This is a user level property that should never change. */
1039
- screenWidth?: number;
1040
- /** @description The device screen height in pixels - window.screen.height in JS. This is a user level property that should never change. */
1041
- screenHeight?: number;
1042
- /**
1043
- * @description The size of the device's screen, based off the actual user experience it will generate, assuming the browser window takes up the whole screen.
1044
- *
1045
- * Based off https://15gifts.atlassian.net/wiki/spaces/AI/pages/3981443139/Breakpoints+for+mobile+desktop
1046
- *
1047
- * screen_width <= 480px = 'mobile'
1048
- * screen_width > 480px = 'large'
1049
- * @enum {string}
1050
- */
1051
- screenSize?: "mobile" | "large";
1052
- /** @description "A code that represents what currency the product price is listed in e.g. USD, GBP. This should match the ISO 4217 standard - see https://www.iban.com/currency-codes. */
1053
- currencyCode?: string;
1054
- /** @description The host/domain of the URL at the time the event is fired */
1055
- siteHost: string;
1056
- /** @description The path of the URL (including an initial `/`) at the time the event is fired */
1057
- sitePath?: string;
1058
- /** @description The query string of the URL (including an initial `?`) at the time the event is fired */
1059
- siteQueryString?: string;
1060
- /** @description The language of the part of the site the sales data is coming from in ISO 639-1 format e.g. 'en-us', 'es-us' etc. */
1061
- language?: string;
1062
- /** @description The recurring payment due per payment period */
1063
- priceRecurring: number;
1064
- /** @description An ISO-8601 duration that represents the period of time that the priceRecurring payment recurs over */
1065
- priceRecurringPeriod: string;
1066
- /** @description The upfront price the user has to pay for the product. */
1067
- priceUpfront?: number;
1068
- /** @description The full basket value of the sale, inclusive of any offers. */
1069
- totalValueOfSale?: number;
1070
- /** @description The taxes the user has to pay relating to the priceUpfront of the product(s) */
1071
- totalUpfrontTax?: number;
1072
- /** @description The taxes the user has to pay relating to the priceRecurring of the product(s), due per payment period */
1073
- totalRecurringTax?: number;
1074
- totalTaxOnSale?: number;
1075
- /** @description A list containing separate line items for each product sold. */
1076
- productsSold: {
1077
- /** @description The ID or SKU of a product that is provided by the customer */
1078
- siteProductId?: string;
1079
- /** @description The name of the product */
1080
- siteProductName: string;
1081
- /** @description The category of products the product belongs to. */
1082
- siteProductType: string;
1083
- /** @description An ISO-8601 duration that represents the contract length */
1084
- productContractLength: string;
1085
- /** @description An integer representing how many of this particular product the user is purchasing */
1086
- quantity: number;
1087
- /** @description The upfront price the user has to pay for the product. */
1088
- productPriceUpfront: number;
1089
- /** @description The recurring payment per payment period for the product */
1090
- productPricePerPeriod: number;
1091
- /** @description An ISO-8601 duration that represents the period of time that the productPricePerPeriod payment recurs over */
1092
- productRecurringPaymentPeriod: string;
1093
- /** @description The ID or SKU of a bundle that the product (and other products being purchased at the same time) are part of */
1094
- bundleId?: string;
1095
- }[];
1096
- } | {
1097
- /**
1098
- * @description The customer that the event occurred on
1099
- * @enum {string}
1100
- */
1101
- customerId: "spectrum-us-media-consumer-en";
1102
- /** @description The timestamp describing the time the event occurred. This should conform to ISO 8601 standards and be in UTC */
1103
- eventAt?: string;
1104
- /** @description A JWT used to identify the user in the system, can be obtained from the identity endpoint */
1105
- identityToken: string;
1106
- /** @description The ID for the sale, a unique value we can correlate with customer records. */
1107
- saleId: string;
1108
- /**
1109
- * @description The type of user, for example, existing or prospect.
1110
- * @enum {string}
1111
- */
1112
- userType: "existing" | "prospect";
1113
- /** @description The browser the user is using, e.g. Chrome, Firefox, Safari, etc. */
1114
- browser?: string;
1115
- /** @description The user agent string e.g. "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.124 Safari/537.36" */
1116
- userAgent?: string;
1117
- /** @description The device screen width in pixels - window.screen.width in JS. This is a user level property that should never change. */
1118
- screenWidth?: number;
1119
- /** @description The device screen height in pixels - window.screen.height in JS. This is a user level property that should never change. */
1120
- screenHeight?: number;
1121
- /**
1122
- * @description The size of the device's screen, based off the actual user experience it will generate, assuming the browser window takes up the whole screen.
1123
- *
1124
- * Based off https://15gifts.atlassian.net/wiki/spaces/AI/pages/3981443139/Breakpoints+for+mobile+desktop
1125
- *
1126
- * screen_width <= 480px = 'mobile'
1127
- * screen_width > 480px = 'large'
1128
- * @enum {string}
1129
- */
1130
- screenSize?: "mobile" | "large";
1131
- /** @description "A code that represents what currency the product price is listed in e.g. USD, GBP. This should match the ISO 4217 standard - see https://www.iban.com/currency-codes. */
1132
- currencyCode?: string;
1133
- /** @description The host/domain of the URL at the time the event is fired */
1134
- siteHost: string;
1135
- /** @description The path of the URL (including an initial `/`) at the time the event is fired */
1136
- sitePath?: string;
1137
- /** @description The query string of the URL (including an initial `?`) at the time the event is fired */
1138
- siteQueryString?: string;
1139
- /** @description The language of the part of the site the sales data is coming from in ISO 639-1 format e.g. 'en-us', 'es-us' etc. */
1140
- language?: string;
1141
- /** @description The recurring payment due per payment period */
1142
- priceRecurring: number;
1143
- /** @description An ISO-8601 duration that represents the period of time that the priceRecurring payment recurs over */
1144
- priceRecurringPeriod: string;
1145
- /** @description The upfront price the user has to pay for the product. */
1146
- priceUpfront?: number;
1147
- /** @description The full basket value of the sale, inclusive of any offers. */
1148
- totalValueOfSale?: number;
1149
- /** @description The taxes the user has to pay relating to the priceUpfront of the product(s) */
1150
- totalUpfrontTax?: number;
1151
- /** @description The taxes the user has to pay relating to the priceRecurring of the product(s), due per payment period */
1152
- totalRecurringTax?: number;
1153
- totalTaxOnSale?: number;
1154
- /** @description A list containing separate line items for each product sold. */
1155
- productsSold: {
1156
- /** @description The ID or SKU of a product that is provided by the customer */
1157
- siteProductId?: string;
1158
- /** @description The name of the product */
1159
- siteProductName: string;
1160
- /** @description The category of products the product belongs to. */
1161
- siteProductType: string;
1162
- /** @description An ISO-8601 duration that represents the contract length */
1163
- productContractLength: string;
1164
- /** @description An integer representing how many of this particular product the user is purchasing */
1165
- quantity: number;
1166
- /** @description The upfront price the user has to pay for the product. */
1167
- productPriceUpfront: number;
1168
- /** @description The recurring payment per payment period for the product */
1169
- productPricePerPeriod: number;
1170
- /** @description An ISO-8601 duration that represents the period of time that the productPricePerPeriod payment recurs over */
1171
- productRecurringPaymentPeriod: string;
1172
- /** @description The ID or SKU of a bundle that the product (and other products being purchased at the same time) are part of */
1173
- bundleId?: string;
1174
- }[];
1175
- };
1176
- };
1177
- };
1178
- responses: {
1179
- /** @description Successful response */
1180
- 204: {
1181
- headers: {
1182
- [name: string]: unknown;
1183
- };
1184
- content?: never;
1185
- };
1186
- /** @description Error response */
1187
- 400: {
1188
- headers: {
1189
- [name: string]: unknown;
1190
- };
1191
- content: {
1192
- "application/json": {
1193
- /** @description The error message */
1194
- message?: string;
1195
- };
1196
- };
1197
- };
1198
- /** @description Error response */
1199
- 401: {
1200
- headers: {
1201
- [name: string]: unknown;
1202
- };
1203
- content: {
1204
- "application/json": {
1205
- /** @description The error message */
1206
- message?: string;
1207
- };
1208
- };
1209
- };
1210
- /** @description Error response */
1211
- 403: {
1212
- headers: {
1213
- [name: string]: unknown;
1214
- };
1215
- content: {
1216
- "application/json": {
1217
- /** @description The error message */
1218
- message?: string;
1219
- };
1220
- };
1221
- };
1222
- /** @description Error response */
1223
- 404: {
1224
- headers: {
1225
- [name: string]: unknown;
1226
- };
1227
- content: {
1228
- "application/json": {
1229
- /** @description The error message */
1230
- message?: string;
1231
- };
1232
- };
1233
- };
1234
- /** @description Default Response */
1235
- 422: {
1236
- headers: {
1237
- [name: string]: unknown;
1238
- };
1239
- content: {
1240
- "application/json": {
1241
- /** @description The path to the field that caused the error */
1242
- instancePath?: string;
1243
- /** @description The error message */
1244
- message?: string;
1245
- /** @description The path to the schema that caused the error */
1246
- schemaPath?: string;
1247
- /** @description The keyword that caused the error */
1248
- keyword?: string;
1249
- params?: {
1250
- /** @description The name of the missing property */
1251
- missingProperty?: string;
1252
- /** @description The pattern that caused the error */
1253
- pattern?: string;
1254
- /** @description The name of the additional property that caused the error */
1255
- additionalProperty?: string;
1256
- /** @description The comparison that caused the error */
1257
- comparison?: string;
1258
- };
1259
- }[] | {
1260
- /** @description The error message */
1261
- message?: string;
1262
- };
1263
- };
1264
- };
1265
- };
1266
- };
1267
- delete?: never;
1268
- options?: never;
1269
- head?: never;
1270
- patch?: never;
1271
- trace?: never;
1272
- };
1273
- "/api/tracking/user/v2": {
877
+ '/api/tracking/user/v2': {
1274
878
  parameters: {
1275
879
  query?: never;
1276
880
  header?: never;
@@ -1303,7 +907,7 @@ interface paths {
1303
907
  * "url": "https://www.example.com/telco/",
1304
908
  * "userAgent": "Mozilla/5.0 (Linux; Android 11; Pixel 5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.210 Mobile Safari/537.36"
1305
909
  * } */
1306
- "application/json": {
910
+ 'application/json': {
1307
911
  additionalProperties?: {
1308
912
  /** @description A 36 character alphanumeric hash that uniquely identifies a user.
1309
913
  *
@@ -1384,88 +988,10 @@ interface paths {
1384
988
  ip_address_hashed?: string;
1385
989
  /** @description Describes the reason the tool ui was closed. When the value is 'customer_triggered' it's because it's been programmatically closed by the customer (by running window.axiom.integrations.hide() or window.axiom.integrations.minimise()). When it's 'user_close_click' it's because the actual end user has closed it manually by clicking. */
1386
990
  tool_ui_closed_reason?: string;
1387
- /** @description The turn number in the conversation. This links each user message to a corresponding assistant response. If there is an opening message from the assistant, this would have a message_turn of 1. Then the first message a user sends would have a message_turn of 2. The first actual response the assistant sends would have a message_turn of 2.
1388
- *
1389
- * All message_turn values except for 1 (the opening message if it exists) should be expected to come in pairs.
1390
- *
1391
- * Here's an example sequence of message_turn values where the user is provided with an opening message at the beginning of a conversation, and then sends 5 separate messages themselves with 5 corresponding assistant responses:
1392
- *
1393
- * 1,2,2,3,3,4,4,5,5,6,6
1394
- * */
1395
- conversation_turn_num?: number;
1396
- /** @description An alphanumeric hash that uniquely identifies a turn in a conversation
1397
- *
1398
- * This should match the UUID V4 as specified in RFC 9652:
1399
- * https://datatracker.ietf.org/doc/html/rfc9562#name-uuid-version-4
1400
- *
1401
- * e.g f81d4fae-7dec-41d0-a765-00a0c91e6bf6 */
1402
- conversation_turn_id?: string;
1403
- /** @description Describes the type of message e.g. text, single select, multi select etc */
1404
- message_type?: string;
1405
- /** @description The text that was sent by either the user or the assistant. For messages where message_type is not 'text', this should be a string representation of the more complex data type. */
1406
- message_text?: string;
1407
- /** @description List of objects that represents the options for single & multiselect questions. */
1408
- message_select_options?: unknown[];
1409
- /** @description true or false depending on whether the users message caused the assistant to provide a fallback guardrail response.
1410
- *
1411
- * This happens for most guardrails, but in the case of pii-masking it will be false, because it strips the PII from the conversation history and continues the conversation as normal.
1412
- *
1413
- * To check whether the guardrail was triggered, use the is_guardrail_triggered property. */
1414
- is_user_message_guardrailed?: boolean;
1415
- /** @description A list of all guardrails checked for in the corresponding turn associated with the assistant_message-submitted event this property is part of. Includes whether they were triggered and some meaningful way of measuring how close to being triggered/not triggered they were, as well as categorising into input/output guardrails. */
1416
- guardrails?: unknown[];
1417
- /** @description True if assistant_message-submitted event is one that is associated with a message chunk before the conversation api checks the llm response against guardrails. False if it's the final message chunk sent to the frontend. See event level description for assistant_message-submitted for more detail. */
1418
- is_pre_output_guardrail_checks?: boolean;
1419
- /** @description Describes the stage that the conversation is currently at. A conversation stage is triggered in response to each user message, and according to the stage, the main LLM prompt is tweaked to apply specific instructions and steer the conversation. */
1420
- conversation_stage?: string | null;
1421
- /** @description A list of ids that each relate to a single recommendation that was shown in a set of recs */
1422
- recommendation_ids_recommended?: unknown[];
1423
- /** @description Contains the fallback text provided by the conversation api to a frontend that non 'text' (single_select/multi_select etc) messages could revert to if they needed to. Described in the conversation api docs as: "What should a client render if they do not have a native renderer for this message type?". */
1424
- fallback_text?: string;
1425
- /** @description Specifies if a free text response can be provided to an assistant single/multi-select message */
1426
- is_allow_free_text_message?: boolean;
1427
- /** @description The reason an exit to chat response was provided by the conversation api */
1428
- exit_to_chat_reason?: string;
1429
- /** @description A list of ids that each correspond to their own recommendation, with all recs in the list being 'exit to purchase-able' or 'exit to chat-able' */
1430
- recommendation_ids_for_exit?: unknown[];
1431
- /** @description The type of destination the user will be sent to as a result of exiting to chat. E.g 'phone','chat','email' etc */
1432
- exit_destination_type?: string;
1433
- /** @description The ID for the sale, a unique, non-empty value we can correlate with customer records. */
1434
- sale_id?: string;
1435
- /** @description The type of user, for example, existing or prospect. */
1436
- user_type?: string;
1437
- /** @description A code that represents what currency the product price is listed in e.g. USD, GBP. This should match the ISO 4217 standard - see https://www.iban.com/currency-codes. */
1438
- currency_code?: string;
1439
- /** @description The full basket value of the sale, inclusive of any offers. */
1440
- sale_total_value?: number;
1441
- /** @description A list containing separate line items for each product sold. */
1442
- products_sold?: unknown[];
1443
- /** @description The language of the part of the site the sales data is coming from in ISO 639-1 format e.g. 'en', 'es' etc. */
1444
- language?: string;
1445
- /** @description A list of product items with properties that are specific to Spectrum */
1446
- products_sold_spectrum?: unknown[];
1447
- /** @description Properties at the sale level (not product item level) specifically required from media customers */
1448
- sale_custom_properties_media?: Record<string, never>;
1449
- /** @description A list of product item objects specific to media customers */
1450
- products_sold_media?: unknown[];
1451
- /** @description Properties at the sale level (not product item level) specifically required from Aidem */
1452
- sale_custom_properties_aidem?: Record<string, never>;
1453
- /** @description A list of product items with properties that are specific to Aidem */
1454
- products_sold_aidem?: unknown[];
1455
991
  /** @description Specifies whether the click on the entry point was a positive or negative CTA. Positive would be expected to open the tool ui, negative would be expected to close the entry point. */
1456
992
  entry_point_click_type?: string | null;
1457
- /** @description True if user has qualified for using the 15gifts sales advisor (except on customers with no qualification process where this will always be True) */
1458
- is_qualified?: boolean;
1459
- /** @description The stage on the particular customer's site that a user would be expected to qualify at. Should be NULL for customer sites that don't have a qualification process.
1460
- *
1461
- * Stage definitions:
1462
- *
1463
- * website - On a page on the main customer website (and not in either of the below)
1464
- *
1465
- * tool_ui - Within whatever frontend overlay exists that a user would have a conversation in, but not within our actual conversation (managed by conversation api). This value is more aimed to towards something like xfinity on comcast where we have a headless customer and they manage the ui.
1466
- *
1467
- * conversation - Within an actual conversation that is managed by the conversation api (a conversation id should exist at this point) */
1468
- qualification_stage?: string;
993
+ /** @description A list of ids that each correspond to their own recommendation, with all recs in the list being 'exit to purchase-able' or 'exit to chat-able' */
994
+ recommendation_ids_for_exit?: unknown[];
1469
995
  /** @description true if the experiment is the main uplift test, false if it isn't. */
1470
996
  is_main_uplift_experiment?: boolean;
1471
997
  /** @description The tracking key that growthbook uses to uniquely identify an experiment. https://docs.growthbook.io/feature-flag-experiments#tracking-key */
@@ -1474,10 +1000,6 @@ interface paths {
1474
1000
  experiment_variation_id?: string;
1475
1001
  /** @description The human readable name for the variation as defined in Growthbook */
1476
1002
  experiment_variation_name?: string;
1477
- /** @description A list of structured information extracted from the conversation that can inform the recommender and the discovery. A single slot would provide a key piece of information such as the users broadband usages (gaming/streaming/working from home).
1478
- *
1479
- * https://backoffice.15gifts.com/product/recommender/slots */
1480
- slots?: unknown[];
1481
1003
  /** @description Describes the reason the entry point was closed. When the value is 'customer_triggered' it's because it's been programmatically closed by the customer (by running window.axiom.integrations.hide()). When it's 'user_close_click' it's because the actual end user has closed it manually by clicking. */
1482
1004
  entry_point_closed_reason?: string;
1483
1005
  /** @description A categorical property to denote which party was responsible for suppression. This is useful for accurately calculating control conversion rates, it allows us to count how many users were suppressed before humara loading, and how many were put in a control group.
@@ -1486,12 +1008,8 @@ interface paths {
1486
1008
  /** @description A categorical property that describes the reason for the suppression. When the value is 'customer_triggered' it's because it's been programmatically closed by the customer (by running window.axiom.integrations.hide())
1487
1009
  * */
1488
1010
  suppressed_reason?: unknown[];
1489
- /** @description A list of objects for recommendations sent in a conversation api message. */
1490
- recommendation_set?: unknown[];
1491
- /** @description This is a score that evaluates how much progress has been made through the discovery phase of the conversation. A higher score means more information has been discovered. This value is generated by the recommender.
1492
- *
1493
- * https://github.com/15gifts/indy-contracts/blob/main/contracts/recommendation_v2_generate.json#L57 */
1494
- discovery_progress_score?: number;
1011
+ /** @description The type of destination the user will be sent to as a result of exiting to chat. E.g 'phone','chat','email' etc */
1012
+ exit_destination_type?: string;
1495
1013
  /** @description Describes whether a user clicked the thumbs up ('positive') or thumbs down ('negative') on the rec card */
1496
1014
  rec_card_feedback_sentiment?: string;
1497
1015
  /** @description A 32 character alphanumeric hash that uniquely identifies a single rec in a recommendation set.
@@ -1500,19 +1018,28 @@ interface paths {
1500
1018
  * https://datatracker.ietf.org/doc/html/rfc9562#name-uuid-version-4
1501
1019
  *
1502
1020
  * e.g f81d4fae-7dec-41d0-a765-00a0c91e6bf6 */
1503
- recommendation_id?: string | null;
1504
- /** @description The number of tokens contained in the sequence of text sent in a request to an external service (from the user message) */
1505
- external_request_input_token_count?: number;
1506
- /** @description The number of tokens contained in the sequence of text received from sending a request to an external service. Should be null for embedding requests. */
1507
- external_request_output_token_count?: number | null;
1508
- /** @description The type of external request e.g. llm/embedding */
1509
- external_request_type?: string;
1510
- /** @description Describes the subcategory of the request for the purpose of bucketing the higher level request_category into different categories */
1511
- external_request_subtype?: string;
1512
- /** @description The provider an external request is sent to */
1513
- external_request_provider?: string;
1514
- /** @description The model ID is used to determine which exact model we use in an external request e.g. 'gpt-4o-mini' */
1515
- external_request_model_id?: string;
1021
+ recommendation_id?: string;
1022
+ /** @description List of objects that represents the options for single & multiselect questions. */
1023
+ message_select_options?: unknown[];
1024
+ /** @description An alphanumeric hash that uniquely identifies a turn in a conversation
1025
+ *
1026
+ * This should match the UUID V4 as specified in RFC 9652:
1027
+ * https://datatracker.ietf.org/doc/html/rfc9562#name-uuid-version-4
1028
+ *
1029
+ * e.g f81d4fae-7dec-41d0-a765-00a0c91e6bf6 */
1030
+ conversation_turn_id?: string;
1031
+ /** @description The turn number in the conversation. This links each user message to a corresponding assistant response. If there is an opening message from the assistant, this would have a message_turn of 1. Then the first message a user sends would have a message_turn of 2. The first actual response the assistant sends would have a message_turn of 2.
1032
+ *
1033
+ * All message_turn values except for 1 (the opening message if it exists) should be expected to come in pairs.
1034
+ *
1035
+ * Here's an example sequence of message_turn values where the user is provided with an opening message at the beginning of a conversation, and then sends 5 separate messages themselves with 5 corresponding assistant responses:
1036
+ *
1037
+ * 1,2,2,3,3,4,4,5,5,6,6
1038
+ * */
1039
+ conversation_turn_num?: number;
1040
+ /** @description The text that was visible to the user on the CTA button
1041
+ * */
1042
+ button_text?: string;
1516
1043
  };
1517
1044
  /**
1518
1045
  * @description A 36 character hash, 5 segments, separated by dashes that uniquely identifies a conversation
@@ -1523,7 +1050,7 @@ interface paths {
1523
1050
  * @description Event Name
1524
1051
  * @enum {string}
1525
1052
  */
1526
- eventName: "entry_point-shown" | "feedback_submit-clicked" | "page-shown" | "tool_ui-closed" | "user_message-submitted" | "user_message-submitted message" | "user_message-submitted single_select" | "user_message-submitted multi_select" | "assistant_message-submitted" | "assistant_message-submitted recommendation" | "assistant_message-submitted message" | "assistant_message-submitted single_select" | "assistant_message-submitted multi_select" | "assistant_message-submitted exit_to_chat" | "assistant_message-submitted exit_to_purchase" | "assistant_message-submitted exit_to_human" | "feedback-shown" | "feedback_skip-clicked" | "sale-completed" | "sale-completed spectrum" | "sale-completed aidem" | "sale-completed spectrum-us-media-consumer-en" | "entry_point-clicked" | "tool_close-clicked" | "exit_to_chat-completed" | "exit_to_purchase-completed" | "conversation-started" | "user_qualification-identified" | "experiment_variation-assigned" | "slot_filling-completed" | "entry_point-closed" | "entry_point-suppressed" | "user-created" | "exit_to_human-completed" | "recommendation_set-returned" | "ww_rag_context-used" | "ww_user_context-received" | "rec_card_feedback-clicked" | "external_request-submitted" | "external_request-submitted llm" | "external_request-submitted embedding" | "external_request-submitted embedding_service_level" | "ww_prompt_context-used" | "message_select_option-clicked";
1053
+ eventName: 'entry_point-shown' | 'feedback_submit-clicked' | 'page-shown' | 'tool_ui-closed' | 'feedback-shown' | 'feedback_skip-clicked' | 'entry_point-clicked' | 'tool_close-clicked' | 'exit_to_chat-completed' | 'exit_to_purchase-completed' | 'experiment_variation-assigned' | 'entry_point-closed' | 'entry_point-suppressed' | 'user-created' | 'exit_to_human-completed' | 'rec_card_feedback-clicked' | 'message_select_option-clicked' | 'rec_card_purchase-clicked';
1527
1054
  /**
1528
1055
  * @description A 36 character hash, 5 segments, separated by dashes that uniquely identifies a page view (page-shown event)
1529
1056
  * @example 1a1a1a1a-1a1a-1a1a-1a1a-1a1a1a1a1a1a
@@ -1540,7 +1067,7 @@ interface paths {
1540
1067
  * screen_width > 480px = 'large'
1541
1068
  * @enum {string}
1542
1069
  */
1543
- screenSize?: "mobile" | "large";
1070
+ screenSize?: 'mobile' | 'large';
1544
1071
  /** @description The device screen width in pixels - window.screen.width in JS. This is a user level property that should never change. */
1545
1072
  screenWidth?: number;
1546
1073
  /** @description The page url at the time the event is fired */
@@ -1602,7 +1129,10 @@ type ApiRecommendationMessage = components['schemas']['AssistantRecommendationMe
1602
1129
  type ApiRecommendationV2Message = components['schemas']['AssistantRecommendationMessageV2'];
1603
1130
  type ApiSingleSelectMessage = components['schemas']['AssistantSingleSelectMessage'];
1604
1131
  type ApiTextMessage = components['schemas']['AssistantTextMessage'];
1605
- type ConversationApiRequest = paths$1['/api/conversation/v3']['post']['requestBody']['content']['application/json'];
1132
+ type UserTextMessage = components['schemas']['UserTextMessage'];
1133
+ type UserSingleSelectMessage = components['schemas']['UserSingleSelectMessage'];
1134
+ type UserMultiSelectMessage = components['schemas']['UserMultiSelectMessage'];
1135
+ type SendMessagePayload = Omit<UserTextMessage, 'conversationId'> | Omit<UserSingleSelectMessage, 'conversationId'> | Omit<UserMultiSelectMessage, 'conversationId'>;
1606
1136
  type ApiIdentityRequest = paths['/api/tracking/identity/v2']['post']['requestBody']['content']['application/json'];
1607
1137
  type ApiTrackingUserRequest = paths['/api/tracking/user/v2']['post']['requestBody']['content']['application/json'];
1608
1138
  /**
@@ -1696,7 +1226,6 @@ interface TextMessage extends ApiTextMessage {
1696
1226
  }
1697
1227
  interface TrackingEvent extends ApiTrackingUserRequest {
1698
1228
  }
1699
- type SendMessagePayload = Exclude<ConversationApiRequest, ConversationIdMessage>;
1700
1229
 
1701
1230
  /**
1702
1231
  * The `Client` class provides methods to manage 15gifts API.
@@ -1888,56 +1417,25 @@ declare class Client {
1888
1417
  feedback_score_num?: number;
1889
1418
  ip_address_hashed?: string;
1890
1419
  tool_ui_closed_reason?: string;
1891
- conversation_turn_num?: number;
1892
- conversation_turn_id?: string;
1893
- message_type?: string;
1894
- message_text?: string;
1895
- message_select_options?: unknown[];
1896
- is_user_message_guardrailed?: boolean;
1897
- guardrails?: unknown[];
1898
- is_pre_output_guardrail_checks?: boolean;
1899
- conversation_stage?: string | null;
1900
- recommendation_ids_recommended?: unknown[];
1901
- fallback_text?: string;
1902
- is_allow_free_text_message?: boolean;
1903
- exit_to_chat_reason?: string;
1904
- recommendation_ids_for_exit?: unknown[];
1905
- exit_destination_type?: string;
1906
- sale_id?: string;
1907
- user_type?: string;
1908
- currency_code?: string;
1909
- sale_total_value?: number;
1910
- products_sold?: unknown[];
1911
- language?: string;
1912
- products_sold_spectrum?: unknown[];
1913
- sale_custom_properties_media?: Record<string, never>;
1914
- products_sold_media?: unknown[];
1915
- sale_custom_properties_aidem?: Record<string, never>;
1916
- products_sold_aidem?: unknown[];
1917
1420
  entry_point_click_type?: string | null;
1918
- is_qualified?: boolean;
1919
- qualification_stage?: string;
1421
+ recommendation_ids_for_exit?: unknown[];
1920
1422
  is_main_uplift_experiment?: boolean;
1921
1423
  experiment_id?: string;
1922
1424
  experiment_variation_id?: string;
1923
1425
  experiment_variation_name?: string;
1924
- slots?: unknown[];
1925
1426
  entry_point_closed_reason?: string;
1926
1427
  suppressed_by?: unknown[];
1927
1428
  suppressed_reason?: unknown[];
1928
- recommendation_set?: unknown[];
1929
- discovery_progress_score?: number;
1429
+ exit_destination_type?: string;
1930
1430
  rec_card_feedback_sentiment?: string;
1931
- recommendation_id?: string | null;
1932
- external_request_input_token_count?: number;
1933
- external_request_output_token_count?: number | null;
1934
- external_request_type?: string;
1935
- external_request_subtype?: string;
1936
- external_request_provider?: string;
1937
- external_request_model_id?: string;
1431
+ recommendation_id?: string;
1432
+ message_select_options?: unknown[];
1433
+ conversation_turn_id?: string;
1434
+ conversation_turn_num?: number;
1435
+ button_text?: string;
1938
1436
  };
1939
1437
  conversationId?: string;
1940
- eventName: "entry_point-shown" | "feedback_submit-clicked" | "page-shown" | "tool_ui-closed" | "user_message-submitted" | "user_message-submitted message" | "user_message-submitted single_select" | "user_message-submitted multi_select" | "assistant_message-submitted" | "assistant_message-submitted recommendation" | "assistant_message-submitted message" | "assistant_message-submitted single_select" | "assistant_message-submitted multi_select" | "assistant_message-submitted exit_to_chat" | "assistant_message-submitted exit_to_purchase" | "assistant_message-submitted exit_to_human" | "feedback-shown" | "feedback_skip-clicked" | "sale-completed" | "sale-completed spectrum" | "sale-completed aidem" | "sale-completed spectrum-us-media-consumer-en" | "entry_point-clicked" | "tool_close-clicked" | "exit_to_chat-completed" | "exit_to_purchase-completed" | "conversation-started" | "user_qualification-identified" | "experiment_variation-assigned" | "slot_filling-completed" | "entry_point-closed" | "entry_point-suppressed" | "user-created" | "exit_to_human-completed" | "recommendation_set-returned" | "ww_rag_context-used" | "ww_user_context-received" | "rec_card_feedback-clicked" | "external_request-submitted" | "external_request-submitted llm" | "external_request-submitted embedding" | "external_request-submitted embedding_service_level" | "ww_prompt_context-used" | "message_select_option-clicked";
1438
+ eventName: "entry_point-shown" | "feedback_submit-clicked" | "page-shown" | "tool_ui-closed" | "feedback-shown" | "feedback_skip-clicked" | "entry_point-clicked" | "tool_close-clicked" | "exit_to_chat-completed" | "exit_to_purchase-completed" | "experiment_variation-assigned" | "entry_point-closed" | "entry_point-suppressed" | "user-created" | "exit_to_human-completed" | "rec_card_feedback-clicked" | "message_select_option-clicked" | "rec_card_purchase-clicked";
1941
1439
  pageviewId: string;
1942
1440
  screenHeight?: number;
1943
1441
  screenSize?: "mobile" | "large";