@outlit/tools 2.3.0 → 2.5.0

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.js CHANGED
@@ -2,6 +2,7 @@
2
2
  var contractVersion = 1;
3
3
  var publicToolNames = [
4
4
  "outlit_list_customers",
5
+ "outlit_list_crm_fields",
5
6
  "outlit_list_users",
6
7
  "outlit_list_workspace_users",
7
8
  "outlit_get_customer",
@@ -60,10 +61,11 @@ var publicToolContracts = {
60
61
  "commandVersion": 1,
61
62
  "ownerDomain": "customers",
62
63
  "title": "List Customers",
63
- "description": "Browse and filter customers. Use this to find customers by billing status, activity recency, revenue, or name. Returns a paginated list with summary info (MRR, last activity, status). currentMrr is in the billing provider's units for the customer's currency, which the result doesn't name. For USD, EUR, GBP and CAD this is cents: divide by 100 (e.g. 1234500 is $12,345 MRR, USD). Other currencies follow the provider's amount rules. ARR is 12 \xD7 currentMrr in the same units.",
64
+ "description": "Browse and filter customers. Use this to find customers by billing status, activity recency, revenue, name, or their CRM and support tool fields (crm; crmFields returns those fields' values on each customer, e.g. segment and health across the book; use outlit_list_crm_fields to find keys and values). Returns a paginated list with summary info (ARR, last activity, status). arr is the annualized revenue run rate, the same figure the Outlit app shows, with its currency: amount is in the billing provider's units for that currency (for USD, EUR, GBP and CAD this is cents: divide by 100, e.g. 1200000 is $12,000 ARR, USD; other currencies follow the provider's amount rules). arr is null when the app shows none, and amount is 0 for a churned, paused or trialing customer.",
64
65
  "annotations": {
65
66
  "readOnlyHint": true,
66
67
  "destructiveHint": false,
68
+ "idempotentHint": true,
67
69
  "openWorldHint": false
68
70
  },
69
71
  "inputSchema": {
@@ -107,13 +109,28 @@ var publicToolContracts = {
107
109
  "90d"
108
110
  ]
109
111
  },
112
+ "arrAbove": {
113
+ "description": "Minimum ARR, in arr.amount's units per year (1200000 is $12,000 for a customer billed in USD). Each customer is compared in its own currency, never converted: pass arrCurrency to compare one currency. Customers whose ARR is unknown never match.",
114
+ "type": "number",
115
+ "minimum": 0
116
+ },
117
+ "arrBelow": {
118
+ "description": "Maximum ARR, in arr.amount's units per year, compared in each customer's own currency like arrAbove. Customers whose ARR is unknown never match.",
119
+ "type": "number",
120
+ "minimum": 0
121
+ },
122
+ "arrCurrency": {
123
+ "description": "Only customers whose ARR is in this ISO 4217 currency, such as USD. Outlit never converts ARR between currencies, so use this to rank or bound ARR within one currency.",
124
+ "type": "string",
125
+ "pattern": "^[A-Za-z]{3}$"
126
+ },
110
127
  "mrrAbove": {
111
- "description": "Minimum MRR, in currentMrr's units (10000 is $100 for a customer billed in USD)",
128
+ "description": "Deprecated: use arrAbove.",
112
129
  "type": "number",
113
130
  "minimum": 0
114
131
  },
115
132
  "mrrBelow": {
116
- "description": "Maximum MRR, in currentMrr's units",
133
+ "description": "Deprecated: use arrBelow.",
117
134
  "type": "number",
118
135
  "minimum": 0
119
136
  },
@@ -158,6 +175,120 @@ var publicToolContracts = {
158
175
  "description": "Filter customers by whether they have an owner",
159
176
  "type": "boolean"
160
177
  },
178
+ "crm": {
179
+ "description": "Filter by fields of the customer's CRM and support tool accounts, such as segment, health or stage; use outlit_list_crm_fields to find keys and values. All filters must hold; each holds when any linked account meets it. eq and in compare text ignoring case; gte and lte compare numbers, or ISO dates, never text. A multi-value field matches when any of its values does.",
180
+ "maxItems": 10,
181
+ "type": "array",
182
+ "items": {
183
+ "type": "object",
184
+ "properties": {
185
+ "field": {
186
+ "type": "object",
187
+ "properties": {
188
+ "provider": {
189
+ "type": "string",
190
+ "enum": [
191
+ "hubspot",
192
+ "salesforce",
193
+ "attio",
194
+ "pylon"
195
+ ]
196
+ },
197
+ "key": {
198
+ "type": "string",
199
+ "minLength": 1,
200
+ "maxLength": 191,
201
+ "description": "The field's key (API name) in that system, as outlit_list_crm_fields lists it."
202
+ }
203
+ },
204
+ "required": [
205
+ "provider",
206
+ "key"
207
+ ]
208
+ },
209
+ "op": {
210
+ "type": "string",
211
+ "enum": [
212
+ "eq",
213
+ "in",
214
+ "gte",
215
+ "lte"
216
+ ]
217
+ },
218
+ "value": {
219
+ "anyOf": [
220
+ {
221
+ "anyOf": [
222
+ {
223
+ "type": "string",
224
+ "maxLength": 500
225
+ },
226
+ {
227
+ "type": "number"
228
+ },
229
+ {
230
+ "type": "boolean"
231
+ }
232
+ ]
233
+ },
234
+ {
235
+ "minItems": 1,
236
+ "maxItems": 50,
237
+ "type": "array",
238
+ "items": {
239
+ "anyOf": [
240
+ {
241
+ "type": "string",
242
+ "maxLength": 500
243
+ },
244
+ {
245
+ "type": "number"
246
+ },
247
+ {
248
+ "type": "boolean"
249
+ }
250
+ ]
251
+ }
252
+ }
253
+ ]
254
+ }
255
+ },
256
+ "required": [
257
+ "field",
258
+ "op",
259
+ "value"
260
+ ]
261
+ }
262
+ },
263
+ "crmFields": {
264
+ "description": "CRM and support tool account fields to return on each customer, as crm; use outlit_list_crm_fields to find keys.",
265
+ "maxItems": 5,
266
+ "type": "array",
267
+ "items": {
268
+ "type": "object",
269
+ "properties": {
270
+ "provider": {
271
+ "type": "string",
272
+ "enum": [
273
+ "hubspot",
274
+ "salesforce",
275
+ "attio",
276
+ "pylon"
277
+ ]
278
+ },
279
+ "key": {
280
+ "type": "string",
281
+ "minLength": 1,
282
+ "maxLength": 191,
283
+ "description": "The field's key (API name) in that system, as outlit_list_crm_fields lists it."
284
+ }
285
+ },
286
+ "required": [
287
+ "provider",
288
+ "key"
289
+ ]
290
+ }
291
+ },
161
292
  "limit": {
162
293
  "description": "Results per page (max 1000)",
163
294
  "default": 50,
@@ -170,13 +301,14 @@ var publicToolContracts = {
170
301
  "type": "string"
171
302
  },
172
303
  "orderBy": {
173
- "description": "Field to order results by",
304
+ "description": "Field to order results by: last_activity_at, first_seen_at, name, arr_cents. arr_cents puts customers whose ARR is unknown last when descending, and compares amounts across currencies without converting them; arrCurrencies in the response says when that happened.",
174
305
  "default": "last_activity_at",
175
306
  "type": "string",
176
307
  "enum": [
177
308
  "last_activity_at",
178
309
  "first_seen_at",
179
310
  "name",
311
+ "arr_cents",
180
312
  "mrr_cents"
181
313
  ]
182
314
  },
@@ -268,24 +400,38 @@ var publicToolContracts = {
268
400
  "minimum": 0,
269
401
  "maximum": 9007199254740991
270
402
  },
271
- "currentMrr": {
403
+ "arr": {
272
404
  "anyOf": [
273
405
  {
274
- "type": "number"
406
+ "type": "object",
407
+ "properties": {
408
+ "amount": {
409
+ "type": "integer",
410
+ "minimum": 0,
411
+ "maximum": 9007199254740991,
412
+ "description": "Annualized revenue run rate, the same ARR figure the Outlit app shows: an integer in the billing provider's units for `currency`. For USD, EUR, GBP and CAD this is cents: divide by 100 (e.g. 1234500 is $12,345, USD). Other currencies follow the provider's amount rules (Stripe's currency docs), so don't assume a divisor for them. 0 for a churned, paused or trialing customer."
413
+ },
414
+ "currency": {
415
+ "type": "string",
416
+ "description": "ISO currency code of amount."
417
+ },
418
+ "estimated": {
419
+ "type": "boolean",
420
+ "description": "The amount includes a usage or per-seat estimate, shown as ~ in the app."
421
+ }
422
+ },
423
+ "required": [
424
+ "amount",
425
+ "currency",
426
+ "estimated"
427
+ ],
428
+ "additionalProperties": false
275
429
  },
276
430
  {
277
431
  "type": "null"
278
432
  }
279
433
  ],
280
- "description": "Monthly recurring revenue as an integer amount in the billing provider's units for the customer's currency, which this result doesn't name. For USD, EUR, GBP and CAD this is cents: divide by 100 (e.g. 1234500 is $12,345, USD). Other currencies follow the provider's amount rules (Stripe's currency docs), so don't assume a divisor for them. ARR is 12 \xD7 this value in the same units. Null unless mrrCalculationStatus is calculated."
281
- },
282
- "mrrCalculationStatus": {
283
- "type": "string",
284
- "enum": [
285
- "calculated",
286
- "mixed_currency",
287
- "unavailable"
288
- ]
434
+ "description": "Null when the app shows no ARR for this customer."
289
435
  },
290
436
  "owner": {
291
437
  "anyOf": [
@@ -325,6 +471,66 @@ var publicToolContracts = {
325
471
  "type": "null"
326
472
  }
327
473
  ]
474
+ },
475
+ "crm": {
476
+ "description": "With crmFields: each asked-for field, in the order asked.",
477
+ "type": "array",
478
+ "items": {
479
+ "type": "object",
480
+ "properties": {
481
+ "field": {
482
+ "type": "object",
483
+ "properties": {
484
+ "provider": {
485
+ "type": "string",
486
+ "enum": [
487
+ "hubspot",
488
+ "salesforce",
489
+ "attio",
490
+ "pylon"
491
+ ]
492
+ },
493
+ "key": {
494
+ "type": "string",
495
+ "minLength": 1,
496
+ "maxLength": 191,
497
+ "description": "The field's key (API name) in that system, as outlit_list_crm_fields lists it."
498
+ }
499
+ },
500
+ "required": [
501
+ "provider",
502
+ "key"
503
+ ],
504
+ "additionalProperties": false
505
+ },
506
+ "label": {
507
+ "type": "string"
508
+ },
509
+ "values": {
510
+ "type": "array",
511
+ "items": {
512
+ "anyOf": [
513
+ {
514
+ "type": "string"
515
+ },
516
+ {
517
+ "type": "number"
518
+ },
519
+ {
520
+ "type": "boolean"
521
+ }
522
+ ]
523
+ },
524
+ "description": "The field's values across the customer's linked accounts in that system, without duplicates; a multi-value field's values are listed one by one. Empty when no linked account has one."
525
+ }
526
+ },
527
+ "required": [
528
+ "field",
529
+ "label",
530
+ "values"
531
+ ],
532
+ "additionalProperties": false
533
+ }
328
534
  }
329
535
  },
330
536
  "required": [
@@ -336,8 +542,7 @@ var publicToolContracts = {
336
542
  "firstSeenAt",
337
543
  "lastActivityAt",
338
544
  "contactCount",
339
- "currentMrr",
340
- "mrrCalculationStatus",
545
+ "arr",
341
546
  "owner",
342
547
  "daysSinceActivity"
343
548
  ],
@@ -372,6 +577,13 @@ var publicToolContracts = {
372
577
  "total"
373
578
  ],
374
579
  "additionalProperties": false
580
+ },
581
+ "arrCurrencies": {
582
+ "description": "Present when the call ordered or bounded by ARR: the ARR currencies among all matched customers. With more than one, amounts were compared as if they were the same unit, so a ranking mixes currencies; pass arrCurrency to rank within one.",
583
+ "type": "array",
584
+ "items": {
585
+ "type": "string"
586
+ }
375
587
  }
376
588
  },
377
589
  "required": [
@@ -381,104 +593,48 @@ var publicToolContracts = {
381
593
  "additionalProperties": false
382
594
  }
383
595
  },
384
- "outlit_list_users": {
385
- "toolName": "outlit_list_users",
386
- "commandId": "user.list",
596
+ "outlit_list_crm_fields": {
597
+ "toolName": "outlit_list_crm_fields",
598
+ "commandId": "crm_field.list",
387
599
  "commandVersion": 1,
388
- "ownerDomain": "users",
389
- "title": "List Users",
390
- "description": "Browse and filter users. Use this to find users by journey stage, activity recency, customer, or email/name. Returns a paginated list with activity info and each user's sources: where Outlit found them (CRM, support tool, product analytics, Slack) and the calls, meetings, emails, tickets and Slack threads they took part in.",
600
+ "ownerDomain": "customers",
601
+ "title": "List CRM Fields",
602
+ "description": "List the account fields the workspace's CRM and support tools hold (segment, health, stage, owner and custom fields), with each field's label, type, picklist options, the values customers' linked accounts hold, and how many accounts hold one. Use it to find the field and values for outlit_list_customers' crm filter and crmFields, for questions across many customers; for one customer's fields use outlit_get_customer with include crm.",
391
603
  "annotations": {
392
604
  "readOnlyHint": true,
393
605
  "destructiveHint": false,
606
+ "idempotentHint": true,
394
607
  "openWorldHint": false
395
608
  },
396
609
  "inputSchema": {
397
610
  "$schema": "https://json-schema.org/draft/2020-12/schema",
398
611
  "type": "object",
399
612
  "properties": {
400
- "journeyStage": {
401
- "description": "Filter by user journey stage",
613
+ "provider": {
614
+ "description": "Only this system's fields",
402
615
  "type": "string",
403
616
  "enum": [
404
- "DISCOVERED",
405
- "SIGNED_UP",
406
- "ACTIVATED",
407
- "ENGAGED",
408
- "INACTIVE"
617
+ "hubspot",
618
+ "salesforce",
619
+ "attio",
620
+ "pylon"
409
621
  ]
410
622
  },
411
- "customerId": {
412
- "description": "Filter users by customer ID",
413
- "type": "string",
414
- "maxLength": 500
415
- },
416
- "traitFilters": {
417
- "description": "Filter by exact trait values using key/value pairs",
418
- "type": "object",
419
- "propertyNames": {
420
- "type": "string",
421
- "pattern": "^[A-Za-z0-9_-]{1,100}$"
422
- },
423
- "additionalProperties": {
424
- "anyOf": [
425
- {
426
- "type": "string",
427
- "maxLength": 500
428
- },
429
- {
430
- "type": "number"
431
- },
432
- {
433
- "type": "boolean"
434
- }
435
- ]
436
- }
437
- },
438
- "hasActivityInLast": {
439
- "description": "Filter users active within this window. Format: Nd, Nh, or Nm (e.g., '7d', '24h', '90m')",
440
- "type": "string",
441
- "pattern": "^\\d+(d|h|m)$"
442
- },
443
- "noActivityInLast": {
444
- "description": "Filter users NOT active within this window. Format: Nd, Nh, or Nm (e.g., '30d', '2h')",
445
- "type": "string",
446
- "pattern": "^\\d+(d|h|m)$"
447
- },
448
623
  "search": {
449
- "description": "Search by user email or name (case-insensitive)",
624
+ "description": "Only fields whose key or label contains this text, ignoring case",
450
625
  "type": "string",
451
- "maxLength": 500
626
+ "maxLength": 100
452
627
  },
453
628
  "limit": {
454
- "description": "Results per page (max 1000)",
455
- "default": 50,
456
- "type": "number",
629
+ "description": "Fields per page (max 50)",
630
+ "default": 20,
631
+ "type": "integer",
457
632
  "minimum": 1,
458
- "maximum": 1e3
633
+ "maximum": 50
459
634
  },
460
635
  "cursor": {
461
636
  "description": "Pagination cursor from previous response",
462
637
  "type": "string"
463
- },
464
- "orderBy": {
465
- "description": "Field to order by",
466
- "default": "last_activity_at",
467
- "type": "string",
468
- "enum": [
469
- "last_activity_at",
470
- "first_seen_at",
471
- "email"
472
- ]
473
- },
474
- "orderDirection": {
475
- "description": "Sort direction",
476
- "default": "desc",
477
- "type": "string",
478
- "enum": [
479
- "asc",
480
- "desc"
481
- ]
482
638
  }
483
639
  }
484
640
  },
@@ -491,20 +647,263 @@ var publicToolContracts = {
491
647
  "items": {
492
648
  "type": "object",
493
649
  "properties": {
494
- "id": {
495
- "type": "string"
496
- },
497
- "email": {
498
- "anyOf": [
499
- {
500
- "type": "string"
650
+ "field": {
651
+ "type": "object",
652
+ "properties": {
653
+ "provider": {
654
+ "type": "string",
655
+ "enum": [
656
+ "hubspot",
657
+ "salesforce",
658
+ "attio",
659
+ "pylon"
660
+ ]
501
661
  },
502
- {
503
- "type": "null"
662
+ "key": {
663
+ "type": "string",
664
+ "minLength": 1,
665
+ "maxLength": 191,
666
+ "description": "The field's key (API name) in that system, as outlit_list_crm_fields lists it."
504
667
  }
505
- ]
506
- },
507
- "name": {
668
+ },
669
+ "required": [
670
+ "provider",
671
+ "key"
672
+ ],
673
+ "additionalProperties": false,
674
+ "description": "Pass this as-is to outlit_list_customers' crm filter or crmFields."
675
+ },
676
+ "label": {
677
+ "type": "string"
678
+ },
679
+ "type": {
680
+ "type": "string",
681
+ "description": "The field's type in that system, as it names it."
682
+ },
683
+ "options": {
684
+ "anyOf": [
685
+ {
686
+ "type": "array",
687
+ "items": {
688
+ "type": "string"
689
+ }
690
+ },
691
+ {
692
+ "type": "null"
693
+ }
694
+ ],
695
+ "description": "A picklist's choices as that system defines them; null for other fields."
696
+ },
697
+ "observedValues": {
698
+ "type": "array",
699
+ "items": {
700
+ "anyOf": [
701
+ {
702
+ "type": "string"
703
+ },
704
+ {
705
+ "type": "number"
706
+ },
707
+ {
708
+ "type": "boolean"
709
+ }
710
+ ]
711
+ },
712
+ "description": "Up to 20 of the values the customers' linked accounts hold, most common first, a multi-value field's values one by one."
713
+ },
714
+ "accounts": {
715
+ "type": "integer",
716
+ "minimum": 0,
717
+ "maximum": 9007199254740991,
718
+ "description": "How many accounts linked to customers hold a value."
719
+ }
720
+ },
721
+ "required": [
722
+ "field",
723
+ "label",
724
+ "type",
725
+ "options",
726
+ "observedValues",
727
+ "accounts"
728
+ ],
729
+ "additionalProperties": false
730
+ }
731
+ },
732
+ "pagination": {
733
+ "type": "object",
734
+ "properties": {
735
+ "hasMore": {
736
+ "type": "boolean"
737
+ },
738
+ "nextCursor": {
739
+ "anyOf": [
740
+ {
741
+ "type": "string"
742
+ },
743
+ {
744
+ "type": "null"
745
+ }
746
+ ]
747
+ }
748
+ },
749
+ "required": [
750
+ "hasMore",
751
+ "nextCursor"
752
+ ],
753
+ "additionalProperties": false
754
+ }
755
+ },
756
+ "required": [
757
+ "items",
758
+ "pagination"
759
+ ],
760
+ "additionalProperties": false
761
+ }
762
+ },
763
+ "outlit_list_users": {
764
+ "toolName": "outlit_list_users",
765
+ "commandId": "user.list",
766
+ "commandVersion": 1,
767
+ "ownerDomain": "users",
768
+ "title": "List Users",
769
+ "description": "Browse and filter users. Use this to find users by journey stage, activity recency, customer, or email/name. Returns a paginated list with activity info and each user's sources: where Outlit found them (CRM, support tool, product analytics, Slack) and the calls, meetings, emails, tickets and Slack threads they took part in. Pass include crm to add each user's contact records in the CRM and support tool with their own fields (job title, lead status, custom fields) as stored there, which can be hundreds, so request it only when needed.",
770
+ "annotations": {
771
+ "readOnlyHint": true,
772
+ "destructiveHint": false,
773
+ "idempotentHint": true,
774
+ "openWorldHint": false
775
+ },
776
+ "inputSchema": {
777
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
778
+ "type": "object",
779
+ "properties": {
780
+ "journeyStage": {
781
+ "description": "Filter by user journey stage",
782
+ "type": "string",
783
+ "enum": [
784
+ "DISCOVERED",
785
+ "SIGNED_UP",
786
+ "ACTIVATED",
787
+ "ENGAGED",
788
+ "INACTIVE"
789
+ ]
790
+ },
791
+ "customerId": {
792
+ "description": "Filter users by customer ID",
793
+ "type": "string",
794
+ "maxLength": 500
795
+ },
796
+ "traitFilters": {
797
+ "description": "Filter by exact trait values using key/value pairs",
798
+ "type": "object",
799
+ "propertyNames": {
800
+ "type": "string",
801
+ "pattern": "^[A-Za-z0-9_-]{1,100}$"
802
+ },
803
+ "additionalProperties": {
804
+ "anyOf": [
805
+ {
806
+ "type": "string",
807
+ "maxLength": 500
808
+ },
809
+ {
810
+ "type": "number"
811
+ },
812
+ {
813
+ "type": "boolean"
814
+ }
815
+ ]
816
+ }
817
+ },
818
+ "hasActivityInLast": {
819
+ "description": "Filter users active within this window. Format: Nd, Nh, or Nm (e.g., '7d', '24h', '90m')",
820
+ "type": "string",
821
+ "pattern": "^\\d+(d|h|m)$"
822
+ },
823
+ "noActivityInLast": {
824
+ "description": "Filter users NOT active within this window. Format: Nd, Nh, or Nm (e.g., '30d', '2h')",
825
+ "type": "string",
826
+ "pattern": "^\\d+(d|h|m)$"
827
+ },
828
+ "search": {
829
+ "description": "Search by user email or name (case-insensitive)",
830
+ "type": "string",
831
+ "maxLength": 500
832
+ },
833
+ "limit": {
834
+ "description": "Results per page (max 1000)",
835
+ "default": 50,
836
+ "type": "number",
837
+ "minimum": 1,
838
+ "maximum": 1e3
839
+ },
840
+ "cursor": {
841
+ "description": "Pagination cursor from previous response",
842
+ "type": "string"
843
+ },
844
+ "orderBy": {
845
+ "description": "Field to order by",
846
+ "default": "last_activity_at",
847
+ "type": "string",
848
+ "enum": [
849
+ "last_activity_at",
850
+ "first_seen_at",
851
+ "email"
852
+ ]
853
+ },
854
+ "orderDirection": {
855
+ "description": "Sort direction",
856
+ "default": "desc",
857
+ "type": "string",
858
+ "enum": [
859
+ "asc",
860
+ "desc"
861
+ ]
862
+ },
863
+ "include": {
864
+ "description": "Additional data to include for each user. crm adds the user's contact records in the CRM and support tool with their own fields (job title, lead status, custom fields) as stored there; request it only when needed.",
865
+ "type": "array",
866
+ "items": {
867
+ "type": "string",
868
+ "enum": [
869
+ "crm"
870
+ ]
871
+ }
872
+ },
873
+ "crmFields": {
874
+ "description": "With include crm only: the CRM fields to return, by key or label (case is ignored), for example the keys an earlier response listed in omittedFields. Send [] (the default) for every field.",
875
+ "maxItems": 100,
876
+ "type": "array",
877
+ "items": {
878
+ "type": "string",
879
+ "maxLength": 191
880
+ }
881
+ }
882
+ }
883
+ },
884
+ "outputSchema": {
885
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
886
+ "type": "object",
887
+ "properties": {
888
+ "items": {
889
+ "type": "array",
890
+ "items": {
891
+ "type": "object",
892
+ "properties": {
893
+ "id": {
894
+ "type": "string"
895
+ },
896
+ "email": {
897
+ "anyOf": [
898
+ {
899
+ "type": "string"
900
+ },
901
+ {
902
+ "type": "null"
903
+ }
904
+ ]
905
+ },
906
+ "name": {
508
907
  "anyOf": [
509
908
  {
510
909
  "type": "string"
@@ -640,47 +1039,132 @@ var publicToolContracts = {
640
1039
  },
641
1040
  "description": "Where Outlit found this person: the systems that hold a record of them and the conversations they took part in. Empty when Outlit has no source recorded; absent from servers that predate it."
642
1041
  },
643
- "relationshipRole": {
644
- "anyOf": [
645
- {
646
- "type": "string"
647
- },
648
- {
649
- "type": "null"
650
- }
651
- ]
652
- },
653
- "jobTitle": {
654
- "anyOf": [
655
- {
656
- "type": "string"
657
- },
658
- {
659
- "type": "null"
660
- }
661
- ]
662
- },
663
- "department": {
664
- "anyOf": [
665
- {
666
- "type": "string"
667
- },
668
- {
669
- "type": "null"
670
- }
671
- ]
672
- },
673
- "employmentStartDate": {
1042
+ "crm": {
1043
+ "description": "With include crm: the contact records in the CRM and support tool that this user is linked to, one entry each, with the contact's own fields as stored there. Empty when the user has no linked contact; null when the read is bound to a past point in time. Absent unless requested, when the section is not enabled for the workspace, or when the size limit left no room for this user (then ask for fewer users or crmFields). The size limit is shared by all users in the response.",
674
1044
  "anyOf": [
675
1045
  {
676
- "type": "string",
677
- "pattern": "^\\d{4}-\\d{2}-\\d{2}$"
678
- },
679
- {
680
- "type": "null"
681
- }
682
- ]
683
- }
1046
+ "type": "array",
1047
+ "items": {
1048
+ "type": "object",
1049
+ "properties": {
1050
+ "provider": {
1051
+ "type": "string",
1052
+ "description": "The system that holds the contact: hubspot, salesforce, attio or pylon."
1053
+ },
1054
+ "connectionId": {
1055
+ "type": "string",
1056
+ "description": "The Outlit integration connection the contact syncs through."
1057
+ },
1058
+ "contactId": {
1059
+ "type": "string",
1060
+ "description": "The contact's id in that system."
1061
+ },
1062
+ "fields": {
1063
+ "type": "array",
1064
+ "items": {
1065
+ "type": "object",
1066
+ "properties": {
1067
+ "key": {
1068
+ "type": "string",
1069
+ "description": "The field's API name or slug in that system."
1070
+ },
1071
+ "label": {
1072
+ "type": "string",
1073
+ "description": "The field's name in that system's UI; the key when unknown."
1074
+ },
1075
+ "value": {
1076
+ "description": "The value as that system stores it: a string, number, boolean, array, or for Attio its value objects. A picklist holds the option's stored value, not its label."
1077
+ },
1078
+ "custom": {
1079
+ "type": "boolean",
1080
+ "description": "True for a field the customer's team added to that system."
1081
+ }
1082
+ },
1083
+ "required": [
1084
+ "key",
1085
+ "label",
1086
+ "value",
1087
+ "custom"
1088
+ ],
1089
+ "additionalProperties": false
1090
+ },
1091
+ "description": "The contact's non-empty fields, sorted by key."
1092
+ },
1093
+ "omittedFields": {
1094
+ "description": "Keys of fields left out so the response stays within its size limit, as many as fit. Ask for them with crmFields.",
1095
+ "type": "array",
1096
+ "items": {
1097
+ "type": "string"
1098
+ }
1099
+ },
1100
+ "omittedFieldCount": {
1101
+ "description": "How many fields were left out, including any not named in omittedFields.",
1102
+ "type": "integer",
1103
+ "minimum": 0,
1104
+ "maximum": 9007199254740991
1105
+ }
1106
+ },
1107
+ "required": [
1108
+ "provider",
1109
+ "connectionId",
1110
+ "contactId",
1111
+ "fields"
1112
+ ],
1113
+ "additionalProperties": false
1114
+ }
1115
+ },
1116
+ {
1117
+ "type": "null"
1118
+ }
1119
+ ]
1120
+ },
1121
+ "omittedCrmContacts": {
1122
+ "description": "With include crm: how many of this user's linked contacts are left out of crm so the response stays within its size limit. Absent when none are.",
1123
+ "type": "integer",
1124
+ "minimum": 1,
1125
+ "maximum": 9007199254740991
1126
+ },
1127
+ "relationshipRole": {
1128
+ "anyOf": [
1129
+ {
1130
+ "type": "string"
1131
+ },
1132
+ {
1133
+ "type": "null"
1134
+ }
1135
+ ]
1136
+ },
1137
+ "jobTitle": {
1138
+ "anyOf": [
1139
+ {
1140
+ "type": "string"
1141
+ },
1142
+ {
1143
+ "type": "null"
1144
+ }
1145
+ ]
1146
+ },
1147
+ "department": {
1148
+ "anyOf": [
1149
+ {
1150
+ "type": "string"
1151
+ },
1152
+ {
1153
+ "type": "null"
1154
+ }
1155
+ ]
1156
+ },
1157
+ "employmentStartDate": {
1158
+ "anyOf": [
1159
+ {
1160
+ "type": "string",
1161
+ "pattern": "^\\d{4}-\\d{2}-\\d{2}$"
1162
+ },
1163
+ {
1164
+ "type": "null"
1165
+ }
1166
+ ]
1167
+ }
684
1168
  },
685
1169
  "required": [
686
1170
  "id",
@@ -747,6 +1231,7 @@ var publicToolContracts = {
747
1231
  "annotations": {
748
1232
  "readOnlyHint": true,
749
1233
  "destructiveHint": false,
1234
+ "idempotentHint": true,
750
1235
  "openWorldHint": false
751
1236
  },
752
1237
  "inputSchema": {
@@ -935,10 +1420,11 @@ var publicToolContracts = {
935
1420
  "commandVersion": 1,
936
1421
  "ownerDomain": "customers",
937
1422
  "title": "Get Customer",
938
- "description": "Get full details for a single customer. Optionally include users (each with their sources: where Outlit found them and the conversations they took part in), revenue, recent activity, engagement metrics, or company enrichment. Revenue amounts (currentMrr, lifetimeRevenue) are in the billing provider's units for the customer's currency, which the result doesn't name. For USD, EUR, GBP and CAD these are cents: divide by 100 (e.g. 1234500 is $12,345, USD). Other currencies follow the provider's amount rules. ARR is 12 \xD7 currentMrr in the same units.",
1423
+ "description": "Get full details for a single customer. Optionally include users (each with their sources: where Outlit found them and the conversations they took part in), revenue, recent activity, engagement metrics, company enrichment, the renewal date and its source, or crm: the CRM and support tool accounts linked to the customer with their own fields (segment, health, stage, lifecycle, owner and custom fields) as stored and the contacts associated with each account; request it when the question is about how that system classifies the account (its stage, segment, health or owner) or who the account's contacts are, and pass crmFields to read only some fields, since an account can carry hundreds; or links: the id of every record in another system linked to the customer (billing customers, CRM and support accounts, product analytics groups, Slack channels). With both users and crm, each user also carries crm: their contact records there, with their own fields. Revenue includes arr, the annualized revenue run rate, exactly as the customer page shows it, with its currency, whether it is an estimate, the revenue lifecycle and the parts it is counted from; amounts are in the billing provider's units for that currency (for USD, EUR, GBP and CAD these are cents: divide by 100, e.g. 1234500 is $12,345, USD; other currencies follow the provider's amount rules). lifetimeRevenueCurrency names lifetimeRevenue's currency.",
939
1424
  "annotations": {
940
1425
  "readOnlyHint": true,
941
1426
  "destructiveHint": false,
1427
+ "idempotentHint": true,
942
1428
  "openWorldHint": false
943
1429
  },
944
1430
  "inputSchema": {
@@ -961,7 +1447,10 @@ var publicToolContracts = {
961
1447
  "revenue",
962
1448
  "recentTimeline",
963
1449
  "behaviorMetrics",
964
- "enrichment"
1450
+ "enrichment",
1451
+ "renewal",
1452
+ "crm",
1453
+ "links"
965
1454
  ]
966
1455
  }
967
1456
  },
@@ -975,6 +1464,23 @@ var publicToolContracts = {
975
1464
  "30d",
976
1465
  "90d"
977
1466
  ]
1467
+ },
1468
+ "subscriptions": {
1469
+ "description": "With include revenue only: which subscriptions revenue.subscriptions lists. live (the default when omitted) lists the ones that bill now; all adds canceled ones with endedAt (the 20 most recently ended), for questions like whether a canceled subscription was replaced or why a customer has two billing records.",
1470
+ "type": "string",
1471
+ "enum": [
1472
+ "live",
1473
+ "all"
1474
+ ]
1475
+ },
1476
+ "crmFields": {
1477
+ "description": "With include crm only: the CRM fields to return, by key or label (case is ignored), for example the keys an earlier response listed in omittedFields. Send [] (the default) for every field. Applies to the accounts and to the users' contacts.",
1478
+ "maxItems": 100,
1479
+ "type": "array",
1480
+ "items": {
1481
+ "type": "string",
1482
+ "maxLength": 191
1483
+ }
978
1484
  }
979
1485
  },
980
1486
  "required": [
@@ -1210,97 +1716,587 @@ var publicToolContracts = {
1210
1716
  },
1211
1717
  "description": "Where Outlit found this person: the systems that hold a record of them and the conversations they took part in. Empty when Outlit has no source recorded; absent from servers that predate it."
1212
1718
  },
1719
+ "crm": {
1720
+ "description": "With include crm: the contact records in the CRM and support tool that this user is linked to, one entry each, with the contact's own fields as stored there. Empty when the user has no linked contact; null when the read is bound to a past point in time. Absent unless requested, when the section is not enabled for the workspace, or when the size limit left no room for this user (then ask for fewer users or crmFields). The size limit is shared by all users in the response.",
1721
+ "anyOf": [
1722
+ {
1723
+ "type": "array",
1724
+ "items": {
1725
+ "type": "object",
1726
+ "properties": {
1727
+ "provider": {
1728
+ "type": "string",
1729
+ "description": "The system that holds the contact: hubspot, salesforce, attio or pylon."
1730
+ },
1731
+ "connectionId": {
1732
+ "type": "string",
1733
+ "description": "The Outlit integration connection the contact syncs through."
1734
+ },
1735
+ "contactId": {
1736
+ "type": "string",
1737
+ "description": "The contact's id in that system."
1738
+ },
1739
+ "fields": {
1740
+ "type": "array",
1741
+ "items": {
1742
+ "type": "object",
1743
+ "properties": {
1744
+ "key": {
1745
+ "type": "string",
1746
+ "description": "The field's API name or slug in that system."
1747
+ },
1748
+ "label": {
1749
+ "type": "string",
1750
+ "description": "The field's name in that system's UI; the key when unknown."
1751
+ },
1752
+ "value": {
1753
+ "description": "The value as that system stores it: a string, number, boolean, array, or for Attio its value objects. A picklist holds the option's stored value, not its label."
1754
+ },
1755
+ "custom": {
1756
+ "type": "boolean",
1757
+ "description": "True for a field the customer's team added to that system."
1758
+ }
1759
+ },
1760
+ "required": [
1761
+ "key",
1762
+ "label",
1763
+ "value",
1764
+ "custom"
1765
+ ],
1766
+ "additionalProperties": false
1767
+ },
1768
+ "description": "The contact's non-empty fields, sorted by key."
1769
+ },
1770
+ "omittedFields": {
1771
+ "description": "Keys of fields left out so the response stays within its size limit, as many as fit. Ask for them with crmFields.",
1772
+ "type": "array",
1773
+ "items": {
1774
+ "type": "string"
1775
+ }
1776
+ },
1777
+ "omittedFieldCount": {
1778
+ "description": "How many fields were left out, including any not named in omittedFields.",
1779
+ "type": "integer",
1780
+ "minimum": 0,
1781
+ "maximum": 9007199254740991
1782
+ }
1783
+ },
1784
+ "required": [
1785
+ "provider",
1786
+ "connectionId",
1787
+ "contactId",
1788
+ "fields"
1789
+ ],
1790
+ "additionalProperties": false
1791
+ }
1792
+ },
1793
+ {
1794
+ "type": "null"
1795
+ }
1796
+ ]
1797
+ },
1798
+ "omittedCrmContacts": {
1799
+ "description": "With include crm: how many of this user's linked contacts are left out of crm so the response stays within its size limit. Absent when none are.",
1800
+ "type": "integer",
1801
+ "minimum": 1,
1802
+ "maximum": 9007199254740991
1803
+ },
1213
1804
  "relationshipRole": {
1214
1805
  "anyOf": [
1215
1806
  {
1216
1807
  "type": "string"
1217
1808
  },
1218
- {
1219
- "type": "null"
1220
- }
1221
- ]
1222
- },
1223
- "jobTitle": {
1224
- "anyOf": [
1225
- {
1226
- "type": "string"
1809
+ {
1810
+ "type": "null"
1811
+ }
1812
+ ]
1813
+ },
1814
+ "jobTitle": {
1815
+ "anyOf": [
1816
+ {
1817
+ "type": "string"
1818
+ },
1819
+ {
1820
+ "type": "null"
1821
+ }
1822
+ ]
1823
+ },
1824
+ "department": {
1825
+ "anyOf": [
1826
+ {
1827
+ "type": "string"
1828
+ },
1829
+ {
1830
+ "type": "null"
1831
+ }
1832
+ ]
1833
+ },
1834
+ "employmentStartDate": {
1835
+ "anyOf": [
1836
+ {
1837
+ "type": "string",
1838
+ "pattern": "^\\d{4}-\\d{2}-\\d{2}$"
1839
+ },
1840
+ {
1841
+ "type": "null"
1842
+ }
1843
+ ]
1844
+ }
1845
+ },
1846
+ "required": [
1847
+ "id",
1848
+ "email",
1849
+ "name",
1850
+ "journeyStage",
1851
+ "lastActivityAt",
1852
+ "relationshipRole",
1853
+ "jobTitle",
1854
+ "department",
1855
+ "employmentStartDate"
1856
+ ],
1857
+ "additionalProperties": false
1858
+ }
1859
+ },
1860
+ "revenue": {
1861
+ "type": "object",
1862
+ "properties": {
1863
+ "arr": {
1864
+ "anyOf": [
1865
+ {
1866
+ "type": "object",
1867
+ "properties": {
1868
+ "amount": {
1869
+ "type": "integer",
1870
+ "minimum": 0,
1871
+ "maximum": 9007199254740991,
1872
+ "description": "Annualized revenue run rate, the same ARR figure the customer page shows: an integer in the billing provider's units for `currency`. For USD, EUR, GBP and CAD this is cents: divide by 100 (e.g. 1234500 is $12,345, USD). Other currencies follow the provider's amount rules (Stripe's currency docs), so don't assume a divisor for them. 0 for a churned, paused or trialing customer."
1873
+ },
1874
+ "currency": {
1875
+ "type": "string",
1876
+ "description": "ISO currency code of amount and parts."
1877
+ },
1878
+ "estimated": {
1879
+ "type": "boolean",
1880
+ "description": "The amount includes a usage or per-seat estimate, shown as ~ in the app."
1881
+ },
1882
+ "lifecycle": {
1883
+ "anyOf": [
1884
+ {
1885
+ "type": "string",
1886
+ "enum": [
1887
+ "active",
1888
+ "past_due",
1889
+ "paused",
1890
+ "churned",
1891
+ "trialing"
1892
+ ]
1893
+ },
1894
+ {
1895
+ "type": "null"
1896
+ }
1897
+ ],
1898
+ "description": "The customer's revenue state; null when unknown."
1899
+ },
1900
+ "parts": {
1901
+ "type": "object",
1902
+ "properties": {
1903
+ "subscriptions": {
1904
+ "anyOf": [
1905
+ {
1906
+ "type": "integer",
1907
+ "minimum": -9007199254740991,
1908
+ "maximum": 9007199254740991
1909
+ },
1910
+ {
1911
+ "type": "null"
1912
+ }
1913
+ ],
1914
+ "description": "Active subscriptions at list price, annualized."
1915
+ },
1916
+ "usage": {
1917
+ "anyOf": [
1918
+ {
1919
+ "type": "integer",
1920
+ "minimum": -9007199254740991,
1921
+ "maximum": 9007199254740991
1922
+ },
1923
+ {
1924
+ "type": "null"
1925
+ }
1926
+ ],
1927
+ "description": "Annualized usage estimate."
1928
+ },
1929
+ "invoicedLast12Months": {
1930
+ "anyOf": [
1931
+ {
1932
+ "type": "integer",
1933
+ "minimum": -9007199254740991,
1934
+ "maximum": 9007199254740991
1935
+ },
1936
+ {
1937
+ "type": "null"
1938
+ }
1939
+ ],
1940
+ "description": "Invoice charges outside any subscription (one-time invoice items, leaving out setup, onboarding and implementation fees and prorations) whose service period began in the last 12 months. Subscription charges are never in it, so it is not the customer's total invoiced."
1941
+ }
1942
+ },
1943
+ "required": [
1944
+ "subscriptions",
1945
+ "usage",
1946
+ "invoicedLast12Months"
1947
+ ],
1948
+ "additionalProperties": false,
1949
+ "description": "What amount was counted from, in the same units: the larger of subscriptions plus usage, and invoicedLast12Months. A part is null when unknown or not applicable."
1950
+ }
1951
+ },
1952
+ "required": [
1953
+ "amount",
1954
+ "currency",
1955
+ "estimated",
1956
+ "lifecycle",
1957
+ "parts"
1958
+ ],
1959
+ "additionalProperties": false
1960
+ },
1961
+ {
1962
+ "type": "null"
1963
+ }
1964
+ ],
1965
+ "description": "Null when the app shows no ARR for this customer."
1966
+ },
1967
+ "lifetimeRevenue": {
1968
+ "type": "number",
1969
+ "description": "Lifetime revenue in the billing provider's units for lifetimeRevenueCurrency, like arr.amount: cents for USD, EUR, GBP and CAD, so divide by 100. Other currencies follow the provider's amount rules, so don't assume a divisor for them."
1970
+ },
1971
+ "lifetimeRevenueCurrency": {
1972
+ "description": "ISO currency code of lifetimeRevenue; null when nothing has been paid or the currency is unknown.",
1973
+ "anyOf": [
1974
+ {
1975
+ "type": "string"
1976
+ },
1977
+ {
1978
+ "type": "null"
1979
+ }
1980
+ ]
1981
+ },
1982
+ "activeSubscriptions": {
1983
+ "type": "integer",
1984
+ "minimum": 0,
1985
+ "maximum": 9007199254740991,
1986
+ "description": "Subscriptions that bill now: active, trialing or past due. billingStatus says whether payments are behind."
1987
+ },
1988
+ "subscriptions": {
1989
+ "description": "The customer's live subscriptions in the billing provider (active, past due, paused or trialing) with every item, including items an invoice skips in a given cycle. With input subscriptions all, canceled subscriptions follow the live ones, most recently ended first (at most 20). Absent when unavailable.",
1990
+ "type": "array",
1991
+ "items": {
1992
+ "type": "object",
1993
+ "properties": {
1994
+ "id": {
1995
+ "type": "string",
1996
+ "description": "The billing provider's subscription id (sub_...)."
1997
+ },
1998
+ "status": {
1999
+ "type": "string",
2000
+ "description": "The provider's own status: active, past_due, paused or trialing, and with subscriptions all also canceled."
2001
+ },
2002
+ "paused": {
2003
+ "type": "boolean",
2004
+ "description": "Collection is paused."
2005
+ },
2006
+ "currentPeriodEnd": {
2007
+ "anyOf": [
2008
+ {
2009
+ "type": "string",
2010
+ "format": "date-time",
2011
+ "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
2012
+ },
2013
+ {
2014
+ "type": "null"
2015
+ }
2016
+ ],
2017
+ "description": "End of the current billing period. With items on different intervals it is the shortest interval's period, not the term."
2018
+ },
2019
+ "cancelAtPeriodEnd": {
2020
+ "anyOf": [
2021
+ {
2022
+ "type": "boolean"
2023
+ },
2024
+ {
2025
+ "type": "null"
2026
+ }
2027
+ ],
2028
+ "description": "The subscription is set to end at currentPeriodEnd instead of renewing. Null when unknown: Outlit's stored billing data predates it, and cancelAt is then null too."
2029
+ },
2030
+ "cancelAt": {
2031
+ "anyOf": [
2032
+ {
2033
+ "type": "string",
2034
+ "format": "date-time",
2035
+ "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
2036
+ },
2037
+ {
2038
+ "type": "null"
2039
+ }
2040
+ ],
2041
+ "description": "When a scheduled cancellation ends the subscription; null when none is scheduled or unknown."
2042
+ },
2043
+ "items": {
2044
+ "type": "array",
2045
+ "items": {
2046
+ "type": "object",
2047
+ "properties": {
2048
+ "productId": {
2049
+ "anyOf": [
2050
+ {
2051
+ "type": "string"
2052
+ },
2053
+ {
2054
+ "type": "null"
2055
+ }
2056
+ ],
2057
+ "description": "The billing provider's product id (prod_...)."
2058
+ },
2059
+ "productName": {
2060
+ "anyOf": [
2061
+ {
2062
+ "type": "string"
2063
+ },
2064
+ {
2065
+ "type": "null"
2066
+ }
2067
+ ],
2068
+ "description": "The product's name in the billing provider; null when Outlit has not synced it."
2069
+ },
2070
+ "priceId": {
2071
+ "anyOf": [
2072
+ {
2073
+ "type": "string"
2074
+ },
2075
+ {
2076
+ "type": "null"
2077
+ }
2078
+ ],
2079
+ "description": "The billing provider's price id (price_...)."
2080
+ },
2081
+ "quantity": {
2082
+ "anyOf": [
2083
+ {
2084
+ "type": "number"
2085
+ },
2086
+ {
2087
+ "type": "null"
2088
+ }
2089
+ ],
2090
+ "description": "Units (seats) on a licensed item; null when unset."
2091
+ },
2092
+ "unitAmount": {
2093
+ "anyOf": [
2094
+ {
2095
+ "type": "number"
2096
+ },
2097
+ {
2098
+ "type": "null"
2099
+ }
2100
+ ],
2101
+ "description": "List price per unit for one billing interval, in the same units as arr.amount; null when the price has no single unit amount (tiers)."
2102
+ },
2103
+ "currency": {
2104
+ "type": "string",
2105
+ "description": "ISO currency code of unitAmount."
2106
+ },
2107
+ "interval": {
2108
+ "anyOf": [
2109
+ {
2110
+ "type": "string",
2111
+ "enum": [
2112
+ "day",
2113
+ "week",
2114
+ "month",
2115
+ "year"
2116
+ ]
2117
+ },
2118
+ {
2119
+ "type": "null"
2120
+ }
2121
+ ]
2122
+ },
2123
+ "intervalCount": {
2124
+ "anyOf": [
2125
+ {
2126
+ "type": "number"
2127
+ },
2128
+ {
2129
+ "type": "null"
2130
+ }
2131
+ ],
2132
+ "description": "Billing intervals per charge, e.g. 3 months."
2133
+ },
2134
+ "usageType": {
2135
+ "anyOf": [
2136
+ {
2137
+ "type": "string",
2138
+ "enum": [
2139
+ "licensed",
2140
+ "metered"
2141
+ ]
2142
+ },
2143
+ {
2144
+ "type": "null"
2145
+ }
2146
+ ],
2147
+ "description": "licensed bills a fixed quantity; metered bills reported usage."
2148
+ },
2149
+ "billingScheme": {
2150
+ "anyOf": [
2151
+ {
2152
+ "type": "string",
2153
+ "enum": [
2154
+ "per_unit",
2155
+ "tiered"
2156
+ ]
2157
+ },
2158
+ {
2159
+ "type": "null"
2160
+ }
2161
+ ]
2162
+ }
2163
+ },
2164
+ "required": [
2165
+ "productId",
2166
+ "productName",
2167
+ "priceId",
2168
+ "quantity",
2169
+ "unitAmount",
2170
+ "currency",
2171
+ "interval",
2172
+ "intervalCount",
2173
+ "usageType",
2174
+ "billingScheme"
2175
+ ],
2176
+ "additionalProperties": false
2177
+ },
2178
+ "description": "Every item on the subscription. Empty for a canceled one, whose stored snapshot lists no items."
2179
+ },
2180
+ "billingAccountId": {
2181
+ "anyOf": [
2182
+ {
2183
+ "type": "string"
2184
+ },
2185
+ {
2186
+ "type": "null"
2187
+ }
2188
+ ],
2189
+ "description": "The Stripe customer id (cus_...) the subscription bills through; null when unknown. Match it against revenue.billingAccounts."
2190
+ },
2191
+ "endedAt": {
2192
+ "anyOf": [
2193
+ {
2194
+ "type": "string",
2195
+ "format": "date-time",
2196
+ "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
2197
+ },
2198
+ {
2199
+ "type": "null"
2200
+ }
2201
+ ],
2202
+ "description": "When the subscription ended; null while it is live."
2203
+ }
2204
+ },
2205
+ "required": [
2206
+ "id",
2207
+ "status",
2208
+ "paused",
2209
+ "currentPeriodEnd",
2210
+ "cancelAtPeriodEnd",
2211
+ "cancelAt",
2212
+ "items",
2213
+ "billingAccountId",
2214
+ "endedAt"
2215
+ ],
2216
+ "additionalProperties": false
2217
+ }
2218
+ },
2219
+ "billingAccounts": {
2220
+ "description": "Every Stripe customer behind this customer, including ones on customers merged into it, sorted by id. Absent when it can't be read.",
2221
+ "type": "array",
2222
+ "items": {
2223
+ "type": "object",
2224
+ "properties": {
2225
+ "provider": {
2226
+ "type": "string",
2227
+ "const": "stripe"
2228
+ },
2229
+ "id": {
2230
+ "type": "string"
2231
+ }
2232
+ },
2233
+ "required": [
2234
+ "provider",
2235
+ "id"
2236
+ ],
2237
+ "additionalProperties": false
2238
+ }
2239
+ },
2240
+ "overdueInvoices": {
2241
+ "description": "Open invoices past their due date that still owe money, oldest due first (at most 20). Empty when none is overdue; absent when unavailable.",
2242
+ "maxItems": 20,
2243
+ "type": "array",
2244
+ "items": {
2245
+ "type": "object",
2246
+ "properties": {
2247
+ "id": {
2248
+ "type": "string",
2249
+ "description": "The invoice id (in_...); read it with outlit_get_source INVOICE."
2250
+ },
2251
+ "number": {
2252
+ "anyOf": [
2253
+ {
2254
+ "type": "string"
2255
+ },
2256
+ {
2257
+ "type": "null"
2258
+ }
2259
+ ]
1227
2260
  },
1228
- {
1229
- "type": "null"
1230
- }
1231
- ]
1232
- },
1233
- "department": {
1234
- "anyOf": [
1235
- {
1236
- "type": "string"
2261
+ "amountRemaining": {
2262
+ "type": "number",
2263
+ "description": "Still owed, in the billing provider's minor units for currency."
1237
2264
  },
1238
- {
1239
- "type": "null"
1240
- }
1241
- ]
1242
- },
1243
- "employmentStartDate": {
1244
- "anyOf": [
1245
- {
2265
+ "currency": {
2266
+ "anyOf": [
2267
+ {
2268
+ "type": "string"
2269
+ },
2270
+ {
2271
+ "type": "null"
2272
+ }
2273
+ ]
2274
+ },
2275
+ "dueDate": {
1246
2276
  "type": "string",
1247
- "pattern": "^\\d{4}-\\d{2}-\\d{2}$"
2277
+ "format": "date-time",
2278
+ "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
1248
2279
  },
1249
- {
1250
- "type": "null"
2280
+ "daysOverdue": {
2281
+ "type": "integer",
2282
+ "minimum": 0,
2283
+ "maximum": 9007199254740991
1251
2284
  }
1252
- ]
1253
- }
1254
- },
1255
- "required": [
1256
- "id",
1257
- "email",
1258
- "name",
1259
- "journeyStage",
1260
- "lastActivityAt",
1261
- "relationshipRole",
1262
- "jobTitle",
1263
- "department",
1264
- "employmentStartDate"
1265
- ],
1266
- "additionalProperties": false
1267
- }
1268
- },
1269
- "revenue": {
1270
- "type": "object",
1271
- "properties": {
1272
- "currentMrr": {
1273
- "anyOf": [
1274
- {
1275
- "type": "number"
1276
2285
  },
1277
- {
1278
- "type": "null"
1279
- }
1280
- ],
1281
- "description": "Monthly recurring revenue as an integer amount in the billing provider's units for the customer's currency, which this result doesn't name. For USD, EUR, GBP and CAD this is cents: divide by 100 (e.g. 1234500 is $12,345, USD). Other currencies follow the provider's amount rules (Stripe's currency docs), so don't assume a divisor for them. ARR is 12 \xD7 this value in the same units. Null unless mrrCalculationStatus is calculated."
1282
- },
1283
- "mrrCalculationStatus": {
1284
- "type": "string",
1285
- "enum": [
1286
- "calculated",
1287
- "mixed_currency",
1288
- "unavailable"
1289
- ]
1290
- },
1291
- "lifetimeRevenue": {
1292
- "type": "number",
1293
- "description": "Lifetime revenue in the billing provider's units for the currency it was billed in, like currentMrr: cents for USD, EUR, GBP and CAD, so divide by 100. Other currencies follow the provider's amount rules, so don't assume a divisor for them."
1294
- },
1295
- "activeSubscriptions": {
1296
- "type": "integer",
1297
- "minimum": 0,
1298
- "maximum": 9007199254740991
2286
+ "required": [
2287
+ "id",
2288
+ "number",
2289
+ "amountRemaining",
2290
+ "currency",
2291
+ "dueDate",
2292
+ "daysOverdue"
2293
+ ],
2294
+ "additionalProperties": false
2295
+ }
1299
2296
  }
1300
2297
  },
1301
2298
  "required": [
1302
- "currentMrr",
1303
- "mrrCalculationStatus",
2299
+ "arr",
1304
2300
  "lifetimeRevenue",
1305
2301
  "activeSubscriptions"
1306
2302
  ],
@@ -1770,37 +2766,364 @@ var publicToolContracts = {
1770
2766
  "class": {
1771
2767
  "type": "string"
1772
2768
  },
1773
- "message": {
1774
- "type": "string"
2769
+ "message": {
2770
+ "type": "string"
2771
+ },
2772
+ "retryable": {
2773
+ "type": "boolean"
2774
+ }
2775
+ },
2776
+ "required": [
2777
+ "class",
2778
+ "message"
2779
+ ],
2780
+ "additionalProperties": false
2781
+ },
2782
+ {
2783
+ "type": "null"
2784
+ }
2785
+ ]
2786
+ }
2787
+ },
2788
+ "required": [
2789
+ "status",
2790
+ "provider",
2791
+ "providerEntityId",
2792
+ "summary",
2793
+ "match",
2794
+ "lastSuccessfulRefreshAt",
2795
+ "lastAttemptAt",
2796
+ "expiresAt",
2797
+ "error"
2798
+ ],
2799
+ "additionalProperties": false
2800
+ },
2801
+ "renewal": {
2802
+ "description": "The renewal date the customer page shows, with its source; null when the customer has none",
2803
+ "anyOf": [
2804
+ {
2805
+ "type": "object",
2806
+ "properties": {
2807
+ "date": {
2808
+ "type": "string",
2809
+ "description": "Renewal date, YYYY-MM-DD"
2810
+ },
2811
+ "source": {
2812
+ "type": "string",
2813
+ "enum": [
2814
+ "outlit",
2815
+ "crm",
2816
+ "billing"
2817
+ ],
2818
+ "description": "Where the date comes from: set in Outlit, a CRM opportunity, or the billing period of a yearly subscription"
2819
+ }
2820
+ },
2821
+ "required": [
2822
+ "date",
2823
+ "source"
2824
+ ],
2825
+ "additionalProperties": false
2826
+ },
2827
+ {
2828
+ "type": "null"
2829
+ }
2830
+ ]
2831
+ },
2832
+ "crm": {
2833
+ "description": "The CRM and support tool accounts linked to this customer, one entry each, with the account's own fields (segment, health, stage, owner and custom fields) as stored there and its associated contacts. Opt-in because an account can carry hundreds of fields. Absent when the section is not enabled for the workspace; null when the read is bound to a past point in time.",
2834
+ "anyOf": [
2835
+ {
2836
+ "type": "array",
2837
+ "items": {
2838
+ "type": "object",
2839
+ "properties": {
2840
+ "provider": {
2841
+ "type": "string",
2842
+ "description": "The system that holds the account: hubspot, salesforce, attio or pylon."
2843
+ },
2844
+ "connectionId": {
2845
+ "type": "string",
2846
+ "description": "The Outlit integration connection the account syncs through."
2847
+ },
2848
+ "accountId": {
2849
+ "type": "string",
2850
+ "description": "The account's id in that system."
2851
+ },
2852
+ "name": {
2853
+ "anyOf": [
2854
+ {
2855
+ "type": "string"
2856
+ },
2857
+ {
2858
+ "type": "null"
2859
+ }
2860
+ ],
2861
+ "description": "The account's name in that system."
2862
+ },
2863
+ "owner": {
2864
+ "anyOf": [
2865
+ {
2866
+ "type": "object",
2867
+ "properties": {
2868
+ "name": {
2869
+ "anyOf": [
2870
+ {
2871
+ "type": "string"
2872
+ },
2873
+ {
2874
+ "type": "null"
2875
+ }
2876
+ ]
2877
+ },
2878
+ "email": {
2879
+ "anyOf": [
2880
+ {
2881
+ "type": "string"
2882
+ },
2883
+ {
2884
+ "type": "null"
2885
+ }
2886
+ ]
2887
+ }
2888
+ },
2889
+ "required": [
2890
+ "name",
2891
+ "email"
2892
+ ],
2893
+ "additionalProperties": false
2894
+ },
2895
+ {
2896
+ "type": "null"
2897
+ }
2898
+ ],
2899
+ "description": "The account owner as that system records it; null when it records none. Not Outlit's customer owner."
2900
+ },
2901
+ "recordUpdatedAt": {
2902
+ "anyOf": [
2903
+ {
2904
+ "type": "string"
2905
+ },
2906
+ {
2907
+ "type": "null"
2908
+ }
2909
+ ],
2910
+ "description": "When that system last modified the account, ISO 8601. A Salesforce formula field can change without moving it, so such a value may lag until the account next changes."
2911
+ },
2912
+ "contacts": {
2913
+ "type": "array",
2914
+ "items": {
2915
+ "type": "object",
2916
+ "properties": {
2917
+ "contactId": {
2918
+ "type": "string",
2919
+ "description": "The contact's id in that system."
2920
+ },
2921
+ "name": {
2922
+ "anyOf": [
2923
+ {
2924
+ "type": "string"
2925
+ },
2926
+ {
2927
+ "type": "null"
2928
+ }
2929
+ ]
2930
+ },
2931
+ "email": {
2932
+ "anyOf": [
2933
+ {
2934
+ "type": "string"
2935
+ },
2936
+ {
2937
+ "type": "null"
2938
+ }
2939
+ ]
2940
+ },
2941
+ "title": {
2942
+ "anyOf": [
2943
+ {
2944
+ "type": "string"
2945
+ },
2946
+ {
2947
+ "type": "null"
2948
+ }
2949
+ ],
2950
+ "description": "The contact's job title there."
2951
+ },
2952
+ "userId": {
2953
+ "anyOf": [
2954
+ {
2955
+ "type": "string"
2956
+ },
2957
+ {
2958
+ "type": "null"
2959
+ }
2960
+ ],
2961
+ "description": "The id of this customer's user with that contact or email; null when the person is not one of its users, for example someone on another email domain."
2962
+ }
2963
+ },
2964
+ "required": [
2965
+ "contactId",
2966
+ "name",
2967
+ "email",
2968
+ "title",
2969
+ "userId"
2970
+ ],
2971
+ "additionalProperties": false
2972
+ },
2973
+ "description": "The contacts that system associates with the account, whatever their email domain, most recently modified first, at most 25."
2974
+ },
2975
+ "omittedContactCount": {
2976
+ "description": "How many more associated contacts there are beyond those listed.",
2977
+ "type": "integer",
2978
+ "minimum": 1,
2979
+ "maximum": 9007199254740991
2980
+ },
2981
+ "fields": {
2982
+ "type": "array",
2983
+ "items": {
2984
+ "type": "object",
2985
+ "properties": {
2986
+ "key": {
2987
+ "type": "string",
2988
+ "description": "The field's API name or slug in that system."
2989
+ },
2990
+ "label": {
2991
+ "type": "string",
2992
+ "description": "The field's name in that system's UI; the key when unknown."
2993
+ },
2994
+ "value": {
2995
+ "description": "The value as that system stores it: a string, number, boolean, array, or for Attio its value objects. A picklist holds the option's stored value, not its label."
2996
+ },
2997
+ "custom": {
2998
+ "type": "boolean",
2999
+ "description": "True for a field the customer's team added to that system."
3000
+ }
3001
+ },
3002
+ "required": [
3003
+ "key",
3004
+ "label",
3005
+ "value",
3006
+ "custom"
3007
+ ],
3008
+ "additionalProperties": false
1775
3009
  },
1776
- "retryable": {
1777
- "type": "boolean"
3010
+ "description": "The account's non-empty fields, sorted by key."
3011
+ },
3012
+ "omittedFields": {
3013
+ "description": "Keys of fields left out so the response stays within its size limit, as many as fit. Ask for them with crmFields.",
3014
+ "type": "array",
3015
+ "items": {
3016
+ "type": "string"
1778
3017
  }
1779
3018
  },
1780
- "required": [
1781
- "class",
1782
- "message"
1783
- ],
1784
- "additionalProperties": false
3019
+ "omittedFieldCount": {
3020
+ "description": "How many fields were left out, including any not named in omittedFields.",
3021
+ "type": "integer",
3022
+ "minimum": 0,
3023
+ "maximum": 9007199254740991
3024
+ }
1785
3025
  },
1786
- {
1787
- "type": "null"
3026
+ "required": [
3027
+ "provider",
3028
+ "connectionId",
3029
+ "accountId",
3030
+ "name",
3031
+ "owner",
3032
+ "recordUpdatedAt",
3033
+ "contacts",
3034
+ "fields"
3035
+ ],
3036
+ "additionalProperties": false
3037
+ }
3038
+ },
3039
+ {
3040
+ "type": "null"
3041
+ }
3042
+ ]
3043
+ },
3044
+ "links": {
3045
+ "description": "Every record in another system linked to this customer, including records still held by customers merged into it: billing customers, CRM and support accounts, product analytics groups and accounts, Slack channels and the product's own customer id. A record is listed only when its id in that system is known. Use it to tell whether two customers share a record, or to name the record to look up in that system; for a CRM account's own fields use include crm. Ordered by kind, provider and id. Null when the read is bound to a past point in time.",
3046
+ "anyOf": [
3047
+ {
3048
+ "type": "object",
3049
+ "properties": {
3050
+ "records": {
3051
+ "type": "array",
3052
+ "items": {
3053
+ "type": "object",
3054
+ "properties": {
3055
+ "kind": {
3056
+ "type": "string",
3057
+ "enum": [
3058
+ "billing_customer",
3059
+ "crm_account",
3060
+ "support_account",
3061
+ "analytics_group",
3062
+ "analytics_account",
3063
+ "slack_channel",
3064
+ "slack_workspace",
3065
+ "external_organization"
3066
+ ],
3067
+ "description": "What the record is: a billing customer (such as a Stripe customer), a CRM or support account, a product analytics group or account, a Slack channel or workspace, or the customer's id in the product's own sign-up system."
3068
+ },
3069
+ "provider": {
3070
+ "anyOf": [
3071
+ {
3072
+ "type": "string"
3073
+ },
3074
+ {
3075
+ "type": "null"
3076
+ }
3077
+ ],
3078
+ "description": "The system that holds the record, such as stripe, hubspot or posthog; null when unknown."
3079
+ },
3080
+ "id": {
3081
+ "type": "string",
3082
+ "description": "The record's id in that system, such as a Stripe customer id (cus_...)."
3083
+ },
3084
+ "connectionId": {
3085
+ "anyOf": [
3086
+ {
3087
+ "type": "string"
3088
+ },
3089
+ {
3090
+ "type": "null"
3091
+ }
3092
+ ],
3093
+ "description": "The Outlit integration connection the record came through; null when none names it."
3094
+ },
3095
+ "linkedAt": {
3096
+ "type": "string",
3097
+ "description": "When Outlit linked the record to this customer, ISO 8601. Outlit's own time, not a fact about the customer."
3098
+ }
3099
+ },
3100
+ "required": [
3101
+ "kind",
3102
+ "provider",
3103
+ "id",
3104
+ "connectionId",
3105
+ "linkedAt"
3106
+ ],
3107
+ "additionalProperties": false
3108
+ }
3109
+ },
3110
+ "omitted": {
3111
+ "type": "integer",
3112
+ "minimum": 0,
3113
+ "maximum": 9007199254740991,
3114
+ "description": "How many more linked records exist beyond the first 50, which are left out."
1788
3115
  }
1789
- ]
3116
+ },
3117
+ "required": [
3118
+ "records",
3119
+ "omitted"
3120
+ ],
3121
+ "additionalProperties": false
3122
+ },
3123
+ {
3124
+ "type": "null"
1790
3125
  }
1791
- },
1792
- "required": [
1793
- "status",
1794
- "provider",
1795
- "providerEntityId",
1796
- "summary",
1797
- "match",
1798
- "lastSuccessfulRefreshAt",
1799
- "lastAttemptAt",
1800
- "expiresAt",
1801
- "error"
1802
- ],
1803
- "additionalProperties": false
3126
+ ]
1804
3127
  }
1805
3128
  },
1806
3129
  "required": [
@@ -1819,6 +3142,7 @@ var publicToolContracts = {
1819
3142
  "annotations": {
1820
3143
  "readOnlyHint": true,
1821
3144
  "destructiveHint": false,
3145
+ "idempotentHint": true,
1822
3146
  "openWorldHint": false
1823
3147
  },
1824
3148
  "inputSchema": {
@@ -1975,6 +3299,7 @@ var publicToolContracts = {
1975
3299
  "annotations": {
1976
3300
  "readOnlyHint": false,
1977
3301
  "destructiveHint": false,
3302
+ "idempotentHint": false,
1978
3303
  "openWorldHint": false
1979
3304
  },
1980
3305
  "inputSchema": {
@@ -2035,7 +3360,8 @@ var publicToolContracts = {
2035
3360
  "description": "Share a customer with an active workspace member as a Viewer or Editor. The customer ID must be exact.",
2036
3361
  "annotations": {
2037
3362
  "readOnlyHint": false,
2038
- "destructiveHint": false,
3363
+ "destructiveHint": true,
3364
+ "idempotentHint": true,
2039
3365
  "openWorldHint": false
2040
3366
  },
2041
3367
  "inputSchema": {
@@ -2121,7 +3447,8 @@ var publicToolContracts = {
2121
3447
  "description": "Change an existing customer collaborator between Viewer and Editor.",
2122
3448
  "annotations": {
2123
3449
  "readOnlyHint": false,
2124
- "destructiveHint": false,
3450
+ "destructiveHint": true,
3451
+ "idempotentHint": true,
2125
3452
  "openWorldHint": false
2126
3453
  },
2127
3454
  "inputSchema": {
@@ -2208,6 +3535,7 @@ var publicToolContracts = {
2208
3535
  "annotations": {
2209
3536
  "readOnlyHint": false,
2210
3537
  "destructiveHint": true,
3538
+ "idempotentHint": true,
2211
3539
  "openWorldHint": false
2212
3540
  },
2213
3541
  "inputSchema": {
@@ -2258,6 +3586,7 @@ var publicToolContracts = {
2258
3586
  "annotations": {
2259
3587
  "readOnlyHint": true,
2260
3588
  "destructiveHint": false,
3589
+ "idempotentHint": true,
2261
3590
  "openWorldHint": false
2262
3591
  },
2263
3592
  "inputSchema": {
@@ -2628,6 +3957,7 @@ var publicToolContracts = {
2628
3957
  "annotations": {
2629
3958
  "readOnlyHint": true,
2630
3959
  "destructiveHint": false,
3960
+ "idempotentHint": true,
2631
3961
  "openWorldHint": false
2632
3962
  },
2633
3963
  "inputSchema": {
@@ -2667,6 +3997,7 @@ var publicToolContracts = {
2667
3997
  "OPPORTUNITY",
2668
3998
  "SLACK",
2669
3999
  "PERSON_PROFILE",
4000
+ "INVOICE",
2670
4001
  "CRM",
2671
4002
  "CRM_OPPORTUNITY"
2672
4003
  ]
@@ -2892,7 +4223,8 @@ var publicToolContracts = {
2892
4223
  "SUPPORT_TICKET",
2893
4224
  "OPPORTUNITY",
2894
4225
  "SLACK",
2895
- "PERSON_PROFILE"
4226
+ "PERSON_PROFILE",
4227
+ "INVOICE"
2896
4228
  ]
2897
4229
  },
2898
4230
  "sourceId": {
@@ -2953,7 +4285,8 @@ var publicToolContracts = {
2953
4285
  "SUPPORT_TICKET",
2954
4286
  "OPPORTUNITY",
2955
4287
  "SLACK",
2956
- "PERSON_PROFILE"
4288
+ "PERSON_PROFILE",
4289
+ "INVOICE"
2957
4290
  ]
2958
4291
  },
2959
4292
  {
@@ -3164,7 +4497,8 @@ var publicToolContracts = {
3164
4497
  "SUPPORT_TICKET",
3165
4498
  "OPPORTUNITY",
3166
4499
  "SLACK",
3167
- "PERSON_PROFILE"
4500
+ "PERSON_PROFILE",
4501
+ "INVOICE"
3168
4502
  ]
3169
4503
  },
3170
4504
  {
@@ -3296,6 +4630,7 @@ var publicToolContracts = {
3296
4630
  "annotations": {
3297
4631
  "readOnlyHint": true,
3298
4632
  "destructiveHint": false,
4633
+ "idempotentHint": true,
3299
4634
  "openWorldHint": false
3300
4635
  },
3301
4636
  "inputSchema": {
@@ -3431,7 +4766,8 @@ var publicToolContracts = {
3431
4766
  "SUPPORT_TICKET",
3432
4767
  "OPPORTUNITY",
3433
4768
  "SLACK",
3434
- "PERSON_PROFILE"
4769
+ "PERSON_PROFILE",
4770
+ "INVOICE"
3435
4771
  ]
3436
4772
  },
3437
4773
  "sourceId": {
@@ -3492,7 +4828,8 @@ var publicToolContracts = {
3492
4828
  "SUPPORT_TICKET",
3493
4829
  "OPPORTUNITY",
3494
4830
  "SLACK",
3495
- "PERSON_PROFILE"
4831
+ "PERSON_PROFILE",
4832
+ "INVOICE"
3496
4833
  ]
3497
4834
  },
3498
4835
  {
@@ -3703,7 +5040,8 @@ var publicToolContracts = {
3703
5040
  "SUPPORT_TICKET",
3704
5041
  "OPPORTUNITY",
3705
5042
  "SLACK",
3706
- "PERSON_PROFILE"
5043
+ "PERSON_PROFILE",
5044
+ "INVOICE"
3707
5045
  ]
3708
5046
  },
3709
5047
  {
@@ -3799,10 +5137,11 @@ var publicToolContracts = {
3799
5137
  "commandVersion": 1,
3800
5138
  "ownerDomain": "customer-context",
3801
5139
  "title": "Get Source",
3802
- "description": "Get one exact source record by generic sourceType and sourceId. Use this when you already know the concrete underlying source you want to inspect.",
5140
+ "description": "Get one exact source record by generic sourceType and sourceId. Use this when you already know the concrete underlying source you want to inspect. For a Stripe invoice use sourceType INVOICE (STRIPE_INVOICE is accepted) with the Stripe invoice id (in_...): the record lists every stored line item, with amounts in the billing provider's minor units for the invoice's currency (cents for USD, EUR, GBP and CAD; other currencies follow the provider's amount rules). The lines are what that invoice billed for its period, not the subscription's item set: a yearly item is absent from its monthly invoices, and a metered item with no usage may be absent too. For a CRM opportunity (sourceType OPPORTUNITY) the record also lists the deal's own CRM fields as record.fields (each with key, label, value and custom, custom fields included) when the workspace has the CRM fields enabled; record.omittedFields names any left out to keep the response small.",
3803
5141
  "annotations": {
3804
5142
  "readOnlyHint": true,
3805
5143
  "destructiveHint": false,
5144
+ "idempotentHint": true,
3806
5145
  "openWorldHint": false
3807
5146
  },
3808
5147
  "inputSchema": {
@@ -3819,8 +5158,10 @@ var publicToolContracts = {
3819
5158
  "OPPORTUNITY",
3820
5159
  "SLACK",
3821
5160
  "PERSON_PROFILE",
5161
+ "INVOICE",
3822
5162
  "CRM",
3823
5163
  "CRM_OPPORTUNITY",
5164
+ "STRIPE_INVOICE",
3824
5165
  "EXTRACTED"
3825
5166
  ]
3826
5167
  },
@@ -3860,7 +5201,8 @@ var publicToolContracts = {
3860
5201
  "SUPPORT_TICKET",
3861
5202
  "OPPORTUNITY",
3862
5203
  "SLACK",
3863
- "PERSON_PROFILE"
5204
+ "PERSON_PROFILE",
5205
+ "INVOICE"
3864
5206
  ]
3865
5207
  },
3866
5208
  "sourceId": {
@@ -4045,7 +5387,8 @@ var publicToolContracts = {
4045
5387
  "SUPPORT_TICKET",
4046
5388
  "OPPORTUNITY",
4047
5389
  "SLACK",
4048
- "PERSON_PROFILE"
5390
+ "PERSON_PROFILE",
5391
+ "INVOICE"
4049
5392
  ]
4050
5393
  },
4051
5394
  "sourceId": {
@@ -4184,10 +5527,11 @@ var publicToolContracts = {
4184
5527
  "commandVersion": 1,
4185
5528
  "ownerDomain": "customer-context",
4186
5529
  "title": "List Sources",
4187
- "description": "List concrete source records deterministically. Use this instead of semantic search when you need enumerated calls, emails, calendar events, support tickets, Slack conversations, or opportunities.",
5530
+ "description": "List concrete source records deterministically. Use this instead of semantic search when you need enumerated calls, emails, calendar events, support tickets, Slack conversations, or opportunities. Invoices are listed only when you pass sourceType INVOICE with a customer, newest first.",
4188
5531
  "annotations": {
4189
5532
  "readOnlyHint": true,
4190
5533
  "destructiveHint": false,
5534
+ "idempotentHint": true,
4191
5535
  "openWorldHint": false
4192
5536
  },
4193
5537
  "inputSchema": {
@@ -4205,8 +5549,10 @@ var publicToolContracts = {
4205
5549
  "OPPORTUNITY",
4206
5550
  "SLACK",
4207
5551
  "PERSON_PROFILE",
5552
+ "INVOICE",
4208
5553
  "CRM",
4209
- "CRM_OPPORTUNITY"
5554
+ "CRM_OPPORTUNITY",
5555
+ "STRIPE_INVOICE"
4210
5556
  ]
4211
5557
  },
4212
5558
  "customer": {
@@ -4277,7 +5623,8 @@ var publicToolContracts = {
4277
5623
  "SUPPORT_TICKET",
4278
5624
  "OPPORTUNITY",
4279
5625
  "SLACK",
4280
- "PERSON_PROFILE"
5626
+ "PERSON_PROFILE",
5627
+ "INVOICE"
4281
5628
  ]
4282
5629
  },
4283
5630
  "sourceId": {
@@ -4462,7 +5809,8 @@ var publicToolContracts = {
4462
5809
  "SUPPORT_TICKET",
4463
5810
  "OPPORTUNITY",
4464
5811
  "SLACK",
4465
- "PERSON_PROFILE"
5812
+ "PERSON_PROFILE",
5813
+ "INVOICE"
4466
5814
  ]
4467
5815
  },
4468
5816
  "sourceId": {
@@ -4636,6 +5984,7 @@ var publicToolContracts = {
4636
5984
  "annotations": {
4637
5985
  "readOnlyHint": true,
4638
5986
  "destructiveHint": false,
5987
+ "idempotentHint": true,
4639
5988
  "openWorldHint": false
4640
5989
  },
4641
5990
  "inputSchema": {
@@ -4692,6 +6041,7 @@ var publicToolContracts = {
4692
6041
  "OPPORTUNITY",
4693
6042
  "SLACK",
4694
6043
  "PERSON_PROFILE",
6044
+ "INVOICE",
4695
6045
  "CRM",
4696
6046
  "CRM_OPPORTUNITY"
4697
6047
  ]
@@ -4938,7 +6288,8 @@ var publicToolContracts = {
4938
6288
  "SUPPORT_TICKET",
4939
6289
  "OPPORTUNITY",
4940
6290
  "SLACK",
4941
- "PERSON_PROFILE"
6291
+ "PERSON_PROFILE",
6292
+ "INVOICE"
4942
6293
  ]
4943
6294
  },
4944
6295
  "sourceId": {
@@ -4999,7 +6350,8 @@ var publicToolContracts = {
4999
6350
  "SUPPORT_TICKET",
5000
6351
  "OPPORTUNITY",
5001
6352
  "SLACK",
5002
- "PERSON_PROFILE"
6353
+ "PERSON_PROFILE",
6354
+ "INVOICE"
5003
6355
  ]
5004
6356
  },
5005
6357
  {
@@ -5210,7 +6562,8 @@ var publicToolContracts = {
5210
6562
  "SUPPORT_TICKET",
5211
6563
  "OPPORTUNITY",
5212
6564
  "SLACK",
5213
- "PERSON_PROFILE"
6565
+ "PERSON_PROFILE",
6566
+ "INVOICE"
5214
6567
  ]
5215
6568
  },
5216
6569
  {
@@ -5328,7 +6681,8 @@ var publicToolContracts = {
5328
6681
  "SUPPORT_TICKET",
5329
6682
  "OPPORTUNITY",
5330
6683
  "SLACK",
5331
- "PERSON_PROFILE"
6684
+ "PERSON_PROFILE",
6685
+ "INVOICE"
5332
6686
  ]
5333
6687
  },
5334
6688
  "sourceId": {
@@ -5495,10 +6849,11 @@ var publicToolContracts = {
5495
6849
  "commandVersion": 1,
5496
6850
  "ownerDomain": "analytics",
5497
6851
  "title": "Run SQL Query",
5498
- "description": "Execute read-only SQL queries against your analytics views.\n\nAvailable views:\n- activity: Customer activity events (event_name, event_type, event_channel, customer_id, occurred_at, properties, ...)\n- customers: Customer attributes (customer_id, domain, name, billing_status, plan, mrr_cents, traits, ...)\n- users: User attributes (user_id, email, name, customer_id, traits, ...)\n- revenue: Revenue snapshots over time (customer_id, snapshot_date, mrr_cents, ...)\n\nAll queries are automatically filtered to your organization's data.\nOnly SELECT queries are allowed.\nProperties and traits are JSON strings; inspect schemas and examples before filtering nested values.\n\nExample queries:\n- SELECT event_name, count(*) FROM activity GROUP BY 1 ORDER BY 2 DESC LIMIT 10\n- SELECT billing_status, sum(mrr_cents)/100 as mrr FROM customers GROUP BY 1\n- SELECT * FROM activity WHERE customer_id = 'cust_123' ORDER BY occurred_at DESC LIMIT 50",
6852
+ "description": "Execute read-only SQL queries against your analytics views.\n\nAvailable views:\n- activity: Customer activity events (event_name, event_type, event_channel, customer_id, occurred_at, properties, ...)\n- customers: Customer attributes (customer_id, domain, name, billing_status, plan, arr_cents (the revenue number: annualized, in arr_currency's units), arr_currency, traits, ...; mrr_cents and mrr_status are deprecated, use arr_cents)\n- users: User attributes (user_id, email, name, customer_id, traits, ...)\n- revenue: Revenue snapshots over time (customer_id, snapshot_date, mrr_cents, ...)\n\nAll queries are automatically filtered to your organization's data.\nOnly SELECT queries are allowed.\nProperties and traits are JSON strings; inspect schemas and examples before filtering nested values.\n\nExample queries:\n- SELECT event_name, count(*) FROM activity GROUP BY 1 ORDER BY 2 DESC LIMIT 10\n- SELECT billing_status, sum(arr_cents)/100 AS arr FROM customers WHERE arr_currency = 'USD' GROUP BY 1\n- SELECT * FROM activity WHERE customer_id = 'cust_123' ORDER BY occurred_at DESC LIMIT 50",
5499
6853
  "annotations": {
5500
6854
  "readOnlyHint": true,
5501
6855
  "destructiveHint": false,
6856
+ "idempotentHint": true,
5502
6857
  "openWorldHint": false
5503
6858
  },
5504
6859
  "inputSchema": {
@@ -5583,6 +6938,7 @@ var publicToolContracts = {
5583
6938
  "annotations": {
5584
6939
  "readOnlyHint": true,
5585
6940
  "destructiveHint": false,
6941
+ "idempotentHint": true,
5586
6942
  "openWorldHint": false
5587
6943
  },
5588
6944
  "inputSchema": {
@@ -5792,6 +7148,7 @@ var publicToolContracts = {
5792
7148
  "annotations": {
5793
7149
  "readOnlyHint": true,
5794
7150
  "destructiveHint": false,
7151
+ "idempotentHint": true,
5795
7152
  "openWorldHint": false
5796
7153
  },
5797
7154
  "inputSchema": {
@@ -6176,6 +7533,7 @@ var publicToolContracts = {
6176
7533
  "annotations": {
6177
7534
  "readOnlyHint": true,
6178
7535
  "destructiveHint": false,
7536
+ "idempotentHint": true,
6179
7537
  "openWorldHint": false
6180
7538
  },
6181
7539
  "inputSchema": {
@@ -6566,6 +7924,7 @@ var publicToolContracts = {
6566
7924
  "annotations": {
6567
7925
  "readOnlyHint": false,
6568
7926
  "destructiveHint": false,
7927
+ "idempotentHint": false,
6569
7928
  "openWorldHint": true
6570
7929
  },
6571
7930
  "inputSchema": {
@@ -6975,6 +8334,7 @@ var publicToolContracts = {
6975
8334
  "annotations": {
6976
8335
  "readOnlyHint": false,
6977
8336
  "destructiveHint": false,
8337
+ "idempotentHint": true,
6978
8338
  "openWorldHint": true
6979
8339
  },
6980
8340
  "inputSchema": {
@@ -7379,6 +8739,7 @@ var publicToolContracts = {
7379
8739
  "annotations": {
7380
8740
  "readOnlyHint": false,
7381
8741
  "destructiveHint": false,
8742
+ "idempotentHint": true,
7382
8743
  "openWorldHint": true
7383
8744
  },
7384
8745
  "inputSchema": {
@@ -7769,6 +9130,7 @@ var publicToolContracts = {
7769
9130
  "annotations": {
7770
9131
  "readOnlyHint": false,
7771
9132
  "destructiveHint": false,
9133
+ "idempotentHint": true,
7772
9134
  "openWorldHint": false
7773
9135
  },
7774
9136
  "inputSchema": {
@@ -8159,6 +9521,7 @@ var publicToolContracts = {
8159
9521
  "annotations": {
8160
9522
  "readOnlyHint": false,
8161
9523
  "destructiveHint": true,
9524
+ "idempotentHint": true,
8162
9525
  "openWorldHint": false
8163
9526
  },
8164
9527
  "inputSchema": {
@@ -8217,6 +9580,7 @@ var publicToolContracts = {
8217
9580
  "annotations": {
8218
9581
  "readOnlyHint": false,
8219
9582
  "destructiveHint": false,
9583
+ "idempotentHint": false,
8220
9584
  "openWorldHint": false
8221
9585
  },
8222
9586
  "inputSchema": {
@@ -8276,6 +9640,7 @@ var publicToolContracts = {
8276
9640
  "annotations": {
8277
9641
  "readOnlyHint": true,
8278
9642
  "destructiveHint": false,
9643
+ "idempotentHint": true,
8279
9644
  "openWorldHint": false
8280
9645
  },
8281
9646
  "inputSchema": {
@@ -8373,6 +9738,7 @@ var publicToolContracts = {
8373
9738
  "annotations": {
8374
9739
  "readOnlyHint": false,
8375
9740
  "destructiveHint": false,
9741
+ "idempotentHint": false,
8376
9742
  "openWorldHint": true
8377
9743
  },
8378
9744
  "inputSchema": {
@@ -8462,6 +9828,7 @@ var publicToolContracts = {
8462
9828
  "annotations": {
8463
9829
  "readOnlyHint": true,
8464
9830
  "destructiveHint": false,
9831
+ "idempotentHint": true,
8465
9832
  "openWorldHint": false
8466
9833
  },
8467
9834
  "inputSchema": {
@@ -8522,6 +9889,7 @@ var publicToolContracts = {
8522
9889
  "annotations": {
8523
9890
  "readOnlyHint": true,
8524
9891
  "destructiveHint": false,
9892
+ "idempotentHint": true,
8525
9893
  "openWorldHint": false
8526
9894
  },
8527
9895
  "inputSchema": {
@@ -8620,10 +9988,11 @@ var publicToolContracts = {
8620
9988
  "commandVersion": 1,
8621
9989
  "ownerDomain": "integrations",
8622
9990
  "title": "Set Up Integration",
8623
- "description": "Continue integration setup through validated credentials, safe configuration, or a trusted browser handoff.",
9991
+ "description": "Continue integration setup through validated credentials, safe configuration, or a trusted browser handoff. For a connected Stripe account, an optional stripe_renewal_date_field step names the subscription metadata key that holds renewal dates.",
8624
9992
  "annotations": {
8625
9993
  "readOnlyHint": false,
8626
9994
  "destructiveHint": false,
9995
+ "idempotentHint": false,
8627
9996
  "openWorldHint": true
8628
9997
  },
8629
9998
  "inputSchema": {
@@ -8758,6 +10127,32 @@ var publicToolContracts = {
8758
10127
  "connectionMode": {
8759
10128
  "type": "string",
8760
10129
  "const": "oauth"
10130
+ },
10131
+ "configuration": {
10132
+ "type": "object",
10133
+ "properties": {
10134
+ "kind": {
10135
+ "type": "string",
10136
+ "const": "stripe_renewal_date_field"
10137
+ },
10138
+ "key": {
10139
+ "anyOf": [
10140
+ {
10141
+ "type": "string",
10142
+ "minLength": 1,
10143
+ "maxLength": 40
10144
+ },
10145
+ {
10146
+ "type": "null"
10147
+ }
10148
+ ]
10149
+ }
10150
+ },
10151
+ "required": [
10152
+ "kind",
10153
+ "key"
10154
+ ],
10155
+ "additionalProperties": false
8761
10156
  }
8762
10157
  },
8763
10158
  "required": [
@@ -8789,6 +10184,32 @@ var publicToolContracts = {
8789
10184
  "apiKey"
8790
10185
  ],
8791
10186
  "additionalProperties": false
10187
+ },
10188
+ "configuration": {
10189
+ "type": "object",
10190
+ "properties": {
10191
+ "kind": {
10192
+ "type": "string",
10193
+ "const": "stripe_renewal_date_field"
10194
+ },
10195
+ "key": {
10196
+ "anyOf": [
10197
+ {
10198
+ "type": "string",
10199
+ "minLength": 1,
10200
+ "maxLength": 40
10201
+ },
10202
+ {
10203
+ "type": "null"
10204
+ }
10205
+ ]
10206
+ }
10207
+ },
10208
+ "required": [
10209
+ "kind",
10210
+ "key"
10211
+ ],
10212
+ "additionalProperties": false
8792
10213
  }
8793
10214
  },
8794
10215
  "required": [
@@ -9491,6 +10912,69 @@ var publicToolContracts = {
9491
10912
  "preview"
9492
10913
  ],
9493
10914
  "additionalProperties": false
10915
+ },
10916
+ {
10917
+ "type": "object",
10918
+ "properties": {
10919
+ "kind": {
10920
+ "type": "string",
10921
+ "const": "stripe_renewal_date_field"
10922
+ },
10923
+ "selectedKey": {
10924
+ "anyOf": [
10925
+ {
10926
+ "type": "string"
10927
+ },
10928
+ {
10929
+ "type": "null"
10930
+ }
10931
+ ]
10932
+ },
10933
+ "liveSubscriptionCount": {
10934
+ "type": "integer",
10935
+ "minimum": 0,
10936
+ "maximum": 9007199254740991
10937
+ },
10938
+ "keys": {
10939
+ "type": "array",
10940
+ "items": {
10941
+ "type": "object",
10942
+ "properties": {
10943
+ "key": {
10944
+ "type": "string"
10945
+ },
10946
+ "subscriptionCount": {
10947
+ "type": "integer",
10948
+ "minimum": 0,
10949
+ "maximum": 9007199254740991
10950
+ },
10951
+ "sampleDate": {
10952
+ "anyOf": [
10953
+ {
10954
+ "type": "string"
10955
+ },
10956
+ {
10957
+ "type": "null"
10958
+ }
10959
+ ]
10960
+ }
10961
+ },
10962
+ "required": [
10963
+ "key",
10964
+ "subscriptionCount",
10965
+ "sampleDate"
10966
+ ],
10967
+ "additionalProperties": false
10968
+ }
10969
+ }
10970
+ },
10971
+ "required": [
10972
+ "kind",
10973
+ "selectedKey",
10974
+ "liveSubscriptionCount",
10975
+ "keys"
10976
+ ],
10977
+ "additionalProperties": false
9494
10978
  }
9495
10979
  ]
9496
10980
  },
@@ -9558,6 +11042,7 @@ var publicToolContracts = {
9558
11042
  "annotations": {
9559
11043
  "readOnlyHint": true,
9560
11044
  "destructiveHint": false,
11045
+ "idempotentHint": true,
9561
11046
  "openWorldHint": false
9562
11047
  },
9563
11048
  "inputSchema": {
@@ -9608,6 +11093,7 @@ var publicToolContracts = {
9608
11093
  "annotations": {
9609
11094
  "readOnlyHint": true,
9610
11095
  "destructiveHint": false,
11096
+ "idempotentHint": true,
9611
11097
  "openWorldHint": false
9612
11098
  },
9613
11099
  "inputSchema": {
@@ -9805,6 +11291,7 @@ var publicToolContracts = {
9805
11291
  "annotations": {
9806
11292
  "readOnlyHint": false,
9807
11293
  "destructiveHint": false,
11294
+ "idempotentHint": true,
9808
11295
  "openWorldHint": false
9809
11296
  },
9810
11297
  "inputSchema": {
@@ -9875,6 +11362,7 @@ var publicToolContracts = {
9875
11362
  "annotations": {
9876
11363
  "readOnlyHint": true,
9877
11364
  "destructiveHint": false,
11365
+ "idempotentHint": true,
9878
11366
  "openWorldHint": false
9879
11367
  },
9880
11368
  "inputSchema": {
@@ -9939,6 +11427,7 @@ var publicToolContracts = {
9939
11427
  "annotations": {
9940
11428
  "readOnlyHint": false,
9941
11429
  "destructiveHint": false,
11430
+ "idempotentHint": true,
9942
11431
  "openWorldHint": false
9943
11432
  },
9944
11433
  "inputSchema": {
@@ -10029,6 +11518,7 @@ var publicToolContracts = {
10029
11518
  "annotations": {
10030
11519
  "readOnlyHint": true,
10031
11520
  "destructiveHint": false,
11521
+ "idempotentHint": true,
10032
11522
  "openWorldHint": false
10033
11523
  },
10034
11524
  "inputSchema": {
@@ -10584,6 +12074,7 @@ var publicToolContracts = {
10584
12074
  "annotations": {
10585
12075
  "readOnlyHint": false,
10586
12076
  "destructiveHint": false,
12077
+ "idempotentHint": true,
10587
12078
  "openWorldHint": false
10588
12079
  },
10589
12080
  "inputSchema": {
@@ -10905,6 +12396,7 @@ var publicToolContracts = {
10905
12396
  "annotations": {
10906
12397
  "readOnlyHint": false,
10907
12398
  "destructiveHint": true,
12399
+ "idempotentHint": true,
10908
12400
  "openWorldHint": false
10909
12401
  },
10910
12402
  "inputSchema": {
@@ -10970,6 +12462,7 @@ var publicToolContracts = {
10970
12462
  "annotations": {
10971
12463
  "readOnlyHint": true,
10972
12464
  "destructiveHint": false,
12465
+ "idempotentHint": true,
10973
12466
  "openWorldHint": false
10974
12467
  },
10975
12468
  "inputSchema": {
@@ -12163,6 +13656,7 @@ var publicToolContracts = {
12163
13656
  "annotations": {
12164
13657
  "readOnlyHint": true,
12165
13658
  "destructiveHint": false,
13659
+ "idempotentHint": true,
12166
13660
  "openWorldHint": false
12167
13661
  },
12168
13662
  "inputSchema": {
@@ -12602,6 +14096,7 @@ var publicToolContracts = {
12602
14096
  "annotations": {
12603
14097
  "readOnlyHint": true,
12604
14098
  "destructiveHint": false,
14099
+ "idempotentHint": true,
12605
14100
  "openWorldHint": false
12606
14101
  },
12607
14102
  "inputSchema": {
@@ -12929,6 +14424,7 @@ var publicToolContracts = {
12929
14424
  "annotations": {
12930
14425
  "readOnlyHint": true,
12931
14426
  "destructiveHint": false,
14427
+ "idempotentHint": true,
12932
14428
  "openWorldHint": false
12933
14429
  },
12934
14430
  "inputSchema": {
@@ -13367,6 +14863,7 @@ var publicToolContracts = {
13367
14863
  "annotations": {
13368
14864
  "readOnlyHint": true,
13369
14865
  "destructiveHint": false,
14866
+ "idempotentHint": true,
13370
14867
  "openWorldHint": false
13371
14868
  },
13372
14869
  "inputSchema": {
@@ -13769,6 +15266,7 @@ var publicToolContracts = {
13769
15266
  "annotations": {
13770
15267
  "readOnlyHint": true,
13771
15268
  "destructiveHint": false,
15269
+ "idempotentHint": true,
13772
15270
  "openWorldHint": false
13773
15271
  },
13774
15272
  "inputSchema": {
@@ -14317,6 +15815,7 @@ var publicToolContracts = {
14317
15815
  "annotations": {
14318
15816
  "readOnlyHint": false,
14319
15817
  "destructiveHint": false,
15818
+ "idempotentHint": false,
14320
15819
  "openWorldHint": false
14321
15820
  },
14322
15821
  "inputSchema": {
@@ -14444,6 +15943,7 @@ var publicToolContracts = {
14444
15943
  "annotations": {
14445
15944
  "readOnlyHint": false,
14446
15945
  "destructiveHint": false,
15946
+ "idempotentHint": false,
14447
15947
  "openWorldHint": false
14448
15948
  },
14449
15949
  "inputSchema": {
@@ -14511,6 +16011,7 @@ var publicToolContracts = {
14511
16011
  "annotations": {
14512
16012
  "readOnlyHint": true,
14513
16013
  "destructiveHint": false,
16014
+ "idempotentHint": true,
14514
16015
  "openWorldHint": false
14515
16016
  },
14516
16017
  "inputSchema": {
@@ -14720,6 +16221,7 @@ var publicToolContracts = {
14720
16221
  "annotations": {
14721
16222
  "readOnlyHint": true,
14722
16223
  "destructiveHint": false,
16224
+ "idempotentHint": true,
14723
16225
  "openWorldHint": false
14724
16226
  },
14725
16227
  "inputSchema": {
@@ -15849,6 +17351,7 @@ var publicToolContracts = {
15849
17351
  "annotations": {
15850
17352
  "readOnlyHint": false,
15851
17353
  "destructiveHint": false,
17354
+ "idempotentHint": true,
15852
17355
  "openWorldHint": false
15853
17356
  },
15854
17357
  "inputSchema": {
@@ -15901,6 +17404,7 @@ var publicToolContracts = {
15901
17404
  "annotations": {
15902
17405
  "readOnlyHint": false,
15903
17406
  "destructiveHint": true,
17407
+ "idempotentHint": true,
15904
17408
  "openWorldHint": false
15905
17409
  },
15906
17410
  "inputSchema": {
@@ -16130,6 +17634,7 @@ var publicToolContracts = {
16130
17634
  "annotations": {
16131
17635
  "readOnlyHint": true,
16132
17636
  "destructiveHint": false,
17637
+ "idempotentHint": true,
16133
17638
  "openWorldHint": false
16134
17639
  },
16135
17640
  "inputSchema": {
@@ -16241,6 +17746,7 @@ var publicOpenApiTransports = [
16241
17746
  var consumerToolPolicies = {
16242
17747
  "default": [
16243
17748
  "outlit_list_customers",
17749
+ "outlit_list_crm_fields",
16244
17750
  "outlit_list_users",
16245
17751
  "outlit_get_customer",
16246
17752
  "outlit_get_timeline",
@@ -16252,6 +17758,7 @@ var consumerToolPolicies = {
16252
17758
  ],
16253
17759
  "analytical": [
16254
17760
  "outlit_list_customers",
17761
+ "outlit_list_crm_fields",
16255
17762
  "outlit_list_users",
16256
17763
  "outlit_get_customer",
16257
17764
  "outlit_get_timeline",
@@ -16265,6 +17772,7 @@ var consumerToolPolicies = {
16265
17772
  ],
16266
17773
  "pi": [
16267
17774
  "outlit_list_customers",
17775
+ "outlit_list_crm_fields",
16268
17776
  "outlit_list_users",
16269
17777
  "outlit_list_workspace_users",
16270
17778
  "outlit_get_customer",
@@ -16318,6 +17826,7 @@ var consumerToolPolicies = {
16318
17826
  ],
16319
17827
  "cli": [
16320
17828
  "outlit_list_customers",
17829
+ "outlit_list_crm_fields",
16321
17830
  "outlit_list_users",
16322
17831
  "outlit_list_workspace_users",
16323
17832
  "outlit_get_customer",
@@ -16955,6 +18464,14 @@ var toolGatewayErrorSchema = {
16955
18464
  "path": {
16956
18465
  "type": "string",
16957
18466
  "maxLength": 200
18467
+ },
18468
+ "validValues": {
18469
+ "maxItems": 30,
18470
+ "type": "array",
18471
+ "items": {
18472
+ "type": "string",
18473
+ "maxLength": 100
18474
+ }
16958
18475
  }
16959
18476
  },
16960
18477
  "required": [
@@ -16963,6 +18480,37 @@ var toolGatewayErrorSchema = {
16963
18480
  ],
16964
18481
  "additionalProperties": false
16965
18482
  }
18483
+ },
18484
+ "next": {
18485
+ "type": "object",
18486
+ "properties": {
18487
+ "instruction": {
18488
+ "type": "string",
18489
+ "minLength": 1,
18490
+ "maxLength": 300
18491
+ },
18492
+ "tool": {
18493
+ "type": "string",
18494
+ "maxLength": 100,
18495
+ "pattern": "^outlit_[a-z0-9_]+$"
18496
+ },
18497
+ "input": {
18498
+ "type": "object",
18499
+ "propertyNames": {
18500
+ "type": "string"
18501
+ },
18502
+ "additionalProperties": {}
18503
+ }
18504
+ },
18505
+ "required": [
18506
+ "instruction"
18507
+ ],
18508
+ "additionalProperties": false
18509
+ },
18510
+ "missingPermission": {
18511
+ "type": "string",
18512
+ "minLength": 1,
18513
+ "maxLength": 100
16966
18514
  }
16967
18515
  },
16968
18516
  "required": [
@@ -17858,14 +19406,17 @@ var customerListOrderFields = [
17858
19406
  "last_activity_at",
17859
19407
  "first_seen_at",
17860
19408
  "name",
17861
- "mrr_cents"
19409
+ "arr_cents"
17862
19410
  ];
17863
19411
  var customerIncludeSections = [
17864
19412
  "users",
17865
19413
  "revenue",
17866
19414
  "recentTimeline",
17867
19415
  "behaviorMetrics",
17868
- "enrichment"
19416
+ "enrichment",
19417
+ "renewal",
19418
+ "crm",
19419
+ "links"
17869
19420
  ];
17870
19421
  var customerSourceTypes = [
17871
19422
  "EMAIL",
@@ -17874,7 +19425,8 @@ var customerSourceTypes = [
17874
19425
  "SUPPORT_TICKET",
17875
19426
  "OPPORTUNITY",
17876
19427
  "SLACK",
17877
- "PERSON_PROFILE"
19428
+ "PERSON_PROFILE",
19429
+ "INVOICE"
17878
19430
  ];
17879
19431
  var customerSourceTypeAliasMap = {
17880
19432
  "CRM": "OPPORTUNITY",
@@ -17892,6 +19444,7 @@ var customerSourceTypeInputs = [
17892
19444
  "OPPORTUNITY",
17893
19445
  "SLACK",
17894
19446
  "PERSON_PROFILE",
19447
+ "INVOICE",
17895
19448
  "CRM",
17896
19449
  "CRM_OPPORTUNITY"
17897
19450
  ];
@@ -17942,7 +19495,7 @@ var schemaTables = [
17942
19495
  "users",
17943
19496
  "revenue"
17944
19497
  ];
17945
- var sdkConsumerContractHash = "9409f42bc10034b8afef6a3ca3597fbe8ae9fa8ed8846f1e7b4b0b6a4320c31c";
19498
+ var sdkConsumerContractHash = "696da531a576098a4d673bf7c25188769d15b1cb096fd60a8431aeb515648510";
17946
19499
 
17947
19500
  // src/contracts.ts
17948
19501
  var publicToolNameSet = new Set(publicToolNames);
@@ -17959,6 +19512,16 @@ function normalizeCustomerSourceType(value) {
17959
19512
  if (customerSourceTypeSet.has(normalized)) return normalized;
17960
19513
  return customerSourceTypeAliasMap[normalized] ?? null;
17961
19514
  }
19515
+ var customerSourceToolInputAliasMap = {
19516
+ STRIPE_INVOICE: "INVOICE"
19517
+ };
19518
+ function normalizeCustomerSourceToolInput(value) {
19519
+ const normalized = normalizeCustomerSourceType(value);
19520
+ if (normalized) return normalized;
19521
+ const key = value.trim().toUpperCase();
19522
+ if (!Object.hasOwn(customerSourceToolInputAliasMap, key)) return null;
19523
+ return customerSourceToolInputAliasMap[key];
19524
+ }
17962
19525
  function resolveCustomerContextSearchInput(value) {
17963
19526
  if (!value.query) return { ok: false, message: "A query argument is required" };
17964
19527
  const normalizedQuery = value.query.trim();
@@ -18059,14 +19622,23 @@ function createOutlitClient(options) {
18059
19622
  }
18060
19623
  function parseGatewayError(text) {
18061
19624
  try {
18062
- const value = JSON.parse(text);
18063
- if (matchesGeneratedJsonSchema(value, toolGatewayErrorSchema)) {
19625
+ const value = withoutUnknownEnvelopeFields(JSON.parse(text));
19626
+ if (matchesGeneratedJsonSchema(value, toolGatewayErrorSchema) && // The generated schema can't carry Core's per-code rule for this field.
19627
+ (value.missingPermission === void 0 || value.code === "TOOL_CALL_FORBIDDEN")) {
18064
19628
  return value;
18065
19629
  }
18066
19630
  } catch {
18067
19631
  }
18068
19632
  return void 0;
18069
19633
  }
19634
+ function withoutUnknownEnvelopeFields(value) {
19635
+ if (typeof value !== "object" || value === null || Array.isArray(value)) return value;
19636
+ return Object.fromEntries(
19637
+ Object.entries(value).filter(
19638
+ ([property]) => Object.hasOwn(toolGatewayErrorSchema.properties, property)
19639
+ )
19640
+ );
19641
+ }
18070
19642
  function matchesGeneratedJsonSchema(value, schema) {
18071
19643
  if (Object.hasOwn(schema, "const") && !Object.is(schema.const, value)) {
18072
19644
  return false;
@@ -18177,6 +19749,7 @@ export {
18177
19749
  isOutlitToolsApiError,
18178
19750
  isPublicToolName,
18179
19751
  matchesGeneratedJsonSchema,
19752
+ normalizeCustomerSourceToolInput,
18180
19753
  normalizeCustomerSourceType,
18181
19754
  piToolNames,
18182
19755
  publicOpenApiTransports,