@sentdm/sentdm 0.35.0 → 0.37.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.
Files changed (108) hide show
  1. package/CHANGELOG.md +18 -0
  2. package/client.d.mts +14 -14
  3. package/client.d.mts.map +1 -1
  4. package/client.d.ts +14 -14
  5. package/client.d.ts.map +1 -1
  6. package/client.js.map +1 -1
  7. package/client.mjs.map +1 -1
  8. package/package.json +1 -1
  9. package/resources/contacts.d.mts +85 -589
  10. package/resources/contacts.d.mts.map +1 -1
  11. package/resources/contacts.d.ts +85 -589
  12. package/resources/contacts.d.ts.map +1 -1
  13. package/resources/contacts.js +4 -4
  14. package/resources/contacts.js.map +1 -1
  15. package/resources/contacts.mjs +4 -4
  16. package/resources/contacts.mjs.map +1 -1
  17. package/resources/conversations.d.mts +69 -328
  18. package/resources/conversations.d.mts.map +1 -1
  19. package/resources/conversations.d.ts +69 -328
  20. package/resources/conversations.d.ts.map +1 -1
  21. package/resources/conversations.js +10 -8
  22. package/resources/conversations.js.map +1 -1
  23. package/resources/conversations.mjs +10 -8
  24. package/resources/conversations.mjs.map +1 -1
  25. package/resources/index.d.mts +7 -7
  26. package/resources/index.d.mts.map +1 -1
  27. package/resources/index.d.ts +7 -7
  28. package/resources/index.d.ts.map +1 -1
  29. package/resources/index.js.map +1 -1
  30. package/resources/index.mjs.map +1 -1
  31. package/resources/me.d.mts +81 -129
  32. package/resources/me.d.mts.map +1 -1
  33. package/resources/me.d.ts +81 -129
  34. package/resources/me.d.ts.map +1 -1
  35. package/resources/me.js +11 -0
  36. package/resources/me.js.map +1 -1
  37. package/resources/me.mjs +11 -0
  38. package/resources/me.mjs.map +1 -1
  39. package/resources/messages.d.mts +8 -171
  40. package/resources/messages.d.mts.map +1 -1
  41. package/resources/messages.d.ts +8 -171
  42. package/resources/messages.d.ts.map +1 -1
  43. package/resources/messages.js.map +1 -1
  44. package/resources/messages.mjs.map +1 -1
  45. package/resources/numbers.d.mts +3 -42
  46. package/resources/numbers.d.mts.map +1 -1
  47. package/resources/numbers.d.ts +3 -42
  48. package/resources/numbers.d.ts.map +1 -1
  49. package/resources/numbers.js.map +1 -1
  50. package/resources/numbers.mjs.map +1 -1
  51. package/resources/profiles/campaigns.d.mts +149 -544
  52. package/resources/profiles/campaigns.d.mts.map +1 -1
  53. package/resources/profiles/campaigns.d.ts +149 -544
  54. package/resources/profiles/campaigns.d.ts.map +1 -1
  55. package/resources/profiles/index.d.mts +2 -2
  56. package/resources/profiles/index.d.mts.map +1 -1
  57. package/resources/profiles/index.d.ts +2 -2
  58. package/resources/profiles/index.d.ts.map +1 -1
  59. package/resources/profiles/index.js.map +1 -1
  60. package/resources/profiles/index.mjs.map +1 -1
  61. package/resources/profiles/profiles.d.mts +411 -1821
  62. package/resources/profiles/profiles.d.mts.map +1 -1
  63. package/resources/profiles/profiles.d.ts +411 -1821
  64. package/resources/profiles/profiles.d.ts.map +1 -1
  65. package/resources/profiles/profiles.js.map +1 -1
  66. package/resources/profiles/profiles.mjs.map +1 -1
  67. package/resources/templates.d.mts +84 -486
  68. package/resources/templates.d.mts.map +1 -1
  69. package/resources/templates.d.ts +84 -486
  70. package/resources/templates.d.ts.map +1 -1
  71. package/resources/templates.js +3 -3
  72. package/resources/templates.js.map +1 -1
  73. package/resources/templates.mjs +3 -3
  74. package/resources/templates.mjs.map +1 -1
  75. package/resources/users.d.mts +47 -437
  76. package/resources/users.d.mts.map +1 -1
  77. package/resources/users.d.ts +47 -437
  78. package/resources/users.d.ts.map +1 -1
  79. package/resources/users.js +3 -3
  80. package/resources/users.js.map +1 -1
  81. package/resources/users.mjs +3 -3
  82. package/resources/users.mjs.map +1 -1
  83. package/resources/webhooks.d.mts +189 -768
  84. package/resources/webhooks.d.mts.map +1 -1
  85. package/resources/webhooks.d.ts +189 -768
  86. package/resources/webhooks.d.ts.map +1 -1
  87. package/resources/webhooks.js +7 -6
  88. package/resources/webhooks.js.map +1 -1
  89. package/resources/webhooks.mjs +7 -6
  90. package/resources/webhooks.mjs.map +1 -1
  91. package/src/client.ts +52 -39
  92. package/src/resources/contacts.ts +88 -678
  93. package/src/resources/conversations.ts +77 -393
  94. package/src/resources/index.ts +26 -20
  95. package/src/resources/me.ts +94 -148
  96. package/src/resources/messages.ts +8 -194
  97. package/src/resources/numbers.ts +3 -47
  98. package/src/resources/profiles/campaigns.ts +174 -673
  99. package/src/resources/profiles/index.ts +14 -6
  100. package/src/resources/profiles/profiles.ts +529 -2216
  101. package/src/resources/templates.ts +100 -572
  102. package/src/resources/users.ts +48 -505
  103. package/src/resources/webhooks.ts +297 -996
  104. package/src/version.ts +1 -1
  105. package/version.d.mts +1 -1
  106. package/version.d.ts +1 -1
  107. package/version.js +1 -1
  108. package/version.mjs +1 -1
