@novu/api 0.6.0 → 0.6.2

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.
Files changed (67) hide show
  1. package/README.md +29 -4
  2. package/bin/mcp-server.js +328 -91
  3. package/bin/mcp-server.js.map +15 -11
  4. package/docs/sdks/subscribers/README.md +113 -0
  5. package/funcs/subscribersSearch.js +1 -0
  6. package/funcs/subscribersSearch.js.map +1 -1
  7. package/funcs/subscribersUpsert.d.ts +18 -0
  8. package/funcs/subscribersUpsert.d.ts.map +1 -0
  9. package/funcs/subscribersUpsert.js +148 -0
  10. package/funcs/subscribersUpsert.js.map +1 -0
  11. package/hooks/types.d.ts +1 -1
  12. package/hooks/types.d.ts.map +1 -1
  13. package/jsr.json +1 -1
  14. package/lib/config.d.ts +3 -3
  15. package/lib/config.js +3 -3
  16. package/mcp-server/mcp-server.js +1 -1
  17. package/mcp-server/server.d.ts.map +1 -1
  18. package/mcp-server/server.js +3 -1
  19. package/mcp-server/server.js.map +1 -1
  20. package/mcp-server/tools/subscribersUpsert.d.ts +11 -0
  21. package/mcp-server/tools/subscribersUpsert.d.ts.map +1 -0
  22. package/mcp-server/tools/subscribersUpsert.js +57 -0
  23. package/mcp-server/tools/subscribersUpsert.js.map +1 -0
  24. package/models/components/index.d.ts +1 -0
  25. package/models/components/index.d.ts.map +1 -1
  26. package/models/components/index.js +1 -0
  27. package/models/components/index.js.map +1 -1
  28. package/models/components/updatesubscriberrequestdto.d.ts +72 -0
  29. package/models/components/updatesubscriberrequestdto.d.ts.map +1 -0
  30. package/models/components/updatesubscriberrequestdto.js +74 -0
  31. package/models/components/updatesubscriberrequestdto.js.map +1 -0
  32. package/models/components/workflowinfodto.d.ts +5 -0
  33. package/models/components/workflowinfodto.d.ts.map +1 -1
  34. package/models/components/workflowinfodto.js +2 -0
  35. package/models/components/workflowinfodto.js.map +1 -1
  36. package/models/operations/index.d.ts +1 -0
  37. package/models/operations/index.d.ts.map +1 -1
  38. package/models/operations/index.js +1 -0
  39. package/models/operations/index.js.map +1 -1
  40. package/models/operations/subscriberscontrollersearchsubscribers.d.ts +26 -6
  41. package/models/operations/subscriberscontrollersearchsubscribers.d.ts.map +1 -1
  42. package/models/operations/subscriberscontrollersearchsubscribers.js +11 -6
  43. package/models/operations/subscriberscontrollersearchsubscribers.js.map +1 -1
  44. package/models/operations/subscribersv1controllerupdatesubscriber.d.ts +68 -0
  45. package/models/operations/subscribersv1controllerupdatesubscriber.d.ts.map +1 -0
  46. package/models/operations/subscribersv1controllerupdatesubscriber.js +114 -0
  47. package/models/operations/subscribersv1controllerupdatesubscriber.js.map +1 -0
  48. package/package.json +2 -2
  49. package/sdk/subscribers.d.ts +7 -0
  50. package/sdk/subscribers.d.ts.map +1 -1
  51. package/sdk/subscribers.js +10 -0
  52. package/sdk/subscribers.js.map +1 -1
  53. package/sources/json-development.json +687 -117
  54. package/src/funcs/subscribersSearch.ts +1 -0
  55. package/src/funcs/subscribersUpsert.ts +240 -0
  56. package/src/hooks/types.ts +1 -1
  57. package/src/lib/config.ts +3 -3
  58. package/src/mcp-server/mcp-server.ts +1 -1
  59. package/src/mcp-server/server.ts +3 -1
  60. package/src/mcp-server/tools/subscribersUpsert.ts +43 -0
  61. package/src/models/components/index.ts +1 -0
  62. package/src/models/components/updatesubscriberrequestdto.ts +124 -0
  63. package/src/models/components/workflowinfodto.ts +7 -0
  64. package/src/models/operations/index.ts +1 -0
  65. package/src/models/operations/subscriberscontrollersearchsubscribers.ts +34 -12
  66. package/src/models/operations/subscribersv1controllerupdatesubscriber.ts +191 -0
  67. package/src/sdk/subscribers.ts +22 -0
@@ -26,66 +26,80 @@
26
26
  }
27
27
  },
28
28
  {
29
- "name": "email",
29
+ "name": "limit",
30
30
  "required": false,
31
31
  "in": "query",
32
- "description": "Email address of the subscriber to filter results.",
32
+ "description": "Limit the number of items to return",
33
33
  "schema": {
34
- "type": "string"
34
+ "type": "number"
35
35
  }
36
36
  },
