@sentdm/sentdm 0.25.4 → 0.26.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 (103) hide show
  1. package/CHANGELOG.md +8 -0
  2. package/client.d.mts +12 -12
  3. package/client.d.mts.map +1 -1
  4. package/client.d.ts +12 -12
  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 +488 -68
  10. package/resources/contacts.d.mts.map +1 -1
  11. package/resources/contacts.d.ts +488 -68
  12. package/resources/contacts.d.ts.map +1 -1
  13. package/resources/contacts.js +3 -3
  14. package/resources/contacts.js.map +1 -1
  15. package/resources/contacts.mjs +3 -3
  16. package/resources/contacts.mjs.map +1 -1
  17. package/resources/index.d.mts +6 -6
  18. package/resources/index.d.mts.map +1 -1
  19. package/resources/index.d.ts +6 -6
  20. package/resources/index.d.ts.map +1 -1
  21. package/resources/index.js.map +1 -1
  22. package/resources/index.mjs.map +1 -1
  23. package/resources/me.d.mts +113 -40
  24. package/resources/me.d.mts.map +1 -1
  25. package/resources/me.d.ts +113 -40
  26. package/resources/me.d.ts.map +1 -1
  27. package/resources/me.js.map +1 -1
  28. package/resources/me.mjs.map +1 -1
  29. package/resources/messages.d.mts +130 -9
  30. package/resources/messages.d.mts.map +1 -1
  31. package/resources/messages.d.ts +130 -9
  32. package/resources/messages.d.ts.map +1 -1
  33. package/resources/messages.js.map +1 -1
  34. package/resources/messages.mjs.map +1 -1
  35. package/resources/numbers.d.mts +42 -3
  36. package/resources/numbers.d.mts.map +1 -1
  37. package/resources/numbers.d.ts +42 -3
  38. package/resources/numbers.d.ts.map +1 -1
  39. package/resources/numbers.js.map +1 -1
  40. package/resources/numbers.mjs.map +1 -1
  41. package/resources/profiles/campaigns.d.mts +480 -147
  42. package/resources/profiles/campaigns.d.mts.map +1 -1
  43. package/resources/profiles/campaigns.d.ts +480 -147
  44. package/resources/profiles/campaigns.d.ts.map +1 -1
  45. package/resources/profiles/campaigns.js +39 -41
  46. package/resources/profiles/campaigns.js.map +1 -1
  47. package/resources/profiles/campaigns.mjs +39 -41
  48. package/resources/profiles/campaigns.mjs.map +1 -1
  49. package/resources/profiles/index.d.mts +2 -2
  50. package/resources/profiles/index.d.mts.map +1 -1
  51. package/resources/profiles/index.d.ts +2 -2
  52. package/resources/profiles/index.d.ts.map +1 -1
  53. package/resources/profiles/index.js.map +1 -1
  54. package/resources/profiles/index.mjs.map +1 -1
  55. package/resources/profiles/profiles.d.mts +1699 -391
  56. package/resources/profiles/profiles.d.mts.map +1 -1
  57. package/resources/profiles/profiles.d.ts +1699 -391
  58. package/resources/profiles/profiles.d.ts.map +1 -1
  59. package/resources/profiles/profiles.js +3 -6
  60. package/resources/profiles/profiles.js.map +1 -1
  61. package/resources/profiles/profiles.mjs +3 -6
  62. package/resources/profiles/profiles.mjs.map +1 -1
  63. package/resources/templates.d.mts +993 -172
  64. package/resources/templates.d.mts.map +1 -1
  65. package/resources/templates.d.ts +993 -172
  66. package/resources/templates.d.ts.map +1 -1
  67. package/resources/templates.js +3 -3
  68. package/resources/templates.js.map +1 -1
  69. package/resources/templates.mjs +3 -3
  70. package/resources/templates.mjs.map +1 -1
  71. package/resources/users.d.mts +373 -46
  72. package/resources/users.d.mts.map +1 -1
  73. package/resources/users.d.ts +373 -46
  74. package/resources/users.d.ts.map +1 -1
  75. package/resources/users.js +3 -7
  76. package/resources/users.js.map +1 -1
  77. package/resources/users.mjs +3 -7
  78. package/resources/users.mjs.map +1 -1
  79. package/resources/webhooks.d.mts +624 -110
  80. package/resources/webhooks.d.mts.map +1 -1
  81. package/resources/webhooks.d.ts +624 -110
  82. package/resources/webhooks.d.ts.map +1 -1
  83. package/resources/webhooks.js +6 -7
  84. package/resources/webhooks.js.map +1 -1
  85. package/resources/webhooks.mjs +6 -7
  86. package/resources/webhooks.mjs.map +1 -1
  87. package/src/client.ts +33 -68
  88. package/src/resources/contacts.ts +567 -66
  89. package/src/resources/index.ts +17 -34
  90. package/src/resources/me.ts +132 -51
  91. package/src/resources/messages.ts +147 -9
  92. package/src/resources/numbers.ts +47 -3
  93. package/src/resources/profiles/campaigns.ts +668 -169
  94. package/src/resources/profiles/index.ts +5 -17
  95. package/src/resources/profiles/profiles.ts +2278 -545
  96. package/src/resources/templates.ts +1261 -206
  97. package/src/resources/users.ts +430 -47
  98. package/src/resources/webhooks.ts +742 -120
  99. package/src/version.ts +1 -1
  100. package/version.d.mts +1 -1
  101. package/version.d.ts +1 -1
  102. package/version.js +1 -1
  103. package/version.mjs +1 -1