@@ -20,10 +20,10 @@ export class Webhooks extends APIResource {
20
20
  *
21
21
  * @example
22
22
  * ```ts
23
- * const webhook = await client.webhooks.create();
23
+ * const apiResponseWebhook = await client.webhooks.create();
24
24
  * ```
25
25
  */
26
- create(params: WebhookCreateParams, options?: RequestOptions): APIPromise<WebhookCreateResponse> {
26
+ create(params: WebhookCreateParams, options?: RequestOptions): APIPromise<APIResponseWebhook> {
27
27
  const { 'Idempotency-Key': idempotencyKey, 'x-profile-id': xProfileID, ...body } = params;
28
28
  return this._client.post('/v3/webhooks', {
29
29
  body,
@@ -43,7 +43,7 @@ export class Webhooks extends APIResource {
43
43
  *
44
44
  * @example
45
45
  * ```ts
46
- * const webhook = await client.webhooks.retrieve(
46
+ * const apiResponseWebhook = await client.webhooks.retrieve(
47
47
  * 'd4f5a6b7-c8d9-4e0f-a1b2-c3d4e5f6a7b8',
48
48
  * );
49
49
  * ```
@@ -52,7 +52,7 @@ export class Webhooks extends APIResource {
52
52
  id: string,
53
53
  params: WebhookRetrieveParams | null | undefined = {},
54
54
  options?: RequestOptions,
55
- ): APIPromise<WebhookRetrieveResponse> {
55
+ ): APIPromise<APIResponseWebhook> {
56
56
  const { 'x-profile-id': xProfileID } = params ?? {};
57
57
  return this._client.get(path`/v3/webhooks/${id}`, {
58
58
  ...options,
@@ -68,16 +68,12 @@ export class Webhooks extends APIResource {
68
68
  *
69
69
  * @example
70
70
  * ```ts
71
- * const webhook = await client.webhooks.update(
71
+ * const apiResponseWebhook = await client.webhooks.update(
72
72
  * 'd4f5a6b7-c8d9-4e0f-a1b2-c3d4e5f6a7b8',
73
73
  * );
74
74
  * ```
75
75
  */
76
- update(
77
- id: string,
78
- params: WebhookUpdateParams,
79
- options?: RequestOptions,
80
- ): APIPromise<WebhookUpdateResponse> {
76
+ update(id: string, params: WebhookUpdateParams, options?: RequestOptions): APIPromise<APIResponseWebhook> {
81
77
  const { 'Idempotency-Key': idempotencyKey, 'x-profile-id': xProfileID, ...body } = params;
82
78
  return this._client.put(path`/v3/webhooks/${id}`, {
83
79
  body,
@@ -249,16 +245,17 @@ export class Webhooks extends APIResource {
249
245
  *
250
246
  * @example
251
247
  * ```ts
252
- * const response = await client.webhooks.toggleStatus(
253
- * 'd4f5a6b7-c8d9-4e0f-a1b2-c3d4e5f6a7b8',
254
- * );
248
+ * const apiResponseWebhook =
249
+ * await client.webhooks.toggleStatus(
250
+ * 'd4f5a6b7-c8d9-4e0f-a1b2-c3d4e5f6a7b8',
251
+ * );
255
252
  * ```
256
253
  */
257
254
  toggleStatus(
258
255
  id: string,
259
256
  params: WebhookToggleStatusParams,
260
257
  options?: RequestOptions,
261
- ): APIPromise<WebhookToggleStatusResponse> {
258
+ ): APIPromise<APIResponseWebhook> {
262
259
  const { 'Idempotency-Key': idempotencyKey, 'x-profile-id': xProfileID, ...body } = params;
263
260
  return this._client.patch(path`/v3/webhooks/${id}/toggle-status`, {
264
261
  body,
@@ -274,6 +271,76 @@ export class Webhooks extends APIResource {
274
271
  }
275
272
  }
276
273
 
274
+ /**
275
+ * Request and response metadata
276
+ */
277
+ export interface APIMeta {
278
+ /**
279
+ * Unique identifier for this request (for tracing and support)
280
+ */
281
+ request_id?: string;
282
+
283
+ /**
284
+ * Server timestamp when the response was generated
285
+ */
286
+ timestamp?: string;
287
+
288
+ /**
289
+ * API version used for this request
290
+ */
291
+ version?: string;
292
+ }
293
+
294
+ /**
295
+ * Standard API response envelope for all v3 endpoints
296
+ */
297
+ export interface APIResponseWebhook {
298
+ /**
299
+ * The response data (null if error)
300
+ */
301
+ data?: WebhookResponse | null;
302
+
303
+ /**
304
+ * Error information
305
+ */
306
+ error?: ErrorDetail | null;
307
+
308
+ /**
309
+ * Request and response metadata
310
+ */
311
+ meta?: APIMeta;
312
+
313
+ /**
314
+ * Indicates whether the request was successful
315
+ */
316
+ success?: boolean;
317
+ }
318
+
319
+ /**
320
+ * Error information
321
+ */
322
+ export interface ErrorDetail {
323
+ /**
324
+ * Machine-readable error code (e.g., "RESOURCE_001")
325
+ */
326
+ code?: string;
327
+
328
+ /**
329
+ * Additional validation error details (field-level errors)
330
+ */
331
+ details?: { [key: string]: Array<string> } | null;
332
+
333
+ /**
334
+ * URL to documentation about this error
335
+ */
336
+ doc_url?: string | null;
337
+
338
+ /**
339
+ * Human-readable error message
340
+ */
341
+ message?: string;
342
+ }
343
+
277
344
  /**
278
345
  * The envelope Sent POSTs to a subscribed webhook endpoint. Every event shares
279
346
  * this shape and varies only in Payload.
@@ -311,6 +378,16 @@ export interface InboundMessageEvent {
311
378
  * numbers.
312
379
  */
313
380
  export interface InboundMessageEventPayload {
381
+ /**
382
+ * The contact's number in E.164 format, meaning the number the message came from.
383
+ */
384
+ inbound_number: string;
385
+
386
+ /**
387
+ * When the message was received, in UTC (yyyy-MM-ddTHH:mm:ssZ).
388
+ */
389
+ received_at: string;
390
+
314
391
  /**
315
392
  * The account the message belongs to.
316
393
  */
@@ -321,11 +398,6 @@ export interface InboundMessageEventPayload {
321
398
  */
322
399
  channel?: string;
323
400
 
324
- /**
325
- * The contact's number in E.164 format, meaning the number the message came from.
326
- */
327
- inbound_number?: string;
328
-
329
401
  /**
330
402
  * The inbound message.
331
403
  */
@@ -336,11 +408,6 @@ export interface InboundMessageEventPayload {
336
408
  */
337
409
  outbound_number?: string;
338
410
 
339
- /**
340
- * When the message was received, in UTC (yyyy-MM-ddTHH:mm:ssZ).
341
- */
342
- received_at?: string;
343
-
344
411
  /**
345
412
  * The message body. Sent as null when the inbound message carried no text, for
346
413
  * example a media-only message. The field is always present, so read it and check
@@ -394,6 +461,13 @@ export interface MessageEvent {
394
461
  * status.
395
462
  */
396
463
  export interface MessageEventPayload {
464
+ /**
465
+ * The status the message just reached, for example SENT, DELIVERED, or FAILED.
466
+ * Sent means dispatched and delivered means confirmed, so treat them as distinct
467
+ * outcomes.
468
+ */
469
+ message_status: string;
470
+
397
471
  /**
398
472
  * The account the message belongs to.
399
473
  */
@@ -416,13 +490,6 @@ export interface MessageEventPayload {
416
490
  */
417
491
  message_id?: string;
418
492
 
419
- /**
420
- * The status the message just reached, for example SENT, DELIVERED, or FAILED.
421
- * Sent means dispatched and delivered means confirmed, so treat them as distinct
422
- * outcomes.
423
- */
424
- message_status?: string;
425
-
426
493
  /**
427
494
  * The recipient's number in E.164 format.
428
495
  */
@@ -445,6 +512,66 @@ export interface MessageEventPayload {
445
512
  updated_at?: string;
446
513
  }
447
514
 
515
+ export interface MutationRequest {
516
+ /**
517
+ * Sandbox flag - when true, the operation is simulated without side effects Useful
518
+ * for testing integrations without actual execution
519
+ */
520
+ sandbox?: boolean;
521
+ }
522
+
523
+ /**
524
+ * Pagination metadata for list responses
525
+ */
526
+ export interface PaginationMeta {
527
+ /**
528
+ * @deprecated Cursor-based pagination. Never populated — see Cursors.
529
+ */
530
+ cursors?: PaginationMeta.Cursors | null;
531
+
532
+ /**
533
+ * Whether there are more pages after this one
534
+ */
535
+ has_more?: boolean;
536
+
537
+ /**
538
+ * Current page number (1-indexed)
539
+ */
540
+ page?: number;
541
+
542
+ /**
543
+ * Number of items per page
544
+ */
545
+ page_size?: number;
546
+
547
+ /**
548
+ * Total number of items across all pages
549
+ */
550
+ total_count?: number;
551
+
552
+ /**
553
+ * Total number of pages
554
+ */
555
+ total_pages?: number;
556
+ }
557
+
558
+ export namespace PaginationMeta {
559
+ /**
560
+ * @deprecated Cursor-based pagination. Never populated — see Cursors.
561
+ */
562
+ export interface Cursors {
563
+ /**
564
+ * Cursor to fetch the next page.
565
+ */
566
+ after?: string | null;
567
+
568
+ /**
569
+ * Cursor to fetch the previous page.
570
+ */
571
+ before?: string | null;
572
+ }
573
+ }
574
+
448
575
  /**
449
576
  * The envelope Sent POSTs to a subscribed webhook endpoint. Every event shares
450
577
  * this shape and varies only in Payload.
@@ -482,6 +609,17 @@ export interface TemplateEvent {
482
609
  * changes, so you can react without polling.
483
610
  */
484
611
  export interface TemplateEventPayload {
612
+ /**
613
+ * The review status the template just reached, for example APPROVED or REJECTED.
614
+ */
615
+ status: string;
616
+
617
+ /**
618
+ * The template's identifier with Meta, assigned when the template is submitted for
619
+ * review.
620
+ */
621
+ whatsapp_template_id: string;
622
+
485
623
  /**
486
624
  * The account the template belongs to.
487
625
  */
@@ -508,11 +646,6 @@ export interface TemplateEventPayload {
508
646
  */
509
647
  reason?: string | null;
510
648
 
511
- /**
512
- * The review status the template just reached, for example APPROVED or REJECTED.
513
- */
514
- status?: string;
515
-
516
649
  /**
517
650
  * The template in Sent.
518
651
  */
@@ -522,32 +655,76 @@ export interface TemplateEventPayload {
522
655
  * The template's display name.
523
656
  */
524
657
  template_name?: string;
658
+ }
659
+
660
+ export interface WebhookEventType {
661
+ description?: string | null;
662
+
663
+ display_name?: string;
664
+
665
+ event_type?: string | null;
666
+
667
+ is_active?: boolean;
668
+
669
+ name?: string;
670
+
671
+ sub_types?: Array<WebhookEventType> | null;
672
+ }
673
+
674
+ export interface WebhookResponse {
675
+ id?: string;
676
+
677
+ consecutive_failures?: number;
678
+
679
+ created_at?: string;
525
680
 
526
681
  /**
527
- * The template's identifier with Meta, assigned when the template is submitted for
528
- * review.
682
+ * Which customer owns this — the key's own, or the profile named in x-profile-id.
683
+ * Says whose resource this is, which the resource's own id does not.
529
684
  */
530
- whatsapp_template_id?: string;
685
+ customer_id?: string;
686
+
687
+ display_name?: string;
688
+
689
+ endpoint_url?: string;
690
+
691
+ event_filters?: { [key: string]: Array<string> } | null;
692
+
693
+ event_types?: Array<string>;
694
+
695
+ is_active?: boolean;
696
+
697
+ last_delivery_attempt_at?: string | null;
698
+
699
+ last_successful_delivery_at?: string | null;
700
+
701
+ retry_count?: number;
702
+
703
+ signing_secret?: string | null;
704
+
705
+ timeout_seconds?: number;
706
+
707
+ updated_at?: string | null;
531
708
  }
532
709
 
533
710
  /**
534
711
  * Standard API response envelope for all v3 endpoints
535
712
  */
536
- export interface WebhookCreateResponse {
713
+ export interface WebhookListResponse {
537
714
  /**
538
- * The response data (null if error)
715
+ * A paginated list of webhooks.
539
716
  */
540
- data?: WebhookCreateResponse.Data | null;
717
+ data?: WebhookListResponse.Data | null;
541
718
 
542
719
  /**
543
720
  * Error information
544
721
  */
545
- error?: WebhookCreateResponse.Error | null;
722
+ error?: ErrorDetail | null;
546
723
 
547
724
  /**
548
725
  * Request and response metadata
549
726
  */
550
- meta?: WebhookCreateResponse.Meta;
727
+ meta?: APIMeta;
551
728
 
552
729
  /**
553
730
  * Indicates whether the request was successful
@@ -555,110 +732,83 @@ export interface WebhookCreateResponse {
555
732
  success?: boolean;
556
733
  }
557
734
 
558
- export namespace WebhookCreateResponse {
735
+ export namespace WebhookListResponse {
559
736
  /**
560
- * The response data (null if error)
737
+ * A paginated list of webhooks.
561
738
  */
562
739
  export interface Data {
563
- id?: string;
564
-
565
- consecutive_failures?: number;
566
-
567
- created_at?: string;
568
-
569
740
  /**
570
- * Which customer owns this — the key's own, or the profile named in x-profile-id.
571
- * Says whose resource this is, which the resource's own id does not.
741
+ * Pagination metadata for list responses
572
742
  */
573
- customer_id?: string;
574
-
575
- display_name?: string;
576
-
577
- endpoint_url?: string;
743
+ pagination?: WebhooksAPI.PaginationMeta;
578
744
 
579
- event_filters?: { [key: string]: Array<string> } | null;
580
-
581
- event_types?: Array<string>;
582
-
583
- is_active?: boolean;
584
-
585
- last_delivery_attempt_at?: string | null;
586
-
587
- last_successful_delivery_at?: string | null;
588
-
589
- retry_count?: number;
590
-
591
- signing_secret?: string | null;
592
-
593
- timeout_seconds?: number;
594
-
595
- updated_at?: string | null;
745
+ /**
746
+ * The webhooks on this page.
747
+ */
748
+ webhooks?: Array<WebhooksAPI.WebhookResponse>;
596
749
  }
750
+ }
751
+
752
+ /**
753
+ * Standard API response envelope for all v3 endpoints
754
+ */
755
+ export interface WebhookListEventTypesResponse {
756
+ /**
757
+ * The webhook event types a customer can subscribe to.
758
+ */
759
+ data?: WebhookListEventTypesResponse.Data | null;
597
760
 
598
761
  /**
599
762
  * Error information
600
763
  */
601
- export interface Error {
602
- /**
603
- * Machine-readable error code (e.g., "RESOURCE_001")
604
- */
605
- code?: string;
606
-
607
- /**
608
- * Additional validation error details (field-level errors)
609
- */
610
- details?: { [key: string]: Array<string> } | null;
611
-
612
- /**
613
- * URL to documentation about this error
614
- */
615
- doc_url?: string | null;
616
-
617
- /**
618
- * Human-readable error message
619
- */
620
- message?: string;
621
- }
764
+ error?: ErrorDetail | null;
622
765
 
623
766
  /**
624
767
  * Request and response metadata
625
768
  */
626
- export interface Meta {
627
- /**
628
- * Unique identifier for this request (for tracing and support)
629
- */
630
- request_id?: string;
769
+ meta?: APIMeta;
770
+
771
+ /**
772
+ * Indicates whether the request was successful
773
+ */
774
+ success?: boolean;
775
+ }
631
776
 
777
+ export namespace WebhookListEventTypesResponse {
778
+ /**
779
+ * The webhook event types a customer can subscribe to.
780
+ */
781
+ export interface Data {
632
782
  /**
633
- * Server timestamp when the response was generated
783
+ * The event_types on this page.
634
784
  */
635
- timestamp?: string;
785
+ event_types?: Array<WebhooksAPI.WebhookEventType>;
636
786
 
637
787
  /**
638
- * API version used for this request
788
+ * Pagination metadata for list responses
639
789
  */
640
- version?: string;
790
+ pagination?: WebhooksAPI.PaginationMeta;
641
791
  }
642
792
  }
643
793
 
644
794
  /**
645
795
  * Standard API response envelope for all v3 endpoints
646
796
  */
647
- export interface WebhookRetrieveResponse {
797
+ export interface WebhookListEventsResponse {
648
798
  /**
649
- * The response data (null if error)
799
+ * A paginated list of webhook delivery records.
650
800
  */
651
- data?: WebhookRetrieveResponse.Data | null;
801
+ data?: WebhookListEventsResponse.Data | null;
652
802
 
653
803
  /**
654
804
  * Error information
655
805
  */
656
- error?: WebhookRetrieveResponse.Error | null;
806
+ error?: ErrorDetail | null;
657
807
 
658
808
  /**
659
809
  * Request and response metadata
660
810
  */
661
- meta?: WebhookRetrieveResponse.Meta;
811
+ meta?: APIMeta;
662
812
 
663
813
  /**
664
814
  * Indicates whether the request was successful
@@ -666,599 +816,45 @@ export interface WebhookRetrieveResponse {
666
816
  success?: boolean;
667
817
  }
668
818
 
669
- export namespace WebhookRetrieveResponse {
819
+ export namespace WebhookListEventsResponse {
670
820
  /**
671
- * The response data (null if error)
821
+ * A paginated list of webhook delivery records.
672
822
  */
673
823
  export interface Data {
674
- id?: string;
675
-
676
- consecutive_failures?: number;
677
-
678
- created_at?: string;
824
+ /**
825
+ * The events on this page.
826
+ */
827
+ events?: Array<Data.Event>;
679
828
 
680
829
  /**
681
- * Which customer owns this — the key's own, or the profile named in x-profile-id.
682
- * Says whose resource this is, which the resource's own id does not.
830
+ * Pagination metadata for list responses
683
831
  */
684
- customer_id?: string;
832
+ pagination?: WebhooksAPI.PaginationMeta;
833
+ }
685
834
 
686
- display_name?: string;
835
+ export namespace Data {
836
+ export interface Event {
837
+ id?: string;
687
838
 
688
- endpoint_url?: string;
839
+ created_at?: string;
689
840
 
690
- event_filters?: { [key: string]: Array<string> } | null;
841
+ delivery_attempts?: number;
691
842
 
692
- event_types?: Array<string>;
843
+ delivery_status?: string;
693
844
 
694
- is_active?: boolean;
845
+ error_message?: string | null;
695
846
 
696
- last_delivery_attempt_at?: string | null;
847
+ /**
848
+ * The exact event body that was delivered, or attempted, for this record. One of
849
+ * the three webhook envelopes: a message status change, an inbound message, or a
850
+ * template status change. Read field and event to tell which, the same way your
851
+ * endpoint does.
852
+ */
853
+ event_data?: WebhooksAPI.MessageEvent | WebhooksAPI.InboundMessageEvent | WebhooksAPI.TemplateEvent;
697
854
 
698
- last_successful_delivery_at?: string | null;
855
+ event_type?: string;
699
856
 
700
- retry_count?: number;
701
-
702
- signing_secret?: string | null;
703
-
704
- timeout_seconds?: number;
705
-
706
- updated_at?: string | null;
707
- }
708
-
709
- /**
710
- * Error information
711
- */
712
- export interface Error {
713
- /**
714
- * Machine-readable error code (e.g., "RESOURCE_001")
715
- */
716
- code?: string;
717
-
718
- /**
719
- * Additional validation error details (field-level errors)
720
- */
721
- details?: { [key: string]: Array<string> } | null;
722
-
723
- /**
724
- * URL to documentation about this error
725
- */
726
- doc_url?: string | null;
727
-
728
- /**
729
- * Human-readable error message
730
- */
731
- message?: string;
732
- }
733
-
734
- /**
735
- * Request and response metadata
736
- */
737
- export interface Meta {
738
- /**
739
- * Unique identifier for this request (for tracing and support)
740
- */
741
- request_id?: string;
742
-
743
- /**
744
- * Server timestamp when the response was generated
745
- */
746
- timestamp?: string;
747
-
748
- /**
749
- * API version used for this request
750
- */
751
- version?: string;
752
- }
753
- }
754
-
755
- /**
756
- * Standard API response envelope for all v3 endpoints
757
- */
758
- export interface WebhookUpdateResponse {
759
- /**
760
- * The response data (null if error)
761
- */
762
- data?: WebhookUpdateResponse.Data | null;
763
-
764
- /**
765
- * Error information
766
- */
767
- error?: WebhookUpdateResponse.Error | null;
768
-
769
- /**
770
- * Request and response metadata
771
- */
772
- meta?: WebhookUpdateResponse.Meta;
773
-
774
- /**
775
- * Indicates whether the request was successful
776
- */
777
- success?: boolean;
778
- }
779
-
780
- export namespace WebhookUpdateResponse {
781
- /**
782
- * The response data (null if error)
783
- */
784
- export interface Data {
785
- id?: string;
786
-
787
- consecutive_failures?: number;
788
-
789
- created_at?: string;
790
-
791
- /**
792
- * Which customer owns this — the key's own, or the profile named in x-profile-id.
793
- * Says whose resource this is, which the resource's own id does not.
794
- */
795
- customer_id?: string;
796
-
797
- display_name?: string;
798
-
799
- endpoint_url?: string;
800
-
801
- event_filters?: { [key: string]: Array<string> } | null;
802
-
803
- event_types?: Array<string>;
804
-
805
- is_active?: boolean;
806
-
807
- last_delivery_attempt_at?: string | null;
808
-
809
- last_successful_delivery_at?: string | null;
810
-
811
- retry_count?: number;
812
-
813
- signing_secret?: string | null;
814
-
815
- timeout_seconds?: number;
816
-
817
- updated_at?: string | null;
818
- }
819
-
820
- /**
821
- * Error information
822
- */
823
- export interface Error {
824
- /**
825
- * Machine-readable error code (e.g., "RESOURCE_001")
826
- */
827
- code?: string;
828
-
829
- /**
830
- * Additional validation error details (field-level errors)
831
- */
832
- details?: { [key: string]: Array<string> } | null;
833
-
834
- /**
835
- * URL to documentation about this error
836
- */
837
- doc_url?: string | null;
838
-
839
- /**
840
- * Human-readable error message
841
- */
842
- message?: string;
843
- }
844
-
845
- /**
846
- * Request and response metadata
847
- */
848
- export interface Meta {
849
- /**
850
- * Unique identifier for this request (for tracing and support)
851
- */
852
- request_id?: string;
853
-
854
- /**
855
- * Server timestamp when the response was generated
856
- */
857
- timestamp?: string;
858
-
859
- /**
860
- * API version used for this request
861
- */
862
- version?: string;
863
- }
864
- }
865
-
866
- /**
867
- * Standard API response envelope for all v3 endpoints
868
- */
869
- export interface WebhookListResponse {
870
- /**
871
- * A paginated list of webhooks.
872
- */
873
- data?: WebhookListResponse.Data | null;
874
-
875
- /**
876
- * Error information
877
- */
878
- error?: WebhookListResponse.Error | null;
879
-
880
- /**
881
- * Request and response metadata
882
- */
883
- meta?: WebhookListResponse.Meta;
884
-
885
- /**
886
- * Indicates whether the request was successful
887
- */
888
- success?: boolean;
889
- }
890
-
891
- export namespace WebhookListResponse {
892
- /**
893
- * A paginated list of webhooks.
894
- */
895
- export interface Data {
896
- /**
897
- * Pagination metadata for list responses
898
- */
899
- pagination?: Data.Pagination;
900
-
901
- /**
902
- * The webhooks on this page.
903
- */
904
- webhooks?: Array<Data.Webhook>;
905
- }
906
-
907
- export namespace Data {
908
- /**
909
- * Pagination metadata for list responses
910
- */
911
- export interface Pagination {
912
- /**
913
- * @deprecated Cursor-based pagination. Never populated — see Cursors.
914
- */
915
- cursors?: Pagination.Cursors | null;
916
-
917
- /**
918
- * Whether there are more pages after this one
919
- */
920
- has_more?: boolean;
921
-
922
- /**
923
- * Current page number (1-indexed)
924
- */
925
- page?: number;
926
-
927
- /**
928
- * Number of items per page
929
- */
930
- page_size?: number;
931
-
932
- /**
933
- * Total number of items across all pages
934
- */
935
- total_count?: number;
936
-
937
- /**
938
- * Total number of pages
939
- */
940
- total_pages?: number;
941
- }
942
-
943
- export namespace Pagination {
944
- /**
945
- * @deprecated Cursor-based pagination. Never populated — see Cursors.
946
- */
947
- export interface Cursors {
948
- /**
949
- * Cursor to fetch the next page.
950
- */
951
- after?: string | null;
952
-
953
- /**
954
- * Cursor to fetch the previous page.
955
- */
956
- before?: string | null;
957
- }
958
- }
959
-
960
- export interface Webhook {
961
- id?: string;
962
-
963
- consecutive_failures?: number;
964
-
965
- created_at?: string;
966
-
967
- /**
968
- * Which customer owns this — the key's own, or the profile named in x-profile-id.
969
- * Says whose resource this is, which the resource's own id does not.
970
- */
971
- customer_id?: string;
972
-
973
- display_name?: string;
974
-
975
- endpoint_url?: string;
976
-
977
- event_filters?: { [key: string]: Array<string> } | null;
978
-
979
- event_types?: Array<string>;
980
-
981
- is_active?: boolean;
982
-
983
- last_delivery_attempt_at?: string | null;
984
-
985
- last_successful_delivery_at?: string | null;
986
-
987
- retry_count?: number;
988
-
989
- signing_secret?: string | null;
990
-
991
- timeout_seconds?: number;
992
-
993
- updated_at?: string | null;
994
- }
995
- }
996
-
997
- /**
998
- * Error information
999
- */
1000
- export interface Error {
1001
- /**
1002
- * Machine-readable error code (e.g., "RESOURCE_001")
1003
- */
1004
- code?: string;
1005
-
1006
- /**
1007
- * Additional validation error details (field-level errors)
1008
- */
1009
- details?: { [key: string]: Array<string> } | null;
1010
-
1011
- /**
1012
- * URL to documentation about this error
1013
- */
1014
- doc_url?: string | null;
1015
-
1016
- /**
1017
- * Human-readable error message
1018
- */
1019
- message?: string;
1020
- }
1021
-
1022
- /**
1023
- * Request and response metadata
1024
- */
1025
- export interface Meta {
1026
- /**
1027
- * Unique identifier for this request (for tracing and support)
1028
- */
1029
- request_id?: string;
1030
-
1031
- /**
1032
- * Server timestamp when the response was generated
1033
- */
1034
- timestamp?: string;
1035
-
1036
- /**
1037
- * API version used for this request
1038
- */
1039
- version?: string;
1040
- }
1041
- }
1042
-
1043
- /**
1044
- * Standard API response envelope for all v3 endpoints
1045
- */
1046
- export interface WebhookListEventTypesResponse {
1047
- /**
1048
- * The webhook event types a customer can subscribe to.
1049
- */
1050
- data?: WebhookListEventTypesResponse.Data | null;
1051
-
1052
- /**
1053
- * Error information
1054
- */
1055
- error?: WebhookListEventTypesResponse.Error | null;
1056
-
1057
- /**
1058
- * Request and response metadata
1059
- */
1060
- meta?: WebhookListEventTypesResponse.Meta;
1061
-
1062
- /**
1063
- * Indicates whether the request was successful
1064
- */
1065
- success?: boolean;
1066
- }
1067
-
1068
- export namespace WebhookListEventTypesResponse {
1069
- /**
1070
- * The webhook event types a customer can subscribe to.
1071
- */
1072
- export interface Data {
1073
- /**
1074
- * The event_types on this page.
1075
- */
1076
- event_types?: Array<Data.EventType>;
1077
-
1078
- /**
1079
- * Pagination metadata for list responses
1080
- */
1081
- pagination?: Data.Pagination;
1082
- }
1083
-
1084
- export namespace Data {
1085
- export interface EventType {
1086
- description?: string | null;
1087
-
1088
- display_name?: string;
1089
-
1090
- event_type?: string | null;
1091
-
1092
- is_active?: boolean;
1093
-
1094
- name?: string;
1095
-
1096
- sub_types?: Array<unknown> | null;
1097
- }
1098
-
1099
- /**
1100
- * Pagination metadata for list responses
1101
- */
1102
- export interface Pagination {
1103
- /**
1104
- * @deprecated Cursor-based pagination. Never populated — see Cursors.
1105
- */
1106
- cursors?: Pagination.Cursors | null;
1107
-
1108
- /**
1109
- * Whether there are more pages after this one
1110
- */
1111
- has_more?: boolean;
1112
-
1113
- /**
1114
- * Current page number (1-indexed)
1115
- */
1116
- page?: number;
1117
-
1118
- /**
1119
- * Number of items per page
1120
- */
1121
- page_size?: number;
1122
-
1123
- /**
1124
- * Total number of items across all pages
1125
- */
1126
- total_count?: number;
1127
-
1128
- /**
1129
- * Total number of pages
1130
- */
1131
- total_pages?: number;
1132
- }
1133
-
1134
- export namespace Pagination {
1135
- /**
1136
- * @deprecated Cursor-based pagination. Never populated — see Cursors.
1137
- */
1138
- export interface Cursors {
1139
- /**
1140
- * Cursor to fetch the next page.
1141
- */
1142
- after?: string | null;
1143
-
1144
- /**
1145
- * Cursor to fetch the previous page.
1146
- */
1147
- before?: string | null;
1148
- }
1149
- }
1150
- }
1151
-
1152
- /**
1153
- * Error information
1154
- */
1155
- export interface Error {
1156
- /**
1157
- * Machine-readable error code (e.g., "RESOURCE_001")
1158
- */
1159
- code?: string;
1160
-
1161
- /**
1162
- * Additional validation error details (field-level errors)
1163
- */
1164
- details?: { [key: string]: Array<string> } | null;
1165
-
1166
- /**
1167
- * URL to documentation about this error
1168
- */
1169
- doc_url?: string | null;
1170
-
1171
- /**
1172
- * Human-readable error message
1173
- */
1174
- message?: string;
1175
- }
1176
-
1177
- /**
1178
- * Request and response metadata
1179
- */
1180
- export interface Meta {
1181
- /**
1182
- * Unique identifier for this request (for tracing and support)
1183
- */
1184
- request_id?: string;
1185
-
1186
- /**
1187
- * Server timestamp when the response was generated
1188
- */
1189
- timestamp?: string;
1190
-
1191
- /**
1192
- * API version used for this request
1193
- */
1194
- version?: string;
1195
- }
1196
- }
1197
-
1198
- /**
1199
- * Standard API response envelope for all v3 endpoints
1200
- */
1201
- export interface WebhookListEventsResponse {
1202
- /**
1203
- * A paginated list of webhook delivery records.
1204
- */
1205
- data?: WebhookListEventsResponse.Data | null;
1206
-
1207
- /**
1208
- * Error information
1209
- */
1210
- error?: WebhookListEventsResponse.Error | null;
1211
-
1212
- /**
1213
- * Request and response metadata
1214
- */
1215
- meta?: WebhookListEventsResponse.Meta;
1216
-
1217
- /**
1218
- * Indicates whether the request was successful
1219
- */
1220
- success?: boolean;
1221
- }
1222
-
1223
- export namespace WebhookListEventsResponse {
1224
- /**
1225
- * A paginated list of webhook delivery records.
1226
- */
1227
- export interface Data {
1228
- /**
1229
- * The events on this page.
1230
- */
1231
- events?: Array<Data.Event>;
1232
-
1233
- /**
1234
- * Pagination metadata for list responses
1235
- */
1236
- pagination?: Data.Pagination;
1237
- }
1238
-
1239
- export namespace Data {
1240
- export interface Event {
1241
- id?: string;
1242
-
1243
- created_at?: string;
1244
-
1245
- delivery_attempts?: number;
1246
-
1247
- delivery_status?: string;
1248
-
1249
- error_message?: string | null;
1250
-
1251
- /**
1252
- * The exact event body that was delivered, or attempted, for this record. One of
1253
- * the three webhook envelopes: a message status change, an inbound message, or a
1254
- * template status change. Read field and event to tell which, the same way your
1255
- * endpoint does.
1256
- */
1257
- event_data?: WebhooksAPI.MessageEvent | WebhooksAPI.InboundMessageEvent | WebhooksAPI.TemplateEvent;
1258
-
1259
- event_type?: string;
1260
-
1261
- http_status_code?: number | null;
857
+ http_status_code?: number | null;
1262
858
 
1263
859
  processing_completed_at?: string | null;
1264
860
 
@@ -1266,103 +862,6 @@ export namespace WebhookListEventsResponse {
1266
862
 
1267
863
  response_body?: string | null;
1268
864
  }
1269
-
1270
- /**
1271
- * Pagination metadata for list responses
1272
- */
1273
- export interface Pagination {
1274
- /**
1275
- * @deprecated Cursor-based pagination. Never populated — see Cursors.
1276
- */
1277
- cursors?: Pagination.Cursors | null;
1278
-
1279
- /**
1280
- * Whether there are more pages after this one
1281
- */
1282
- has_more?: boolean;
1283
-
1284
- /**
1285
- * Current page number (1-indexed)
1286
- */
1287
- page?: number;
1288
-
1289
- /**
1290
- * Number of items per page
1291
- */
1292
- page_size?: number;
1293
-
1294
- /**
1295
- * Total number of items across all pages
1296
- */
1297
- total_count?: number;
1298
-
1299
- /**
1300
- * Total number of pages
1301
- */
1302
- total_pages?: number;
1303
- }
1304
-
1305
- export namespace Pagination {
1306
- /**
1307
- * @deprecated Cursor-based pagination. Never populated — see Cursors.
1308
- */
1309
- export interface Cursors {
1310
- /**
1311
- * Cursor to fetch the next page.
1312
- */
1313
- after?: string | null;
1314
-
1315
- /**
1316
- * Cursor to fetch the previous page.
1317
- */
1318
- before?: string | null;
1319
- }
1320
- }
1321
- }
1322
-
1323
- /**
1324
- * Error information
1325
- */
1326
- export interface Error {
1327
- /**
1328
- * Machine-readable error code (e.g., "RESOURCE_001")
1329
- */
1330
- code?: string;
1331
-
1332
- /**
1333
- * Additional validation error details (field-level errors)
1334
- */
1335
- details?: { [key: string]: Array<string> } | null;
1336
-
1337
- /**
1338
- * URL to documentation about this error
1339
- */
1340
- doc_url?: string | null;
1341
-
1342
- /**
1343
- * Human-readable error message
1344
- */
1345
- message?: string;
1346
- }
1347
-
1348
- /**
1349
- * Request and response metadata
1350
- */
1351
- export interface Meta {
1352
- /**
1353
- * Unique identifier for this request (for tracing and support)
1354
- */
1355
- request_id?: string;
1356
-
1357
- /**
1358
- * Server timestamp when the response was generated
1359
- */
1360
- timestamp?: string;
1361
-
1362
- /**
1363
- * API version used for this request
1364
- */
1365
- version?: string;
1366
865
  }
1367
866
  }
1368
867
 
@@ -1378,12 +877,12 @@ export interface WebhookRotateSecretResponse {
1378
877
  /**
1379
878
  * Error information
1380
879
  */
1381
- error?: WebhookRotateSecretResponse.Error | null;
880
+ error?: ErrorDetail | null;
1382
881
 
1383
882
  /**
1384
883
  * Request and response metadata
1385
884
  */
1386
- meta?: WebhookRotateSecretResponse.Meta;
885
+ meta?: APIMeta;
1387
886
 
1388
887
  /**
1389
888
  * Indicates whether the request was successful
@@ -1398,51 +897,6 @@ export namespace WebhookRotateSecretResponse {
1398
897
  export interface Data {
1399
898
  signing_secret?: string;
1400
899
  }
1401
-
1402
- /**
1403
- * Error information
1404
- */
1405
- export interface Error {
1406
- /**
1407
- * Machine-readable error code (e.g., "RESOURCE_001")
1408
- */
1409
- code?: string;
1410
-
1411
- /**
1412
- * Additional validation error details (field-level errors)
1413
- */
1414
- details?: { [key: string]: Array<string> } | null;
1415
-
1416
- /**
1417
- * URL to documentation about this error
1418
- */
1419
- doc_url?: string | null;
1420
-
1421
- /**
1422
- * Human-readable error message
1423
- */
1424
- message?: string;
1425
- }
1426
-
1427
- /**
1428
- * Request and response metadata
1429
- */
1430
- export interface Meta {
1431
- /**
1432
- * Unique identifier for this request (for tracing and support)
1433
- */
1434
- request_id?: string;
1435
-
1436
- /**
1437
- * Server timestamp when the response was generated
1438
- */
1439
- timestamp?: string;
1440
-
1441
- /**
1442
- * API version used for this request
1443
- */
1444
- version?: string;
1445
- }
1446
900
  }
1447
901
 
1448
902
  /**
@@ -1457,12 +911,12 @@ export interface WebhookTestResponse {
1457
911
  /**
1458
912
  * Error information
1459
913
  */
1460
- error?: WebhookTestResponse.Error | null;
914
+ error?: ErrorDetail | null;
1461
915
 
1462
916
  /**
1463
917
  * Request and response metadata
1464
918
  */
1465
- meta?: WebhookTestResponse.Meta;
919
+ meta?: APIMeta;
1466
920
 
1467
921
  /**
1468
922
  * Indicates whether the request was successful
@@ -1479,162 +933,6 @@ export namespace WebhookTestResponse {
1479
933
 
1480
934
  success?: boolean;
1481
935
  }
1482
-
1483
- /**
1484
- * Error information
1485
- */
1486
- export interface Error {
1487
- /**
1488
- * Machine-readable error code (e.g., "RESOURCE_001")
1489
- */
1490
- code?: string;
1491
-
1492
- /**
1493
- * Additional validation error details (field-level errors)
1494
- */
1495
- details?: { [key: string]: Array<string> } | null;
1496
-
1497
- /**
1498
- * URL to documentation about this error
1499
- */
1500
- doc_url?: string | null;
1501
-
1502
- /**
1503
- * Human-readable error message
1504
- */
1505
- message?: string;
1506
- }
1507
-
1508
- /**
1509
- * Request and response metadata
1510
- */
1511
- export interface Meta {
1512
- /**
1513
- * Unique identifier for this request (for tracing and support)
1514
- */
1515
- request_id?: string;
1516
-
1517
- /**
1518
- * Server timestamp when the response was generated
1519
- */
1520
- timestamp?: string;
1521
-
1522
- /**
1523
- * API version used for this request
1524
- */
1525
- version?: string;
1526
- }
1527
- }
1528
-
1529
- /**
1530
- * Standard API response envelope for all v3 endpoints
1531
- */
1532
- export interface WebhookToggleStatusResponse {
1533
- /**
1534
- * The response data (null if error)
1535
- */
1536
- data?: WebhookToggleStatusResponse.Data | null;
1537
-
1538
- /**
1539
- * Error information
1540
- */
1541
- error?: WebhookToggleStatusResponse.Error | null;
1542
-
1543
- /**
1544
- * Request and response metadata
1545
- */
1546
- meta?: WebhookToggleStatusResponse.Meta;
1547
-
1548
- /**
1549
- * Indicates whether the request was successful
1550
- */
1551
- success?: boolean;
1552
- }
1553
-
1554
- export namespace WebhookToggleStatusResponse {
1555
- /**
1556
- * The response data (null if error)
1557
- */
1558
- export interface Data {
1559
- id?: string;
1560
-
1561
- consecutive_failures?: number;
1562
-
1563
- created_at?: string;
1564
-
1565
- /**
1566
- * Which customer owns this — the key's own, or the profile named in x-profile-id.
1567
- * Says whose resource this is, which the resource's own id does not.
1568
- */
1569
- customer_id?: string;
1570
-
1571
- display_name?: string;
1572
-
1573
- endpoint_url?: string;
1574
-
1575
- event_filters?: { [key: string]: Array<string> } | null;
1576
-
1577
- event_types?: Array<string>;
1578
-
1579
- is_active?: boolean;
1580
-
1581
- last_delivery_attempt_at?: string | null;
1582
-
1583
- last_successful_delivery_at?: string | null;
1584
-
1585
- retry_count?: number;
1586
-
1587
- signing_secret?: string | null;
1588
-
1589
- timeout_seconds?: number;
1590
-
1591
- updated_at?: string | null;
1592
- }
1593
-
1594
- /**
1595
- * Error information
1596
- */
1597
- export interface Error {
1598
- /**
1599
- * Machine-readable error code (e.g., "RESOURCE_001")
1600
- */
1601
- code?: string;
1602
-
1603
- /**
1604
- * Additional validation error details (field-level errors)
1605
- */
1606
- details?: { [key: string]: Array<string> } | null;
1607
-
1608
- /**
1609
- * URL to documentation about this error
1610
- */
1611
- doc_url?: string | null;
1612
-
1613
- /**
1614
- * Human-readable error message
1615
- */
1616
- message?: string;
1617
- }
1618
-
1619
- /**
1620
- * Request and response metadata
1621
- */
1622
- export interface Meta {
1623
- /**
1624
- * Unique identifier for this request (for tracing and support)
1625
- */
1626
- request_id?: string;
1627
-
1628
- /**
1629
- * Server timestamp when the response was generated
1630
- */
1631
- timestamp?: string;
1632
-
1633
- /**
1634
- * API version used for this request
1635
- */
1636
- version?: string;
1637
- }
1638
936
  }
1639
937
 
1640
938
  export interface WebhookCreateParams {
@@ -1896,21 +1194,24 @@ export interface WebhookToggleStatusParams {
1896
1194
 
1897
1195
  export declare namespace Webhooks {
1898
1196
  export {
1197
+ type APIMeta as APIMeta,
1198
+ type APIResponseWebhook as APIResponseWebhook,
1199
+ type ErrorDetail as ErrorDetail,
1899
1200
  type InboundMessageEvent as InboundMessageEvent,
1900
1201
  type InboundMessageEventPayload as InboundMessageEventPayload,
1901
1202
  type MessageEvent as MessageEvent,
1902
1203
  type MessageEventPayload as MessageEventPayload,
1204
+ type MutationRequest as MutationRequest,
1205
+ type PaginationMeta as PaginationMeta,
1903
1206
  type TemplateEvent as TemplateEvent,
1904
1207
  type TemplateEventPayload as TemplateEventPayload,
1905
- type WebhookCreateResponse as WebhookCreateResponse,
1906
- type WebhookRetrieveResponse as WebhookRetrieveResponse,
1907
- type WebhookUpdateResponse as WebhookUpdateResponse,
1208
+ type WebhookEventType as WebhookEventType,
1209
+ type WebhookResponse as WebhookResponse,
1908
1210
  type WebhookListResponse as WebhookListResponse,
1909
1211
  type WebhookListEventTypesResponse as WebhookListEventTypesResponse,
1910
1212
  type WebhookListEventsResponse as WebhookListEventsResponse,
1911
1213
  type WebhookRotateSecretResponse as WebhookRotateSecretResponse,
1912
1214
  type WebhookTestResponse as WebhookTestResponse,
1913
- type WebhookToggleStatusResponse as WebhookToggleStatusResponse,
1914
1215
  type WebhookCreateParams as WebhookCreateParams,
1915
1216
  type WebhookRetrieveParams as WebhookRetrieveParams,
1916
1217
  type WebhookUpdateParams as WebhookUpdateParams,