37
37
  {
38
- "name": "name",
38
+ "name": "orderDirection",
39
39
  "required": false,
40
40
  "in": "query",
41
- "description": "Name of the subscriber to filter results.",
41
+ "description": "Direction of sorting",
42
42
  "schema": {
43
+ "enum": [
44
+ "ASC",
45
+ "DESC"
46
+ ],
43
47
  "type": "string"
44
48
  }
45
49
  },
46
50
  {
47
- "name": "phone",
51
+ "name": "orderBy",
48
52
  "required": false,
49
53
  "in": "query",
50
- "description": "Phone number of the subscriber to filter results.",
54
+ "description": "Field to order by",
51
55
  "schema": {
52
56
  "type": "string"
53
57
  }
54
58
  },
55
59
  {
56
- "name": "subscriberId",
60
+ "name": "includeCursor",
57
61
  "required": false,
58
62
  "in": "query",
59
- "description": "Unique identifier of the subscriber to filter results.",
63
+ "description": "Include cursor item in response",
64
+ "schema": {
65
+ "type": "boolean"
66
+ }
67
+ },
68
+ {
69
+ "name": "email",
70
+ "required": false,
71
+ "in": "query",
72
+ "description": "Email address of the subscriber to filter results.",
60
73
  "schema": {
61
74
  "type": "string"
62
75
  }
63
76
  },
64
77
  {
65
- "name": "limit",
78
+ "name": "name",
66
79
  "required": false,
67
80
  "in": "query",
81
+ "description": "Name of the subscriber to filter results.",
68
82
  "schema": {
69
- "type": "number"
83
+ "type": "string"
70
84
  }
71
85
  },
72
86
  {
73
- "name": "orderDirection",
87
+ "name": "phone",
74
88
  "required": false,
75
89
  "in": "query",
90
+ "description": "Phone number of the subscriber to filter results.",
76
91
  "schema": {
77
- "enum": [
78
- "ASC",
79
- "DESC"
80
- ],
81
92
  "type": "string"
82
93
  }
83
94
  },
84
95
  {
85
- "name": "orderBy",
96
+ "name": "subscriberId",
86
97
  "required": false,
87
98
  "in": "query",
88
- "schema": {}
99
+ "description": "Unique identifier of the subscriber to filter results.",
100
+ "schema": {
101
+ "type": "string"
102
+ }
89
103
  },