@@ -1,5 +1,4 @@
1
1
  import { APIResource } from "../core/resource.js";
2
- import * as WebhooksAPI from "./webhooks.js";
3
2
  import { APIPromise } from "../core/api-promise.js";
4
3
  import { RequestOptions } from "../internal/request-options.js";
5
4
  /**
@@ -11,32 +10,32 @@ export declare class Webhooks extends APIResource {
11
10
  *
12
11
  * @example
13
12
  * ```ts
14
- * const apiResponseWebhook = await client.webhooks.create();
13
+ * const webhook = await client.webhooks.create();
15
14
  * ```
16
15
  */
17
- create(params: WebhookCreateParams, options?: RequestOptions): APIPromise<APIResponseWebhook>;
16
+ create(params: WebhookCreateParams, options?: RequestOptions): APIPromise<WebhookCreateResponse>;
18
17
  /**
19
18
  * Retrieves a single webhook by ID for the authenticated customer.
20
19
  *
21
20
  * @example
22
21
  * ```ts
23
- * const apiResponseWebhook = await client.webhooks.retrieve(
22
+ * const webhook = await client.webhooks.retrieve(
24
23
  * 'd4f5a6b7-c8d9-4e0f-a1b2-c3d4e5f6a7b8',
25
24
  * );
26
25
  * ```
27
26
  */
28
- retrieve(id: string, params?: WebhookRetrieveParams | null | undefined, options?: RequestOptions): APIPromise<APIResponseWebhook>;
27
+ retrieve(id: string, params?: WebhookRetrieveParams | null | undefined, options?: RequestOptions): APIPromise<WebhookRetrieveResponse>;
29
28
  /**
30
29
  * Updates an existing webhook for the authenticated customer.
31
30
  *
32
31
  * @example
33
32
  * ```ts
34
- * const apiResponseWebhook = await client.webhooks.update(
33
+ * const webhook = await client.webhooks.update(
35
34
  * 'd4f5a6b7-c8d9-4e0f-a1b2-c3d4e5f6a7b8',
36
35
  * );
37
36
  * ```
38
37
  */
39
- update(id: string, params: WebhookUpdateParams, options?: RequestOptions): APIPromise<APIResponseWebhook>;
38
+ update(id: string, params: WebhookUpdateParams, options?: RequestOptions): APIPromise<WebhookUpdateResponse>;
40
39
  /**
41
40
  * Retrieves a paginated list of webhooks for the authenticated customer.
42
41
  *
@@ -109,152 +108,265 @@ export declare class Webhooks extends APIResource {
109
108
  *
110
109
  * @example
111
110
  * ```ts
112
- * const apiResponseWebhook =
113
- * await client.webhooks.toggleStatus(
114
- * 'd4f5a6b7-c8d9-4e0f-a1b2-c3d4e5f6a7b8',
115
- * );
111
+ * const response = await client.webhooks.toggleStatus(
112
+ * 'd4f5a6b7-c8d9-4e0f-a1b2-c3d4e5f6a7b8',
113
+ * );
116
114
  * ```
117
115
  */
118
- toggleStatus(id: string, params: WebhookToggleStatusParams, options?: RequestOptions): APIPromise<APIResponseWebhook>;
116
+ toggleStatus(id: string, params: WebhookToggleStatusParams, options?: RequestOptions): APIPromise<WebhookToggleStatusResponse>;
119
117
  }
120
118
  /**
121
- * Request and response metadata
119
+ * Standard API response envelope for all v3 endpoints
122
120
  */
