@setluca/mcp 0.1.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.
@@ -0,0 +1,2926 @@
1
+ export const OPENAPI_INPUTS = {
2
+ "GET /api/capabilities": {},
3
+ "GET /api/leads": {
4
+ "query": {
5
+ "type": "object",
6
+ "properties": {
7
+ "limit": {
8
+ "type": "integer",
9
+ "minimum": 1,
10
+ "maximum": 100
11
+ },
12
+ "cursor": {
13
+ "type": "string",
14
+ "minLength": 1
15
+ },
16
+ "channel": {
17
+ "type": "string",
18
+ "enum": [
19
+ "telegram",
20
+ "instagram",
21
+ "messenger",
22
+ "whatsapp"
23
+ ]
24
+ },
25
+ "q": {
26
+ "type": "string",
27
+ "minLength": 1
28
+ }
29
+ }
30
+ }
31
+ },
32
+ "GET /api/leads/{id}": {
33
+ "path": {
34
+ "type": "object",
35
+ "properties": {
36
+ "id": {
37
+ "type": "string",
38
+ "format": "uuid"
39
+ }
40
+ },
41
+ "required": [
42
+ "id"
43
+ ]
44
+ }
45
+ },
46
+ "GET /api/leads/{id}/explain": {
47
+ "path": {
48
+ "type": "object",
49
+ "properties": {
50
+ "id": {
51
+ "type": "string",
52
+ "format": "uuid"
53
+ }
54
+ },
55
+ "required": [
56
+ "id"
57
+ ]
58
+ }
59
+ },
60
+ "POST /api/leads": {
61
+ "body": {
62
+ "type": "object",
63
+ "properties": {
64
+ "channel": {
65
+ "type": "string",
66
+ "enum": [
67
+ "telegram",
68
+ "instagram",
69
+ "messenger",
70
+ "whatsapp"
71
+ ]
72
+ },
73
+ "externalUserId": {
74
+ "type": "string",
75
+ "minLength": 1
76
+ },
77
+ "displayName": {
78
+ "type": "string",
79
+ "minLength": 1
80
+ },
81
+ "stage": {
82
+ "type": "string",
83
+ "minLength": 1
84
+ },
85
+ "customFields": {
86
+ "type": "object",
87
+ "additionalProperties": {}
88
+ },
89
+ "tags": {
90
+ "type": "array",
91
+ "items": {
92
+ "type": "string",
93
+ "minLength": 1
94
+ }
95
+ }
96
+ },
97
+ "required": [
98
+ "channel",
99
+ "externalUserId"
100
+ ]
101
+ }
102
+ },
103
+ "PATCH /api/leads/{id}": {
104
+ "path": {
105
+ "type": "object",
106
+ "properties": {
107
+ "id": {
108
+ "type": "string",
109
+ "format": "uuid"
110
+ }
111
+ },
112
+ "required": [
113
+ "id"
114
+ ]
115
+ },
116
+ "body": {
117
+ "type": "object",
118
+ "properties": {
119
+ "displayName": {
120
+ "type": "string",
121
+ "minLength": 1
122
+ },
123
+ "stage": {
124
+ "type": "string",
125
+ "minLength": 1
126
+ },
127
+ "customFields": {
128
+ "type": "object",
129
+ "additionalProperties": {}
130
+ },
131
+ "tags": {
132
+ "type": "array",
133
+ "items": {
134
+ "type": "string",
135
+ "minLength": 1
136
+ }
137
+ }
138
+ }
139
+ }
140
+ },
141
+ "GET /api/leads/field-definitions": {},
142
+ "POST /api/leads/field-definitions": {
143
+ "body": {
144
+ "type": "object",
145
+ "properties": {
146
+ "key": {
147
+ "type": "string",
148
+ "minLength": 1,
149
+ "pattern": "^[a-z][a-z0-9_]*$"
150
+ },
151
+ "label": {
152
+ "type": "string",
153
+ "minLength": 1
154
+ },
155
+ "type": {
156
+ "type": "string",
157
+ "enum": [
158
+ "text",
159
+ "number",
160
+ "boolean",
161
+ "date",
162
+ "select"
163
+ ],
164
+ "default": "text"
165
+ },
166
+ "options": {
167
+ "type": "object",
168
+ "additionalProperties": {}
169
+ }
170
+ },
171
+ "required": [
172
+ "key",
173
+ "label"
174
+ ]
175
+ }
176
+ },
177
+ "POST /api/leads/imports/preview": {
178
+ "body": {
179
+ "type": "object",
180
+ "properties": {
181
+ "source": {
182
+ "type": "string",
183
+ "minLength": 1,
184
+ "default": "csv_import"
185
+ },
186
+ "rows": {
187
+ "type": "array",
188
+ "items": {
189
+ "type": "object",
190
+ "additionalProperties": {}
191
+ },
192
+ "minItems": 1,
193
+ "maxItems": 1000
194
+ },
195
+ "mapping": {
196
+ "type": "object",
197
+ "properties": {
198
+ "identity": {
199
+ "type": "object",
200
+ "properties": {
201
+ "channelColumn": {
202
+ "type": "string",
203
+ "minLength": 1
204
+ },
205
+ "channelDefault": {
206
+ "type": "string",
207
+ "enum": [
208
+ "telegram",
209
+ "instagram",
210
+ "messenger",
211
+ "whatsapp"
212
+ ]
213
+ },
214
+ "externalUserIdColumn": {
215
+ "type": "string",
216
+ "minLength": 1
217
+ },
218
+ "displayNameColumn": {
219
+ "type": "string",
220
+ "minLength": 1
221
+ }
222
+ },
223
+ "required": [
224
+ "externalUserIdColumn"
225
+ ]
226
+ },
227
+ "tagsColumn": {
228
+ "type": "string",
229
+ "minLength": 1
230
+ },
231
+ "tagsDelimiter": {
232
+ "type": "string",
233
+ "minLength": 1,
234
+ "maxLength": 4,
235
+ "default": ","
236
+ },
237
+ "stageColumn": {
238
+ "type": "string",
239
+ "minLength": 1
240
+ },
241
+ "customFields": {
242
+ "type": "object",
243
+ "additionalProperties": {
244
+ "type": "string"
245
+ }
246
+ },
247
+ "identities": {
248
+ "type": "array",
249
+ "items": {
250
+ "type": "object",
251
+ "properties": {
252
+ "channelColumn": {
253
+ "type": "string",
254
+ "minLength": 1
255
+ },
256
+ "channelDefault": {
257
+ "type": "string",
258
+ "enum": [
259
+ "telegram",
260
+ "instagram",
261
+ "messenger",
262
+ "whatsapp"
263
+ ]
264
+ },
265
+ "externalUserIdColumn": {
266
+ "type": "string",
267
+ "minLength": 1
268
+ },
269
+ "displayNameColumn": {
270
+ "type": "string",
271
+ "minLength": 1
272
+ },
273
+ "verificationStatus": {
274
+ "type": "string",
275
+ "enum": [
276
+ "inferred",
277
+ "claimed",
278
+ "verified",
279
+ "rejected"
280
+ ],
281
+ "default": "claimed"
282
+ },
283
+ "source": {
284
+ "type": "string",
285
+ "minLength": 1
286
+ }
287
+ },
288
+ "required": [
289
+ "externalUserIdColumn"
290
+ ]
291
+ },
292
+ "maxItems": 20,
293
+ "default": []
294
+ },
295
+ "consents": {
296
+ "type": "array",
297
+ "items": {
298
+ "type": "object",
299
+ "properties": {
300
+ "channelColumn": {
301
+ "type": "string",
302
+ "minLength": 1
303
+ },
304
+ "channelDefault": {
305
+ "type": "string",
306
+ "enum": [
307
+ "telegram",
308
+ "instagram",
309
+ "messenger",
310
+ "whatsapp"
311
+ ]
312
+ },
313
+ "purpose": {
314
+ "type": "string",
315
+ "enum": [
316
+ "booking_reminders",
317
+ "sales_follow_up",
318
+ "support"
319
+ ]
320
+ },
321
+ "grantedColumn": {
322
+ "type": "string",
323
+ "minLength": 1
324
+ },
325
+ "evidenceColumn": {
326
+ "type": "string",
327
+ "minLength": 1
328
+ },
329
+ "source": {
330
+ "type": "string",
331
+ "minLength": 1
332
+ }
333
+ },
334
+ "required": [
335
+ "purpose",
336
+ "grantedColumn"
337
+ ]
338
+ },
339
+ "maxItems": 20,
340
+ "default": []
341
+ }
342
+ },
343
+ "required": [
344
+ "identity"
345
+ ]
346
+ }
347
+ },
348
+ "required": [
349
+ "rows",
350
+ "mapping"
351
+ ]
352
+ }
353
+ },
354
+ "POST /api/leads/imports/apply": {
355
+ "body": {
356
+ "type": "object",
357
+ "properties": {
358
+ "source": {
359
+ "type": "string",
360
+ "minLength": 1,
361
+ "default": "csv_import"
362
+ },
363
+ "rows": {
364
+ "type": "array",
365
+ "items": {
366
+ "type": "object",
367
+ "additionalProperties": {}
368
+ },
369
+ "minItems": 1,
370
+ "maxItems": 1000
371
+ },
372
+ "mapping": {
373
+ "type": "object",
374
+ "properties": {
375
+ "identity": {
376
+ "type": "object",
377
+ "properties": {
378
+ "channelColumn": {
379
+ "type": "string",
380
+ "minLength": 1
381
+ },
382
+ "channelDefault": {
383
+ "type": "string",
384
+ "enum": [
385
+ "telegram",
386
+ "instagram",
387
+ "messenger",
388
+ "whatsapp"
389
+ ]
390
+ },
391
+ "externalUserIdColumn": {
392
+ "type": "string",
393
+ "minLength": 1
394
+ },
395
+ "displayNameColumn": {
396
+ "type": "string",
397
+ "minLength": 1
398
+ }
399
+ },
400
+ "required": [
401
+ "externalUserIdColumn"
402
+ ]
403
+ },
404
+ "tagsColumn": {
405
+ "type": "string",
406
+ "minLength": 1
407
+ },
408
+ "tagsDelimiter": {
409
+ "type": "string",
410
+ "minLength": 1,
411
+ "maxLength": 4,
412
+ "default": ","
413
+ },
414
+ "stageColumn": {
415
+ "type": "string",
416
+ "minLength": 1
417
+ },
418
+ "customFields": {
419
+ "type": "object",
420
+ "additionalProperties": {
421
+ "type": "string"
422
+ }
423
+ },
424
+ "identities": {
425
+ "type": "array",
426
+ "items": {
427
+ "type": "object",
428
+ "properties": {
429
+ "channelColumn": {
430
+ "type": "string",
431
+ "minLength": 1
432
+ },
433
+ "channelDefault": {
434
+ "type": "string",
435
+ "enum": [
436
+ "telegram",
437
+ "instagram",
438
+ "messenger",
439
+ "whatsapp"
440
+ ]
441
+ },
442
+ "externalUserIdColumn": {
443
+ "type": "string",
444
+ "minLength": 1
445
+ },
446
+ "displayNameColumn": {
447
+ "type": "string",
448
+ "minLength": 1
449
+ },
450
+ "verificationStatus": {
451
+ "type": "string",
452
+ "enum": [
453
+ "inferred",
454
+ "claimed",
455
+ "verified",
456
+ "rejected"
457
+ ],
458
+ "default": "claimed"
459
+ },
460
+ "source": {
461
+ "type": "string",
462
+ "minLength": 1
463
+ }
464
+ },
465
+ "required": [
466
+ "externalUserIdColumn"
467
+ ]
468
+ },
469
+ "maxItems": 20,
470
+ "default": []
471
+ },
472
+ "consents": {
473
+ "type": "array",
474
+ "items": {
475
+ "type": "object",
476
+ "properties": {
477
+ "channelColumn": {
478
+ "type": "string",
479
+ "minLength": 1
480
+ },
481
+ "channelDefault": {
482
+ "type": "string",
483
+ "enum": [
484
+ "telegram",
485
+ "instagram",
486
+ "messenger",
487
+ "whatsapp"
488
+ ]
489
+ },
490
+ "purpose": {
491
+ "type": "string",
492
+ "enum": [
493
+ "booking_reminders",
494
+ "sales_follow_up",
495
+ "support"
496
+ ]
497
+ },
498
+ "grantedColumn": {
499
+ "type": "string",
500
+ "minLength": 1
501
+ },
502
+ "evidenceColumn": {
503
+ "type": "string",
504
+ "minLength": 1
505
+ },
506
+ "source": {
507
+ "type": "string",
508
+ "minLength": 1
509
+ }
510
+ },
511
+ "required": [
512
+ "purpose",
513
+ "grantedColumn"
514
+ ]
515
+ },
516
+ "maxItems": 20,
517
+ "default": []
518
+ }
519
+ },
520
+ "required": [
521
+ "identity"
522
+ ]
523
+ }
524
+ },
525
+ "required": [
526
+ "rows",
527
+ "mapping"
528
+ ]
529
+ }
530
+ },
531
+ "POST /api/leads/{id}/identities": {
532
+ "path": {
533
+ "type": "object",
534
+ "properties": {
535
+ "id": {
536
+ "type": "string",
537
+ "format": "uuid"
538
+ }
539
+ },
540
+ "required": [
541
+ "id"
542
+ ]
543
+ },
544
+ "body": {
545
+ "type": "object",
546
+ "properties": {
547
+ "channel": {
548
+ "type": "string",
549
+ "enum": [
550
+ "telegram",
551
+ "instagram",
552
+ "messenger",
553
+ "whatsapp"
554
+ ]
555
+ },
556
+ "externalUserId": {
557
+ "type": "string",
558
+ "minLength": 1
559
+ },
560
+ "displayName": {
561
+ "type": "string",
562
+ "minLength": 1
563
+ },
564
+ "verificationStatus": {
565
+ "type": "string",
566
+ "enum": [
567
+ "inferred",
568
+ "claimed",
569
+ "verified",
570
+ "rejected"
571
+ ],
572
+ "default": "claimed"
573
+ },
574
+ "source": {
575
+ "type": "string",
576
+ "minLength": 1,
577
+ "default": "api"
578
+ },
579
+ "sourceRef": {
580
+ "type": "string",
581
+ "minLength": 1
582
+ }
583
+ },
584
+ "required": [
585
+ "channel",
586
+ "externalUserId"
587
+ ]
588
+ }
589
+ },
590
+ "POST /api/leads/{id}/consents": {
591
+ "path": {
592
+ "type": "object",
593
+ "properties": {
594
+ "id": {
595
+ "type": "string",
596
+ "format": "uuid"
597
+ }
598
+ },
599
+ "required": [
600
+ "id"
601
+ ]
602
+ },
603
+ "body": {
604
+ "type": "object",
605
+ "properties": {
606
+ "channel": {
607
+ "type": "string",
608
+ "enum": [
609
+ "telegram",
610
+ "instagram",
611
+ "messenger",
612
+ "whatsapp"
613
+ ]
614
+ },
615
+ "purpose": {
616
+ "type": "string",
617
+ "enum": [
618
+ "booking_reminders",
619
+ "sales_follow_up",
620
+ "support"
621
+ ]
622
+ },
623
+ "source": {
624
+ "type": "string",
625
+ "minLength": 1
626
+ },
627
+ "evidenceId": {
628
+ "type": "string",
629
+ "minLength": 1
630
+ },
631
+ "grantedAt": {
632
+ "type": [
633
+ "string",
634
+ "null"
635
+ ],
636
+ "format": "date-time"
637
+ }
638
+ },
639
+ "required": [
640
+ "channel",
641
+ "purpose",
642
+ "source",
643
+ "evidenceId"
644
+ ]
645
+ }
646
+ },
647
+ "POST /api/leads/{id}/consents/revoke": {
648
+ "path": {
649
+ "type": "object",
650
+ "properties": {
651
+ "id": {
652
+ "type": "string",
653
+ "format": "uuid"
654
+ }
655
+ },
656
+ "required": [
657
+ "id"
658
+ ]
659
+ },
660
+ "body": {
661
+ "type": "object",
662
+ "properties": {
663
+ "channel": {
664
+ "type": "string",
665
+ "enum": [
666
+ "telegram",
667
+ "instagram",
668
+ "messenger",
669
+ "whatsapp"
670
+ ]
671
+ },
672
+ "purpose": {
673
+ "type": "string",
674
+ "enum": [
675
+ "booking_reminders",
676
+ "sales_follow_up",
677
+ "support"
678
+ ]
679
+ }
680
+ },
681
+ "required": [
682
+ "channel",
683
+ "purpose"
684
+ ]
685
+ }
686
+ },
687
+ "POST /api/leads/{id}/notes": {
688
+ "path": {
689
+ "type": "object",
690
+ "properties": {
691
+ "id": {
692
+ "type": "string",
693
+ "format": "uuid"
694
+ }
695
+ },
696
+ "required": [
697
+ "id"
698
+ ]
699
+ },
700
+ "body": {
701
+ "type": "object",
702
+ "properties": {
703
+ "body": {
704
+ "type": "string",
705
+ "minLength": 1
706
+ }
707
+ },
708
+ "required": [
709
+ "body"
710
+ ]
711
+ }
712
+ },
713
+ "GET /api/conversations": {
714
+ "query": {
715
+ "type": "object",
716
+ "properties": {
717
+ "limit": {
718
+ "type": "integer",
719
+ "minimum": 1,
720
+ "maximum": 100
721
+ },
722
+ "cursor": {
723
+ "type": "string",
724
+ "minLength": 1
725
+ },
726
+ "channel": {
727
+ "type": "string",
728
+ "enum": [
729
+ "telegram",
730
+ "instagram",
731
+ "messenger",
732
+ "whatsapp"
733
+ ]
734
+ },
735
+ "q": {
736
+ "type": "string",
737
+ "minLength": 1
738
+ }
739
+ }
740
+ }
741
+ },
742
+ "GET /api/conversations/{id}": {
743
+ "path": {
744
+ "type": "object",
745
+ "properties": {
746
+ "id": {
747
+ "type": "string",
748
+ "format": "uuid"
749
+ }
750
+ },
751
+ "required": [
752
+ "id"
753
+ ]
754
+ }
755
+ },
756
+ "GET /api/review-queue": {
757
+ "query": {
758
+ "type": "object",
759
+ "properties": {
760
+ "limit": {
761
+ "type": "integer",
762
+ "minimum": 1,
763
+ "maximum": 100
764
+ },
765
+ "cursor": {
766
+ "type": "string",
767
+ "minLength": 1
768
+ },
769
+ "status": {
770
+ "type": "string",
771
+ "minLength": 1
772
+ }
773
+ }
774
+ }
775
+ },
776
+ "GET /api/review-queue/{id}/explain": {
777
+ "path": {
778
+ "type": "object",
779
+ "properties": {
780
+ "id": {
781
+ "type": "string",
782
+ "format": "uuid"
783
+ }
784
+ },
785
+ "required": [
786
+ "id"
787
+ ]
788
+ }
789
+ },
790
+ "GET /api/bookings": {
791
+ "query": {
792
+ "type": "object",
793
+ "properties": {
794
+ "limit": {
795
+ "type": "integer",
796
+ "minimum": 1,
797
+ "maximum": 100
798
+ },
799
+ "cursor": {
800
+ "type": "string",
801
+ "minLength": 1
802
+ },
803
+ "status": {
804
+ "type": "string",
805
+ "minLength": 1
806
+ },
807
+ "upcoming": {
808
+ "type": "string",
809
+ "minLength": 1
810
+ }
811
+ }
812
+ }
813
+ },
814
+ "POST /api/bookings": {
815
+ "body": {
816
+ "type": "object",
817
+ "properties": {
818
+ "leadId": {
819
+ "type": "string",
820
+ "format": "uuid"
821
+ },
822
+ "slotAt": {
823
+ "type": [
824
+ "string",
825
+ "null"
826
+ ],
827
+ "format": "date-time"
828
+ },
829
+ "status": {
830
+ "type": "string",
831
+ "enum": [
832
+ "held",
833
+ "confirmed",
834
+ "cancelled",
835
+ "completed",
836
+ "no_show"
837
+ ]
838
+ },
839
+ "provider": {
840
+ "type": "string",
841
+ "enum": [
842
+ "manual",
843
+ "calendly",
844
+ "cal_com",
845
+ "iclosed",
846
+ "gohighlevel"
847
+ ],
848
+ "default": "manual"
849
+ },
850
+ "providerEventId": {
851
+ "type": [
852
+ "string",
853
+ "null"
854
+ ]
855
+ },
856
+ "providerInviteeId": {
857
+ "type": [
858
+ "string",
859
+ "null"
860
+ ]
861
+ },
862
+ "timezone": {
863
+ "type": "string",
864
+ "minLength": 1,
865
+ "default": "UTC"
866
+ },
867
+ "rawPayload": {
868
+ "type": "object",
869
+ "additionalProperties": {}
870
+ },
871
+ "calendlyEventId": {
872
+ "type": [
873
+ "string",
874
+ "null"
875
+ ]
876
+ },
877
+ "calendlyInviteeId": {
878
+ "type": [
879
+ "string",
880
+ "null"
881
+ ]
882
+ }
883
+ },
884
+ "required": [
885
+ "leadId",
886
+ "slotAt"
887
+ ]
888
+ }
889
+ },
890
+ "PATCH /api/bookings/{id}": {
891
+ "path": {
892
+ "type": "object",
893
+ "properties": {
894
+ "id": {
895
+ "type": "string",
896
+ "format": "uuid"
897
+ }
898
+ },
899
+ "required": [
900
+ "id"
901
+ ]
902
+ },
903
+ "body": {
904
+ "type": "object",
905
+ "properties": {
906
+ "slotAt": {
907
+ "type": [
908
+ "string",
909
+ "null"
910
+ ],
911
+ "format": "date-time"
912
+ },
913
+ "status": {
914
+ "type": "string",
915
+ "enum": [
916
+ "held",
917
+ "confirmed",
918
+ "cancelled",
919
+ "completed",
920
+ "no_show"
921
+ ]
922
+ },
923
+ "provider": {
924
+ "type": "string",
925
+ "enum": [
926
+ "manual",
927
+ "calendly",
928
+ "cal_com",
929
+ "iclosed",
930
+ "gohighlevel"
931
+ ]
932
+ },
933
+ "providerEventId": {
934
+ "type": [
935
+ "string",
936
+ "null"
937
+ ]
938
+ },
939
+ "providerInviteeId": {
940
+ "type": [
941
+ "string",
942
+ "null"
943
+ ]
944
+ },
945
+ "timezone": {
946
+ "type": "string",
947
+ "minLength": 1
948
+ },
949
+ "rawPayload": {
950
+ "type": "object",
951
+ "additionalProperties": {}
952
+ },
953
+ "calendlyEventId": {
954
+ "type": [
955
+ "string",
956
+ "null"
957
+ ]
958
+ },
959
+ "calendlyInviteeId": {
960
+ "type": [
961
+ "string",
962
+ "null"
963
+ ]
964
+ }
965
+ }
966
+ }
967
+ },
968
+ "DELETE /api/bookings/{id}": {
969
+ "path": {
970
+ "type": "object",
971
+ "properties": {
972
+ "id": {
973
+ "type": "string",
974
+ "format": "uuid"
975
+ }
976
+ },
977
+ "required": [
978
+ "id"
979
+ ]
980
+ }
981
+ },
982
+ "GET /api/campaigns": {
983
+ "query": {
984
+ "type": "object",
985
+ "properties": {
986
+ "limit": {
987
+ "type": "integer",
988
+ "minimum": 1,
989
+ "maximum": 100
990
+ },
991
+ "cursor": {
992
+ "type": "string",
993
+ "minLength": 1
994
+ },
995
+ "status": {
996
+ "type": "string",
997
+ "enum": [
998
+ "draft",
999
+ "published",
1000
+ "paused",
1001
+ "archived"
1002
+ ]
1003
+ }
1004
+ }
1005
+ }
1006
+ },
1007
+ "GET /api/campaigns/{id}": {
1008
+ "path": {
1009
+ "type": "object",
1010
+ "properties": {
1011
+ "id": {
1012
+ "type": "string",
1013
+ "format": "uuid"
1014
+ }
1015
+ },
1016
+ "required": [
1017
+ "id"
1018
+ ]
1019
+ }
1020
+ },
1021
+ "POST /api/campaigns": {
1022
+ "body": {
1023
+ "type": "object",
1024
+ "properties": {
1025
+ "name": {
1026
+ "type": "string",
1027
+ "minLength": 1
1028
+ },
1029
+ "description": {
1030
+ "type": "string",
1031
+ "minLength": 1
1032
+ },
1033
+ "graph": {}
1034
+ },
1035
+ "required": [
1036
+ "name"
1037
+ ]
1038
+ }
1039
+ },
1040
+ "POST /api/campaigns/generate": {
1041
+ "body": {
1042
+ "type": "object",
1043
+ "properties": {
1044
+ "mode": {
1045
+ "type": "string",
1046
+ "enum": [
1047
+ "new",
1048
+ "guided_improvement",
1049
+ "improve_existing"
1050
+ ],
1051
+ "default": "new"
1052
+ },
1053
+ "prompt": {
1054
+ "type": "string",
1055
+ "minLength": 1,
1056
+ "maxLength": 2000
1057
+ },
1058
+ "targetAudience": {
1059
+ "type": "string",
1060
+ "minLength": 1,
1061
+ "maxLength": 2000
1062
+ },
1063
+ "goal": {
1064
+ "type": "string",
1065
+ "enum": [
1066
+ "book_call",
1067
+ "qualify",
1068
+ "nurture",
1069
+ "recover",
1070
+ "reactivation",
1071
+ "event_webinar",
1072
+ "promo"
1073
+ ]
1074
+ },
1075
+ "primaryChannel": {
1076
+ "type": "string",
1077
+ "enum": [
1078
+ "telegram",
1079
+ "instagram",
1080
+ "messenger",
1081
+ "whatsapp"
1082
+ ]
1083
+ },
1084
+ "fallbackChannels": {
1085
+ "type": "array",
1086
+ "items": {
1087
+ "type": "string",
1088
+ "enum": [
1089
+ "telegram",
1090
+ "instagram",
1091
+ "messenger",
1092
+ "whatsapp"
1093
+ ]
1094
+ },
1095
+ "maxItems": 50,
1096
+ "default": []
1097
+ },
1098
+ "source": {
1099
+ "type": "string",
1100
+ "enum": [
1101
+ "instagram_comments",
1102
+ "instagram_dm",
1103
+ "whatsapp",
1104
+ "csv_import",
1105
+ "webhook_crm",
1106
+ "broadcast"
1107
+ ]
1108
+ },
1109
+ "sampleMessages": {
1110
+ "type": "array",
1111
+ "items": {
1112
+ "type": "string",
1113
+ "minLength": 1,
1114
+ "maxLength": 2000
1115
+ },
1116
+ "maxItems": 50,
1117
+ "default": []
1118
+ },
1119
+ "faqsAndObjections": {
1120
+ "type": "array",
1121
+ "items": {
1122
+ "type": "string",
1123
+ "minLength": 1,
1124
+ "maxLength": 2000
1125
+ },
1126
+ "maxItems": 50,
1127
+ "default": []
1128
+ },
1129
+ "pricingAndPaymentFacts": {
1130
+ "type": "array",
1131
+ "items": {
1132
+ "type": "string",
1133
+ "minLength": 1,
1134
+ "maxLength": 2000
1135
+ },
1136
+ "maxItems": 50,
1137
+ "default": []
1138
+ },
1139
+ "bookingConstraints": {
1140
+ "type": "array",
1141
+ "items": {
1142
+ "type": "string",
1143
+ "minLength": 1,
1144
+ "maxLength": 2000
1145
+ },
1146
+ "maxItems": 50,
1147
+ "default": []
1148
+ },
1149
+ "complianceDisallowedClaims": {
1150
+ "type": "array",
1151
+ "items": {
1152
+ "type": "string",
1153
+ "minLength": 1,
1154
+ "maxLength": 2000
1155
+ },
1156
+ "maxItems": 50,
1157
+ "default": []
1158
+ },
1159
+ "toneExamples": {
1160
+ "type": "array",
1161
+ "items": {
1162
+ "type": "string",
1163
+ "minLength": 1,
1164
+ "maxLength": 2000
1165
+ },
1166
+ "maxItems": 50,
1167
+ "default": []
1168
+ },
1169
+ "existingGraph": {
1170
+ "type": "object",
1171
+ "properties": {
1172
+ "version": {
1173
+ "type": "number",
1174
+ "enum": [
1175
+ 1
1176
+ ]
1177
+ },
1178
+ "startNodeId": {
1179
+ "type": "string",
1180
+ "minLength": 1
1181
+ },
1182
+ "nodes": {
1183
+ "type": "array",
1184
+ "items": {
1185
+ "type": "object",
1186
+ "properties": {
1187
+ "id": {
1188
+ "type": "string",
1189
+ "minLength": 1,
1190
+ "maxLength": 128
1191
+ },
1192
+ "type": {
1193
+ "type": "string",
1194
+ "enum": [
1195
+ "trigger",
1196
+ "condition",
1197
+ "action",
1198
+ "ai",
1199
+ "message",
1200
+ "booking",
1201
+ "wait_duration",
1202
+ "wait_until_time",
1203
+ "wait_for_event",
1204
+ "wait_for_reply",
1205
+ "wait_for_condition",
1206
+ "branch",
1207
+ "control",
1208
+ "stop"
1209
+ ]
1210
+ },
1211
+ "label": {
1212
+ "type": "string",
1213
+ "minLength": 1,
1214
+ "maxLength": 256
1215
+ },
1216
+ "config": {
1217
+ "type": "object",
1218
+ "additionalProperties": {},
1219
+ "default": {}
1220
+ }
1221
+ },
1222
+ "required": [
1223
+ "id",
1224
+ "type"
1225
+ ]
1226
+ },
1227
+ "minItems": 1,
1228
+ "maxItems": 100
1229
+ },
1230
+ "edges": {
1231
+ "type": "array",
1232
+ "items": {
1233
+ "type": "object",
1234
+ "properties": {
1235
+ "id": {
1236
+ "type": "string",
1237
+ "minLength": 1,
1238
+ "maxLength": 128
1239
+ },
1240
+ "source": {
1241
+ "type": "string",
1242
+ "minLength": 1,
1243
+ "maxLength": 128
1244
+ },
1245
+ "target": {
1246
+ "type": "string",
1247
+ "minLength": 1,
1248
+ "maxLength": 128
1249
+ },
1250
+ "label": {
1251
+ "type": "string",
1252
+ "minLength": 1,
1253
+ "maxLength": 256
1254
+ },
1255
+ "condition": {
1256
+ "type": "object",
1257
+ "additionalProperties": {}
1258
+ }
1259
+ },
1260
+ "required": [
1261
+ "id",
1262
+ "source",
1263
+ "target"
1264
+ ]
1265
+ },
1266
+ "maxItems": 200,
1267
+ "default": []
1268
+ },
1269
+ "knowledge": {
1270
+ "type": "object",
1271
+ "properties": {
1272
+ "offerDescription": {
1273
+ "type": "string",
1274
+ "minLength": 1,
1275
+ "maxLength": 2000
1276
+ },
1277
+ "priceAndPaymentFacts": {
1278
+ "type": "array",
1279
+ "items": {
1280
+ "type": "string",
1281
+ "minLength": 1,
1282
+ "maxLength": 2000
1283
+ },
1284
+ "maxItems": 50
1285
+ },
1286
+ "programStructure": {
1287
+ "type": "array",
1288
+ "items": {
1289
+ "type": "string",
1290
+ "minLength": 1,
1291
+ "maxLength": 2000
1292
+ },
1293
+ "maxItems": 50
1294
+ },
1295
+ "bookingRules": {
1296
+ "type": "array",
1297
+ "items": {
1298
+ "type": "string",
1299
+ "minLength": 1,
1300
+ "maxLength": 2000
1301
+ },
1302
+ "maxItems": 50
1303
+ },
1304
+ "faqsAndObjections": {
1305
+ "type": "array",
1306
+ "items": {
1307
+ "type": "string",
1308
+ "minLength": 1,
1309
+ "maxLength": 2000
1310
+ },
1311
+ "maxItems": 50
1312
+ },
1313
+ "disallowedClaims": {
1314
+ "type": "array",
1315
+ "items": {
1316
+ "type": "string",
1317
+ "minLength": 1,
1318
+ "maxLength": 2000
1319
+ },
1320
+ "maxItems": 50
1321
+ },
1322
+ "resourceLinks": {
1323
+ "type": "array",
1324
+ "items": {
1325
+ "type": "string",
1326
+ "maxLength": 2000,
1327
+ "format": "uri"
1328
+ },
1329
+ "maxItems": 50
1330
+ },
1331
+ "exampleGoodReplies": {
1332
+ "type": "array",
1333
+ "items": {
1334
+ "type": "string",
1335
+ "minLength": 1,
1336
+ "maxLength": 2000
1337
+ },
1338
+ "maxItems": 50
1339
+ },
1340
+ "sourceNotes": {
1341
+ "type": "array",
1342
+ "items": {
1343
+ "type": "string",
1344
+ "minLength": 1,
1345
+ "maxLength": 2000
1346
+ },
1347
+ "maxItems": 50
1348
+ }
1349
+ }
1350
+ },
1351
+ "qualification": {
1352
+ "type": "object",
1353
+ "properties": {
1354
+ "requiredFields": {
1355
+ "type": "array",
1356
+ "items": {
1357
+ "type": "string",
1358
+ "minLength": 1,
1359
+ "maxLength": 2000
1360
+ },
1361
+ "maxItems": 50
1362
+ },
1363
+ "disqualifiers": {
1364
+ "type": "array",
1365
+ "items": {
1366
+ "type": "string",
1367
+ "minLength": 1,
1368
+ "maxLength": 2000
1369
+ },
1370
+ "maxItems": 50
1371
+ },
1372
+ "minimumScore": {
1373
+ "type": "number",
1374
+ "minimum": 0,
1375
+ "maximum": 100
1376
+ },
1377
+ "requireExplicitConsentBeforeBooking": {
1378
+ "type": "boolean"
1379
+ },
1380
+ "bookingCtaLogic": {
1381
+ "type": "string",
1382
+ "minLength": 1,
1383
+ "maxLength": 2000
1384
+ },
1385
+ "outcomes": {
1386
+ "type": "array",
1387
+ "items": {
1388
+ "type": "string",
1389
+ "enum": [
1390
+ "qualified",
1391
+ "nurture",
1392
+ "disqualified",
1393
+ "needs_human"
1394
+ ]
1395
+ },
1396
+ "maxItems": 50
1397
+ }
1398
+ }
1399
+ },
1400
+ "analyticsGoal": {
1401
+ "type": "string",
1402
+ "minLength": 1,
1403
+ "maxLength": 2000
1404
+ }
1405
+ },
1406
+ "required": [
1407
+ "version",
1408
+ "startNodeId",
1409
+ "nodes"
1410
+ ]
1411
+ },
1412
+ "guidance": {
1413
+ "type": "string",
1414
+ "minLength": 1,
1415
+ "maxLength": 2000
1416
+ }
1417
+ },
1418
+ "required": [
1419
+ "prompt"
1420
+ ]
1421
+ }
1422
+ },
1423
+ "PATCH /api/campaigns/{id}/draft": {
1424
+ "path": {
1425
+ "type": "object",
1426
+ "properties": {
1427
+ "id": {
1428
+ "type": "string",
1429
+ "format": "uuid"
1430
+ }
1431
+ },
1432
+ "required": [
1433
+ "id"
1434
+ ]
1435
+ },
1436
+ "body": {
1437
+ "type": "object",
1438
+ "properties": {
1439
+ "name": {
1440
+ "type": "string",
1441
+ "minLength": 1
1442
+ },
1443
+ "description": {
1444
+ "type": [
1445
+ "string",
1446
+ "null"
1447
+ ],
1448
+ "minLength": 1
1449
+ },
1450
+ "graph": {
1451
+ "type": "object",
1452
+ "properties": {
1453
+ "version": {
1454
+ "type": "number",
1455
+ "enum": [
1456
+ 1
1457
+ ]
1458
+ },
1459
+ "startNodeId": {
1460
+ "type": "string",
1461
+ "minLength": 1
1462
+ },
1463
+ "nodes": {
1464
+ "type": "array",
1465
+ "items": {
1466
+ "type": "object",
1467
+ "properties": {
1468
+ "id": {
1469
+ "type": "string",
1470
+ "minLength": 1,
1471
+ "maxLength": 128
1472
+ },
1473
+ "type": {
1474
+ "type": "string",
1475
+ "enum": [
1476
+ "trigger",
1477
+ "condition",
1478
+ "action",
1479
+ "ai",
1480
+ "message",
1481
+ "booking",
1482
+ "wait_duration",
1483
+ "wait_until_time",
1484
+ "wait_for_event",
1485
+ "wait_for_reply",
1486
+ "wait_for_condition",
1487
+ "branch",
1488
+ "control",
1489
+ "stop"
1490
+ ]
1491
+ },
1492
+ "label": {
1493
+ "type": "string",
1494
+ "minLength": 1,
1495
+ "maxLength": 256
1496
+ },
1497
+ "config": {
1498
+ "type": "object",
1499
+ "additionalProperties": {},
1500
+ "default": {}
1501
+ }
1502
+ },
1503
+ "required": [
1504
+ "id",
1505
+ "type"
1506
+ ]
1507
+ },
1508
+ "minItems": 1,
1509
+ "maxItems": 100
1510
+ },
1511
+ "edges": {
1512
+ "type": "array",
1513
+ "items": {
1514
+ "type": "object",
1515
+ "properties": {
1516
+ "id": {
1517
+ "type": "string",
1518
+ "minLength": 1,
1519
+ "maxLength": 128
1520
+ },
1521
+ "source": {
1522
+ "type": "string",
1523
+ "minLength": 1,
1524
+ "maxLength": 128
1525
+ },
1526
+ "target": {
1527
+ "type": "string",
1528
+ "minLength": 1,
1529
+ "maxLength": 128
1530
+ },
1531
+ "label": {
1532
+ "type": "string",
1533
+ "minLength": 1,
1534
+ "maxLength": 256
1535
+ },
1536
+ "condition": {
1537
+ "type": "object",
1538
+ "additionalProperties": {}
1539
+ }
1540
+ },
1541
+ "required": [
1542
+ "id",
1543
+ "source",
1544
+ "target"
1545
+ ]
1546
+ },
1547
+ "maxItems": 200,
1548
+ "default": []
1549
+ },
1550
+ "knowledge": {
1551
+ "type": "object",
1552
+ "properties": {
1553
+ "offerDescription": {
1554
+ "type": "string",
1555
+ "minLength": 1,
1556
+ "maxLength": 2000
1557
+ },
1558
+ "priceAndPaymentFacts": {
1559
+ "type": "array",
1560
+ "items": {
1561
+ "type": "string",
1562
+ "minLength": 1,
1563
+ "maxLength": 2000
1564
+ },
1565
+ "maxItems": 50
1566
+ },
1567
+ "programStructure": {
1568
+ "type": "array",
1569
+ "items": {
1570
+ "type": "string",
1571
+ "minLength": 1,
1572
+ "maxLength": 2000
1573
+ },
1574
+ "maxItems": 50
1575
+ },
1576
+ "bookingRules": {
1577
+ "type": "array",
1578
+ "items": {
1579
+ "type": "string",
1580
+ "minLength": 1,
1581
+ "maxLength": 2000
1582
+ },
1583
+ "maxItems": 50
1584
+ },
1585
+ "faqsAndObjections": {
1586
+ "type": "array",
1587
+ "items": {
1588
+ "type": "string",
1589
+ "minLength": 1,
1590
+ "maxLength": 2000
1591
+ },
1592
+ "maxItems": 50
1593
+ },
1594
+ "disallowedClaims": {
1595
+ "type": "array",
1596
+ "items": {
1597
+ "type": "string",
1598
+ "minLength": 1,
1599
+ "maxLength": 2000
1600
+ },
1601
+ "maxItems": 50
1602
+ },
1603
+ "resourceLinks": {
1604
+ "type": "array",
1605
+ "items": {
1606
+ "type": "string",
1607
+ "maxLength": 2000,
1608
+ "format": "uri"
1609
+ },
1610
+ "maxItems": 50
1611
+ },
1612
+ "exampleGoodReplies": {
1613
+ "type": "array",
1614
+ "items": {
1615
+ "type": "string",
1616
+ "minLength": 1,
1617
+ "maxLength": 2000
1618
+ },
1619
+ "maxItems": 50
1620
+ },
1621
+ "sourceNotes": {
1622
+ "type": "array",
1623
+ "items": {
1624
+ "type": "string",
1625
+ "minLength": 1,
1626
+ "maxLength": 2000
1627
+ },
1628
+ "maxItems": 50
1629
+ }
1630
+ }
1631
+ },
1632
+ "qualification": {
1633
+ "type": "object",
1634
+ "properties": {
1635
+ "requiredFields": {
1636
+ "type": "array",
1637
+ "items": {
1638
+ "type": "string",
1639
+ "minLength": 1,
1640
+ "maxLength": 2000
1641
+ },
1642
+ "maxItems": 50
1643
+ },
1644
+ "disqualifiers": {
1645
+ "type": "array",
1646
+ "items": {
1647
+ "type": "string",
1648
+ "minLength": 1,
1649
+ "maxLength": 2000
1650
+ },
1651
+ "maxItems": 50
1652
+ },
1653
+ "minimumScore": {
1654
+ "type": "number",
1655
+ "minimum": 0,
1656
+ "maximum": 100
1657
+ },
1658
+ "requireExplicitConsentBeforeBooking": {
1659
+ "type": "boolean"
1660
+ },
1661
+ "bookingCtaLogic": {
1662
+ "type": "string",
1663
+ "minLength": 1,
1664
+ "maxLength": 2000
1665
+ },
1666
+ "outcomes": {
1667
+ "type": "array",
1668
+ "items": {
1669
+ "type": "string",
1670
+ "enum": [
1671
+ "qualified",
1672
+ "nurture",
1673
+ "disqualified",
1674
+ "needs_human"
1675
+ ]
1676
+ },
1677
+ "maxItems": 50
1678
+ }
1679
+ }
1680
+ },
1681
+ "analyticsGoal": {
1682
+ "type": "string",
1683
+ "minLength": 1,
1684
+ "maxLength": 2000
1685
+ }
1686
+ },
1687
+ "required": [
1688
+ "version",
1689
+ "startNodeId",
1690
+ "nodes"
1691
+ ]
1692
+ },
1693
+ "expectedDraftUpdatedAt": {
1694
+ "type": "string",
1695
+ "format": "date-time"
1696
+ }
1697
+ },
1698
+ "required": [
1699
+ "graph"
1700
+ ]
1701
+ }
1702
+ },
1703
+ "GET /api/campaigns/{id}/enrollments": {
1704
+ "path": {
1705
+ "type": "object",
1706
+ "properties": {
1707
+ "id": {
1708
+ "type": "string",
1709
+ "format": "uuid"
1710
+ }
1711
+ },
1712
+ "required": [
1713
+ "id"
1714
+ ]
1715
+ }
1716
+ },
1717
+ "POST /api/campaigns/{id}/enrollments": {
1718
+ "path": {
1719
+ "type": "object",
1720
+ "properties": {
1721
+ "id": {
1722
+ "type": "string",
1723
+ "format": "uuid"
1724
+ }
1725
+ },
1726
+ "required": [
1727
+ "id"
1728
+ ]
1729
+ },
1730
+ "body": {
1731
+ "type": "object",
1732
+ "properties": {
1733
+ "leadId": {
1734
+ "type": "string",
1735
+ "format": "uuid"
1736
+ }
1737
+ },
1738
+ "required": [
1739
+ "leadId"
1740
+ ]
1741
+ }
1742
+ },
1743
+ "GET /api/campaigns/{id}/analytics": {
1744
+ "path": {
1745
+ "type": "object",
1746
+ "properties": {
1747
+ "id": {
1748
+ "type": "string",
1749
+ "format": "uuid"
1750
+ }
1751
+ },
1752
+ "required": [
1753
+ "id"
1754
+ ]
1755
+ },
1756
+ "query": {
1757
+ "type": "object",
1758
+ "properties": {
1759
+ "since": {
1760
+ "type": "string",
1761
+ "minLength": 1
1762
+ },
1763
+ "until": {
1764
+ "type": "string",
1765
+ "minLength": 1
1766
+ }
1767
+ }
1768
+ }
1769
+ },
1770
+ "GET /api/campaigns/{id}/provider-capabilities": {
1771
+ "path": {
1772
+ "type": "object",
1773
+ "properties": {
1774
+ "id": {
1775
+ "type": "string",
1776
+ "format": "uuid"
1777
+ }
1778
+ },
1779
+ "required": [
1780
+ "id"
1781
+ ]
1782
+ }
1783
+ },
1784
+ "GET /api/campaigns/comment-events": {
1785
+ "query": {
1786
+ "type": "object",
1787
+ "properties": {
1788
+ "campaignId": {
1789
+ "type": "string",
1790
+ "format": "uuid"
1791
+ },
1792
+ "status": {
1793
+ "type": "string",
1794
+ "enum": [
1795
+ "matched",
1796
+ "suppressed",
1797
+ "blocked",
1798
+ "pending_review",
1799
+ "sent",
1800
+ "failed",
1801
+ "enrolled",
1802
+ "replayed",
1803
+ "resolved"
1804
+ ]
1805
+ },
1806
+ "sourceType": {
1807
+ "type": "string",
1808
+ "minLength": 1
1809
+ },
1810
+ "tokenState": {
1811
+ "type": "string",
1812
+ "enum": [
1813
+ "valid",
1814
+ "expired",
1815
+ "missing_scope",
1816
+ "unknown"
1817
+ ]
1818
+ },
1819
+ "providerHealth": {
1820
+ "type": "string",
1821
+ "enum": [
1822
+ "green",
1823
+ "yellow",
1824
+ "red",
1825
+ "unknown"
1826
+ ]
1827
+ },
1828
+ "repairState": {
1829
+ "type": "string",
1830
+ "minLength": 1
1831
+ },
1832
+ "q": {
1833
+ "type": "string",
1834
+ "minLength": 1,
1835
+ "maxLength": 120
1836
+ },
1837
+ "limit": {
1838
+ "type": "integer",
1839
+ "minimum": 1,
1840
+ "maximum": 100,
1841
+ "default": 50
1842
+ }
1843
+ }
1844
+ }
1845
+ },
1846
+ "GET /api/campaigns/{id}/simulations": {
1847
+ "path": {
1848
+ "type": "object",
1849
+ "properties": {
1850
+ "id": {
1851
+ "type": "string",
1852
+ "format": "uuid"
1853
+ }
1854
+ },
1855
+ "required": [
1856
+ "id"
1857
+ ]
1858
+ }
1859
+ },
1860
+ "POST /api/campaigns/{id}/simulations": {
1861
+ "path": {
1862
+ "type": "object",
1863
+ "properties": {
1864
+ "id": {
1865
+ "type": "string",
1866
+ "format": "uuid"
1867
+ }
1868
+ },
1869
+ "required": [
1870
+ "id"
1871
+ ]
1872
+ },
1873
+ "body": {
1874
+ "type": "object",
1875
+ "properties": {
1876
+ "sourceKind": {
1877
+ "type": "string",
1878
+ "enum": [
1879
+ "fake_input",
1880
+ "seed_case",
1881
+ "replayed_enrollment"
1882
+ ],
1883
+ "default": "fake_input"
1884
+ },
1885
+ "eventType": {
1886
+ "type": "string",
1887
+ "enum": [
1888
+ "instagram_comment",
1889
+ "instagram_dm",
1890
+ "whatsapp_reply",
1891
+ "booking_event",
1892
+ "crm_event",
1893
+ "webhook_event",
1894
+ "csv_import",
1895
+ "manual_enrollment"
1896
+ ],
1897
+ "default": "manual_enrollment"
1898
+ },
1899
+ "startNodeId": {
1900
+ "type": "string",
1901
+ "minLength": 1
1902
+ },
1903
+ "lead": {
1904
+ "type": "object",
1905
+ "additionalProperties": {},
1906
+ "default": {}
1907
+ },
1908
+ "eventPayload": {
1909
+ "type": "object",
1910
+ "additionalProperties": {},
1911
+ "default": {}
1912
+ },
1913
+ "context": {
1914
+ "type": "object",
1915
+ "additionalProperties": {},
1916
+ "default": {}
1917
+ },
1918
+ "replayedEnrollmentId": {
1919
+ "type": "string",
1920
+ "format": "uuid"
1921
+ },
1922
+ "maxSteps": {
1923
+ "type": "integer",
1924
+ "minimum": 1,
1925
+ "maximum": 100,
1926
+ "default": 50
1927
+ }
1928
+ }
1929
+ }
1930
+ },
1931
+ "GET /api/campaigns/{id}/simulations/{simulationId}": {
1932
+ "path": {
1933
+ "type": "object",
1934
+ "properties": {
1935
+ "id": {
1936
+ "type": "string",
1937
+ "format": "uuid"
1938
+ },
1939
+ "simulationId": {
1940
+ "type": "string",
1941
+ "format": "uuid"
1942
+ }
1943
+ },
1944
+ "required": [
1945
+ "id",
1946
+ "simulationId"
1947
+ ]
1948
+ }
1949
+ },
1950
+ "GET /api/broadcasts": {
1951
+ "query": {
1952
+ "type": "object",
1953
+ "properties": {
1954
+ "limit": {
1955
+ "type": "integer",
1956
+ "minimum": 1,
1957
+ "maximum": 100
1958
+ },
1959
+ "cursor": {
1960
+ "type": "string",
1961
+ "minLength": 1
1962
+ },
1963
+ "status": {
1964
+ "type": "string",
1965
+ "enum": [
1966
+ "draft",
1967
+ "previewed",
1968
+ "approved",
1969
+ "running",
1970
+ "paused",
1971
+ "cancelled",
1972
+ "completed",
1973
+ "failed"
1974
+ ]
1975
+ }
1976
+ }
1977
+ }
1978
+ },
1979
+ "GET /api/broadcasts/{id}": {
1980
+ "path": {
1981
+ "type": "object",
1982
+ "properties": {
1983
+ "id": {
1984
+ "type": "string",
1985
+ "format": "uuid"
1986
+ }
1987
+ },
1988
+ "required": [
1989
+ "id"
1990
+ ]
1991
+ }
1992
+ },
1993
+ "POST /api/broadcasts": {
1994
+ "body": {
1995
+ "type": "object",
1996
+ "properties": {
1997
+ "campaignId": {
1998
+ "type": "string",
1999
+ "format": "uuid"
2000
+ },
2001
+ "name": {
2002
+ "type": "string",
2003
+ "minLength": 1
2004
+ },
2005
+ "segment": {
2006
+ "type": "object",
2007
+ "properties": {
2008
+ "mode": {
2009
+ "type": "string",
2010
+ "enum": [
2011
+ "all",
2012
+ "any"
2013
+ ],
2014
+ "default": "all"
2015
+ },
2016
+ "rules": {
2017
+ "type": "array",
2018
+ "items": {
2019
+ "type": "object",
2020
+ "properties": {
2021
+ "field": {
2022
+ "type": "string",
2023
+ "enum": [
2024
+ "channel",
2025
+ "tags",
2026
+ "stage",
2027
+ "score",
2028
+ "sourceCampaignId",
2029
+ "sourceTrigger",
2030
+ "lastMessageAt",
2031
+ "lastReplyAt",
2032
+ "bookingStatus",
2033
+ "crmField",
2034
+ "consent",
2035
+ "timezone",
2036
+ "localTime",
2037
+ "blacklisted"
2038
+ ]
2039
+ },
2040
+ "operator": {
2041
+ "type": "string",
2042
+ "enum": [
2043
+ "equals",
2044
+ "not_equals",
2045
+ "contains",
2046
+ "not_contains",
2047
+ "in",
2048
+ "not_in",
2049
+ "greater_than",
2050
+ "less_than",
2051
+ "before",
2052
+ "after",
2053
+ "exists",
2054
+ "missing"
2055
+ ]
2056
+ },
2057
+ "value": {},
2058
+ "path": {
2059
+ "type": "string",
2060
+ "minLength": 1
2061
+ }
2062
+ },
2063
+ "required": [
2064
+ "field",
2065
+ "operator"
2066
+ ]
2067
+ }
2068
+ },
2069
+ "groups": {
2070
+ "type": "array",
2071
+ "items": {
2072
+ "type": "object",
2073
+ "properties": {
2074
+ "mode": {
2075
+ "type": "string",
2076
+ "enum": [
2077
+ "all",
2078
+ "any"
2079
+ ],
2080
+ "default": "all"
2081
+ },
2082
+ "rules": {
2083
+ "type": "array",
2084
+ "items": {
2085
+ "type": "object",
2086
+ "properties": {
2087
+ "field": {
2088
+ "type": "string",
2089
+ "enum": [
2090
+ "channel",
2091
+ "tags",
2092
+ "stage",
2093
+ "score",
2094
+ "sourceCampaignId",
2095
+ "sourceTrigger",
2096
+ "lastMessageAt",
2097
+ "lastReplyAt",
2098
+ "bookingStatus",
2099
+ "crmField",
2100
+ "consent",
2101
+ "timezone",
2102
+ "localTime",
2103
+ "blacklisted"
2104
+ ]
2105
+ },
2106
+ "operator": {
2107
+ "type": "string",
2108
+ "enum": [
2109
+ "equals",
2110
+ "not_equals",
2111
+ "contains",
2112
+ "not_contains",
2113
+ "in",
2114
+ "not_in",
2115
+ "greater_than",
2116
+ "less_than",
2117
+ "before",
2118
+ "after",
2119
+ "exists",
2120
+ "missing"
2121
+ ]
2122
+ },
2123
+ "value": {},
2124
+ "path": {
2125
+ "type": "string",
2126
+ "minLength": 1
2127
+ }
2128
+ },
2129
+ "required": [
2130
+ "field",
2131
+ "operator"
2132
+ ]
2133
+ },
2134
+ "default": []
2135
+ }
2136
+ }
2137
+ }
2138
+ },
2139
+ "channel": {
2140
+ "type": "string",
2141
+ "minLength": 1
2142
+ },
2143
+ "channels": {
2144
+ "type": "array",
2145
+ "items": {
2146
+ "type": "string",
2147
+ "minLength": 1
2148
+ }
2149
+ },
2150
+ "stage": {
2151
+ "type": "string",
2152
+ "minLength": 1
2153
+ },
2154
+ "stages": {
2155
+ "type": "array",
2156
+ "items": {
2157
+ "type": "string",
2158
+ "minLength": 1
2159
+ }
2160
+ },
2161
+ "tagsAny": {
2162
+ "type": "array",
2163
+ "items": {
2164
+ "type": "string",
2165
+ "minLength": 1
2166
+ }
2167
+ },
2168
+ "tagsAll": {
2169
+ "type": "array",
2170
+ "items": {
2171
+ "type": "string",
2172
+ "minLength": 1
2173
+ }
2174
+ },
2175
+ "minScore": {
2176
+ "type": "integer"
2177
+ },
2178
+ "maxScore": {
2179
+ "type": "integer"
2180
+ },
2181
+ "includeLeadIds": {
2182
+ "type": "array",
2183
+ "items": {
2184
+ "type": "string",
2185
+ "format": "uuid"
2186
+ }
2187
+ },
2188
+ "excludeLeadIds": {
2189
+ "type": "array",
2190
+ "items": {
2191
+ "type": "string",
2192
+ "format": "uuid"
2193
+ }
2194
+ },
2195
+ "limit": {
2196
+ "type": "integer",
2197
+ "minimum": 1,
2198
+ "maximum": 5000
2199
+ }
2200
+ },
2201
+ "default": {}
2202
+ },
2203
+ "personalizationMode": {
2204
+ "type": "string",
2205
+ "enum": [
2206
+ "same_message",
2207
+ "personalized_light",
2208
+ "personalized_ai"
2209
+ ],
2210
+ "default": "personalized_light"
2211
+ },
2212
+ "canarySize": {
2213
+ "type": "integer",
2214
+ "minimum": 0,
2215
+ "maximum": 100,
2216
+ "default": 10
2217
+ },
2218
+ "batchSize": {
2219
+ "type": "integer",
2220
+ "minimum": 1,
2221
+ "maximum": 500,
2222
+ "default": 100
2223
+ }
2224
+ },
2225
+ "required": [
2226
+ "campaignId",
2227
+ "name"
2228
+ ]
2229
+ }
2230
+ },
2231
+ "POST /api/broadcasts/{id}/preview": {
2232
+ "path": {
2233
+ "type": "object",
2234
+ "properties": {
2235
+ "id": {
2236
+ "type": "string",
2237
+ "format": "uuid"
2238
+ }
2239
+ },
2240
+ "required": [
2241
+ "id"
2242
+ ]
2243
+ },
2244
+ "body": {
2245
+ "type": "object",
2246
+ "properties": {
2247
+ "sampleSize": {
2248
+ "type": "integer",
2249
+ "minimum": 1,
2250
+ "maximum": 20,
2251
+ "default": 3
2252
+ }
2253
+ }
2254
+ }
2255
+ },
2256
+ "POST /api/broadcasts/{id}/approve": {
2257
+ "path": {
2258
+ "type": "object",
2259
+ "properties": {
2260
+ "id": {
2261
+ "type": "string",
2262
+ "format": "uuid"
2263
+ }
2264
+ },
2265
+ "required": [
2266
+ "id"
2267
+ ]
2268
+ }
2269
+ },
2270
+ "POST /api/broadcasts/{id}/launch": {
2271
+ "path": {
2272
+ "type": "object",
2273
+ "properties": {
2274
+ "id": {
2275
+ "type": "string",
2276
+ "format": "uuid"
2277
+ }
2278
+ },
2279
+ "required": [
2280
+ "id"
2281
+ ]
2282
+ }
2283
+ },
2284
+ "POST /api/broadcasts/{id}/pause": {
2285
+ "path": {
2286
+ "type": "object",
2287
+ "properties": {
2288
+ "id": {
2289
+ "type": "string",
2290
+ "format": "uuid"
2291
+ }
2292
+ },
2293
+ "required": [
2294
+ "id"
2295
+ ]
2296
+ },
2297
+ "body": {
2298
+ "type": "object",
2299
+ "properties": {
2300
+ "reason": {
2301
+ "type": "string",
2302
+ "minLength": 1
2303
+ }
2304
+ }
2305
+ }
2306
+ },
2307
+ "POST /api/broadcasts/{id}/retry": {
2308
+ "path": {
2309
+ "type": "object",
2310
+ "properties": {
2311
+ "id": {
2312
+ "type": "string",
2313
+ "format": "uuid"
2314
+ }
2315
+ },
2316
+ "required": [
2317
+ "id"
2318
+ ]
2319
+ },
2320
+ "body": {
2321
+ "type": "object",
2322
+ "properties": {
2323
+ "reason": {
2324
+ "type": "string",
2325
+ "minLength": 1
2326
+ },
2327
+ "failedOnly": {
2328
+ "type": "boolean",
2329
+ "default": true
2330
+ }
2331
+ }
2332
+ }
2333
+ },
2334
+ "POST /api/broadcasts/{id}/cancel": {
2335
+ "path": {
2336
+ "type": "object",
2337
+ "properties": {
2338
+ "id": {
2339
+ "type": "string",
2340
+ "format": "uuid"
2341
+ }
2342
+ },
2343
+ "required": [
2344
+ "id"
2345
+ ]
2346
+ },
2347
+ "body": {
2348
+ "type": "object",
2349
+ "properties": {
2350
+ "reason": {
2351
+ "type": "string",
2352
+ "minLength": 1
2353
+ }
2354
+ }
2355
+ }
2356
+ },
2357
+ "GET /api/webhook-subscriptions": {},
2358
+ "POST /api/webhook-subscriptions": {
2359
+ "body": {
2360
+ "type": "object",
2361
+ "properties": {
2362
+ "targetUrl": {
2363
+ "type": "string",
2364
+ "format": "uri"
2365
+ },
2366
+ "eventTypes": {
2367
+ "type": "array",
2368
+ "items": {
2369
+ "type": "string",
2370
+ "enum": [
2371
+ "lead.created",
2372
+ "lead.updated",
2373
+ "lead.qualified",
2374
+ "lead.stage_changed",
2375
+ "message.received",
2376
+ "message.draft_created",
2377
+ "message.sent",
2378
+ "review.created",
2379
+ "review.approved",
2380
+ "review.rejected",
2381
+ "booking.created",
2382
+ "booking.updated",
2383
+ "booking.cancelled",
2384
+ "campaign.enrolled",
2385
+ "campaign.completed",
2386
+ "campaign.failed",
2387
+ "broadcast.started",
2388
+ "broadcast.completed",
2389
+ "broadcast.paused",
2390
+ "broadcast.failed",
2391
+ "crm.sync_failed",
2392
+ "integration.connection_health_changed"
2393
+ ]
2394
+ },
2395
+ "minItems": 1
2396
+ },
2397
+ "workspaceScoped": {
2398
+ "type": "boolean",
2399
+ "default": true
2400
+ },
2401
+ "consumerMetadata": {
2402
+ "type": "object",
2403
+ "additionalProperties": {},
2404
+ "default": {}
2405
+ }
2406
+ },
2407
+ "required": [
2408
+ "targetUrl",
2409
+ "eventTypes"
2410
+ ]
2411
+ }
2412
+ },
2413
+ "PATCH /api/webhook-subscriptions/{id}": {
2414
+ "path": {
2415
+ "type": "object",
2416
+ "properties": {
2417
+ "id": {
2418
+ "type": "string",
2419
+ "format": "uuid"
2420
+ }
2421
+ },
2422
+ "required": [
2423
+ "id"
2424
+ ]
2425
+ },
2426
+ "body": {
2427
+ "type": "object",
2428
+ "properties": {
2429
+ "targetUrl": {
2430
+ "type": "string",
2431
+ "format": "uri"
2432
+ },
2433
+ "eventTypes": {
2434
+ "type": "array",
2435
+ "items": {
2436
+ "type": "string",
2437
+ "enum": [
2438
+ "lead.created",
2439
+ "lead.updated",
2440
+ "lead.qualified",
2441
+ "lead.stage_changed",
2442
+ "message.received",
2443
+ "message.draft_created",
2444
+ "message.sent",
2445
+ "review.created",
2446
+ "review.approved",
2447
+ "review.rejected",
2448
+ "booking.created",
2449
+ "booking.updated",
2450
+ "booking.cancelled",
2451
+ "campaign.enrolled",
2452
+ "campaign.completed",
2453
+ "campaign.failed",
2454
+ "broadcast.started",
2455
+ "broadcast.completed",
2456
+ "broadcast.paused",
2457
+ "broadcast.failed",
2458
+ "crm.sync_failed",
2459
+ "integration.connection_health_changed"
2460
+ ]
2461
+ },
2462
+ "minItems": 1
2463
+ },
2464
+ "status": {
2465
+ "type": "string",
2466
+ "enum": [
2467
+ "active",
2468
+ "paused",
2469
+ "disabled"
2470
+ ]
2471
+ },
2472
+ "consumerMetadata": {
2473
+ "type": "object",
2474
+ "additionalProperties": {}
2475
+ }
2476
+ }
2477
+ }
2478
+ },
2479
+ "POST /api/webhook-subscriptions/test-delivery": {
2480
+ "body": {
2481
+ "type": "object",
2482
+ "properties": {
2483
+ "type": {
2484
+ "type": "string",
2485
+ "enum": [
2486
+ "lead.created",
2487
+ "lead.updated",
2488
+ "lead.qualified",
2489
+ "lead.stage_changed",
2490
+ "message.received",
2491
+ "message.draft_created",
2492
+ "message.sent",
2493
+ "review.created",
2494
+ "review.approved",
2495
+ "review.rejected",
2496
+ "booking.created",
2497
+ "booking.updated",
2498
+ "booking.cancelled",
2499
+ "campaign.enrolled",
2500
+ "campaign.completed",
2501
+ "campaign.failed",
2502
+ "broadcast.started",
2503
+ "broadcast.completed",
2504
+ "broadcast.paused",
2505
+ "broadcast.failed",
2506
+ "crm.sync_failed",
2507
+ "integration.connection_health_changed"
2508
+ ],
2509
+ "default": "lead.created"
2510
+ },
2511
+ "data": {
2512
+ "type": "object",
2513
+ "additionalProperties": {},
2514
+ "default": {}
2515
+ }
2516
+ }
2517
+ }
2518
+ },
2519
+ "GET /api/webhook-subscriptions/deliveries": {
2520
+ "query": {
2521
+ "type": "object",
2522
+ "properties": {
2523
+ "limit": {
2524
+ "type": "integer",
2525
+ "minimum": 1,
2526
+ "maximum": 100
2527
+ }
2528
+ }
2529
+ }
2530
+ },
2531
+ "GET /api/webhook-subscriptions/signature-guide": {},
2532
+ "POST /api/webhook-subscriptions/deliveries/{deliveryId}/replay": {
2533
+ "path": {
2534
+ "type": "object",
2535
+ "properties": {
2536
+ "deliveryId": {
2537
+ "type": "string",
2538
+ "format": "uuid"
2539
+ }
2540
+ },
2541
+ "required": [
2542
+ "deliveryId"
2543
+ ]
2544
+ }
2545
+ },
2546
+ "POST /api/webhook-subscriptions/events/{eventId}/replay": {
2547
+ "path": {
2548
+ "type": "object",
2549
+ "properties": {
2550
+ "eventId": {
2551
+ "type": "string",
2552
+ "minLength": 1
2553
+ }
2554
+ },
2555
+ "required": [
2556
+ "eventId"
2557
+ ]
2558
+ },
2559
+ "body": {
2560
+ "type": "object",
2561
+ "properties": {
2562
+ "subscriptionId": {
2563
+ "type": "string",
2564
+ "format": "uuid"
2565
+ }
2566
+ }
2567
+ }
2568
+ },
2569
+ "POST /api/webhook-subscriptions/events/replay": {
2570
+ "body": {
2571
+ "type": "object",
2572
+ "properties": {
2573
+ "eventTypes": {
2574
+ "type": "array",
2575
+ "items": {
2576
+ "type": "string",
2577
+ "enum": [
2578
+ "lead.created",
2579
+ "lead.updated",
2580
+ "lead.qualified",
2581
+ "lead.stage_changed",
2582
+ "message.received",
2583
+ "message.draft_created",
2584
+ "message.sent",
2585
+ "review.created",
2586
+ "review.approved",
2587
+ "review.rejected",
2588
+ "booking.created",
2589
+ "booking.updated",
2590
+ "booking.cancelled",
2591
+ "campaign.enrolled",
2592
+ "campaign.completed",
2593
+ "campaign.failed",
2594
+ "broadcast.started",
2595
+ "broadcast.completed",
2596
+ "broadcast.paused",
2597
+ "broadcast.failed",
2598
+ "crm.sync_failed",
2599
+ "integration.connection_health_changed"
2600
+ ]
2601
+ },
2602
+ "minItems": 1
2603
+ },
2604
+ "from": {
2605
+ "type": "string",
2606
+ "format": "date-time"
2607
+ },
2608
+ "to": {
2609
+ "type": "string",
2610
+ "format": "date-time"
2611
+ },
2612
+ "limit": {
2613
+ "type": "integer",
2614
+ "minimum": 1,
2615
+ "maximum": 100,
2616
+ "default": 100
2617
+ }
2618
+ }
2619
+ }
2620
+ },
2621
+ "GET /api/integrations/connectors": {},
2622
+ "GET /api/integrations/crm/providers/{provider}/oauth-url": {
2623
+ "path": {
2624
+ "type": "object",
2625
+ "properties": {
2626
+ "provider": {
2627
+ "type": "string",
2628
+ "enum": [
2629
+ "gohighlevel",
2630
+ "hubspot",
2631
+ "activecampaign",
2632
+ "salesforce",
2633
+ "pipedrive"
2634
+ ]
2635
+ }
2636
+ },
2637
+ "required": [
2638
+ "provider"
2639
+ ]
2640
+ },
2641
+ "query": {
2642
+ "type": "object",
2643
+ "properties": {
2644
+ "redirectUri": {
2645
+ "type": "string",
2646
+ "format": "uri"
2647
+ },
2648
+ "locationId": {
2649
+ "type": "string",
2650
+ "minLength": 1
2651
+ }
2652
+ }
2653
+ }
2654
+ },
2655
+ "POST /api/integrations/crm/oauth/callback": {
2656
+ "body": {
2657
+ "type": "object",
2658
+ "properties": {
2659
+ "provider": {
2660
+ "type": "string",
2661
+ "enum": [
2662
+ "gohighlevel",
2663
+ "hubspot",
2664
+ "activecampaign",
2665
+ "salesforce",
2666
+ "pipedrive"
2667
+ ]
2668
+ },
2669
+ "code": {
2670
+ "type": "string",
2671
+ "minLength": 1
2672
+ },
2673
+ "state": {
2674
+ "type": "string",
2675
+ "minLength": 1
2676
+ },
2677
+ "redirectUri": {
2678
+ "type": "string",
2679
+ "format": "uri"
2680
+ }
2681
+ },
2682
+ "required": [
2683
+ "provider",
2684
+ "code",
2685
+ "state"
2686
+ ]
2687
+ }
2688
+ },
2689
+ "GET /api/integrations/crm/connections": {},
2690
+ "POST /api/integrations/crm/connections": {
2691
+ "body": {
2692
+ "type": "object",
2693
+ "properties": {
2694
+ "provider": {
2695
+ "type": "string",
2696
+ "enum": [
2697
+ "gohighlevel",
2698
+ "hubspot",
2699
+ "activecampaign",
2700
+ "salesforce",
2701
+ "pipedrive"
2702
+ ]
2703
+ },
2704
+ "credentialsRef": {
2705
+ "type": "string",
2706
+ "pattern": "^v1\\.[A-Za-z0-9+/]{16}\\.[A-Za-z0-9+/]{22,}={0,2}$"
2707
+ },
2708
+ "settings": {
2709
+ "type": "object",
2710
+ "additionalProperties": {},
2711
+ "default": {}
2712
+ }
2713
+ },
2714
+ "required": [
2715
+ "provider",
2716
+ "credentialsRef"
2717
+ ]
2718
+ }
2719
+ },
2720
+ "GET /api/integrations/crm/connections/{id}/schema": {
2721
+ "path": {
2722
+ "type": "object",
2723
+ "properties": {
2724
+ "id": {
2725
+ "type": "string",
2726
+ "format": "uuid"
2727
+ }
2728
+ },
2729
+ "required": [
2730
+ "id"
2731
+ ]
2732
+ }
2733
+ },
2734
+ "POST /api/integrations/crm/connections/{id}/health": {
2735
+ "path": {
2736
+ "type": "object",
2737
+ "properties": {
2738
+ "id": {
2739
+ "type": "string",
2740
+ "format": "uuid"
2741
+ }
2742
+ },
2743
+ "required": [
2744
+ "id"
2745
+ ]
2746
+ }
2747
+ },
2748
+ "POST /api/integrations/crm/connections/{id}/webhooks/setup": {
2749
+ "path": {
2750
+ "type": "object",
2751
+ "properties": {
2752
+ "id": {
2753
+ "type": "string",
2754
+ "format": "uuid"
2755
+ }
2756
+ },
2757
+ "required": [
2758
+ "id"
2759
+ ]
2760
+ },
2761
+ "body": {
2762
+ "type": "object",
2763
+ "properties": {
2764
+ "enabled": {
2765
+ "type": "boolean",
2766
+ "default": true
2767
+ },
2768
+ "targetUrl": {
2769
+ "type": "string",
2770
+ "format": "uri"
2771
+ }
2772
+ }
2773
+ }
2774
+ },
2775
+ "POST /api/integrations/crm/connections/{id}/mappings/suggest": {
2776
+ "path": {
2777
+ "type": "object",
2778
+ "properties": {
2779
+ "id": {
2780
+ "type": "string",
2781
+ "format": "uuid"
2782
+ }
2783
+ },
2784
+ "required": [
2785
+ "id"
2786
+ ]
2787
+ }
2788
+ },
2789
+ "PUT /api/integrations/crm/connections/{id}/mappings": {
2790
+ "path": {
2791
+ "type": "object",
2792
+ "properties": {
2793
+ "id": {
2794
+ "type": "string",
2795
+ "format": "uuid"
2796
+ }
2797
+ },
2798
+ "required": [
2799
+ "id"
2800
+ ]
2801
+ },
2802
+ "body": {
2803
+ "type": "object",
2804
+ "properties": {
2805
+ "mappings": {
2806
+ "type": "array",
2807
+ "items": {
2808
+ "type": "object",
2809
+ "properties": {
2810
+ "lucaField": {
2811
+ "type": "string",
2812
+ "minLength": 1
2813
+ },
2814
+ "providerField": {
2815
+ "type": "string",
2816
+ "minLength": 1
2817
+ },
2818
+ "direction": {
2819
+ "type": "string",
2820
+ "enum": [
2821
+ "luca_to_crm",
2822
+ "crm_to_luca",
2823
+ "bidirectional"
2824
+ ]
2825
+ },
2826
+ "transform": {
2827
+ "type": "object",
2828
+ "additionalProperties": {},
2829
+ "default": {}
2830
+ },
2831
+ "dangerous": {
2832
+ "type": "boolean",
2833
+ "default": false
2834
+ }
2835
+ },
2836
+ "required": [
2837
+ "lucaField",
2838
+ "providerField",
2839
+ "direction"
2840
+ ]
2841
+ }
2842
+ }
2843
+ },
2844
+ "required": [
2845
+ "mappings"
2846
+ ]
2847
+ }
2848
+ },
2849
+ "GET /api/integrations/crm/connections/{id}/sync-runs": {
2850
+ "path": {
2851
+ "type": "object",
2852
+ "properties": {
2853
+ "id": {
2854
+ "type": "string",
2855
+ "format": "uuid"
2856
+ }
2857
+ },
2858
+ "required": [
2859
+ "id"
2860
+ ]
2861
+ }
2862
+ },
2863
+ "POST /api/integrations/crm/connections/{id}/sync-runs": {
2864
+ "path": {
2865
+ "type": "object",
2866
+ "properties": {
2867
+ "id": {
2868
+ "type": "string",
2869
+ "format": "uuid"
2870
+ }
2871
+ },
2872
+ "required": [
2873
+ "id"
2874
+ ]
2875
+ },
2876
+ "body": {
2877
+ "type": "object",
2878
+ "properties": {
2879
+ "mode": {
2880
+ "type": "string",
2881
+ "enum": [
2882
+ "dry_run",
2883
+ "live"
2884
+ ],
2885
+ "default": "dry_run"
2886
+ },
2887
+ "direction": {
2888
+ "type": "string",
2889
+ "enum": [
2890
+ "luca_to_crm",
2891
+ "crm_to_luca",
2892
+ "bidirectional"
2893
+ ],
2894
+ "default": "bidirectional"
2895
+ }
2896
+ }
2897
+ }
2898
+ },
2899
+ "GET /api/integrations/events": {
2900
+ "query": {
2901
+ "type": "object",
2902
+ "properties": {
2903
+ "limit": {
2904
+ "type": "integer",
2905
+ "minimum": 1,
2906
+ "maximum": 100
2907
+ },
2908
+ "cursor": {
2909
+ "type": "string",
2910
+ "minLength": 1
2911
+ },
2912
+ "source": {
2913
+ "type": "string",
2914
+ "enum": [
2915
+ "webhook",
2916
+ "zapier",
2917
+ "make",
2918
+ "crm",
2919
+ "api"
2920
+ ]
2921
+ }
2922
+ }
2923
+ }
2924
+ },
2925
+ "GET /api/voice/profile": {}
2926
+ };