90
104
  {
91
105
  "name": "idempotency-key",
@@ -10428,21 +10442,503 @@
10428
10442
  "schema": {
10429
10443
  "type": "string"
10430
10444
  }
10431
- },
10445
+ },
10446
+ {
10447
+ "name": "after",
10448
+ "required": false,
10449
+ "in": "query",
10450
+ "description": "Date filter for records after this timestamp. Defaults to earliest date allowed by subscription plan",
10451
+ "schema": {
10452
+ "type": "string"
10453
+ }
10454
+ },
10455
+ {
10456
+ "name": "before",
10457
+ "required": false,
10458
+ "in": "query",
10459
+ "description": "Date filter for records before this timestamp. Defaults to current time of request (now)",
10460
+ "schema": {
10461
+ "type": "string"
10462
+ }
10463
+ },
10464
+ {
10465
+ "name": "idempotency-key",
10466
+ "in": "header",
10467
+ "description": "A header for idempotency purposes",
10468
+ "required": false,
10469
+ "schema": {
10470
+ "type": "string"
10471
+ }
10472
+ }
10473
+ ],
10474
+ "responses": {
10475
+ "200": {
10476
+ "headers": {
10477
+ "Content-Type": {
10478
+ "$ref": "#/components/headers/Content-Type"
10479
+ },
10480
+ "RateLimit-Limit": {
10481
+ "$ref": "#/components/headers/RateLimit-Limit"
10482
+ },
10483
+ "RateLimit-Remaining": {
10484
+ "$ref": "#/components/headers/RateLimit-Remaining"
10485
+ },
10486
+ "RateLimit-Reset": {
10487
+ "$ref": "#/components/headers/RateLimit-Reset"
10488
+ },
10489
+ "RateLimit-Policy": {
10490
+ "$ref": "#/components/headers/RateLimit-Policy"
10491
+ },
10492
+ "Idempotency-Key": {
10493
+ "$ref": "#/components/headers/Idempotency-Key"
10494
+ },
10495
+ "Idempotency-Replay": {
10496
+ "$ref": "#/components/headers/Idempotency-Replay"
10497
+ }
10498
+ },
10499
+ "description": "",
10500
+ "content": {
10501
+ "application/json": {
10502
+ "schema": {
10503
+ "$ref": "#/components/schemas/ActivitiesResponseDto"
10504
+ }
10505
+ }
10506
+ }
10507
+ },
10508
+ "400": {
10509
+ "description": "Bad Request",
10510
+ "headers": {
10511
+ "Content-Type": {
10512
+ "$ref": "#/components/headers/Content-Type"
10513
+ },
10514
+ "RateLimit-Limit": {
10515
+ "$ref": "#/components/headers/RateLimit-Limit"
10516
+ },
10517
+ "RateLimit-Remaining": {
10518
+ "$ref": "#/components/headers/RateLimit-Remaining"
10519
+ },
10520
+ "RateLimit-Reset": {
10521
+ "$ref": "#/components/headers/RateLimit-Reset"
10522
+ },
10523
+ "RateLimit-Policy": {
10524
+ "$ref": "#/components/headers/RateLimit-Policy"
10525
+ },
10526
+ "Idempotency-Key": {
10527
+ "$ref": "#/components/headers/Idempotency-Key"
10528
+ },
10529
+ "Idempotency-Replay": {
10530
+ "$ref": "#/components/headers/Idempotency-Replay"
10531
+ }
10532
+ },
10533
+ "content": {
10534
+ "application/json": {
10535
+ "schema": {
10536
+ "$ref": "#/components/schemas/ErrorDto"
10537
+ }
10538
+ }
10539
+ }
10540
+ },
10541
+ "401": {
10542
+ "description": "Unauthorized",
10543
+ "headers": {
10544
+ "Content-Type": {
10545
+ "$ref": "#/components/headers/Content-Type"
10546
+ },
10547
+ "RateLimit-Limit": {
10548
+ "$ref": "#/components/headers/RateLimit-Limit"
10549
+ },
10550
+ "RateLimit-Remaining": {
10551
+ "$ref": "#/components/headers/RateLimit-Remaining"
10552
+ },
10553
+ "RateLimit-Reset": {
10554
+ "$ref": "#/components/headers/RateLimit-Reset"
10555
+ },
10556
+ "RateLimit-Policy": {
10557
+ "$ref": "#/components/headers/RateLimit-Policy"
10558
+ },
10559
+ "Idempotency-Key": {
10560
+ "$ref": "#/components/headers/Idempotency-Key"
10561
+ },
10562
+ "Idempotency-Replay": {
10563
+ "$ref": "#/components/headers/Idempotency-Replay"
10564
+ }
10565
+ },
10566
+ "content": {
10567
+ "application/json": {
10568
+ "schema": {
10569
+ "$ref": "#/components/schemas/ErrorDto"
10570
+ }
10571
+ }
10572
+ }
10573
+ },
10574
+ "403": {
10575
+ "description": "Forbidden",
10576
+ "headers": {
10577
+ "Content-Type": {
10578
+ "$ref": "#/components/headers/Content-Type"
10579
+ },
10580
+ "RateLimit-Limit": {
10581
+ "$ref": "#/components/headers/RateLimit-Limit"
10582
+ },
10583
+ "RateLimit-Remaining": {
10584
+ "$ref": "#/components/headers/RateLimit-Remaining"
10585
+ },
10586
+ "RateLimit-Reset": {
10587
+ "$ref": "#/components/headers/RateLimit-Reset"
10588
+ },
10589
+ "RateLimit-Policy": {
10590
+ "$ref": "#/components/headers/RateLimit-Policy"
10591
+ },
10592
+ "Idempotency-Key": {
10593
+ "$ref": "#/components/headers/Idempotency-Key"
10594
+ },
10595
+ "Idempotency-Replay": {
10596
+ "$ref": "#/components/headers/Idempotency-Replay"
10597
+ }
10598
+ },
10599
+ "content": {
10600
+ "application/json": {
10601
+ "schema": {
10602
+ "$ref": "#/components/schemas/ErrorDto"
10603
+ }
10604
+ }
10605
+ }
10606
+ },
10607
+ "404": {
10608
+ "description": "Not Found",
10609
+ "headers": {
10610
+ "Content-Type": {
10611
+ "$ref": "#/components/headers/Content-Type"
10612
+ },
10613
+ "RateLimit-Limit": {
10614
+ "$ref": "#/components/headers/RateLimit-Limit"
10615
+ },
10616
+ "RateLimit-Remaining": {
10617
+ "$ref": "#/components/headers/RateLimit-Remaining"
10618
+ },
10619
+ "RateLimit-Reset": {
10620
+ "$ref": "#/components/headers/RateLimit-Reset"
10621
+ },
10622
+ "RateLimit-Policy": {
10623
+ "$ref": "#/components/headers/RateLimit-Policy"
10624
+ },
10625
+ "Idempotency-Key": {
10626
+ "$ref": "#/components/headers/Idempotency-Key"
10627
+ },
10628
+ "Idempotency-Replay": {
10629
+ "$ref": "#/components/headers/Idempotency-Replay"
10630
+ }
10631
+ },
10632
+ "content": {
10633
+ "application/json": {
10634
+ "schema": {
10635
+ "$ref": "#/components/schemas/ErrorDto"
10636
+ }
10637
+ }
10638
+ }
10639
+ },
10640
+ "405": {
10641
+ "description": "Method Not Allowed",
10642
+ "headers": {
10643
+ "Content-Type": {
10644
+ "$ref": "#/components/headers/Content-Type"
10645
+ },
10646
+ "RateLimit-Limit": {
10647
+ "$ref": "#/components/headers/RateLimit-Limit"
10648
+ },
10649
+ "RateLimit-Remaining": {
10650
+ "$ref": "#/components/headers/RateLimit-Remaining"
10651
+ },
10652
+ "RateLimit-Reset": {
10653
+ "$ref": "#/components/headers/RateLimit-Reset"
10654
+ },
10655
+ "RateLimit-Policy": {
10656
+ "$ref": "#/components/headers/RateLimit-Policy"
10657
+ },
10658
+ "Idempotency-Key": {
10659
+ "$ref": "#/components/headers/Idempotency-Key"
10660
+ },
10661
+ "Idempotency-Replay": {
10662
+ "$ref": "#/components/headers/Idempotency-Replay"
10663
+ }
10664
+ },
10665
+ "content": {
10666
+ "application/json": {
10667
+ "schema": {
10668
+ "$ref": "#/components/schemas/ErrorDto"
10669
+ }
10670
+ }
10671
+ }
10672
+ },
10673
+ "409": {
10674
+ "description": "Conflict",
10675
+ "headers": {
10676
+ "Content-Type": {
10677
+ "$ref": "#/components/headers/Content-Type"
10678
+ },
10679
+ "RateLimit-Limit": {
10680
+ "$ref": "#/components/headers/RateLimit-Limit"
10681
+ },
10682
+ "RateLimit-Remaining": {
10683
+ "$ref": "#/components/headers/RateLimit-Remaining"
10684
+ },
10685
+ "RateLimit-Reset": {
10686
+ "$ref": "#/components/headers/RateLimit-Reset"
10687
+ },
10688
+ "RateLimit-Policy": {
10689
+ "$ref": "#/components/headers/RateLimit-Policy"
10690
+ },
10691
+ "Idempotency-Key": {
10692
+ "$ref": "#/components/headers/Idempotency-Key"
10693
+ },
10694
+ "Idempotency-Replay": {
10695
+ "$ref": "#/components/headers/Idempotency-Replay"
10696
+ }
10697
+ },
10698
+ "content": {
10699
+ "application/json": {
10700
+ "schema": {
10701
+ "$ref": "#/components/schemas/ErrorDto"
10702
+ }
10703
+ }
10704
+ }
10705
+ },
10706
+ "413": {
10707
+ "description": "Payload Too Large",
10708
+ "headers": {
10709
+ "Content-Type": {
10710
+ "$ref": "#/components/headers/Content-Type"
10711
+ },
10712
+ "RateLimit-Limit": {
10713
+ "$ref": "#/components/headers/RateLimit-Limit"
10714
+ },
10715
+ "RateLimit-Remaining": {
10716
+ "$ref": "#/components/headers/RateLimit-Remaining"
10717
+ },
10718
+ "RateLimit-Reset": {
10719
+ "$ref": "#/components/headers/RateLimit-Reset"
10720
+ },
10721
+ "RateLimit-Policy": {
10722
+ "$ref": "#/components/headers/RateLimit-Policy"
10723
+ },
10724
+ "Idempotency-Key": {
10725
+ "$ref": "#/components/headers/Idempotency-Key"
10726
+ },
10727
+ "Idempotency-Replay": {
10728
+ "$ref": "#/components/headers/Idempotency-Replay"
10729
+ }
10730
+ },
10731
+ "content": {
10732
+ "application/json": {
10733
+ "schema": {
10734
+ "$ref": "#/components/schemas/ErrorDto"
10735
+ }
10736
+ }
10737
+ }
10738
+ },
10739
+ "414": {
10740
+ "description": "URI Too Long",
10741
+ "content": {
10742
+ "application/json": {
10743
+ "schema": {
10744
+ "$ref": "#/components/schemas/ErrorDto"
10745
+ }
10746
+ }
10747
+ }
10748
+ },
10749
+ "415": {
10750
+ "description": "Unsupported Media Type",
10751
+ "headers": {
10752
+ "Content-Type": {
10753
+ "$ref": "#/components/headers/Content-Type"
10754
+ },
10755
+ "RateLimit-Limit": {
10756
+ "$ref": "#/components/headers/RateLimit-Limit"
10757
+ },
10758
+ "RateLimit-Remaining": {
10759
+ "$ref": "#/components/headers/RateLimit-Remaining"
10760
+ },
10761
+ "RateLimit-Reset": {
10762
+ "$ref": "#/components/headers/RateLimit-Reset"
10763
+ },
10764
+ "RateLimit-Policy": {
10765
+ "$ref": "#/components/headers/RateLimit-Policy"
10766
+ },
10767
+ "Idempotency-Key": {
10768
+ "$ref": "#/components/headers/Idempotency-Key"
10769
+ },
10770
+ "Idempotency-Replay": {
10771
+ "$ref": "#/components/headers/Idempotency-Replay"
10772
+ }
10773
+ },
10774
+ "content": {
10775
+ "application/json": {
10776
+ "schema": {
10777
+ "$ref": "#/components/schemas/ErrorDto"
10778
+ }
10779
+ }
10780
+ }
10781
+ },
10782
+ "422": {
10783
+ "description": "Unprocessable Entity",
10784
+ "headers": {
10785
+ "Content-Type": {
10786
+ "$ref": "#/components/headers/Content-Type"
10787
+ },
10788
+ "RateLimit-Limit": {
10789
+ "$ref": "#/components/headers/RateLimit-Limit"
10790
+ },
10791
+ "RateLimit-Remaining": {
10792
+ "$ref": "#/components/headers/RateLimit-Remaining"
10793
+ },
10794
+ "RateLimit-Reset": {
10795
+ "$ref": "#/components/headers/RateLimit-Reset"
10796
+ },
10797
+ "RateLimit-Policy": {
10798
+ "$ref": "#/components/headers/RateLimit-Policy"
10799
+ },
10800
+ "Idempotency-Key": {
10801
+ "$ref": "#/components/headers/Idempotency-Key"
10802
+ },
10803
+ "Idempotency-Replay": {
10804
+ "$ref": "#/components/headers/Idempotency-Replay"
10805
+ }
10806
+ },
10807
+ "content": {
10808
+ "application/json": {
10809
+ "schema": {
10810
+ "$ref": "#/components/schemas/ValidationErrorDto"
10811
+ }
10812
+ }
10813
+ }
10814
+ },
10815
+ "429": {
10816
+ "description": "The client has sent too many requests in a given amount of time. ",
10817
+ "headers": {
10818
+ "Content-Type": {
10819
+ "$ref": "#/components/headers/Content-Type"
10820
+ },
10821
+ "RateLimit-Limit": {
10822
+ "$ref": "#/components/headers/RateLimit-Limit"
10823
+ },
10824
+ "RateLimit-Remaining": {
10825
+ "$ref": "#/components/headers/RateLimit-Remaining"
10826
+ },
10827
+ "RateLimit-Reset": {
10828
+ "$ref": "#/components/headers/RateLimit-Reset"
10829
+ },
10830
+ "RateLimit-Policy": {
10831
+ "$ref": "#/components/headers/RateLimit-Policy"
10832
+ },
10833
+ "Idempotency-Key": {
10834
+ "$ref": "#/components/headers/Idempotency-Key"
10835
+ },
10836
+ "Idempotency-Replay": {
10837
+ "$ref": "#/components/headers/Idempotency-Replay"
10838
+ },
10839
+ "Retry-After": {
10840
+ "$ref": "#/components/headers/Retry-After"
10841
+ }
10842
+ },
10843
+ "content": {
10844
+ "application/json": {
10845
+ "schema": {
10846
+ "type": "string",
10847
+ "example": "API rate limit exceeded"
10848
+ }
10849
+ }
10850
+ }
10851
+ },
10852
+ "500": {
10853
+ "description": "Internal Server Error",
10854
+ "headers": {
10855
+ "Content-Type": {
10856
+ "$ref": "#/components/headers/Content-Type"
10857
+ },
10858
+ "RateLimit-Limit": {
10859
+ "$ref": "#/components/headers/RateLimit-Limit"
10860
+ },
10861
+ "RateLimit-Remaining": {
10862
+ "$ref": "#/components/headers/RateLimit-Remaining"
10863
+ },
10864
+ "RateLimit-Reset": {
10865
+ "$ref": "#/components/headers/RateLimit-Reset"
10866
+ },
10867
+ "RateLimit-Policy": {
10868
+ "$ref": "#/components/headers/RateLimit-Policy"
10869
+ },
10870
+ "Idempotency-Key": {
10871
+ "$ref": "#/components/headers/Idempotency-Key"
10872
+ },
10873
+ "Idempotency-Replay": {
10874
+ "$ref": "#/components/headers/Idempotency-Replay"
10875
+ }
10876
+ },
10877
+ "content": {
10878
+ "application/json": {
10879
+ "schema": {
10880
+ "$ref": "#/components/schemas/ErrorDto"
10881
+ }
10882
+ }
10883
+ }
10884
+ },
10885
+ "503": {
10886
+ "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.",
10887
+ "headers": {
10888
+ "Content-Type": {
10889
+ "$ref": "#/components/headers/Content-Type"
10890
+ },
10891
+ "RateLimit-Limit": {
10892
+ "$ref": "#/components/headers/RateLimit-Limit"
10893
+ },
10894
+ "RateLimit-Remaining": {
10895
+ "$ref": "#/components/headers/RateLimit-Remaining"
10896
+ },
10897
+ "RateLimit-Reset": {
10898
+ "$ref": "#/components/headers/RateLimit-Reset"
10899
+ },
10900
+ "RateLimit-Policy": {
10901
+ "$ref": "#/components/headers/RateLimit-Policy"
10902
+ },
10903
+ "Idempotency-Key": {
10904
+ "$ref": "#/components/headers/Idempotency-Key"
10905
+ },
10906
+ "Idempotency-Replay": {
10907
+ "$ref": "#/components/headers/Idempotency-Replay"
10908
+ },
10909
+ "Retry-After": {
10910
+ "$ref": "#/components/headers/Retry-After"
10911
+ }
10912
+ },
10913
+ "content": {
10914
+ "application/json": {
10915
+ "schema": {
10916
+ "type": "string",
10917
+ "example": "Please wait some time, then try again."
10918
+ }
10919
+ }
10920
+ }
10921
+ }
10922
+ },
10923
+ "tags": [
10924
+ "Notifications"
10925
+ ],
10926
+ "security": [
10432
10927
  {
10433
- "name": "after",
10434
- "required": false,
10435
- "in": "query",
10436
- "description": "Date filter for records after this timestamp. Defaults to earliest date allowed by subscription plan",
10437
- "schema": {
10438
- "type": "string"
10439
- }
10440
- },
10928
+ "secretKey": []
10929
+ }
10930
+ ]
10931
+ }
10932
+ },
10933
+ "/v1/notifications/{notificationId}": {
10934
+ "get": {
10935
+ "operationId": "NotificationsController_getNotification",
10936
+ "summary": "Get notification",
10937
+ "parameters": [
10441
10938
  {
10442
- "name": "before",
10443
- "required": false,
10444
- "in": "query",
10445
- "description": "Date filter for records before this timestamp. Defaults to current time of request (now)",
10939
+ "name": "notificationId",
10940
+ "required": true,
10941
+ "in": "path",
10446
10942
  "schema": {
10447
10943
  "type": "string"
10448
10944
  }
@@ -10459,6 +10955,7 @@
10459
10955
  ],
10460
10956
  "responses": {
10461
10957
  "200": {
10958
+ "description": "OK",
10462
10959
  "headers": {
10463
10960
  "Content-Type": {
10464
10961
  "$ref": "#/components/headers/Content-Type"
@@ -10482,11 +10979,10 @@
10482
10979
  "$ref": "#/components/headers/Idempotency-Replay"
10483
10980
  }
10484
10981
  },
10485
- "description": "",
10486
10982
  "content": {
10487
10983
  "application/json": {
10488
10984
  "schema": {
10489
- "$ref": "#/components/schemas/ActivitiesResponseDto"
10985
+ "$ref": "#/components/schemas/ActivityNotificationResponseDto"
10490
10986
  }
10491
10987
  }
10492
10988
  }
@@ -10916,17 +11412,19 @@
10916
11412
  ]
10917
11413
  }
10918
11414
  },
10919
- "/v1/notifications/{notificationId}": {
11415
+ "/v1/notifications/graph/stats": {
10920
11416
  "get": {
10921
- "operationId": "NotificationsController_getNotification",
10922
- "summary": "Get notification",
11417
+ "operationId": "NotificationsController_getActivityGraphStats",
11418
+ "x-speakeasy-name-override": "graph",
11419
+ "x-speakeasy-group": "Notifications.Stats",
11420
+ "summary": "Get notification graph statistics",
10923
11421
  "parameters": [
10924
11422
  {
10925
- "name": "notificationId",
10926
- "required": true,
10927
- "in": "path",
11423
+ "name": "days",
11424
+ "required": false,
11425
+ "in": "query",
10928
11426
  "schema": {
10929
- "type": "string"
11427
+ "type": "number"
10930
11428
  }
10931
11429
  },
10932
11430
  {
@@ -10968,7 +11466,10 @@
10968
11466
  "content": {
10969
11467
  "application/json": {
10970
11468
  "schema": {
10971
- "$ref": "#/components/schemas/ActivityNotificationResponseDto"
11469
+ "type": "array",
11470
+ "items": {
11471
+ "$ref": "#/components/schemas/ActivityGraphStatesResponse"
11472
+ }
10972
11473
  }
10973
11474
  }
10974
11475
  }
@@ -11398,21 +11899,12 @@
11398
11899
  ]
11399
11900
  }
11400
11901
  },
11401
- "/v1/notifications/graph/stats": {
11902
+ "/v1/notifications/stats": {
11402
11903
  "get": {
11403
- "operationId": "NotificationsController_getActivityGraphStats",
11404
- "x-speakeasy-name-override": "graph",
11904
+ "operationId": "NotificationsController_getActivityStats",
11405
11905
  "x-speakeasy-group": "Notifications.Stats",
11406
- "summary": "Get notification graph statistics",
11906
+ "summary": "Get notification statistics",
11407
11907
  "parameters": [
11408
- {
11409
- "name": "days",
11410
- "required": false,
11411
- "in": "query",
11412
- "schema": {
11413
- "type": "number"
11414
- }
11415
- },
11416
11908
  {
11417
11909
  "name": "idempotency-key",
11418
11910
  "in": "header",
@@ -11452,10 +11944,7 @@
11452
11944
  "content": {
11453
11945
  "application/json": {
11454
11946
  "schema": {
11455
- "type": "array",
11456
- "items": {
11457
- "$ref": "#/components/schemas/ActivityGraphStatesResponse"
11458
- }
11947
+ "$ref": "#/components/schemas/ActivityStatsResponseDto"
11459
11948
  }
11460
11949
  }
11461
11950
  }
@@ -11885,12 +12374,48 @@
11885
12374
  ]
11886
12375
  }
11887
12376
  },
11888
- "/v1/notifications/stats": {
12377
+ "/v1/subscribers": {
11889
12378
  "get": {
11890
- "operationId": "NotificationsController_getActivityStats",
11891
- "x-speakeasy-group": "Notifications.Stats",
11892
- "summary": "Get notification statistics",
12379
+ "operationId": "SubscribersV1Controller_listSubscribers",
12380
+ "x-speakeasy-pagination": {
12381
+ "type": "offsetLimit",
12382
+ "inputs": [
12383
+ {
12384
+ "name": "page",
12385
+ "in": "parameters",
12386
+ "type": "page"
12387
+ },
12388
+ {
12389
+ "name": "limit",
12390
+ "in": "parameters",
12391
+ "type": "limit"
12392
+ }
12393
+ ],
12394
+ "outputs": {
12395
+ "results": "$.data.resultArray"
12396
+ }
12397
+ },
12398
+ "summary": "Get subscribers",
12399
+ "description": "Returns a list of subscribers, could paginated using the `page` and `limit` query parameter",
11893
12400
  "parameters": [
12401
+ {
12402
+ "name": "page",
12403
+ "required": false,
12404
+ "in": "query",
12405
+ "schema": {
12406
+ "type": "number"
12407
+ }
12408
+ },
12409
+ {
12410
+ "name": "limit",
12411
+ "required": false,
12412
+ "in": "query",
12413
+ "schema": {
12414
+ "maximum": 100,
12415
+ "default": 10,
12416
+ "type": "number"
12417
+ }
12418
+ },
11894
12419
  {
11895
12420
  "name": "idempotency-key",
11896
12421
  "in": "header",
@@ -11903,7 +12428,6 @@
11903
12428
  ],
11904
12429
  "responses": {
11905
12430
  "200": {
11906
- "description": "OK",
11907
12431
  "headers": {
11908
12432
  "Content-Type": {
11909
12433
  "$ref": "#/components/headers/Content-Type"
@@ -11927,10 +12451,25 @@
11927
12451
  "$ref": "#/components/headers/Idempotency-Replay"
11928
12452
  }
11929
12453
  },
12454
+ "description": "",
11930
12455
  "content": {
11931
12456
  "application/json": {
11932
12457
  "schema": {
11933
- "$ref": "#/components/schemas/ActivityStatsResponseDto"
12458
+ "allOf": [
12459
+ {
12460
+ "$ref": "#/components/schemas/PaginatedResponseDto"
12461
+ },
12462
+ {
12463
+ "properties": {
12464
+ "data": {
12465
+ "type": "array",
12466
+ "items": {
12467
+ "$ref": "#/components/schemas/SubscriberResponseDto"
12468
+ }
12469
+ }
12470
+ }
12471
+ }
12472
+ ]
11934
12473
  }
11935
12474
  }
11936
12475
  }
@@ -12351,7 +12890,7 @@
12351
12890
  }
12352
12891
  },
12353
12892
  "tags": [
12354
- "Notifications"
12893
+ "Subscribers"
12355
12894
  ],
12356
12895
  "security": [
12357
12896
  {
@@ -12360,46 +12899,19 @@
12360
12899
  ]
12361
12900
  }
12362
12901
  },
12363
- "/v1/subscribers": {
12364
- "get": {
12365
- "operationId": "SubscribersV1Controller_listSubscribers",
12366
- "x-speakeasy-pagination": {
12367
- "type": "offsetLimit",
12368
- "inputs": [
12369
- {
12370
- "name": "page",
12371
- "in": "parameters",
12372
- "type": "page"
12373
- },
12374
- {
12375
- "name": "limit",
12376
- "in": "parameters",
12377
- "type": "limit"
12378
- }
12379
- ],
12380
- "outputs": {
12381
- "results": "$.data.resultArray"
12382
- }
12383
- },
12384
- "summary": "Get subscribers",
12385
- "description": "Returns a list of subscribers, could paginated using the `page` and `limit` query parameter",
12902
+ "/v1/subscribers/{subscriberId}": {
12903
+ "put": {
12904
+ "operationId": "SubscribersV1Controller_updateSubscriber",
12905
+ "x-speakeasy-name-override": "upsert",
12906
+ "summary": "Upsert subscriber",
12907
+ "description": "Used to upsert the subscriber entity with new information",
12386
12908
  "parameters": [
12387
12909
  {
12388
- "name": "page",
12389
- "required": false,
12390
- "in": "query",
12391
- "schema": {
12392
- "type": "number"
12393
- }
12394
- },
12395
- {
12396
- "name": "limit",
12397
- "required": false,
12398
- "in": "query",
12910
+ "name": "subscriberId",
12911
+ "required": true,
12912
+ "in": "path",
12399
12913
  "schema": {
12400
- "maximum": 100,
12401
- "default": 10,
12402
- "type": "number"
12914
+ "type": "string"
12403
12915
  }
12404
12916
  },
12405
12917
  {
@@ -12412,8 +12924,19 @@
12412
12924
  }
12413
12925
  }
12414
12926
  ],
12927
+ "requestBody": {
12928
+ "required": true,
12929
+ "content": {
12930
+ "application/json": {
12931
+ "schema": {
12932
+ "$ref": "#/components/schemas/UpdateSubscriberRequestDto"
12933
+ }
12934
+ }
12935
+ }
12936
+ },
12415
12937
  "responses": {
12416
12938
  "200": {
12939
+ "description": "OK",
12417
12940
  "headers": {
12418
12941
  "Content-Type": {
12419
12942
  "$ref": "#/components/headers/Content-Type"
@@ -12437,25 +12960,10 @@
12437
12960
  "$ref": "#/components/headers/Idempotency-Replay"
12438
12961
  }
12439
12962
  },
12440
- "description": "",
12441
12963
  "content": {
12442
12964
  "application/json": {
12443
12965
  "schema": {
12444
- "allOf": [
12445
- {
12446
- "$ref": "#/components/schemas/PaginatedResponseDto"
12447
- },
12448
- {
12449
- "properties": {
12450
- "data": {
12451
- "type": "array",
12452
- "items": {
12453
- "$ref": "#/components/schemas/SubscriberResponseDto"
12454
- }
12455
- }
12456
- }
12457
- }
12458
- ]
12966
+ "$ref": "#/components/schemas/SubscriberResponseDto"
12459
12967
  }
12460
12968
  }
12461
12969
  }
@@ -25148,6 +25656,7 @@
25148
25656
  "properties": {
25149
25657
  "subscriberId": {
25150
25658
  "type": "string",
25659
+ "pattern": "VALID_ID_REGEX",
25151
25660
  "description": "Unique identifier of the subscriber"
25152
25661
  },
25153
25662
  "firstName": {
@@ -25211,6 +25720,63 @@
25211
25720
  "subscribers"
25212
25721
  ]
25213
25722
  },
25723
+ "UpdateSubscriberRequestDto": {
25724
+ "type": "object",
25725
+ "properties": {
25726
+ "email": {
25727
+ "type": "string",
25728
+ "description": "The email address of the subscriber.",
25729
+ "example": "john.doe@example.com"
25730
+ },
25731
+ "firstName": {
25732
+ "type": "string",
25733
+ "description": "The first name of the subscriber.",
25734
+ "example": "John"
25735
+ },
25736
+ "lastName": {
25737
+ "type": "string",
25738
+ "description": "The last name of the subscriber.",
25739
+ "example": "Doe"
25740
+ },
25741
+ "phone": {
25742
+ "type": "string",
25743
+ "description": "The phone number of the subscriber.",
25744
+ "example": "+1234567890"
25745
+ },
25746
+ "avatar": {
25747
+ "type": "string",
25748
+ "description": "The avatar URL of the subscriber.",
25749
+ "example": "https://example.com/avatar.jpg"
25750
+ },
25751
+ "locale": {
25752
+ "type": "string",
25753
+ "description": "The locale of the subscriber, for example \"en-US\".",
25754
+ "example": "en-US"
25755
+ },
25756
+ "data": {
25757
+ "type": "object",
25758
+ "description": "Custom data associated with the subscriber. Can contain any additional properties.",
25759
+ "additionalProperties": true,
25760
+ "example": {
25761
+ "preferences": {
25762
+ "notifications": true,
25763
+ "theme": "dark"
25764
+ },
25765
+ "tags": [
25766
+ "premium",
25767
+ "newsletter"
25768
+ ]
25769
+ }
25770
+ },
25771
+ "channels": {
25772
+ "description": "An array of communication channels for the subscriber.",
25773
+ "type": "array",
25774
+ "items": {
25775
+ "$ref": "#/components/schemas/SubscriberChannelDto"
25776
+ }
25777
+ }
25778
+ }
25779
+ },
25214
25780
  "UpdateSubscriberChannelRequestDto": {
25215
25781
  "type": "object",
25216
25782
  "properties": {
@@ -26688,6 +27254,10 @@
26688
27254
  "name": {
26689
27255
  "type": "string",
26690
27256
  "description": "Display name of the workflow"
27257
+ },
27258
+ "updatedAt": {
27259
+ "type": "string",
27260
+ "description": "last updated date"
26691
27261
  }
26692
27262
  },
26693
27263
  "required": [