123
- export interface APIMeta {
121
+ export interface WebhookCreateResponse {
124
122
  /**
125
- * Unique identifier for this request (for tracing and support)
123
+ * The response data (null if error)
126
124
  */
127
- request_id?: string;
125
+ data?: WebhookCreateResponse.Data | null;
128
126
  /**
129
- * Server timestamp when the response was generated
127
+ * Error information
130
128
  */
131
- timestamp?: string;
129
+ error?: WebhookCreateResponse.Error | null;
132
130
  /**
133
- * API version used for this request
131
+ * Request and response metadata
132
+ */
133
+ meta?: WebhookCreateResponse.Meta;
134
+ /**
135
+ * Indicates whether the request was successful
134
136
  */
135
- version?: string;
137
+ success?: boolean;
136
138
  }
137
- /**
138
- * Standard API response envelope for all v3 endpoints
139
- */
140
- export interface APIResponseWebhook {
139
+ export declare namespace WebhookCreateResponse {
141
140
  /**
142
141
  * The response data (null if error)
143
142
  */
144
- data?: WebhookResponse | null;
143
+ interface Data {
144
+ id?: string;
145
+ consecutive_failures?: number;
146
+ created_at?: string;
147
+ display_name?: string;
148
+ endpoint_url?: string;
149
+ event_filters?: {
150
+ [key: string]: Array<string>;
151
+ } | null;
152
+ event_types?: Array<string>;
153
+ is_active?: boolean;
154
+ last_delivery_attempt_at?: string | null;
155
+ last_successful_delivery_at?: string | null;
156
+ retry_count?: number;
157
+ signing_secret?: string | null;
158
+ timeout_seconds?: number;
159
+ updated_at?: string | null;
160
+ }
145
161
  /**
146
162
  * Error information
147
163
  */
148
- error?: ErrorDetail | null;
164
+ interface Error {
165
+ /**
166
+ * Machine-readable error code (e.g., "RESOURCE_001")
167
+ */
168
+ code?: string;
169
+ /**
170
+ * Additional validation error details (field-level errors)
171
+ */
172
+ details?: {
173
+ [key: string]: Array<string>;
174
+ } | null;
175
+ /**
176
+ * URL to documentation about this error
177
+ */
178
+ doc_url?: string | null;
179
+ /**
180
+ * Human-readable error message
181
+ */
182
+ message?: string;
183
+ }
149
184
  /**
150
185
  * Request and response metadata
151
186
  */
152
- meta?: APIMeta;
153
- /**
154
- * Indicates whether the request was successful
155
- */
156
- success?: boolean;
187
+ interface Meta {
188
+ /**
189
+ * Unique identifier for this request (for tracing and support)
190
+ */
191
+ request_id?: string;
192
+ /**
193
+ * Server timestamp when the response was generated
194
+ */
195
+ timestamp?: string;
196
+ /**
197
+ * API version used for this request
198
+ */
199
+ version?: string;
200
+ }
157
201
  }
158
202
  /**
159
- * Error information
203
+ * Standard API response envelope for all v3 endpoints
160
204
  */
161
- export interface ErrorDetail {
205
+ export interface WebhookRetrieveResponse {
162
206
  /**
163
- * Machine-readable error code (e.g., "RESOURCE_001")
207
+ * The response data (null if error)
164
208
  */
165
- code?: string;
209
+ data?: WebhookRetrieveResponse.Data | null;
166
210
  /**
167
- * Additional validation error details (field-level errors)
211
+ * Error information
168
212
  */
169
- details?: {
170
- [key: string]: Array<string>;
171
- } | null;
213
+ error?: WebhookRetrieveResponse.Error | null;
172
214
  /**
173
- * URL to documentation about this error
215
+ * Request and response metadata
174
216
  */
175
- doc_url?: string | null;
217
+ meta?: WebhookRetrieveResponse.Meta;
176
218
  /**
177
- * Human-readable error message
219
+ * Indicates whether the request was successful
178
220
  */
179
- message?: string;
221
+ success?: boolean;
180
222
  }
181
- export interface MutationRequest {
223
+ export declare namespace WebhookRetrieveResponse {
224
+ /**
225
+ * The response data (null if error)
226
+ */
227
+ interface Data {
228
+ id?: string;
229
+ consecutive_failures?: number;
230
+ created_at?: string;
231
+ display_name?: string;
232
+ endpoint_url?: string;
233
+ event_filters?: {
234
+ [key: string]: Array<string>;
235
+ } | null;
236
+ event_types?: Array<string>;
237
+ is_active?: boolean;
238
+ last_delivery_attempt_at?: string | null;
239
+ last_successful_delivery_at?: string | null;
240
+ retry_count?: number;
241
+ signing_secret?: string | null;
242
+ timeout_seconds?: number;
243
+ updated_at?: string | null;
244
+ }
182
245
  /**
183
- * Sandbox flag - when true, the operation is simulated without side effects Useful
184
- * for testing integrations without actual execution
246
+ * Error information
185
247
  */
186
- sandbox?: boolean;
248
+ interface Error {
249
+ /**
250
+ * Machine-readable error code (e.g., "RESOURCE_001")
251
+ */
252
+ code?: string;
253
+ /**
254
+ * Additional validation error details (field-level errors)
255
+ */
256
+ details?: {
257
+ [key: string]: Array<string>;
258
+ } | null;
259
+ /**
260
+ * URL to documentation about this error
261
+ */
262
+ doc_url?: string | null;
263
+ /**
264
+ * Human-readable error message
265
+ */
266
+ message?: string;
267
+ }
268
+ /**
269
+ * Request and response metadata
270
+ */
271
+ interface Meta {
272
+ /**
273
+ * Unique identifier for this request (for tracing and support)
274
+ */
275
+ request_id?: string;
276
+ /**
277
+ * Server timestamp when the response was generated
278
+ */
279
+ timestamp?: string;
280
+ /**
281
+ * API version used for this request
282
+ */
283
+ version?: string;
284
+ }
187
285
  }
188
286
  /**
189
- * Pagination metadata for list responses
287
+ * Standard API response envelope for all v3 endpoints
190
288
  */
191
- export interface PaginationMeta {
289
+ export interface WebhookUpdateResponse {
192
290
  /**
193
- * Cursor-based pagination pointers
291
+ * The response data (null if error)
194
292
  */
195
- cursors?: PaginationMeta.Cursors | null;
293
+ data?: WebhookUpdateResponse.Data | null;
196
294
  /**
197
- * Whether there are more pages after this one
295
+ * Error information
198
296
  */
199
- has_more?: boolean;
297
+ error?: WebhookUpdateResponse.Error | null;
200
298
  /**
201
- * Current page number (1-indexed)
299
+ * Request and response metadata
202
300
  */
203
- page?: number;
301
+ meta?: WebhookUpdateResponse.Meta;
204
302
  /**
205
- * Number of items per page
303
+ * Indicates whether the request was successful
206
304
  */
207
- page_size?: number;
305
+ success?: boolean;
306
+ }
307
+ export declare namespace WebhookUpdateResponse {
208
308
  /**
209
- * Total number of items across all pages
309
+ * The response data (null if error)
210
310
  */
211
- total_count?: number;
311
+ interface Data {
312
+ id?: string;
313
+ consecutive_failures?: number;
314
+ created_at?: string;
315
+ display_name?: string;
316
+ endpoint_url?: string;
317
+ event_filters?: {
318
+ [key: string]: Array<string>;
319
+ } | null;
320
+ event_types?: Array<string>;
321
+ is_active?: boolean;
322
+ last_delivery_attempt_at?: string | null;
323
+ last_successful_delivery_at?: string | null;
324
+ retry_count?: number;
325
+ signing_secret?: string | null;
326
+ timeout_seconds?: number;
327
+ updated_at?: string | null;
328
+ }
212
329
  /**
213
- * Total number of pages
330
+ * Error information
214
331
  */
215
- total_pages?: number;
216
- }
217
- export declare namespace PaginationMeta {
332
+ interface Error {
333
+ /**
334
+ * Machine-readable error code (e.g., "RESOURCE_001")
335
+ */
336
+ code?: string;
337
+ /**
338
+ * Additional validation error details (field-level errors)
339
+ */
340
+ details?: {
341
+ [key: string]: Array<string>;
342
+ } | null;
343
+ /**
344
+ * URL to documentation about this error
345
+ */
346
+ doc_url?: string | null;
347
+ /**
348
+ * Human-readable error message
349
+ */
350
+ message?: string;
351
+ }
218
352
  /**
219
- * Cursor-based pagination pointers
353
+ * Request and response metadata
220
354
  */
221
- interface Cursors {
355
+ interface Meta {
222
356
  /**
223
- * Cursor to fetch the next page
357
+ * Unique identifier for this request (for tracing and support)
224
358
  */
225
- after?: string | null;
359
+ request_id?: string;
226
360
  /**
227
- * Cursor to fetch the previous page
361
+ * Server timestamp when the response was generated
228
362
  */
229
- before?: string | null;
363
+ timestamp?: string;
364
+ /**
365
+ * API version used for this request
366
+ */
367
+ version?: string;
230
368
  }
231
369
  }
232
- export interface WebhookEventType {
233
- description?: string | null;
234
- display_name?: string;
235
- event_type?: string | null;
236
- is_active?: boolean;
237
- name?: string;
238
- sub_types?: Array<WebhookEventType> | null;
239
- }
240
- export interface WebhookResponse {
241
- id?: string;
242
- consecutive_failures?: number;
243
- created_at?: string;
244
- display_name?: string;
245
- endpoint_url?: string;
246
- event_filters?: {
247
- [key: string]: Array<string>;
248
- } | null;
249
- event_types?: Array<string>;
250
- is_active?: boolean;
251
- last_delivery_attempt_at?: string | null;
252
- last_successful_delivery_at?: string | null;
253
- retry_count?: number;
254
- signing_secret?: string | null;
255
- timeout_seconds?: number;
256
- updated_at?: string | null;
257
- }
258
370
  /**
259
371
  * Standard API response envelope for all v3 endpoints
260
372
  */
@@ -266,11 +378,11 @@ export interface WebhookListResponse {
266
378
  /**
267
379
  * Error information
268
380
  */
269
- error?: ErrorDetail | null;
381
+ error?: WebhookListResponse.Error | null;
270
382
  /**
271
383
  * Request and response metadata
272
384
  */
273
- meta?: APIMeta;
385
+ meta?: WebhookListResponse.Meta;
274
386
  /**
275
387
  * Indicates whether the request was successful
276
388
  */
@@ -284,8 +396,112 @@ export declare namespace WebhookListResponse {
284
396
  /**
285
397
  * Pagination metadata for list responses
286
398
  */
287
- pagination?: WebhooksAPI.PaginationMeta;
288
- webhooks?: Array<WebhooksAPI.WebhookResponse>;
399
+ pagination?: Data.Pagination;
400
+ webhooks?: Array<Data.Webhook>;
401
+ }
402
+ namespace Data {
403
+ /**
404
+ * Pagination metadata for list responses
405
+ */
406
+ interface Pagination {
407
+ /**
408
+ * Cursor-based pagination pointers
409
+ */
410
+ cursors?: Pagination.Cursors | null;
411
+ /**
412
+ * Whether there are more pages after this one
413
+ */
414
+ has_more?: boolean;
415
+ /**
416
+ * Current page number (1-indexed)
417
+ */
418
+ page?: number;
419
+ /**
420
+ * Number of items per page
421
+ */
422
+ page_size?: number;
423
+ /**
424
+ * Total number of items across all pages
425
+ */
426
+ total_count?: number;
427
+ /**
428
+ * Total number of pages
429
+ */
430
+ total_pages?: number;
431
+ }
432
+ namespace Pagination {
433
+ /**
434
+ * Cursor-based pagination pointers
435
+ */
436
+ interface Cursors {
437
+ /**
438
+ * Cursor to fetch the next page
439
+ */
440
+ after?: string | null;
441
+ /**
442
+ * Cursor to fetch the previous page
443
+ */
444
+ before?: string | null;
445
+ }
446
+ }
447
+ interface Webhook {
448
+ id?: string;
449
+ consecutive_failures?: number;
450
+ created_at?: string;
451
+ display_name?: string;
452
+ endpoint_url?: string;
453
+ event_filters?: {
454
+ [key: string]: Array<string>;
455
+ } | null;
456
+ event_types?: Array<string>;
457
+ is_active?: boolean;
458
+ last_delivery_attempt_at?: string | null;
459
+ last_successful_delivery_at?: string | null;
460
+ retry_count?: number;
461
+ signing_secret?: string | null;
462
+ timeout_seconds?: number;
463
+ updated_at?: string | null;
464
+ }
465
+ }
466
+ /**
467
+ * Error information
468
+ */
469
+ interface Error {
470
+ /**
471
+ * Machine-readable error code (e.g., "RESOURCE_001")
472
+ */
473
+ code?: string;
474
+ /**
475
+ * Additional validation error details (field-level errors)
476
+ */
477
+ details?: {
478
+ [key: string]: Array<string>;
479
+ } | null;
480
+ /**
481
+ * URL to documentation about this error
482
+ */
483
+ doc_url?: string | null;
484
+ /**
485
+ * Human-readable error message
486
+ */
487
+ message?: string;
488
+ }
489
+ /**
490
+ * Request and response metadata
491
+ */
492
+ interface Meta {
493
+ /**
494
+ * Unique identifier for this request (for tracing and support)
495
+ */
496
+ request_id?: string;
497
+ /**
498
+ * Server timestamp when the response was generated
499
+ */
500
+ timestamp?: string;
501
+ /**
502
+ * API version used for this request
503
+ */
504
+ version?: string;
289
505
  }
290
506
  }
291
507
  /**
@@ -299,11 +515,11 @@ export interface WebhookListEventTypesResponse {
299
515
  /**
300
516
  * Error information
301
517
  */
302
- error?: ErrorDetail | null;
518
+ error?: WebhookListEventTypesResponse.Error | null;
303
519
  /**
304
520
  * Request and response metadata
305
521
  */
306
- meta?: APIMeta;
522
+ meta?: WebhookListEventTypesResponse.Meta;
307
523
  /**
308
524
  * Indicates whether the request was successful
309
525
  */
@@ -314,7 +530,57 @@ export declare namespace WebhookListEventTypesResponse {
314
530
  * The response data (null if error)
315
531
  */
316
532
  interface Data {
317
- event_types?: Array<WebhooksAPI.WebhookEventType>;
533
+ event_types?: Array<Data.EventType>;
534
+ }
535
+ namespace Data {
536
+ interface EventType {
537
+ description?: string | null;
538
+ display_name?: string;
539
+ event_type?: string | null;
540
+ is_active?: boolean;
541
+ name?: string;
542
+ sub_types?: Array<unknown> | null;
543
+ }
544
+ }
545
+ /**
546
+ * Error information
547
+ */
548
+ interface Error {
549
+ /**
550
+ * Machine-readable error code (e.g., "RESOURCE_001")
551
+ */
552
+ code?: string;
553
+ /**
554
+ * Additional validation error details (field-level errors)
555
+ */
556
+ details?: {
557
+ [key: string]: Array<string>;
558
+ } | null;
559
+ /**
560
+ * URL to documentation about this error
561
+ */
562
+ doc_url?: string | null;
563
+ /**
564
+ * Human-readable error message
565
+ */
566
+ message?: string;
567
+ }
568
+ /**
569
+ * Request and response metadata
570
+ */
571
+ interface Meta {
572
+ /**
573
+ * Unique identifier for this request (for tracing and support)
574
+ */
575
+ request_id?: string;
576
+ /**
577
+ * Server timestamp when the response was generated
578
+ */
579
+ timestamp?: string;
580
+ /**
581
+ * API version used for this request
582
+ */
583
+ version?: string;
318
584
  }
319
585
  }
320
586
  /**
@@ -328,11 +594,11 @@ export interface WebhookListEventsResponse {
328
594
  /**
329
595
  * Error information
330
596
  */
331
- error?: ErrorDetail | null;
597
+ error?: WebhookListEventsResponse.Error | null;
332
598
  /**
333
599
  * Request and response metadata
334
600
  */
335
- meta?: APIMeta;
601
+ meta?: WebhookListEventsResponse.Meta;
336
602
  /**
337
603
  * Indicates whether the request was successful
338
604
  */
@@ -347,7 +613,7 @@ export declare namespace WebhookListEventsResponse {
347
613
  /**
348
614
  * Pagination metadata for list responses
349
615
  */
350
- pagination?: WebhooksAPI.PaginationMeta;
616
+ pagination?: Data.Pagination;
351
617
  }
352
618
  namespace Data {
353
619
  interface Event {
@@ -363,6 +629,90 @@ export declare namespace WebhookListEventsResponse {
363
629
  processing_started_at?: string | null;
364
630
  response_body?: string | null;
365
631
  }
632
+ /**
633
+ * Pagination metadata for list responses
634
+ */
635
+ interface Pagination {
636
+ /**
637
+ * Cursor-based pagination pointers
638
+ */
639
+ cursors?: Pagination.Cursors | null;
640
+ /**
641
+ * Whether there are more pages after this one
642
+ */
643
+ has_more?: boolean;
644
+ /**
645
+ * Current page number (1-indexed)
646
+ */
647
+ page?: number;
648
+ /**
649
+ * Number of items per page
650
+ */
651
+ page_size?: number;
652
+ /**
653
+ * Total number of items across all pages
654
+ */
655
+ total_count?: number;
656
+ /**
657
+ * Total number of pages
658
+ */
659
+ total_pages?: number;
660
+ }
661
+ namespace Pagination {
662
+ /**
663
+ * Cursor-based pagination pointers
664
+ */
665
+ interface Cursors {
666
+ /**
667
+ * Cursor to fetch the next page
668
+ */
669
+ after?: string | null;
670
+ /**
671
+ * Cursor to fetch the previous page
672
+ */
673
+ before?: string | null;
674
+ }
675
+ }
676
+ }
677
+ /**
678
+ * Error information
679
+ */
680
+ interface Error {
681
+ /**
682
+ * Machine-readable error code (e.g., "RESOURCE_001")
683
+ */
684
+ code?: string;
685
+ /**
686
+ * Additional validation error details (field-level errors)
687
+ */
688
+ details?: {
689
+ [key: string]: Array<string>;
690
+ } | null;
691
+ /**
692
+ * URL to documentation about this error
693
+ */
694
+ doc_url?: string | null;
695
+ /**
696
+ * Human-readable error message
697
+ */
698
+ message?: string;
699
+ }
700
+ /**
701
+ * Request and response metadata
702
+ */
703
+ interface Meta {
704
+ /**
705
+ * Unique identifier for this request (for tracing and support)
706
+ */
707
+ request_id?: string;
708
+ /**
709
+ * Server timestamp when the response was generated
710
+ */
711
+ timestamp?: string;
712
+ /**
713
+ * API version used for this request
714
+ */
715
+ version?: string;
366
716
  }
367
717
  }
368
718
  /**
@@ -376,11 +726,11 @@ export interface WebhookRotateSecretResponse {
376
726
  /**
377
727
  * Error information
378
728
  */
379
- error?: ErrorDetail | null;
729
+ error?: WebhookRotateSecretResponse.Error | null;
380
730
  /**
381
731
  * Request and response metadata
382
732
  */
383
- meta?: APIMeta;
733
+ meta?: WebhookRotateSecretResponse.Meta;
384
734
  /**
385
735
  * Indicates whether the request was successful
386
736
  */
@@ -393,6 +743,46 @@ export declare namespace WebhookRotateSecretResponse {
393
743
  interface Data {
394
744
  signing_secret?: string;
395
745
  }
746
+ /**
747
+ * Error information
748
+ */
749
+ interface Error {
750
+ /**
751
+ * Machine-readable error code (e.g., "RESOURCE_001")
752
+ */
753
+ code?: string;
754
+ /**
755
+ * Additional validation error details (field-level errors)
756
+ */
757
+ details?: {
758
+ [key: string]: Array<string>;
759
+ } | null;
760
+ /**
761
+ * URL to documentation about this error
762
+ */
763
+ doc_url?: string | null;
764
+ /**
765
+ * Human-readable error message
766
+ */
767
+ message?: string;
768
+ }
769
+ /**
770
+ * Request and response metadata
771
+ */
772
+ interface Meta {
773
+ /**
774
+ * Unique identifier for this request (for tracing and support)
775
+ */
776
+ request_id?: string;
777
+ /**
778
+ * Server timestamp when the response was generated
779
+ */
780
+ timestamp?: string;
781
+ /**
782
+ * API version used for this request
783
+ */
784
+ version?: string;
785
+ }
396
786
  }
397
787
  /**
398
788
  * Standard API response envelope for all v3 endpoints
@@ -405,11 +795,11 @@ export interface WebhookTestResponse {
405
795
  /**
406
796
  * Error information
407
797
  */
408
- error?: ErrorDetail | null;
798
+ error?: WebhookTestResponse.Error | null;
409
799
  /**
410
800
  * Request and response metadata
411
801
  */
412
- meta?: APIMeta;
802
+ meta?: WebhookTestResponse.Meta;
413
803
  /**
414
804
  * Indicates whether the request was successful
415
805
  */
@@ -423,6 +813,130 @@ export declare namespace WebhookTestResponse {
423
813
  message?: string;
424
814
  success?: boolean;
425
815
  }
816
+ /**
817
+ * Error information
818
+ */
819
+ interface Error {
820
+ /**
821
+ * Machine-readable error code (e.g., "RESOURCE_001")
822
+ */
823
+ code?: string;
824
+ /**
825
+ * Additional validation error details (field-level errors)
826
+ */
827
+ details?: {
828
+ [key: string]: Array<string>;
829
+ } | null;
830
+ /**
831
+ * URL to documentation about this error
832
+ */
833
+ doc_url?: string | null;
834
+ /**
835
+ * Human-readable error message
836
+ */
837
+ message?: string;
838
+ }
839
+ /**
840
+ * Request and response metadata
841
+ */
842
+ interface Meta {
843
+ /**
844
+ * Unique identifier for this request (for tracing and support)
845
+ */
846
+ request_id?: string;
847
+ /**
848
+ * Server timestamp when the response was generated
849
+ */
850
+ timestamp?: string;
851
+ /**
852
+ * API version used for this request
853
+ */
854
+ version?: string;
855
+ }
856
+ }
857
+ /**
858
+ * Standard API response envelope for all v3 endpoints
859
+ */
860
+ export interface WebhookToggleStatusResponse {
861
+ /**
862
+ * The response data (null if error)
863
+ */
864
+ data?: WebhookToggleStatusResponse.Data | null;
865
+ /**
866
+ * Error information
867
+ */
868
+ error?: WebhookToggleStatusResponse.Error | null;
869
+ /**
870
+ * Request and response metadata
871
+ */
872
+ meta?: WebhookToggleStatusResponse.Meta;
873
+ /**
874
+ * Indicates whether the request was successful
875
+ */
876
+ success?: boolean;
877
+ }
878
+ export declare namespace WebhookToggleStatusResponse {
879
+ /**
880
+ * The response data (null if error)
881
+ */
882
+ interface Data {
883
+ id?: string;
884
+ consecutive_failures?: number;
885
+ created_at?: string;
886
+ display_name?: string;
887
+ endpoint_url?: string;
888
+ event_filters?: {
889
+ [key: string]: Array<string>;
890
+ } | null;
891
+ event_types?: Array<string>;
892
+ is_active?: boolean;
893
+ last_delivery_attempt_at?: string | null;
894
+ last_successful_delivery_at?: string | null;
895
+ retry_count?: number;
896
+ signing_secret?: string | null;
897
+ timeout_seconds?: number;
898
+ updated_at?: string | null;
899
+ }
900
+ /**
901
+ * Error information
902
+ */
903
+ interface Error {
904
+ /**
905
+ * Machine-readable error code (e.g., "RESOURCE_001")
906
+ */
907
+ code?: string;
908
+ /**
909
+ * Additional validation error details (field-level errors)
910
+ */
911
+ details?: {
912
+ [key: string]: Array<string>;
913
+ } | null;
914
+ /**
915
+ * URL to documentation about this error
916
+ */
917
+ doc_url?: string | null;
918
+ /**
919
+ * Human-readable error message
920
+ */
921
+ message?: string;
922
+ }
923
+ /**
924
+ * Request and response metadata
925
+ */
926
+ interface Meta {
927
+ /**
928
+ * Unique identifier for this request (for tracing and support)
929
+ */
930
+ request_id?: string;
931
+ /**
932
+ * Server timestamp when the response was generated
933
+ */
934
+ timestamp?: string;
935
+ /**
936
+ * API version used for this request
937
+ */
938
+ version?: string;
939
+ }
426
940
  }
427
941
  export interface WebhookCreateParams {
428
942
  /**
@@ -645,6 +1159,6 @@ export interface WebhookToggleStatusParams {
645
1159
  'x-profile-id'?: string;
646
1160
  }
647
1161
  export declare namespace Webhooks {
648
- export { type APIMeta as APIMeta, type APIResponseWebhook as APIResponseWebhook, type ErrorDetail as ErrorDetail, type MutationRequest as MutationRequest, type PaginationMeta as PaginationMeta, type WebhookEventType as WebhookEventType, type WebhookResponse as WebhookResponse, type WebhookListResponse as WebhookListResponse, type WebhookListEventTypesResponse as WebhookListEventTypesResponse, type WebhookListEventsResponse as WebhookListEventsResponse, type WebhookRotateSecretResponse as WebhookRotateSecretResponse, type WebhookTestResponse as WebhookTestResponse, type WebhookCreateParams as WebhookCreateParams, type WebhookRetrieveParams as WebhookRetrieveParams, type WebhookUpdateParams as WebhookUpdateParams, type WebhookListParams as WebhookListParams, type WebhookDeleteParams as WebhookDeleteParams, type WebhookListEventTypesParams as WebhookListEventTypesParams, type WebhookListEventsParams as WebhookListEventsParams, type WebhookRotateSecretParams as WebhookRotateSecretParams, type WebhookTestParams as WebhookTestParams, type WebhookToggleStatusParams as WebhookToggleStatusParams, };
1162
+ export { type WebhookCreateResponse as WebhookCreateResponse, type WebhookRetrieveResponse as WebhookRetrieveResponse, type WebhookUpdateResponse as WebhookUpdateResponse, type WebhookListResponse as WebhookListResponse, type WebhookListEventTypesResponse as WebhookListEventTypesResponse, type WebhookListEventsResponse as WebhookListEventsResponse, type WebhookRotateSecretResponse as WebhookRotateSecretResponse, type WebhookTestResponse as WebhookTestResponse, type WebhookToggleStatusResponse as WebhookToggleStatusResponse, type WebhookCreateParams as WebhookCreateParams, type WebhookRetrieveParams as WebhookRetrieveParams, type WebhookUpdateParams as WebhookUpdateParams, type WebhookListParams as WebhookListParams, type WebhookDeleteParams as WebhookDeleteParams, type WebhookListEventTypesParams as WebhookListEventTypesParams, type WebhookListEventsParams as WebhookListEventsParams, type WebhookRotateSecretParams as WebhookRotateSecretParams, type WebhookTestParams as WebhookTestParams, type WebhookToggleStatusParams as WebhookToggleStatusParams, };
649
1163
  }
650
1164
  //# sourceMappingURL=webhooks.d.ts.map