@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,8 +1,6 @@
1
1
  // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
2
 
3
3
  import { APIResource } from '../core/resource';
4
- import * as TemplatesAPI from './templates';
5
- import * as WebhooksAPI from './webhooks';
6
4
  import { APIPromise } from '../core/api-promise';
7
5
  import { buildHeaders } from '../internal/headers';
8
6
  import { RequestOptions } from '../internal/request-options';
@@ -19,10 +17,10 @@ export class Templates extends APIResource {
19
17
  *
20
18
  * @example
21
19
  * ```ts
22
- * const apiResponseTemplate = await client.templates.create();
20
+ * const template = await client.templates.create();
23
21
  * ```
24
22
  */
25
- create(params: TemplateCreateParams, options?: RequestOptions): APIPromise<APIResponseTemplate> {
23
+ create(params: TemplateCreateParams, options?: RequestOptions): APIPromise<TemplateCreateResponse> {
26
24
  const { 'Idempotency-Key': idempotencyKey, 'x-profile-id': xProfileID, ...body } = params;
27
25
  return this._client.post('/v3/templates', {
28
26
  body,
@@ -43,7 +41,7 @@ export class Templates extends APIResource {
43
41
  *
44
42
  * @example
45
43
  * ```ts
46
- * const apiResponseTemplate = await client.templates.retrieve(
44
+ * const template = await client.templates.retrieve(
47
45
  * '7ba7b820-9dad-11d1-80b4-00c04fd430c8',
48
46
  * );
49
47
  * ```
@@ -52,7 +50,7 @@ export class Templates extends APIResource {
52
50
  id: string,
53
51
  params: TemplateRetrieveParams | null | undefined = {},
54
52
  options?: RequestOptions,
55
- ): APIPromise<APIResponseTemplate> {
53
+ ): APIPromise<TemplateRetrieveResponse> {
56
54
  const { 'x-profile-id': xProfileID } = params ?? {};
57
55
  return this._client.get(path`/v3/templates/${id}`, {
58
56
  ...options,
@@ -69,7 +67,7 @@ export class Templates extends APIResource {
69
67
  *
70
68
  * @example
71
69
  * ```ts
72
- * const apiResponseTemplate = await client.templates.update(
70
+ * const template = await client.templates.update(
73
71
  * '7ba7b820-9dad-11d1-80b4-00c04fd430c8',
74
72
  * );
75
73
  * ```
@@ -78,7 +76,7 @@ export class Templates extends APIResource {
78
76
  id: string,
79
77
  params: TemplateUpdateParams,
80
78
  options?: RequestOptions,
81
- ): APIPromise<APIResponseTemplate> {
79
+ ): APIPromise<TemplateUpdateResponse> {
82
80
  const { 'Idempotency-Key': idempotencyKey, 'x-profile-id': xProfileID, ...body } = params;
83
81
  return this._client.put(path`/v3/templates/${id}`, {
84
82
  body,
@@ -144,21 +142,21 @@ export class Templates extends APIResource {
144
142
  /**
145
143
  * Standard API response envelope for all v3 endpoints
146
144
  */
147
- export interface APIResponseTemplate {
145
+ export interface TemplateCreateResponse {
148
146
  /**
149
147
  * Template response for v3 API
150
148
  */
151
- data?: Template | null;
149
+ data?: TemplateCreateResponse.Data | null;
152
150
 
153
151
  /**
154
152
  * Error information
155
153
  */
156
- error?: WebhooksAPI.ErrorDetail | null;
154
+ error?: TemplateCreateResponse.Error | null;
157
155
 
158
156
  /**
159
157
  * Request and response metadata
160
158
  */
161
- meta?: WebhooksAPI.APIMeta;
159
+ meta?: TemplateCreateResponse.Meta;
162
160
 
163
161
  /**
164
162
  * Indicates whether the request was successful
@@ -166,256 +164,359 @@ export interface APIResponseTemplate {
166
164
  success?: boolean;
167
165
  }
168
166
 
169
- /**
170
- * Configuration for AUTHENTICATION category templates
171
- */
172
- export interface SentDmServicesCommonContractsPocOsAuthenticationConfig {
173
- /**
174
- * Whether to add the security recommendation text: "For your security, do not
175
- * share this code."
176
- */
177
- addSecurityRecommendation?: boolean;
178
-
179
- /**
180
- * Code expiration time in minutes (1-90). If set, adds footer: "This code expires
181
- * in X minutes."
182
- */
183
- codeExpirationMinutes?: number | null;
184
- }
185
-
186
- /**
187
- * Body section of a message template with channel-specific content
188
- */
189
- export interface SentDmServicesCommonContractsPocOsTemplateBody {
190
- /**
191
- * Content that will be used for all channels (SMS and WhatsApp) unless
192
- * channel-specific content is provided
193
- */
194
- multiChannel?: TemplateBodyContent | null;
195
-
167
+ export namespace TemplateCreateResponse {
196
168
  /**
197
- * SMS-specific content that overrides multi-channel content for SMS messages
169
+ * Template response for v3 API
198
170
  */
199
- sms?: TemplateBodyContent | null;
171
+ export interface Data {
172
+ /**
173
+ * Unique template identifier
174
+ */
175
+ id?: string;
200
176
 
201
- /**
202
- * WhatsApp-specific content that overrides multi-channel content for WhatsApp
203
- * messages
204
- */
205
- whatsapp?: TemplateBodyContent | null;
206
- }
177
+ /**
178
+ * Template category: MARKETING, UTILITY, AUTHENTICATION
179
+ */
180
+ category?: string;
207
181
 
208
- /**
209
- * Interactive button in a message template
210
- */
211
- export interface SentDmServicesCommonContractsPocOsTemplateButton {
212
- /**
213
- * Properties specific to the button type
214
- */
215
- props: SentDmServicesCommonContractsPocOsTemplateButtonProps;
182
+ /**
183
+ * Supported channels: sms, whatsapp
184
+ */
185
+ channels?: Array<string> | null;
216
186
 
217
- /**
218
- * The type of button (e.g., QUICK_REPLY, URL, PHONE_NUMBER, VOICE_CALL, COPY_CODE)
219
- */
220
- type: string;
187
+ /**
188
+ * When the template was created
189
+ */
190
+ created_at?: string;
221
191
 
222
- /**
223
- * The unique identifier of the button (1-based index)
224
- */
225
- id?: number;
226
- }
192
+ /**
193
+ * Whether the template is published and active
194
+ */
195
+ is_published?: boolean;
227
196
 
228
- export interface SentDmServicesCommonContractsPocOsTemplateButtonProps {
229
- activeFor: number;
197
+ /**
198
+ * Template language code (e.g., en_US)
199
+ */
200
+ language?: string;
230
201
 
231
- countryCode: string;
202
+ /**
203
+ * Template display name
204
+ */
205
+ name?: string;
232
206
 
233
- offerCode: string;
207
+ /**
208
+ * Template status: APPROVED, PENDING, REJECTED
209
+ */
210
+ status?: string;
234
211
 
235
- phoneNumber: string;
212
+ /**
213
+ * When the template was last updated
214
+ */
215
+ updated_at?: string | null;
236
216
 
237
- quickReplyType: string;
217
+ /**
218
+ * Template variables for personalization
219
+ */
220
+ variables?: Array<string> | null;
221
+ }
238
222
 
239
- text: string;
223
+ /**
224
+ * Error information
225
+ */
226
+ export interface Error {
227
+ /**
228
+ * Machine-readable error code (e.g., "RESOURCE_001")
229
+ */
230
+ code?: string;
240
231
 
241
- url: string;
232
+ /**
233
+ * Additional validation error details (field-level errors)
234
+ */
235
+ details?: { [key: string]: Array<string> } | null;
242
236
 
243
- urlType: string;
237
+ /**
238
+ * URL to documentation about this error
239
+ */
240
+ doc_url?: string | null;
244
241
 
245
- autofillText?: string | null;
242
+ /**
243
+ * Human-readable error message
244
+ */
245
+ message?: string;
246
+ }
246
247
 
247
- otpType?: string | null;
248
+ /**
249
+ * Request and response metadata
250
+ */
251
+ export interface Meta {
252
+ /**
253
+ * Unique identifier for this request (for tracing and support)
254
+ */
255
+ request_id?: string;
248
256
 
249
- packageName?: string | null;
257
+ /**
258
+ * Server timestamp when the response was generated
259
+ */
260
+ timestamp?: string;
250
261
 
251
- signatureHash?: string | null;
262
+ /**
263
+ * API version used for this request
264
+ */
265
+ version?: string;
266
+ }
252
267
  }
253
268
 
254
269
  /**
255
- * Footer section of a message template
270
+ * Standard API response envelope for all v3 endpoints
256
271
  */
257
- export interface SentDmServicesCommonContractsPocOsTemplateFooter {
272
+ export interface TemplateRetrieveResponse {
258
273
  /**
259
- * The footer template text with optional variable placeholders
274
+ * Template response for v3 API
260
275
  */
261
- template: string;
276
+ data?: TemplateRetrieveResponse.Data | null;
262
277
 
263
278
  /**
264
- * The type of footer (typically "text")
279
+ * Error information
265
280
  */
266
- type?: string | null;
281
+ error?: TemplateRetrieveResponse.Error | null;
267
282
 
268
283
  /**
269
- * List of variables used in the footer template
284
+ * Request and response metadata
270
285
  */
271
- variables?: Array<TemplateVariable> | null;
272
- }
286
+ meta?: TemplateRetrieveResponse.Meta;
273
287
 
274
- /**
275
- * Header section of a message template
276
- */
277
- export interface SentDmServicesCommonContractsPocOsTemplateHeader {
278
288
  /**
279
- * The header template text with optional variable placeholders (e.g., "Welcome to
280
- * {{0:variable}}")
289
+ * Indicates whether the request was successful
281
290
  */
282
- template: string;
291
+ success?: boolean;
292
+ }
283
293
 
294
+ export namespace TemplateRetrieveResponse {
284
295
  /**
285
- * The type of header (e.g., "text", "image", "video", "document")
296
+ * Template response for v3 API
286
297
  */
287
- type?: string | null;
298
+ export interface Data {
299
+ /**
300
+ * Unique template identifier
301
+ */
302
+ id?: string;
288
303
 
289
- /**
290
- * List of variables used in the header template
291
- */
292
- variables?: Array<TemplateVariable> | null;
293
- }
304
+ /**
305
+ * Template category: MARKETING, UTILITY, AUTHENTICATION
306
+ */
307
+ category?: string;
294
308
 
295
- /**
296
- * Template response for v3 API
297
- */
298
- export interface Template {
299
- /**
300
- * Unique template identifier
301
- */
302
- id?: string;
309
+ /**
310
+ * Supported channels: sms, whatsapp
311
+ */
312
+ channels?: Array<string> | null;
303
313
 
304
- /**
305
- * Template category: MARKETING, UTILITY, AUTHENTICATION
306
- */
307
- category?: string;
314
+ /**
315
+ * When the template was created
316
+ */
317
+ created_at?: string;
308
318
 
309
- /**
310
- * Supported channels: sms, whatsapp
311
- */
312
- channels?: Array<string> | null;
319
+ /**
320
+ * Whether the template is published and active
321
+ */
322
+ is_published?: boolean;
313
323
 
314
- /**
315
- * When the template was created
316
- */
317
- created_at?: string;
324
+ /**
325
+ * Template language code (e.g., en_US)
326
+ */
327
+ language?: string;
318
328
 
319
- /**
320
- * Whether the template is published and active
321
- */
322
- is_published?: boolean;
329
+ /**
330
+ * Template display name
331
+ */
332
+ name?: string;
323
333
 
324
- /**
325
- * Template language code (e.g., en_US)
326
- */
327
- language?: string;
334
+ /**
335
+ * Template status: APPROVED, PENDING, REJECTED
336
+ */
337
+ status?: string;
328
338
 
329
- /**
330
- * Template display name
331
- */
332
- name?: string;
339
+ /**
340
+ * When the template was last updated
341
+ */
342
+ updated_at?: string | null;
333
343
 
334
- /**
335
- * Template status: APPROVED, PENDING, REJECTED
336
- */
337
- status?: string;
344
+ /**
345
+ * Template variables for personalization
346
+ */
347
+ variables?: Array<string> | null;
348
+ }
338
349
 
339
350
  /**
340
- * When the template was last updated
351
+ * Error information
341
352
  */
342
- updated_at?: string | null;
353
+ export interface Error {
354
+ /**
355
+ * Machine-readable error code (e.g., "RESOURCE_001")
356
+ */
357
+ code?: string;
358
+
359
+ /**
360
+ * Additional validation error details (field-level errors)
361
+ */
362
+ details?: { [key: string]: Array<string> } | null;
363
+
364
+ /**
365
+ * URL to documentation about this error
366
+ */
367
+ doc_url?: string | null;
368
+
369
+ /**
370
+ * Human-readable error message
371
+ */
372
+ message?: string;
373
+ }
343
374
 
344
375
  /**
345
- * Template variables for personalization
376
+ * Request and response metadata
346
377
  */
347
- variables?: Array<string> | null;
348
- }
349
-
350
- export interface TemplateBodyContent {
351
- template: string;
378
+ export interface Meta {
379
+ /**
380
+ * Unique identifier for this request (for tracing and support)
381
+ */
382
+ request_id?: string;
352
383
 
353
- type?: string | null;
384
+ /**
385
+ * Server timestamp when the response was generated
386
+ */
387
+ timestamp?: string;
354
388
 
355
- variables?: Array<TemplateVariable> | null;
389
+ /**
390
+ * API version used for this request
391
+ */
392
+ version?: string;
393
+ }
356
394
  }
357
395
 
358
396
  /**
359
- * Complete definition of a message template including header, body, footer, and
360
- * buttons
397
+ * Standard API response envelope for all v3 endpoints
361
398
  */
362
- export interface TemplateDefinition {
399
+ export interface TemplateUpdateResponse {
363
400
  /**
364
- * Body section of a message template with channel-specific content
401
+ * Template response for v3 API
365
402
  */
366
- body: SentDmServicesCommonContractsPocOsTemplateBody;
403
+ data?: TemplateUpdateResponse.Data | null;
367
404
 
368
405
  /**
369
- * Configuration for AUTHENTICATION category templates
406
+ * Error information
370
407
  */
371
- authenticationConfig?: SentDmServicesCommonContractsPocOsAuthenticationConfig | null;
408
+ error?: TemplateUpdateResponse.Error | null;
372
409
 
373
410
  /**
374
- * Optional list of interactive buttons (e.g., quick replies, URLs, phone numbers)
411
+ * Request and response metadata
375
412
  */
376
- buttons?: Array<SentDmServicesCommonContractsPocOsTemplateButton> | null;
413
+ meta?: TemplateUpdateResponse.Meta;
377
414
 
378
415
  /**
379
- * The version of the template definition format
416
+ * Indicates whether the request was successful
380
417
  */
381
- definitionVersion?: string | null;
418
+ success?: boolean;
419
+ }
382
420
 
421
+ export namespace TemplateUpdateResponse {
383
422
  /**
384
- * Footer section of a message template
423
+ * Template response for v3 API
385
424
  */
386
- footer?: SentDmServicesCommonContractsPocOsTemplateFooter | null;
425
+ export interface Data {
426
+ /**
427
+ * Unique template identifier
428
+ */
429
+ id?: string;
387
430
 
388
- /**
389
- * Header section of a message template
390
- */
391
- header?: SentDmServicesCommonContractsPocOsTemplateHeader | null;
392
- }
431
+ /**
432
+ * Template category: MARKETING, UTILITY, AUTHENTICATION
433
+ */
434
+ category?: string;
393
435
 
394
- export interface TemplateVariable {
395
- name: string;
436
+ /**
437
+ * Supported channels: sms, whatsapp
438
+ */
439
+ channels?: Array<string> | null;
440
+
441
+ /**
442
+ * When the template was created
443
+ */
444
+ created_at?: string;
396
445
 
397
- props: TemplateVariable.Props;
446
+ /**
447
+ * Whether the template is published and active
448
+ */
449
+ is_published?: boolean;
398
450
 
399
- type: string;
451
+ /**
452
+ * Template language code (e.g., en_US)
453
+ */
454
+ language?: string;
400
455
 
401
- id?: number;
402
- }
456
+ /**
457
+ * Template display name
458
+ */
459
+ name?: string;
403
460
 
404
- export namespace TemplateVariable {
405
- export interface Props {
406
- mediaType: string;
461
+ /**
462
+ * Template status: APPROVED, PENDING, REJECTED
463
+ */
464
+ status?: string;
465
+
466
+ /**
467
+ * When the template was last updated
468
+ */
469
+ updated_at?: string | null;
470
+
471
+ /**
472
+ * Template variables for personalization
473
+ */
474
+ variables?: Array<string> | null;
475
+ }
476
+
477
+ /**
478
+ * Error information
479
+ */
480
+ export interface Error {
481
+ /**
482
+ * Machine-readable error code (e.g., "RESOURCE_001")
483
+ */
484
+ code?: string;
407
485
 
408
- sample: string;
486
+ /**
487
+ * Additional validation error details (field-level errors)
488
+ */
489
+ details?: { [key: string]: Array<string> } | null;
409
490
 
410
- url: string;
491
+ /**
492
+ * URL to documentation about this error
493
+ */
494
+ doc_url?: string | null;
411
495
 
412
- variableType: string;
496
+ /**
497
+ * Human-readable error message
498
+ */
499
+ message?: string;
500
+ }
413
501
 
414
- alt?: string | null;
502
+ /**
503
+ * Request and response metadata
504
+ */
505
+ export interface Meta {
506
+ /**
507
+ * Unique identifier for this request (for tracing and support)
508
+ */
509
+ request_id?: string;
415
510
 
416
- regex?: string | null;
511
+ /**
512
+ * Server timestamp when the response was generated
513
+ */
514
+ timestamp?: string;
417
515
 
418
- shortUrl?: string | null;
516
+ /**
517
+ * API version used for this request
518
+ */
519
+ version?: string;
419
520
  }
420
521
  }
421
522
 
@@ -431,12 +532,12 @@ export interface TemplateListResponse {
431
532
  /**
432
533
  * Error information
433
534
  */
434
- error?: WebhooksAPI.ErrorDetail | null;
535
+ error?: TemplateListResponse.Error | null;
435
536
 
436
537
  /**
437
538
  * Request and response metadata
438
539
  */
439
- meta?: WebhooksAPI.APIMeta;
540
+ meta?: TemplateListResponse.Meta;
440
541
 
441
542
  /**
442
543
  * Indicates whether the request was successful
@@ -452,12 +553,166 @@ export namespace TemplateListResponse {
452
553
  /**
453
554
  * Pagination metadata for list responses
454
555
  */
455
- pagination?: WebhooksAPI.PaginationMeta;
556
+ pagination?: Data.Pagination;
456
557
 
457
558
  /**
458
559
  * List of templates
459
560
  */
460
- templates?: Array<TemplatesAPI.Template>;
561
+ templates?: Array<Data.Template>;
562
+ }
563
+
564
+ export namespace Data {
565
+ /**
566
+ * Pagination metadata for list responses
567
+ */
568
+ export interface Pagination {
569
+ /**
570
+ * Cursor-based pagination pointers
571
+ */
572
+ cursors?: Pagination.Cursors | null;
573
+
574
+ /**
575
+ * Whether there are more pages after this one
576
+ */
577
+ has_more?: boolean;
578
+
579
+ /**
580
+ * Current page number (1-indexed)
581
+ */
582
+ page?: number;
583
+
584
+ /**
585
+ * Number of items per page
586
+ */
587
+ page_size?: number;
588
+
589
+ /**
590
+ * Total number of items across all pages
591
+ */
592
+ total_count?: number;
593
+
594
+ /**
595
+ * Total number of pages
596
+ */
597
+ total_pages?: number;
598
+ }
599
+
600
+ export namespace Pagination {
601
+ /**
602
+ * Cursor-based pagination pointers
603
+ */
604
+ export interface Cursors {
605
+ /**
606
+ * Cursor to fetch the next page
607
+ */
608
+ after?: string | null;
609
+
610
+ /**
611
+ * Cursor to fetch the previous page
612
+ */
613
+ before?: string | null;
614
+ }
615
+ }
616
+
617
+ /**
618
+ * Template response for v3 API
619
+ */
620
+ export interface Template {
621
+ /**
622
+ * Unique template identifier
623
+ */
624
+ id?: string;
625
+
626
+ /**
627
+ * Template category: MARKETING, UTILITY, AUTHENTICATION
628
+ */
629
+ category?: string;
630
+
631
+ /**
632
+ * Supported channels: sms, whatsapp
633
+ */
634
+ channels?: Array<string> | null;
635
+
636
+ /**
637
+ * When the template was created
638
+ */
639
+ created_at?: string;
640
+
641
+ /**
642
+ * Whether the template is published and active
643
+ */
644
+ is_published?: boolean;
645
+
646
+ /**
647
+ * Template language code (e.g., en_US)
648
+ */
649
+ language?: string;
650
+
651
+ /**
652
+ * Template display name
653
+ */
654
+ name?: string;
655
+
656
+ /**
657
+ * Template status: APPROVED, PENDING, REJECTED
658
+ */
659
+ status?: string;
660
+
661
+ /**
662
+ * When the template was last updated
663
+ */
664
+ updated_at?: string | null;
665
+
666
+ /**
667
+ * Template variables for personalization
668
+ */
669
+ variables?: Array<string> | null;
670
+ }
671
+ }
672
+
673
+ /**
674
+ * Error information
675
+ */
676
+ export interface Error {
677
+ /**
678
+ * Machine-readable error code (e.g., "RESOURCE_001")
679
+ */
680
+ code?: string;
681
+
682
+ /**
683
+ * Additional validation error details (field-level errors)
684
+ */
685
+ details?: { [key: string]: Array<string> } | null;
686
+
687
+ /**
688
+ * URL to documentation about this error
689
+ */
690
+ doc_url?: string | null;
691
+
692
+ /**
693
+ * Human-readable error message
694
+ */
695
+ message?: string;
696
+ }
697
+
698
+ /**
699
+ * Request and response metadata
700
+ */
701
+ export interface Meta {
702
+ /**
703
+ * Unique identifier for this request (for tracing and support)
704
+ */
705
+ request_id?: string;
706
+
707
+ /**
708
+ * Server timestamp when the response was generated
709
+ */
710
+ timestamp?: string;
711
+
712
+ /**
713
+ * API version used for this request
714
+ */
715
+ version?: string;
461
716
  }
462
717
  }
463
718
 
@@ -477,7 +732,7 @@ export interface TemplateCreateParams {
477
732
  * Body param: Complete definition of a message template including header, body,
478
733
  * footer, and buttons
479
734
  */
480
- definition?: TemplateDefinition;
735
+ definition?: TemplateCreateParams.Definition;
481
736
 
482
737
  /**
483
738
  * Body param: Template language code (e.g., en_US) (optional, auto-detected if not
@@ -512,25 +767,429 @@ export interface TemplateCreateParams {
512
767
  'x-profile-id'?: string;
513
768
  }
514
769
 
515
- export interface TemplateRetrieveParams {
770
+ export namespace TemplateCreateParams {
516
771
  /**
517
- * Profile UUID to scope the request to a child profile. Only organization API keys
518
- * can use this header. The profile must belong to the calling organization.
772
+ * Complete definition of a message template including header, body, footer, and
773
+ * buttons
519
774
  */
520
- 'x-profile-id'?: string;
521
- }
775
+ export interface Definition {
776
+ /**
777
+ * Body section of a message template with channel-specific content
778
+ */
779
+ body: Definition.Body;
522
780
 
523
- export interface TemplateUpdateParams {
524
- /**
525
- * Body param: Template category: MARKETING, UTILITY, AUTHENTICATION
526
- */
527
- category?: string | null;
781
+ /**
782
+ * Configuration for AUTHENTICATION category templates
783
+ */
784
+ authenticationConfig?: Definition.AuthenticationConfig | null;
785
+
786
+ /**
787
+ * Optional list of interactive buttons (e.g., quick replies, URLs, phone numbers)
788
+ */
789
+ buttons?: Array<Definition.Button> | null;
790
+
791
+ /**
792
+ * The version of the template definition format
793
+ */
794
+ definitionVersion?: string | null;
795
+
796
+ /**
797
+ * Footer section of a message template
798
+ */
799
+ footer?: Definition.Footer | null;
800
+
801
+ /**
802
+ * Header section of a message template
803
+ */
804
+ header?: Definition.Header | null;
805
+ }
806
+
807
+ export namespace Definition {
808
+ /**
809
+ * Body section of a message template with channel-specific content
810
+ */
811
+ export interface Body {
812
+ /**
813
+ * Content that will be used for all channels (SMS and WhatsApp) unless
814
+ * channel-specific content is provided
815
+ */
816
+ multiChannel?: Body.MultiChannel | null;
817
+
818
+ /**
819
+ * RCS-specific content that overrides multi-channel content for RCS messages
820
+ */
821
+ rcs?: Body.Rcs | null;
822
+
823
+ /**
824
+ * SMS-specific content that overrides multi-channel content for SMS messages
825
+ */
826
+ sms?: Body.SMS | null;
827
+
828
+ /**
829
+ * WhatsApp-specific content that overrides multi-channel content for WhatsApp
830
+ * messages
831
+ */
832
+ whatsapp?: Body.Whatsapp | null;
833
+ }
834
+
835
+ export namespace Body {
836
+ /**
837
+ * Content that will be used for all channels (SMS and WhatsApp) unless
838
+ * channel-specific content is provided
839
+ */
840
+ export interface MultiChannel {
841
+ template: string;
842
+
843
+ type?: string | null;
844
+
845
+ variables?: Array<MultiChannel.Variable> | null;
846
+ }
847
+
848
+ export namespace MultiChannel {
849
+ export interface Variable {
850
+ name: string;
851
+
852
+ props: Variable.Props;
853
+
854
+ type: string;
855
+
856
+ id?: number;
857
+ }
858
+
859
+ export namespace Variable {
860
+ export interface Props {
861
+ mediaType: string;
862
+
863
+ sample: string;
864
+
865
+ url: string;
866
+
867
+ variableType: string;
868
+
869
+ alt?: string | null;
870
+
871
+ regex?: string | null;
872
+
873
+ shortUrl?: string | null;
874
+ }
875
+ }
876
+ }
877
+
878
+ /**
879
+ * RCS-specific content that overrides multi-channel content for RCS messages
880
+ */
881
+ export interface Rcs {
882
+ template: string;
883
+
884
+ type?: string | null;
885
+
886
+ variables?: Array<Rcs.Variable> | null;
887
+ }
888
+
889
+ export namespace Rcs {
890
+ export interface Variable {
891
+ name: string;
892
+
893
+ props: Variable.Props;
894
+
895
+ type: string;
896
+
897
+ id?: number;
898
+ }
899
+
900
+ export namespace Variable {
901
+ export interface Props {
902
+ mediaType: string;
903
+
904
+ sample: string;
905
+
906
+ url: string;
907
+
908
+ variableType: string;
909
+
910
+ alt?: string | null;
911
+
912
+ regex?: string | null;
913
+
914
+ shortUrl?: string | null;
915
+ }
916
+ }
917
+ }
918
+
919
+ /**
920
+ * SMS-specific content that overrides multi-channel content for SMS messages
921
+ */
922
+ export interface SMS {
923
+ template: string;
924
+
925
+ type?: string | null;
926
+
927
+ variables?: Array<SMS.Variable> | null;
928
+ }
929
+
930
+ export namespace SMS {
931
+ export interface Variable {
932
+ name: string;
933
+
934
+ props: Variable.Props;
935
+
936
+ type: string;
937
+
938
+ id?: number;
939
+ }
940
+
941
+ export namespace Variable {
942
+ export interface Props {
943
+ mediaType: string;
944
+
945
+ sample: string;
946
+
947
+ url: string;
948
+
949
+ variableType: string;
950
+
951
+ alt?: string | null;
952
+
953
+ regex?: string | null;
954
+
955
+ shortUrl?: string | null;
956
+ }
957
+ }
958
+ }
959
+
960
+ /**
961
+ * WhatsApp-specific content that overrides multi-channel content for WhatsApp
962
+ * messages
963
+ */
964
+ export interface Whatsapp {
965
+ template: string;
966
+
967
+ type?: string | null;
968
+
969
+ variables?: Array<Whatsapp.Variable> | null;
970
+ }
971
+
972
+ export namespace Whatsapp {
973
+ export interface Variable {
974
+ name: string;
975
+
976
+ props: Variable.Props;
977
+
978
+ type: string;
979
+
980
+ id?: number;
981
+ }
982
+
983
+ export namespace Variable {
984
+ export interface Props {
985
+ mediaType: string;
986
+
987
+ sample: string;
988
+
989
+ url: string;
990
+
991
+ variableType: string;
992
+
993
+ alt?: string | null;
994
+
995
+ regex?: string | null;
996
+
997
+ shortUrl?: string | null;
998
+ }
999
+ }
1000
+ }
1001
+ }
1002
+
1003
+ /**
1004
+ * Configuration for AUTHENTICATION category templates
1005
+ */
1006
+ export interface AuthenticationConfig {
1007
+ /**
1008
+ * Whether to add the security recommendation text: "For your security, do not
1009
+ * share this code."
1010
+ */
1011
+ addSecurityRecommendation?: boolean;
1012
+
1013
+ /**
1014
+ * Code expiration time in minutes (1-90). If set, adds footer: "This code expires
1015
+ * in X minutes."
1016
+ */
1017
+ codeExpirationMinutes?: number | null;
1018
+ }
1019
+
1020
+ /**
1021
+ * Interactive button in a message template
1022
+ */
1023
+ export interface Button {
1024
+ /**
1025
+ * Properties specific to the button type
1026
+ */
1027
+ props: Button.Props;
1028
+
1029
+ /**
1030
+ * The type of button (e.g., QUICK_REPLY, URL, PHONE_NUMBER, VOICE_CALL, COPY_CODE)
1031
+ */
1032
+ type: string;
1033
+
1034
+ /**
1035
+ * The unique identifier of the button (1-based index)
1036
+ */
1037
+ id?: number;
1038
+ }
1039
+
1040
+ export namespace Button {
1041
+ /**
1042
+ * Properties specific to the button type
1043
+ */
1044
+ export interface Props {
1045
+ activeFor: number;
1046
+
1047
+ countryCode: string;
1048
+
1049
+ offerCode: string;
1050
+
1051
+ phoneNumber: string;
1052
+
1053
+ quickReplyType: string;
1054
+
1055
+ text: string;
1056
+
1057
+ url: string;
1058
+
1059
+ urlType: string;
1060
+
1061
+ autofillText?: string | null;
1062
+
1063
+ otpType?: string | null;
1064
+
1065
+ packageName?: string | null;
1066
+
1067
+ signatureHash?: string | null;
1068
+ }
1069
+ }
1070
+
1071
+ /**
1072
+ * Footer section of a message template
1073
+ */
1074
+ export interface Footer {
1075
+ /**
1076
+ * The footer template text with optional variable placeholders
1077
+ */
1078
+ template: string;
1079
+
1080
+ /**
1081
+ * The type of footer (typically "text")
1082
+ */
1083
+ type?: string | null;
1084
+
1085
+ /**
1086
+ * List of variables used in the footer template
1087
+ */
1088
+ variables?: Array<Footer.Variable> | null;
1089
+ }
1090
+
1091
+ export namespace Footer {
1092
+ export interface Variable {
1093
+ name: string;
1094
+
1095
+ props: Variable.Props;
1096
+
1097
+ type: string;
1098
+
1099
+ id?: number;
1100
+ }
1101
+
1102
+ export namespace Variable {
1103
+ export interface Props {
1104
+ mediaType: string;
1105
+
1106
+ sample: string;
1107
+
1108
+ url: string;
1109
+
1110
+ variableType: string;
1111
+
1112
+ alt?: string | null;
1113
+
1114
+ regex?: string | null;
1115
+
1116
+ shortUrl?: string | null;
1117
+ }
1118
+ }
1119
+ }
1120
+
1121
+ /**
1122
+ * Header section of a message template
1123
+ */
1124
+ export interface Header {
1125
+ /**
1126
+ * The header template text with optional variable placeholders (e.g., "Welcome to
1127
+ * {{0:variable}}")
1128
+ */
1129
+ template: string;
1130
+
1131
+ /**
1132
+ * The type of header (e.g., "text", "image", "video", "document")
1133
+ */
1134
+ type?: string | null;
1135
+
1136
+ /**
1137
+ * List of variables used in the header template
1138
+ */
1139
+ variables?: Array<Header.Variable> | null;
1140
+ }
1141
+
1142
+ export namespace Header {
1143
+ export interface Variable {
1144
+ name: string;
1145
+
1146
+ props: Variable.Props;
1147
+
1148
+ type: string;
1149
+
1150
+ id?: number;
1151
+ }
1152
+
1153
+ export namespace Variable {
1154
+ export interface Props {
1155
+ mediaType: string;
1156
+
1157
+ sample: string;
1158
+
1159
+ url: string;
1160
+
1161
+ variableType: string;
1162
+
1163
+ alt?: string | null;
1164
+
1165
+ regex?: string | null;
1166
+
1167
+ shortUrl?: string | null;
1168
+ }
1169
+ }
1170
+ }
1171
+ }
1172
+ }
1173
+
1174
+ export interface TemplateRetrieveParams {
1175
+ /**
1176
+ * Profile UUID to scope the request to a child profile. Only organization API keys
1177
+ * can use this header. The profile must belong to the calling organization.
1178
+ */
1179
+ 'x-profile-id'?: string;
1180
+ }
1181
+
1182
+ export interface TemplateUpdateParams {
1183
+ /**
1184
+ * Body param: Template category: MARKETING, UTILITY, AUTHENTICATION
1185
+ */
1186
+ category?: string | null;
528
1187
 
529
1188
  /**
530
1189
  * Body param: Complete definition of a message template including header, body,
531
1190
  * footer, and buttons
532
1191
  */
533
- definition?: TemplateDefinition | null;
1192
+ definition?: TemplateUpdateParams.Definition | null;
534
1193
 
535
1194
  /**
536
1195
  * Body param: Template language code (e.g., en_US)
@@ -569,6 +1228,410 @@ export interface TemplateUpdateParams {
569
1228
  'x-profile-id'?: string;
570
1229
  }
571
1230
 
1231
+ export namespace TemplateUpdateParams {
1232
+ /**
1233
+ * Complete definition of a message template including header, body, footer, and
1234
+ * buttons
1235
+ */
1236
+ export interface Definition {
1237
+ /**
1238
+ * Body section of a message template with channel-specific content
1239
+ */
1240
+ body: Definition.Body;
1241
+
1242
+ /**
1243
+ * Configuration for AUTHENTICATION category templates
1244
+ */
1245
+ authenticationConfig?: Definition.AuthenticationConfig | null;
1246
+
1247
+ /**
1248
+ * Optional list of interactive buttons (e.g., quick replies, URLs, phone numbers)
1249
+ */
1250
+ buttons?: Array<Definition.Button> | null;
1251
+
1252
+ /**
1253
+ * The version of the template definition format
1254
+ */
1255
+ definitionVersion?: string | null;
1256
+
1257
+ /**
1258
+ * Footer section of a message template
1259
+ */
1260
+ footer?: Definition.Footer | null;
1261
+
1262
+ /**
1263
+ * Header section of a message template
1264
+ */
1265
+ header?: Definition.Header | null;
1266
+ }
1267
+
1268
+ export namespace Definition {
1269
+ /**
1270
+ * Body section of a message template with channel-specific content
1271
+ */
1272
+ export interface Body {
1273
+ /**
1274
+ * Content that will be used for all channels (SMS and WhatsApp) unless
1275
+ * channel-specific content is provided
1276
+ */
1277
+ multiChannel?: Body.MultiChannel | null;
1278
+
1279
+ /**
1280
+ * RCS-specific content that overrides multi-channel content for RCS messages
1281
+ */
1282
+ rcs?: Body.Rcs | null;
1283
+
1284
+ /**
1285
+ * SMS-specific content that overrides multi-channel content for SMS messages
1286
+ */
1287
+ sms?: Body.SMS | null;
1288
+
1289
+ /**
1290
+ * WhatsApp-specific content that overrides multi-channel content for WhatsApp
1291
+ * messages
1292
+ */
1293
+ whatsapp?: Body.Whatsapp | null;
1294
+ }
1295
+
1296
+ export namespace Body {
1297
+ /**
1298
+ * Content that will be used for all channels (SMS and WhatsApp) unless
1299
+ * channel-specific content is provided
1300
+ */
1301
+ export interface MultiChannel {
1302
+ template: string;
1303
+
1304
+ type?: string | null;
1305
+
1306
+ variables?: Array<MultiChannel.Variable> | null;
1307
+ }
1308
+
1309
+ export namespace MultiChannel {
1310
+ export interface Variable {
1311
+ name: string;
1312
+
1313
+ props: Variable.Props;
1314
+
1315
+ type: string;
1316
+
1317
+ id?: number;
1318
+ }
1319
+
1320
+ export namespace Variable {
1321
+ export interface Props {
1322
+ mediaType: string;
1323
+
1324
+ sample: string;
1325
+
1326
+ url: string;
1327
+
1328
+ variableType: string;
1329
+
1330
+ alt?: string | null;
1331
+
1332
+ regex?: string | null;
1333
+
1334
+ shortUrl?: string | null;
1335
+ }
1336
+ }
1337
+ }
1338
+
1339
+ /**
1340
+ * RCS-specific content that overrides multi-channel content for RCS messages
1341
+ */
1342
+ export interface Rcs {
1343
+ template: string;
1344
+
1345
+ type?: string | null;
1346
+
1347
+ variables?: Array<Rcs.Variable> | null;
1348
+ }
1349
+
1350
+ export namespace Rcs {
1351
+ export interface Variable {
1352
+ name: string;
1353
+
1354
+ props: Variable.Props;
1355
+
1356
+ type: string;
1357
+
1358
+ id?: number;
1359
+ }
1360
+
1361
+ export namespace Variable {
1362
+ export interface Props {
1363
+ mediaType: string;
1364
+
1365
+ sample: string;
1366
+
1367
+ url: string;
1368
+
1369
+ variableType: string;
1370
+
1371
+ alt?: string | null;
1372
+
1373
+ regex?: string | null;
1374
+
1375
+ shortUrl?: string | null;
1376
+ }
1377
+ }
1378
+ }
1379
+
1380
+ /**
1381
+ * SMS-specific content that overrides multi-channel content for SMS messages
1382
+ */
1383
+ export interface SMS {
1384
+ template: string;
1385
+
1386
+ type?: string | null;
1387
+
1388
+ variables?: Array<SMS.Variable> | null;
1389
+ }
1390
+
1391
+ export namespace SMS {
1392
+ export interface Variable {
1393
+ name: string;
1394
+
1395
+ props: Variable.Props;
1396
+
1397
+ type: string;
1398
+
1399
+ id?: number;
1400
+ }
1401
+
1402
+ export namespace Variable {
1403
+ export interface Props {
1404
+ mediaType: string;
1405
+
1406
+ sample: string;
1407
+
1408
+ url: string;
1409
+
1410
+ variableType: string;
1411
+
1412
+ alt?: string | null;
1413
+
1414
+ regex?: string | null;
1415
+
1416
+ shortUrl?: string | null;
1417
+ }
1418
+ }
1419
+ }
1420
+
1421
+ /**
1422
+ * WhatsApp-specific content that overrides multi-channel content for WhatsApp
1423
+ * messages
1424
+ */
1425
+ export interface Whatsapp {
1426
+ template: string;
1427
+
1428
+ type?: string | null;
1429
+
1430
+ variables?: Array<Whatsapp.Variable> | null;
1431
+ }
1432
+
1433
+ export namespace Whatsapp {
1434
+ export interface Variable {
1435
+ name: string;
1436
+
1437
+ props: Variable.Props;
1438
+
1439
+ type: string;
1440
+
1441
+ id?: number;
1442
+ }
1443
+
1444
+ export namespace Variable {
1445
+ export interface Props {
1446
+ mediaType: string;
1447
+
1448
+ sample: string;
1449
+
1450
+ url: string;
1451
+
1452
+ variableType: string;
1453
+
1454
+ alt?: string | null;
1455
+
1456
+ regex?: string | null;
1457
+
1458
+ shortUrl?: string | null;
1459
+ }
1460
+ }
1461
+ }
1462
+ }
1463
+
1464
+ /**
1465
+ * Configuration for AUTHENTICATION category templates
1466
+ */
1467
+ export interface AuthenticationConfig {
1468
+ /**
1469
+ * Whether to add the security recommendation text: "For your security, do not
1470
+ * share this code."
1471
+ */
1472
+ addSecurityRecommendation?: boolean;
1473
+
1474
+ /**
1475
+ * Code expiration time in minutes (1-90). If set, adds footer: "This code expires
1476
+ * in X minutes."
1477
+ */
1478
+ codeExpirationMinutes?: number | null;
1479
+ }
1480
+
1481
+ /**
1482
+ * Interactive button in a message template
1483
+ */
1484
+ export interface Button {
1485
+ /**
1486
+ * Properties specific to the button type
1487
+ */
1488
+ props: Button.Props;
1489
+
1490
+ /**
1491
+ * The type of button (e.g., QUICK_REPLY, URL, PHONE_NUMBER, VOICE_CALL, COPY_CODE)
1492
+ */
1493
+ type: string;
1494
+
1495
+ /**
1496
+ * The unique identifier of the button (1-based index)
1497
+ */
1498
+ id?: number;
1499
+ }
1500
+
1501
+ export namespace Button {
1502
+ /**
1503
+ * Properties specific to the button type
1504
+ */
1505
+ export interface Props {
1506
+ activeFor: number;
1507
+
1508
+ countryCode: string;
1509
+
1510
+ offerCode: string;
1511
+
1512
+ phoneNumber: string;
1513
+
1514
+ quickReplyType: string;
1515
+
1516
+ text: string;
1517
+
1518
+ url: string;
1519
+
1520
+ urlType: string;
1521
+
1522
+ autofillText?: string | null;
1523
+
1524
+ otpType?: string | null;
1525
+
1526
+ packageName?: string | null;
1527
+
1528
+ signatureHash?: string | null;
1529
+ }
1530
+ }
1531
+
1532
+ /**
1533
+ * Footer section of a message template
1534
+ */
1535
+ export interface Footer {
1536
+ /**
1537
+ * The footer template text with optional variable placeholders
1538
+ */
1539
+ template: string;
1540
+
1541
+ /**
1542
+ * The type of footer (typically "text")
1543
+ */
1544
+ type?: string | null;
1545
+
1546
+ /**
1547
+ * List of variables used in the footer template
1548
+ */
1549
+ variables?: Array<Footer.Variable> | null;
1550
+ }
1551
+
1552
+ export namespace Footer {
1553
+ export interface Variable {
1554
+ name: string;
1555
+
1556
+ props: Variable.Props;
1557
+
1558
+ type: string;
1559
+
1560
+ id?: number;
1561
+ }
1562
+
1563
+ export namespace Variable {
1564
+ export interface Props {
1565
+ mediaType: string;
1566
+
1567
+ sample: string;
1568
+
1569
+ url: string;
1570
+
1571
+ variableType: string;
1572
+
1573
+ alt?: string | null;
1574
+
1575
+ regex?: string | null;
1576
+
1577
+ shortUrl?: string | null;
1578
+ }
1579
+ }
1580
+ }
1581
+
1582
+ /**
1583
+ * Header section of a message template
1584
+ */
1585
+ export interface Header {
1586
+ /**
1587
+ * The header template text with optional variable placeholders (e.g., "Welcome to
1588
+ * {{0:variable}}")
1589
+ */
1590
+ template: string;
1591
+
1592
+ /**
1593
+ * The type of header (e.g., "text", "image", "video", "document")
1594
+ */
1595
+ type?: string | null;
1596
+
1597
+ /**
1598
+ * List of variables used in the header template
1599
+ */
1600
+ variables?: Array<Header.Variable> | null;
1601
+ }
1602
+
1603
+ export namespace Header {
1604
+ export interface Variable {
1605
+ name: string;
1606
+
1607
+ props: Variable.Props;
1608
+
1609
+ type: string;
1610
+
1611
+ id?: number;
1612
+ }
1613
+
1614
+ export namespace Variable {
1615
+ export interface Props {
1616
+ mediaType: string;
1617
+
1618
+ sample: string;
1619
+
1620
+ url: string;
1621
+
1622
+ variableType: string;
1623
+
1624
+ alt?: string | null;
1625
+
1626
+ regex?: string | null;
1627
+
1628
+ shortUrl?: string | null;
1629
+ }
1630
+ }
1631
+ }
1632
+ }
1633
+ }
1634
+
572
1635
  export interface TemplateListParams {
573
1636
  /**
574
1637
  * Query param: Page number (1-indexed)
@@ -631,17 +1694,9 @@ export interface TemplateDeleteParams {
631
1694
 
632
1695
  export declare namespace Templates {
633
1696
  export {
634
- type APIResponseTemplate as APIResponseTemplate,
635
- type SentDmServicesCommonContractsPocOsAuthenticationConfig as SentDmServicesCommonContractsPocOsAuthenticationConfig,
636
- type SentDmServicesCommonContractsPocOsTemplateBody as SentDmServicesCommonContractsPocOsTemplateBody,
637
- type SentDmServicesCommonContractsPocOsTemplateButton as SentDmServicesCommonContractsPocOsTemplateButton,
638
- type SentDmServicesCommonContractsPocOsTemplateButtonProps as SentDmServicesCommonContractsPocOsTemplateButtonProps,
639
- type SentDmServicesCommonContractsPocOsTemplateFooter as SentDmServicesCommonContractsPocOsTemplateFooter,
640
- type SentDmServicesCommonContractsPocOsTemplateHeader as SentDmServicesCommonContractsPocOsTemplateHeader,
641
- type Template as Template,
642
- type TemplateBodyContent as TemplateBodyContent,
643
- type TemplateDefinition as TemplateDefinition,
644
- type TemplateVariable as TemplateVariable,
1697
+ type TemplateCreateResponse as TemplateCreateResponse,
1698
+ type TemplateRetrieveResponse as TemplateRetrieveResponse,
1699
+ type TemplateUpdateResponse as TemplateUpdateResponse,
645
1700
  type TemplateListResponse as TemplateListResponse,
646
1701
  type TemplateCreateParams as TemplateCreateParams,
647
1702
  type TemplateRetrieveParams as TemplateRetrieveParams,