@linqapp/sdk 0.21.0 → 0.22.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.
@@ -296,6 +296,21 @@ export interface Chat {
296
296
  */
297
297
  handles: Array<Shared.ChatHandle>;
298
298
 
299
+ /**
300
+ * **[BETA]** Current health for a chat. Always present — chats start at `healthy`
301
+ * and may shift based on engagement and delivery signals on the conversation. Many
302
+ * `at_risk` or `critical` chats on a single line increase the risk of line
303
+ * flagging.
304
+ *
305
+ * Switch on `status` to gate sends or surface line health in your UI — the enum is
306
+ * the long-term contract. Each status carries a `doc_url` that deep-links to the
307
+ * relevant section of the Chat Health guide.
308
+ *
309
+ * See the [Chat Health guide](/guides/chats/chat-health) for what each status
310
+ * means and how to react.
311
+ */
312
+ health_status: Chat.HealthStatus;
313
+
299
314
  /**
300
315
  * Whether the chat is archived
301
316
  */
@@ -311,12 +326,6 @@ export interface Chat {
311
326
  */
312
327
  updated_at: string;
313
328
 
314
- /**
315
- * **[BETA]** Health assessment for a chat. Higher `score` is healthier. `null`
316
- * when a score isn't available yet. Scoring may change during beta.
317
- */
318
- health_score?: Chat.HealthScore | null;
319
-
320
329
  /**
321
330
  * Messaging service type
322
331
  */
@@ -325,19 +334,35 @@ export interface Chat {
325
334
 
326
335
  export namespace Chat {
327
336
  /**
328
- * **[BETA]** Health assessment for a chat. Higher `score` is healthier. `null`
329
- * when a score isn't available yet. Scoring may change during beta.
337
+ * **[BETA]** Current health for a chat. Always present chats start at `healthy`
338
+ * and may shift based on engagement and delivery signals on the conversation. Many
339
+ * `at_risk` or `critical` chats on a single line increase the risk of line
340
+ * flagging.
341
+ *
342
+ * Switch on `status` to gate sends or surface line health in your UI — the enum is
343
+ * the long-term contract. Each status carries a `doc_url` that deep-links to the
344
+ * relevant section of the Chat Health guide.
345
+ *
346
+ * See the [Chat Health guide](/guides/chats/chat-health) for what each status
347
+ * means and how to react.
330
348
  */
331
- export interface HealthScore {
349
+ export interface HealthStatus {
350
+ /**
351
+ * Deep-link to the relevant section of the Chat Health guide for this status.
352
+ */
353
+ doc_url: string;
354
+
332
355
  /**
333
- * Short summary of what's affecting the score. Empty when the score is 100.
356
+ * Current health bucket for the chat. See the
357
+ * [Chat Health guide](/guides/chats/chat-health) for what each value means and how
358
+ * to react. `doc_url` deep-links to the relevant section.
334
359
  */
335
- reason: string;
360
+ status: 'healthy' | 'at_risk' | 'critical' | 'opted_out';
336
361
 
337
362
  /**
338
- * Health score from 0 to 100. Higher is healthier.
363
+ * When this status last changed.
339
364
  */
340
- score: number;
365
+ updated_at: string;
341
366
  }
342
367
  }
343
368
 
@@ -535,6 +560,21 @@ export namespace ChatCreateResponse {
535
560
  */
536
561
  handles: Array<Shared.ChatHandle>;
537
562
 
563
+ /**
564
+ * **[BETA]** Current health for a chat. Always present — chats start at `healthy`
565
+ * and may shift based on engagement and delivery signals on the conversation. Many
566
+ * `at_risk` or `critical` chats on a single line increase the risk of line
567
+ * flagging.
568
+ *
569
+ * Switch on `status` to gate sends or surface line health in your UI — the enum is
570
+ * the long-term contract. Each status carries a `doc_url` that deep-links to the
571
+ * relevant section of the Chat Health guide.
572
+ *
573
+ * See the [Chat Health guide](/guides/chats/chat-health) for what each status
574
+ * means and how to react.
575
+ */
576
+ health_status: Chat.HealthStatus;
577
+
538
578
  /**
539
579
  * Whether this is a group chat
540
580
  */
@@ -549,29 +589,39 @@ export namespace ChatCreateResponse {
549
589
  * Messaging service type
550
590
  */
551
591
  service: Shared.ServiceType;
552
-
553
- /**
554
- * **[BETA]** Health assessment for a chat. Higher `score` is healthier. `null`
555
- * when a score isn't available yet. Scoring may change during beta.
556
- */
557
- health_score?: Chat.HealthScore | null;
558
592
  }
559
593
 
560
594
  export namespace Chat {
561
595
  /**
562
- * **[BETA]** Health assessment for a chat. Higher `score` is healthier. `null`
563
- * when a score isn't available yet. Scoring may change during beta.
596
+ * **[BETA]** Current health for a chat. Always present chats start at `healthy`
597
+ * and may shift based on engagement and delivery signals on the conversation. Many
598
+ * `at_risk` or `critical` chats on a single line increase the risk of line
599
+ * flagging.
600
+ *
601
+ * Switch on `status` to gate sends or surface line health in your UI — the enum is
602
+ * the long-term contract. Each status carries a `doc_url` that deep-links to the
603
+ * relevant section of the Chat Health guide.
604
+ *
605
+ * See the [Chat Health guide](/guides/chats/chat-health) for what each status
606
+ * means and how to react.
564
607
  */
565
- export interface HealthScore {
608
+ export interface HealthStatus {
609
+ /**
610
+ * Deep-link to the relevant section of the Chat Health guide for this status.
611
+ */
612
+ doc_url: string;
613
+
566
614
  /**
567
- * Short summary of what's affecting the score. Empty when the score is 100.
615
+ * Current health bucket for the chat. See the
616
+ * [Chat Health guide](/guides/chats/chat-health) for what each value means and how
617
+ * to react. `doc_url` deep-links to the relevant section.
568
618
  */
569
- reason: string;
619
+ status: 'healthy' | 'at_risk' | 'critical' | 'opted_out';
570
620
 
571
621
  /**
572
- * Health score from 0 to 100. Higher is healthier.
622
+ * When this status last changed.
573
623
  */
574
- score: number;
624
+ updated_at: string;
575
625
  }
576
626
  }
577
627
  }
@@ -28,11 +28,11 @@ export class ContactCard extends APIResource {
28
28
  * @example
29
29
  * ```ts
30
30
  * const setContactCard = await client.contactCard.create({
31
- * first_name: 'John',
31
+ * first_name: 'Acme',
32
32
  * phone_number: '+15551234567',
33
33
  * image_url:
34
34
  * 'https://cdn.linqapp.com/contact-card/example.jpg',
35
- * last_name: 'Doe',
35
+ * last_name: 'Support',
36
36
  * });
37
37
  * ```
38
38
  */
@@ -109,10 +109,19 @@ export namespace MessageEventV2 {
109
109
  id: string;
110
110
 
111
111
  /**
112
- * **[BETA]** Health assessment for a chat. Higher `score` is healthier. `null`
113
- * when a score isn't available yet. Scoring may change during beta.
112
+ * **[BETA]** Current health for a chat. Always present chats start at `healthy`
113
+ * and may shift based on engagement and delivery signals on the conversation. Many
114
+ * `at_risk` or `critical` chats on a single line increase the risk of line
115
+ * flagging.
116
+ *
117
+ * Switch on `status` to gate sends or surface line health in your UI — the enum is
118
+ * the long-term contract. Each status carries a `doc_url` that deep-links to the
119
+ * relevant section of the Chat Health guide.
120
+ *
121
+ * See the [Chat Health guide](/guides/chats/chat-health) for what each status
122
+ * means and how to react.
114
123
  */
115
- health_score?: Chat.HealthScore | null;
124
+ health_status: Chat.HealthStatus;
116
125
 
117
126
  /**
118
127
  * Whether this is a group chat
@@ -127,19 +136,35 @@ export namespace MessageEventV2 {
127
136
 
128
137
  export namespace Chat {
129
138
  /**
130
- * **[BETA]** Health assessment for a chat. Higher `score` is healthier. `null`
131
- * when a score isn't available yet. Scoring may change during beta.
132
- */
133
- export interface HealthScore {
139
+ * **[BETA]** Current health for a chat. Always present chats start at `healthy`
140
+ * and may shift based on engagement and delivery signals on the conversation. Many
141
+ * `at_risk` or `critical` chats on a single line increase the risk of line
142
+ * flagging.
143
+ *
144
+ * Switch on `status` to gate sends or surface line health in your UI — the enum is
145
+ * the long-term contract. Each status carries a `doc_url` that deep-links to the
146
+ * relevant section of the Chat Health guide.
147
+ *
148
+ * See the [Chat Health guide](/guides/chats/chat-health) for what each status
149
+ * means and how to react.
150
+ */
151
+ export interface HealthStatus {
152
+ /**
153
+ * Deep-link to the relevant section of the Chat Health guide for this status.
154
+ */
155
+ doc_url: string;
156
+
134
157
  /**
135
- * Short summary of what's affecting the score. Empty when the score is 100.
158
+ * Current health bucket for the chat. See the
159
+ * [Chat Health guide](/guides/chats/chat-health) for what each value means and how
160
+ * to react. `doc_url` deep-links to the relevant section.
136
161
  */
137
- reason: string;
162
+ status: 'healthy' | 'at_risk' | 'critical' | 'opted_out';
138
163
 
139
164
  /**
140
- * Health score from 0 to 100. Higher is healthier.
165
+ * When this status last changed.
141
166
  */
142
- score: number;
167
+ updated_at: string;
143
168
  }
144
169
  }
145
170
 
@@ -898,6 +923,21 @@ export namespace MessageEditedWebhookEvent {
898
923
  */
899
924
  id: string;
900
925
 
926
+ /**
927
+ * **[BETA]** Current health for a chat. Always present — chats start at `healthy`
928
+ * and may shift based on engagement and delivery signals on the conversation. Many
929
+ * `at_risk` or `critical` chats on a single line increase the risk of line
930
+ * flagging.
931
+ *
932
+ * Switch on `status` to gate sends or surface line health in your UI — the enum is
933
+ * the long-term contract. Each status carries a `doc_url` that deep-links to the
934
+ * relevant section of the Chat Health guide.
935
+ *
936
+ * See the [Chat Health guide](/guides/chats/chat-health) for what each status
937
+ * means and how to react.
938
+ */
939
+ health_status: Chat.HealthStatus;
940
+
901
941
  /**
902
942
  * Whether this is a group chat
903
943
  */
@@ -909,6 +949,40 @@ export namespace MessageEditedWebhookEvent {
909
949
  owner_handle: Shared.ChatHandle;
910
950
  }
911
951
 
952
+ export namespace Chat {
953
+ /**
954
+ * **[BETA]** Current health for a chat. Always present — chats start at `healthy`
955
+ * and may shift based on engagement and delivery signals on the conversation. Many
956
+ * `at_risk` or `critical` chats on a single line increase the risk of line
957
+ * flagging.
958
+ *
959
+ * Switch on `status` to gate sends or surface line health in your UI — the enum is
960
+ * the long-term contract. Each status carries a `doc_url` that deep-links to the
961
+ * relevant section of the Chat Health guide.
962
+ *
963
+ * See the [Chat Health guide](/guides/chats/chat-health) for what each status
964
+ * means and how to react.
965
+ */
966
+ export interface HealthStatus {
967
+ /**
968
+ * Deep-link to the relevant section of the Chat Health guide for this status.
969
+ */
970
+ doc_url: string;
971
+
972
+ /**
973
+ * Current health bucket for the chat. See the
974
+ * [Chat Health guide](/guides/chats/chat-health) for what each value means and how
975
+ * to react. `doc_url` deep-links to the relevant section.
976
+ */
977
+ status: 'healthy' | 'at_risk' | 'critical' | 'opted_out';
978
+
979
+ /**
980
+ * When this status last changed.
981
+ */
982
+ updated_at: string;
983
+ }
984
+ }
985
+
912
986
  /**
913
987
  * The edited part
914
988
  */
@@ -1266,6 +1340,21 @@ export namespace ChatCreatedWebhookEvent {
1266
1340
  */
1267
1341
  handles: Array<Shared.ChatHandle>;
1268
1342
 
1343
+ /**
1344
+ * **[BETA]** Current health for a chat. Always present — chats start at `healthy`
1345
+ * and may shift based on engagement and delivery signals on the conversation. Many
1346
+ * `at_risk` or `critical` chats on a single line increase the risk of line
1347
+ * flagging.
1348
+ *
1349
+ * Switch on `status` to gate sends or surface line health in your UI — the enum is
1350
+ * the long-term contract. Each status carries a `doc_url` that deep-links to the
1351
+ * relevant section of the Chat Health guide.
1352
+ *
1353
+ * See the [Chat Health guide](/guides/chats/chat-health) for what each status
1354
+ * means and how to react.
1355
+ */
1356
+ health_status: Data.HealthStatus;
1357
+
1269
1358
  /**
1270
1359
  * Whether this is a group chat
1271
1360
  */
@@ -1281,6 +1370,40 @@ export namespace ChatCreatedWebhookEvent {
1281
1370
  */
1282
1371
  service?: Shared.ServiceType | null;
1283
1372
  }
1373
+
1374
+ export namespace Data {
1375
+ /**
1376
+ * **[BETA]** Current health for a chat. Always present — chats start at `healthy`
1377
+ * and may shift based on engagement and delivery signals on the conversation. Many
1378
+ * `at_risk` or `critical` chats on a single line increase the risk of line
1379
+ * flagging.
1380
+ *
1381
+ * Switch on `status` to gate sends or surface line health in your UI — the enum is
1382
+ * the long-term contract. Each status carries a `doc_url` that deep-links to the
1383
+ * relevant section of the Chat Health guide.
1384
+ *
1385
+ * See the [Chat Health guide](/guides/chats/chat-health) for what each status
1386
+ * means and how to react.
1387
+ */
1388
+ export interface HealthStatus {
1389
+ /**
1390
+ * Deep-link to the relevant section of the Chat Health guide for this status.
1391
+ */
1392
+ doc_url: string;
1393
+
1394
+ /**
1395
+ * Current health bucket for the chat. See the
1396
+ * [Chat Health guide](/guides/chats/chat-health) for what each value means and how
1397
+ * to react. `doc_url` deep-links to the relevant section.
1398
+ */
1399
+ status: 'healthy' | 'at_risk' | 'critical' | 'opted_out';
1400
+
1401
+ /**
1402
+ * When this status last changed.
1403
+ */
1404
+ updated_at: string;
1405
+ }
1406
+ }
1284
1407
  }
1285
1408
 
1286
1409
  /**
package/src/version.ts CHANGED
@@ -1 +1 @@
1
- export const VERSION = '0.21.0'; // x-release-please-version
1
+ export const VERSION = '0.22.1'; // x-release-please-version
package/version.d.mts CHANGED
@@ -1,2 +1,2 @@
1
- export declare const VERSION = "0.21.0";
1
+ export declare const VERSION = "0.22.1";
2
2
  //# sourceMappingURL=version.d.mts.map
package/version.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- export declare const VERSION = "0.21.0";
1
+ export declare const VERSION = "0.22.1";
2
2
  //# sourceMappingURL=version.d.ts.map
package/version.js CHANGED
@@ -1,5 +1,5 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.VERSION = void 0;
4
- exports.VERSION = '0.21.0'; // x-release-please-version
4
+ exports.VERSION = '0.22.1'; // x-release-please-version
5
5
  //# sourceMappingURL=version.js.map
package/version.mjs CHANGED
@@ -1,2 +1,2 @@
1
- export const VERSION = '0.21.0'; // x-release-please-version
1
+ export const VERSION = '0.22.1'; // x-release-please-version
2
2
  //# sourceMappingURL=version.mjs.map