@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
@@ -1,7 +1,8 @@
1
1
  import { APIResource } from "../../core/resource.mjs";
2
2
  import * as ProfilesAPI from "./profiles.mjs";
3
+ import * as WebhooksAPI from "../webhooks.mjs";
3
4
  import * as CampaignsAPI from "./campaigns.mjs";
4
- import { CampaignCreateParams, CampaignCreateResponse, CampaignDeleteParams, CampaignListParams, CampaignListResponse, CampaignUpdateParams, CampaignUpdateResponse, Campaigns, MessagingUseCaseUs } from "./campaigns.mjs";
5
+ import { APIResponseOfBrandCampaign, APIResponseOfListOfBrandCampaign, BrandCampaign, CampaignCreateParams, CampaignData, CampaignDeleteParams, CampaignListParams, CampaignUpdateParams, CampaignUseCase, CampaignUseCaseData, Campaigns, MessagingUseCaseUs } from "./campaigns.mjs";
5
6
  import { APIPromise } from "../../core/api-promise.mjs";
6
7
  import { RequestOptions } from "../../internal/request-options.mjs";
7
8
  /**
@@ -51,7 +52,7 @@ export declare class Profiles extends APIResource {
51
52
  *
52
53
  * @deprecated
53
54
  */
54
- create(params: ProfileCreateParams, options?: RequestOptions): APIPromise<ProfileCreateResponse>;
55
+ create(params: ProfileCreateParams, options?: RequestOptions): APIPromise<APIResponseOfProfileDetail>;
55
56
  /**
56
57
  * **Deprecated.** This endpoint is replaced by `/v3/sender-profiles` and will be
57
58
  * removed in a future release. It still behaves exactly as before, so nothing
@@ -65,7 +66,7 @@ export declare class Profiles extends APIResource {
65
66
  *
66
67
  * @deprecated
67
68
  */
68
- retrieve(profileID: string, params?: ProfileRetrieveParams | null | undefined, options?: RequestOptions): APIPromise<ProfileRetrieveResponse>;
69
+ retrieve(profileID: string, params?: ProfileRetrieveParams | null | undefined, options?: RequestOptions): APIPromise<APIResponseOfProfileDetail>;
69
70
  /**
70
71
  * **Deprecated.** This endpoint is replaced by `/v3/sender-profiles` and will be
71
72
  * removed in a future release. It still behaves exactly as before, so nothing
@@ -108,7 +109,7 @@ export declare class Profiles extends APIResource {
108
109
  *
109
110
  * @deprecated
110
111
  */
111
- update(profileID: string, params: ProfileUpdateParams, options?: RequestOptions): APIPromise<ProfileUpdateResponse>;
112
+ update(profileID: string, params: ProfileUpdateParams, options?: RequestOptions): APIPromise<APIResponseOfProfileDetail>;
112
113
  /**
113
114
  * **Deprecated.** This endpoint is replaced by `/v3/sender-profiles` and will be
114
115
  * removed in a future release. It still behaves exactly as before, so nothing
@@ -189,1660 +190,577 @@ export declare class Profiles extends APIResource {
189
190
  */
190
191
  complete(profileID: string, params: ProfileCompleteParams, options?: RequestOptions): APIPromise<ProfileCompleteResponse>;
191
192
  }
192
- export interface DestinationCountry {
193
- id?: string;
194
- isMain?: boolean;
195
- }
196
- export type TcrBrandRelationship = 'BASIC_ACCOUNT' | 'MEDIUM_ACCOUNT' | 'LARGE_ACCOUNT' | 'SMALL_ACCOUNT' | 'KEY_ACCOUNT';
197
- export type TcrVertical = 'PROFESSIONAL' | 'REAL_ESTATE' | 'HEALTHCARE' | 'HUMAN_RESOURCES' | 'ENERGY' | 'ENTERTAINMENT' | 'RETAIL' | 'TRANSPORTATION' | 'AGRICULTURE' | 'INSURANCE' | 'POSTAL' | 'EDUCATION' | 'HOSPITALITY' | 'FINANCIAL' | 'POLITICAL' | 'GAMBLING' | 'LEGAL' | 'CONSTRUCTION' | 'NGO' | 'MANUFACTURING' | 'GOVERNMENT' | 'TECHNOLOGY' | 'COMMUNICATION';
198
193
  /**
199
194
  * Standard API response envelope for all v3 endpoints
200
195
  */
201
- export interface ProfileCreateResponse {
196
+ export interface APIResponseOfProfileDetail {
202
197
  /**
203
198
  * Detailed profile response for v3 API
204
199
  */
205
- data?: ProfileCreateResponse.Data | null;
200
+ data?: ProfileDetail | null;
206
201
  /**
207
202
  * Error information
208
203
  */
209
- error?: ProfileCreateResponse.Error | null;
204
+ error?: WebhooksAPI.ErrorDetail | null;
210
205
  /**
211
206
  * Request and response metadata
212
207
  */
213
- meta?: ProfileCreateResponse.Meta;
208
+ meta?: WebhooksAPI.APIMeta;
214
209
  /**
215
210
  * Indicates whether the request was successful
216
211
  */
217
212
  success?: boolean;
218
213
  }
219
- export declare namespace ProfileCreateResponse {
214
+ /**
215
+ * Billing contact information for a profile. Required when billing_model is
216
+ * "profile" or "profile_and_organization".
217
+ */
218
+ export interface BillingContactInfo {
220
219
  /**
221
- * Detailed profile response for v3 API
220
+ * Email address where invoices will be sent (required)
222
221
  */
223
- interface Data {
224
- /**
225
- * Profile unique identifier
226
- */
227
- id?: string;
228
- /**
229
- * @deprecated Always false. A profile no longer shares contacts with sibling
230
- * profiles — it sees only what it owns. Retained so existing v3 clients reading
231
- * allow_contact_sharing keep deserializing; it carries no information.
232
- */
233
- allow_contact_sharing?: boolean | null;
234
- /**
235
- * Whether number changes are allowed during onboarding
236
- */
237
- allow_number_change_during_onboarding?: boolean | null;
238
- /**
239
- * @deprecated Always false. A profile no longer shares templates with sibling
240
- * profiles. Retained so existing v3 clients reading allow_template_sharing keep
241
- * deserializing; it carries no information.
242
- */
243
- allow_template_sharing?: boolean | null;
244
- /**
245
- * Billing contact info returned in profile responses
246
- */
247
- billing_contact?: Data.BillingContact | null;
248
- /**
249
- * Billing model: profile, organization, or profile_and_organization
250
- */
251
- billing_model?: string;
252
- /**
253
- * Brand response with nested contact, business, and compliance sections — mirrors
254
- * the request structure.
255
- */
256
- brand?: Data.Brand | null;
257
- /**
258
- * When the profile was created
259
- */
260
- created_at?: string;
261
- /**
262
- * Profile description
263
- */
264
- description?: string | null;
265
- /**
266
- * Profile email (inherited from organization)
267
- */
268
- email?: string | null;
269
- /**
270
- * Profile icon URL
271
- */
272
- icon?: string | null;
273
- /**
274
- * @deprecated Always false. A profile no longer inherits its organization's
275
- * contacts. Retained so existing v3 clients reading inherit_contacts keep
276
- * deserializing; it carries no information.
277
- */
278
- inherit_contacts?: boolean | null;
279
- /**
280
- * Whether this profile inherits TCR brand from the organization
281
- */
282
- inherit_tcr_brand?: boolean;
283
- /**
284
- * Whether this profile inherits TCR campaign from the organization
285
- */
286
- inherit_tcr_campaign?: boolean;
287
- /**
288
- * @deprecated Always false. A profile no longer inherits its organization's
289
- * templates. Retained so existing v3 clients reading inherit_templates keep
290
- * deserializing; it carries no information.
291
- */
292
- inherit_templates?: boolean | null;
293
- /**
294
- * Profile name
295
- */
296
- name?: string;
297
- /**
298
- * Parent organization ID
299
- */
300
- organization_id?: string | null;
301
- /**
302
- * Direct SMS phone number
303
- */
304
- sending_phone_number?: string | null;
305
- /**
306
- * @deprecated Deprecated. Always null. Sender borrowing is gone: a profile no
307
- * longer points at another profile for its SMS sender, and every profile owns the
308
- * sender it sends from.
309
- *
310
- * Kept on the wire, and never populated, because those are two different promises.
311
- * Removing the key changes the response's shape — a generated client loses the
312
- * property and stops compiling on the next regenerate, for a value that is now
313
- * null for every profile in existence. Keeping it null costs a key and breaks
314
- * nobody, and null is the honest answer rather than a placeholder: there is no
315
- * borrowing left to report.
316
- *
317
- * Nothing could populate it. Migration 260813161500 dropped the column and copied
318
- * each borrower its own channel-provider row; its Down() says outright that the
319
- * borrower-to-lender pairing is not recoverable. The only surviving trace is a
320
- * notes string on the copied row.
321
- */
322
- sending_phone_number_profile_id?: string | null;
323
- /**
324
- * @deprecated
325
- */
326
- sending_whatsapp_number_profile_id?: string | null;
327
- /**
328
- * Profile short name/abbreviation. 3–11 characters: letters, numbers, and spaces
329
- * only, with at least one letter.
330
- */
331
- short_name?: string | null;
332
- /**
333
- * Profile setup status: incomplete, pending_review, approved, rejected
334
- */
335
- status?: string;
336
- /**
337
- * When the profile was last updated
338
- */
339
- updated_at?: string | null;
340
- /**
341
- * WhatsApp Business Account ID associated with this profile. Present whether the
342
- * WABA is inherited from the organization or configured directly.
343
- */
344
- waba_id?: string | null;
345
- /**
346
- * Direct WhatsApp phone number
347
- */
348
- whatsapp_phone_number?: string | null;
349
- }
350
- namespace Data {
351
- /**
352
- * Billing contact info returned in profile responses
353
- */
354
- interface BillingContact {
355
- address?: string | null;
356
- email?: string | null;
357
- name?: string | null;
358
- phone?: string | null;
359
- }
360
- /**
361
- * Brand response with nested contact, business, and compliance sections — mirrors
362
- * the request structure.
363
- */
364
- interface Brand {
365
- /**
366
- * Unique identifier for the brand
367
- */
368
- id?: string;
369
- /**
370
- * Business details and address information
371
- */
372
- business?: Brand.Business | null;
373
- /**
374
- * Compliance and TCR-related information
375
- */
376
- compliance?: Brand.Compliance | null;
377
- /**
378
- * Contact information for the brand
379
- */
380
- contact?: Brand.Contact | null;
381
- /**
382
- * When the brand was created
383
- */
384
- created_at?: string;
385
- /**
386
- * @deprecated Deprecated and scheduled for removal. Identifies the Campaign
387
- * Service Provider that registered the brand, which is Sent, so the value is the
388
- * same for every brand and every account. Nothing on your side can act on it and
389
- * there is no replacement. Stop reading it.
390
- */
391
- csp_id?: string | null;
392
- identity_status?: 'SELF_DECLARED' | 'UNVERIFIED' | 'VERIFIED' | 'VETTED_VERIFIED' | null;
393
- /**
394
- * Whether this brand is inherited from the parent organization
395
- */
396
- is_inherited?: boolean;
397
- status?: 'ACTIVE' | 'INACTIVE' | 'SUSPENDED' | null;
398
- /**
399
- * When the brand was submitted to TCR
400
- */
401
- submitted_at?: string | null;
402
- /**
403
- * Whether this brand has been submitted to TCR
404
- */
405
- submitted_to_tcr?: boolean;
406
- /**
407
- * TCR brand ID (populated after TCR submission)
408
- */
409
- tcr_brand_id?: string | null;
410
- /**
411
- * Universal EIN from TCR
412
- */
413
- universal_ein?: string | null;
414
- /**
415
- * When the brand was last updated
416
- */
417
- updated_at?: string | null;
418
- }
419
- namespace Brand {
420
- /**
421
- * Business details and address information
422
- */
423
- interface Business {
424
- /**
425
- * City
426
- */
427
- city?: string | null;
428
- /**
429
- * Country code (e.g., US, CA)
430
- */
431
- country?: string | null;
432
- /**
433
- * Country where the business is registered
434
- */
435
- country_of_registration?: string | null;
436
- /**
437
- * Business entity type
438
- */
439
- entity_type?: string | null;
440
- /**
441
- * Legal business name
442
- */
443
- legal_name?: string | null;
444
- /**
445
- * Postal/ZIP code
446
- */
447
- postal_code?: string | null;
448
- /**
449
- * State/province code
450
- */
451
- state?: string | null;
452
- /**
453
- * Street address
454
- */
455
- street?: string | null;
456
- /**
457
- * Tax ID/EIN number
458
- */
459
- tax_id?: string | null;
460
- /**
461
- * Type of tax ID (e.g., us_ein, ca_bn)
462
- */
463
- tax_id_type?: string | null;
464
- /**
465
- * Business website URL
466
- */
467
- url?: string | null;
468
- }
469
- /**
470
- * Compliance and TCR-related information
471
- */
472
- interface Compliance {
473
- brand_relationship?: ProfilesAPI.TcrBrandRelationship | null;
474
- /**
475
- * List of destination countries for messaging
476
- */
477
- destination_countries?: Array<ProfilesAPI.DestinationCountry>;
478
- /**
479
- * Whether this is a TCR (Campaign Registry) application
480
- */
481
- is_tcr_application?: boolean;
482
- /**
483
- * Additional notes about the business or use case
484
- */
485
- notes?: string | null;
486
- /**
487
- * Phone number prefix for messaging (e.g., "+1")
488
- */
489
- phone_number_prefix?: string | null;
490
- /**
491
- * @deprecated Always null. The brand's free-text primary use case is no longer
492
- * stored: it reached neither TCR nor any decision, and its column is dropped with
493
- * no backfill, because the values were prose and the typed equivalent is the
494
- * campaign's MessagingUseCaseUS.
495
- *
496
- * Retained so existing v3 clients reading primary_use_case keep deserializing.
497
- * Unlike the profile sharing flags, which can answer false truthfully, there is no
498
- * value to report here — the field is present and empty rather than present and
499
- * wrong.
500
- */
501
- primary_use_case?: string | null;
502
- vertical?: ProfilesAPI.TcrVertical | null;
503
- }
504
- /**
505
- * Contact information for the brand
506
- */
507
- interface Contact {
508
- /**
509
- * Business/brand name
510
- */
511
- business_name?: string | null;
512
- /**
513
- * Contact email address
514
- */
515
- email?: string | null;
516
- /**
517
- * Primary contact name
518
- */
519
- name?: string;
520
- /**
521
- * Contact phone number in E.164 format
522
- */
523
- phone?: string | null;
524
- /**
525
- * Contact phone country code (e.g., "1" for US)
526
- */
527
- phone_country_code?: string | null;
528
- /**
529
- * Contact's role in the business
530
- */
531
- role?: string | null;
532
- }
533
- }
534
- }
222
+ email: string;
535
223
  /**
536
- * Error information
224
+ * Full name of the billing contact or company (required)
537
225
  */
538
- interface Error {
539
- /**
540
- * Machine-readable error code (e.g., "RESOURCE_001")
541
- */
542
- code?: string;
543
- /**
544
- * Additional validation error details (field-level errors)
545
- */
546
- details?: {
547
- [key: string]: Array<string>;
548
- } | null;
549
- /**
550
- * URL to documentation about this error
551
- */
552
- doc_url?: string | null;
553
- /**
554
- * Human-readable error message
555
- */
556
- message?: string;
557
- }
226
+ name: string;
558
227
  /**
559
- * Request and response metadata
228
+ * Billing address (optional). Free-form text including street, city, state, postal
229
+ * code, and country.
560
230
  */
561
- interface Meta {
562
- /**
563
- * Unique identifier for this request (for tracing and support)
564
- */
565
- request_id?: string;
566
- /**
567
- * Server timestamp when the response was generated
568
- */
569
- timestamp?: string;
570
- /**
571
- * API version used for this request
572
- */
573
- version?: string;
574
- }
231
+ address?: string | null;
232
+ /**
233
+ * Phone number for the billing contact (optional)
234
+ */
235
+ phone?: string | null;
575
236
  }
576
237
  /**
577
- * Standard API response envelope for all v3 endpoints
238
+ * Business details and address for brand KYC
578
239
  */
579
- export interface ProfileRetrieveResponse {
240
+ export interface BrandBusinessInfo {
580
241
  /**
581
- * Detailed profile response for v3 API
242
+ * City
582
243
  */
583
- data?: ProfileRetrieveResponse.Data | null;
244
+ city?: string | null;
584
245
  /**
585
- * Error information
246
+ * Country code (e.g., US, CA)
586
247
  */
587
- error?: ProfileRetrieveResponse.Error | null;
248
+ country?: string | null;
588
249
  /**
589
- * Request and response metadata
250
+ * Country where the business is registered
590
251
  */
591
- meta?: ProfileRetrieveResponse.Meta;
252
+ countryOfRegistration?: string | null;
253
+ entityType?: 'PRIVATE_PROFIT' | 'PUBLIC_PROFIT' | 'NON_PROFIT' | 'SOLE_PROPRIETOR' | 'GOVERNMENT' | null;
592
254
  /**
593
- * Indicates whether the request was successful
255
+ * Legal business name
594
256
  */
595
- success?: boolean;
257
+ legalName?: string | null;
258
+ /**
259
+ * Postal/ZIP code
260
+ */
261
+ postalCode?: string | null;
262
+ /**
263
+ * State/province code
264
+ */
265
+ state?: string | null;
266
+ /**
267
+ * Street address
268
+ */
269
+ street?: string | null;
270
+ /**
271
+ * Tax ID/EIN number
272
+ */
273
+ taxId?: string | null;
274
+ /**
275
+ * Type of tax ID (e.g., us_ein, ca_bn)
276
+ */
277
+ taxIdType?: string | null;
278
+ /**
279
+ * Business website URL
280
+ */
281
+ url?: string | null;
596
282
  }
597
- export declare namespace ProfileRetrieveResponse {
283
+ /**
284
+ * Compliance and TCR information for brand registration
285
+ */
286
+ export interface BrandComplianceInfo {
287
+ brandRelationship: TcrBrandRelationship;
288
+ vertical: TcrVertical;
598
289
  /**
599
- * Detailed profile response for v3 API
290
+ * List of destination countries for messaging
600
291
  */
601
- interface Data {
602
- /**
603
- * Profile unique identifier
604
- */
605
- id?: string;
606
- /**
607
- * @deprecated Always false. A profile no longer shares contacts with sibling
608
- * profiles — it sees only what it owns. Retained so existing v3 clients reading
609
- * allow_contact_sharing keep deserializing; it carries no information.
610
- */
611
- allow_contact_sharing?: boolean | null;
612
- /**
613
- * Whether number changes are allowed during onboarding
614
- */
615
- allow_number_change_during_onboarding?: boolean | null;
616
- /**
617
- * @deprecated Always false. A profile no longer shares templates with sibling
618
- * profiles. Retained so existing v3 clients reading allow_template_sharing keep
619
- * deserializing; it carries no information.
620
- */
621
- allow_template_sharing?: boolean | null;
622
- /**
623
- * Billing contact info returned in profile responses
624
- */
625
- billing_contact?: Data.BillingContact | null;
626
- /**
627
- * Billing model: profile, organization, or profile_and_organization
628
- */
629
- billing_model?: string;
630
- /**
631
- * Brand response with nested contact, business, and compliance sections — mirrors
632
- * the request structure.
633
- */
634
- brand?: Data.Brand | null;
635
- /**
636
- * When the profile was created
637
- */
638
- created_at?: string;
639
- /**
640
- * Profile description
641
- */
642
- description?: string | null;
643
- /**
644
- * Profile email (inherited from organization)
645
- */
646
- email?: string | null;
647
- /**
648
- * Profile icon URL
649
- */
650
- icon?: string | null;
651
- /**
652
- * @deprecated Always false. A profile no longer inherits its organization's
653
- * contacts. Retained so existing v3 clients reading inherit_contacts keep
654
- * deserializing; it carries no information.
655
- */
656
- inherit_contacts?: boolean | null;
657
- /**
658
- * Whether this profile inherits TCR brand from the organization
659
- */
660
- inherit_tcr_brand?: boolean;
661
- /**
662
- * Whether this profile inherits TCR campaign from the organization
663
- */
664
- inherit_tcr_campaign?: boolean;
665
- /**
666
- * @deprecated Always false. A profile no longer inherits its organization's
667
- * templates. Retained so existing v3 clients reading inherit_templates keep
668
- * deserializing; it carries no information.
669
- */
670
- inherit_templates?: boolean | null;
671
- /**
672
- * Profile name
673
- */
674
- name?: string;
675
- /**
676
- * Parent organization ID
677
- */
678
- organization_id?: string | null;
679
- /**
680
- * Direct SMS phone number
681
- */
682
- sending_phone_number?: string | null;
683
- /**
684
- * @deprecated Deprecated. Always null. Sender borrowing is gone: a profile no
685
- * longer points at another profile for its SMS sender, and every profile owns the
686
- * sender it sends from.
687
- *
688
- * Kept on the wire, and never populated, because those are two different promises.
689
- * Removing the key changes the response's shape — a generated client loses the
690
- * property and stops compiling on the next regenerate, for a value that is now
691
- * null for every profile in existence. Keeping it null costs a key and breaks
692
- * nobody, and null is the honest answer rather than a placeholder: there is no
693
- * borrowing left to report.
694
- *
695
- * Nothing could populate it. Migration 260813161500 dropped the column and copied
696
- * each borrower its own channel-provider row; its Down() says outright that the
697
- * borrower-to-lender pairing is not recoverable. The only surviving trace is a
698
- * notes string on the copied row.
699
- */
700
- sending_phone_number_profile_id?: string | null;
701
- /**
702
- * @deprecated
703
- */
704
- sending_whatsapp_number_profile_id?: string | null;
705
- /**
706
- * Profile short name/abbreviation. 3–11 characters: letters, numbers, and spaces
707
- * only, with at least one letter.
708
- */
709
- short_name?: string | null;
710
- /**
711
- * Profile setup status: incomplete, pending_review, approved, rejected
712
- */
713
- status?: string;
714
- /**
715
- * When the profile was last updated
716
- */
717
- updated_at?: string | null;
718
- /**
719
- * WhatsApp Business Account ID associated with this profile. Present whether the
720
- * WABA is inherited from the organization or configured directly.
721
- */
722
- waba_id?: string | null;
723
- /**
724
- * Direct WhatsApp phone number
725
- */
726
- whatsapp_phone_number?: string | null;
727
- }
728
- namespace Data {
729
- /**
730
- * Billing contact info returned in profile responses
731
- */
732
- interface BillingContact {
733
- address?: string | null;
734
- email?: string | null;
735
- name?: string | null;
736
- phone?: string | null;
737
- }
738
- /**
739
- * Brand response with nested contact, business, and compliance sections — mirrors
740
- * the request structure.
741
- */
742
- interface Brand {
743
- /**
744
- * Unique identifier for the brand
745
- */
746
- id?: string;
747
- /**
748
- * Business details and address information
749
- */
750
- business?: Brand.Business | null;
751
- /**
752
- * Compliance and TCR-related information
753
- */
754
- compliance?: Brand.Compliance | null;
755
- /**
756
- * Contact information for the brand
757
- */
758
- contact?: Brand.Contact | null;
759
- /**
760
- * When the brand was created
761
- */
762
- created_at?: string;
763
- /**
764
- * @deprecated Deprecated and scheduled for removal. Identifies the Campaign
765
- * Service Provider that registered the brand, which is Sent, so the value is the
766
- * same for every brand and every account. Nothing on your side can act on it and
767
- * there is no replacement. Stop reading it.
768
- */
769
- csp_id?: string | null;
770
- identity_status?: 'SELF_DECLARED' | 'UNVERIFIED' | 'VERIFIED' | 'VETTED_VERIFIED' | null;
771
- /**
772
- * Whether this brand is inherited from the parent organization
773
- */
774
- is_inherited?: boolean;
775
- status?: 'ACTIVE' | 'INACTIVE' | 'SUSPENDED' | null;
776
- /**
777
- * When the brand was submitted to TCR
778
- */
779
- submitted_at?: string | null;
780
- /**
781
- * Whether this brand has been submitted to TCR
782
- */
783
- submitted_to_tcr?: boolean;
784
- /**
785
- * TCR brand ID (populated after TCR submission)
786
- */
787
- tcr_brand_id?: string | null;
788
- /**
789
- * Universal EIN from TCR
790
- */
791
- universal_ein?: string | null;
792
- /**
793
- * When the brand was last updated
794
- */
795
- updated_at?: string | null;
796
- }
797
- namespace Brand {
798
- /**
799
- * Business details and address information
800
- */
801
- interface Business {
802
- /**
803
- * City
804
- */
805
- city?: string | null;
806
- /**
807
- * Country code (e.g., US, CA)
808
- */
809
- country?: string | null;
810
- /**
811
- * Country where the business is registered
812
- */
813
- country_of_registration?: string | null;
814
- /**
815
- * Business entity type
816
- */
817
- entity_type?: string | null;
818
- /**
819
- * Legal business name
820
- */
821
- legal_name?: string | null;
822
- /**
823
- * Postal/ZIP code
824
- */
825
- postal_code?: string | null;
826
- /**
827
- * State/province code
828
- */
829
- state?: string | null;
830
- /**
831
- * Street address
832
- */
833
- street?: string | null;
834
- /**
835
- * Tax ID/EIN number
836
- */
837
- tax_id?: string | null;
838
- /**
839
- * Type of tax ID (e.g., us_ein, ca_bn)
840
- */
841
- tax_id_type?: string | null;
842
- /**
843
- * Business website URL
844
- */
845
- url?: string | null;
846
- }
847
- /**
848
- * Compliance and TCR-related information
849
- */
850
- interface Compliance {
851
- brand_relationship?: ProfilesAPI.TcrBrandRelationship | null;
852
- /**
853
- * List of destination countries for messaging
854
- */
855
- destination_countries?: Array<ProfilesAPI.DestinationCountry>;
856
- /**
857
- * Whether this is a TCR (Campaign Registry) application
858
- */
859
- is_tcr_application?: boolean;
860
- /**
861
- * Additional notes about the business or use case
862
- */
863
- notes?: string | null;
864
- /**
865
- * Phone number prefix for messaging (e.g., "+1")
866
- */
867
- phone_number_prefix?: string | null;
868
- /**
869
- * @deprecated Always null. The brand's free-text primary use case is no longer
870
- * stored: it reached neither TCR nor any decision, and its column is dropped with
871
- * no backfill, because the values were prose and the typed equivalent is the
872
- * campaign's MessagingUseCaseUS.
873
- *
874
- * Retained so existing v3 clients reading primary_use_case keep deserializing.
875
- * Unlike the profile sharing flags, which can answer false truthfully, there is no
876
- * value to report here — the field is present and empty rather than present and
877
- * wrong.
878
- */
879
- primary_use_case?: string | null;
880
- vertical?: ProfilesAPI.TcrVertical | null;
881
- }
882
- /**
883
- * Contact information for the brand
884
- */
885
- interface Contact {
886
- /**
887
- * Business/brand name
888
- */
889
- business_name?: string | null;
890
- /**
891
- * Contact email address
892
- */
893
- email?: string | null;
894
- /**
895
- * Primary contact name
896
- */
897
- name?: string;
898
- /**
899
- * Contact phone number in E.164 format
900
- */
901
- phone?: string | null;
902
- /**
903
- * Contact phone country code (e.g., "1" for US)
904
- */
905
- phone_country_code?: string | null;
906
- /**
907
- * Contact's role in the business
908
- */
909
- role?: string | null;
910
- }
911
- }
912
- }
292
+ destinationCountries?: Array<DestinationCountry> | null;
913
293
  /**
914
- * Error information
294
+ * Whether this is a TCR (Campaign Registry) application
915
295
  */
916
- interface Error {
917
- /**
918
- * Machine-readable error code (e.g., "RESOURCE_001")
919
- */
920
- code?: string;
921
- /**
922
- * Additional validation error details (field-level errors)
923
- */
924
- details?: {
925
- [key: string]: Array<string>;
926
- } | null;
927
- /**
928
- * URL to documentation about this error
929
- */
930
- doc_url?: string | null;
931
- /**
932
- * Human-readable error message
933
- */
934
- message?: string;
935
- }
296
+ isTcrApplication?: boolean | null;
936
297
  /**
937
- * Request and response metadata
298
+ * Additional notes about the business or use case
938
299
  */
939
- interface Meta {
940
- /**
941
- * Unique identifier for this request (for tracing and support)
942
- */
943
- request_id?: string;
944
- /**
945
- * Server timestamp when the response was generated
946
- */
947
- timestamp?: string;
948
- /**
949
- * API version used for this request
950
- */
951
- version?: string;
952
- }
300
+ notes?: string | null;
301
+ /**
302
+ * Phone number prefix for messaging (e.g., "+1")
303
+ */
304
+ phoneNumberPrefix?: string | null;
953
305
  }
954
306
  /**
955
- * Standard API response envelope for all v3 endpoints
307
+ * Contact information for brand KYC
956
308
  */
957
- export interface ProfileUpdateResponse {
309
+ export interface BrandContactInfo {
958
310
  /**
959
- * Detailed profile response for v3 API
311
+ * Primary contact name (required)
960
312
  */
961
- data?: ProfileUpdateResponse.Data | null;
313
+ name: string;
962
314
  /**
963
- * Error information
315
+ * Business/brand name
964
316
  */
965
- error?: ProfileUpdateResponse.Error | null;
317
+ businessName?: string | null;
966
318
  /**
967
- * Request and response metadata
319
+ * Contact email address
968
320
  */
969
- meta?: ProfileUpdateResponse.Meta;
321
+ email?: string | null;
970
322
  /**
971
- * Indicates whether the request was successful
323
+ * Contact phone number in E.164 format
972
324
  */
973
- success?: boolean;
325
+ phone?: string | null;
326
+ /**
327
+ * Contact phone country code (e.g., "1" for US)
328
+ */
329
+ phoneCountryCode?: string | null;
330
+ /**
331
+ * Contact's role in the business
332
+ */
333
+ role?: string | null;
334
+ }
335
+ /**
336
+ * Brand and KYC data grouped into contact, business, and compliance sections
337
+ */
338
+ export interface BrandsBrandData {
339
+ /**
340
+ * Compliance and TCR information for brand registration
341
+ */
342
+ compliance: BrandComplianceInfo;
343
+ /**
344
+ * Contact information for brand KYC
345
+ */
346
+ contact: BrandContactInfo;
347
+ /**
348
+ * Business details and address for brand KYC
349
+ */
350
+ business?: BrandBusinessInfo | null;
351
+ }
352
+ export interface DestinationCountry {
353
+ id?: string;
354
+ isMain?: boolean;
355
+ }
356
+ export interface PaymentDetails {
357
+ /**
358
+ * Card number (digits only, 13–19 characters)
359
+ */
360
+ card_number: string;
361
+ /**
362
+ * Card security code (3–4 digits)
363
+ */
364
+ cvc: string;
365
+ /**
366
+ * Card expiry date in MM/YY format (e.g. "09/27")
367
+ */
368
+ expiry: string;
369
+ /**
370
+ * Billing ZIP / postal code associated with the card
371
+ */
372
+ zip_code: string;
373
+ }
374
+ /**
375
+ * Detailed profile response for v3 API
376
+ */
377
+ export interface ProfileDetail {
378
+ /**
379
+ * Profile unique identifier
380
+ */
381
+ id?: string;
382
+ /**
383
+ * @deprecated Always false. A profile no longer shares contacts with sibling
384
+ * profiles — it sees only what it owns. Retained so existing v3 clients reading
385
+ * allow_contact_sharing keep deserializing; it carries no information.
386
+ */
387
+ allow_contact_sharing?: boolean | null;
388
+ /**
389
+ * Whether number changes are allowed during onboarding
390
+ */
391
+ allow_number_change_during_onboarding?: boolean | null;
392
+ /**
393
+ * @deprecated Always false. A profile no longer shares templates with sibling
394
+ * profiles. Retained so existing v3 clients reading allow_template_sharing keep
395
+ * deserializing; it carries no information.
396
+ */
397
+ allow_template_sharing?: boolean | null;
398
+ /**
399
+ * Billing contact info returned in profile responses
400
+ */
401
+ billing_contact?: ProfileDetail.BillingContact | null;
402
+ /**
403
+ * Billing model: profile, organization, or profile_and_organization
404
+ */
405
+ billing_model?: string;
406
+ /**
407
+ * Brand response with nested contact, business, and compliance sections — mirrors
408
+ * the request structure.
409
+ */
410
+ brand?: ProfileDetail.Brand | null;
411
+ /**
412
+ * When the profile was created
413
+ */
414
+ created_at?: string;
415
+ /**
416
+ * Profile description
417
+ */
418
+ description?: string | null;
419
+ /**
420
+ * Profile email (inherited from organization)
421
+ */
422
+ email?: string | null;
423
+ /**
424
+ * Profile icon URL
425
+ */
426
+ icon?: string | null;
427
+ /**
428
+ * @deprecated Always false. A profile no longer inherits its organization's
429
+ * contacts. Retained so existing v3 clients reading inherit_contacts keep
430
+ * deserializing; it carries no information.
431
+ */
432
+ inherit_contacts?: boolean | null;
433
+ /**
434
+ * Whether this profile inherits TCR brand from the organization
435
+ */
436
+ inherit_tcr_brand?: boolean;
437
+ /**
438
+ * Whether this profile inherits TCR campaign from the organization
439
+ */
440
+ inherit_tcr_campaign?: boolean;
441
+ /**
442
+ * @deprecated Always false. A profile no longer inherits its organization's
443
+ * templates. Retained so existing v3 clients reading inherit_templates keep
444
+ * deserializing; it carries no information.
445
+ */
446
+ inherit_templates?: boolean | null;
447
+ /**
448
+ * Profile name
449
+ */
450
+ name?: string;
451
+ /**
452
+ * Parent organization ID
453
+ */
454
+ organization_id?: string | null;
455
+ /**
456
+ * Direct SMS phone number
457
+ */
458
+ sending_phone_number?: string | null;
459
+ /**
460
+ * @deprecated Deprecated. Always null. Sender borrowing is gone: a profile no
461
+ * longer points at another profile for its SMS sender, and every profile owns the
462
+ * sender it sends from.
463
+ *
464
+ * Kept on the wire, and never populated, because those are two different promises.
465
+ * Removing the key changes the response's shape — a generated client loses the
466
+ * property and stops compiling on the next regenerate, for a value that is now
467
+ * null for every profile in existence. Keeping it null costs a key and breaks
468
+ * nobody, and null is the honest answer rather than a placeholder: there is no
469
+ * borrowing left to report.
470
+ *
471
+ * Nothing could populate it. Migration 260813161500 dropped the column and copied
472
+ * each borrower its own channel-provider row; its Down() says outright that the
473
+ * borrower-to-lender pairing is not recoverable. The only surviving trace is a
474
+ * notes string on the copied row.
475
+ */
476
+ sending_phone_number_profile_id?: string | null;
477
+ /**
478
+ * @deprecated
479
+ */
480
+ sending_whatsapp_number_profile_id?: string | null;
481
+ /**
482
+ * Profile short name/abbreviation. 3–11 characters: letters, numbers, and spaces
483
+ * only, with at least one letter.
484
+ */
485
+ short_name?: string | null;
486
+ /**
487
+ * Profile setup status: incomplete, pending_review, approved, rejected
488
+ */
489
+ status?: string;
490
+ /**
491
+ * When the profile was last updated
492
+ */
493
+ updated_at?: string | null;
494
+ /**
495
+ * WhatsApp Business Account ID associated with this profile. Present whether the
496
+ * WABA is inherited from the organization or configured directly.
497
+ */
498
+ waba_id?: string | null;
499
+ /**
500
+ * Direct WhatsApp phone number
501
+ */
502
+ whatsapp_phone_number?: string | null;
974
503
  }
975
- export declare namespace ProfileUpdateResponse {
504
+ export declare namespace ProfileDetail {
505
+ /**
506
+ * Billing contact info returned in profile responses
507
+ */
508
+ interface BillingContact {
509
+ address?: string | null;
510
+ email?: string | null;
511
+ name?: string | null;
512
+ phone?: string | null;
513
+ }
976
514
  /**
977
- * Detailed profile response for v3 API
515
+ * Brand response with nested contact, business, and compliance sections — mirrors
516
+ * the request structure.
978
517
  */
979
- interface Data {
518
+ interface Brand {
980
519
  /**
981
- * Profile unique identifier
520
+ * Unique identifier for the brand
982
521
  */
983
522
  id?: string;
984
523
  /**
985
- * @deprecated Always false. A profile no longer shares contacts with sibling
986
- * profiles — it sees only what it owns. Retained so existing v3 clients reading
987
- * allow_contact_sharing keep deserializing; it carries no information.
988
- */
989
- allow_contact_sharing?: boolean | null;
990
- /**
991
- * Whether number changes are allowed during onboarding
992
- */
993
- allow_number_change_during_onboarding?: boolean | null;
994
- /**
995
- * @deprecated Always false. A profile no longer shares templates with sibling
996
- * profiles. Retained so existing v3 clients reading allow_template_sharing keep
997
- * deserializing; it carries no information.
998
- */
999
- allow_template_sharing?: boolean | null;
1000
- /**
1001
- * Billing contact info returned in profile responses
524
+ * Business details and address information
1002
525
  */
1003
- billing_contact?: Data.BillingContact | null;
526
+ business?: Brand.Business | null;
1004
527
  /**
1005
- * Billing model: profile, organization, or profile_and_organization
528
+ * Compliance and TCR-related information
1006
529
  */
1007
- billing_model?: string;
530
+ compliance?: Brand.Compliance | null;
1008
531
  /**
1009
- * Brand response with nested contact, business, and compliance sections — mirrors
1010
- * the request structure.
532
+ * Contact information for the brand
1011
533
  */
1012
- brand?: Data.Brand | null;
534
+ contact?: Brand.Contact | null;
1013
535
  /**
1014
- * When the profile was created
536
+ * When the brand was created
1015
537
  */
1016
538
  created_at?: string;
1017
539
  /**
1018
- * Profile description
1019
- */
1020
- description?: string | null;
1021
- /**
1022
- * Profile email (inherited from organization)
1023
- */
1024
- email?: string | null;
1025
- /**
1026
- * Profile icon URL
1027
- */
1028
- icon?: string | null;
1029
- /**
1030
- * @deprecated Always false. A profile no longer inherits its organization's
1031
- * contacts. Retained so existing v3 clients reading inherit_contacts keep
1032
- * deserializing; it carries no information.
1033
- */
1034
- inherit_contacts?: boolean | null;
1035
- /**
1036
- * Whether this profile inherits TCR brand from the organization
1037
- */
1038
- inherit_tcr_brand?: boolean;
1039
- /**
1040
- * Whether this profile inherits TCR campaign from the organization
1041
- */
1042
- inherit_tcr_campaign?: boolean;
1043
- /**
1044
- * @deprecated Always false. A profile no longer inherits its organization's
1045
- * templates. Retained so existing v3 clients reading inherit_templates keep
1046
- * deserializing; it carries no information.
1047
- */
1048
- inherit_templates?: boolean | null;
1049
- /**
1050
- * Profile name
1051
- */
1052
- name?: string;
1053
- /**
1054
- * Parent organization ID
540
+ * @deprecated Deprecated and scheduled for removal. Identifies the Campaign
541
+ * Service Provider that registered the brand, which is Sent, so the value is the
542
+ * same for every brand and every account. Nothing on your side can act on it and
543
+ * there is no replacement. Stop reading it.
1055
544
  */
1056
- organization_id?: string | null;
545
+ csp_id?: string | null;
546
+ identity_status?: 'SELF_DECLARED' | 'UNVERIFIED' | 'VERIFIED' | 'VETTED_VERIFIED' | null;
1057
547
  /**
1058
- * Direct SMS phone number
548
+ * Whether this brand is inherited from the parent organization
1059
549
  */
1060
- sending_phone_number?: string | null;
550
+ is_inherited?: boolean;
551
+ status?: 'ACTIVE' | 'INACTIVE' | 'SUSPENDED' | null;
1061
552
  /**
1062
- * @deprecated Deprecated. Always null. Sender borrowing is gone: a profile no
1063
- * longer points at another profile for its SMS sender, and every profile owns the
1064
- * sender it sends from.
1065
- *
1066
- * Kept on the wire, and never populated, because those are two different promises.
1067
- * Removing the key changes the response's shape — a generated client loses the
1068
- * property and stops compiling on the next regenerate, for a value that is now
1069
- * null for every profile in existence. Keeping it null costs a key and breaks
1070
- * nobody, and null is the honest answer rather than a placeholder: there is no
1071
- * borrowing left to report.
1072
- *
1073
- * Nothing could populate it. Migration 260813161500 dropped the column and copied
1074
- * each borrower its own channel-provider row; its Down() says outright that the
1075
- * borrower-to-lender pairing is not recoverable. The only surviving trace is a
1076
- * notes string on the copied row.
553
+ * When the brand was submitted to TCR
1077
554
  */
1078
- sending_phone_number_profile_id?: string | null;
555
+ submitted_at?: string | null;
1079
556
  /**
1080
- * @deprecated
557
+ * Whether this brand has been submitted to TCR
1081
558
  */
1082
- sending_whatsapp_number_profile_id?: string | null;
559
+ submitted_to_tcr?: boolean;
1083
560
  /**
1084
- * Profile short name/abbreviation. 3–11 characters: letters, numbers, and spaces
1085
- * only, with at least one letter.
561
+ * TCR brand ID (populated after TCR submission)
1086
562
  */
1087
- short_name?: string | null;
563
+ tcr_brand_id?: string | null;
1088
564
  /**
1089
- * Profile setup status: incomplete, pending_review, approved, rejected
565
+ * Universal EIN from TCR
1090
566
  */
1091
- status?: string;
567
+ universal_ein?: string | null;
1092
568
  /**
1093
- * When the profile was last updated
569
+ * When the brand was last updated
1094
570
  */
1095
571
  updated_at?: string | null;
1096
- /**
1097
- * WhatsApp Business Account ID associated with this profile. Present whether the
1098
- * WABA is inherited from the organization or configured directly.
1099
- */
1100
- waba_id?: string | null;
1101
- /**
1102
- * Direct WhatsApp phone number
1103
- */
1104
- whatsapp_phone_number?: string | null;
1105
572
  }
1106
- namespace Data {
1107
- /**
1108
- * Billing contact info returned in profile responses
1109
- */
1110
- interface BillingContact {
1111
- address?: string | null;
1112
- email?: string | null;
1113
- name?: string | null;
1114
- phone?: string | null;
1115
- }
573
+ namespace Brand {
1116
574
  /**
1117
- * Brand response with nested contact, business, and compliance sections — mirrors
1118
- * the request structure.
575
+ * Business details and address information
1119
576
  */
1120
- interface Brand {
1121
- /**
1122
- * Unique identifier for the brand
1123
- */
1124
- id?: string;
1125
- /**
1126
- * Business details and address information
1127
- */
1128
- business?: Brand.Business | null;
1129
- /**
1130
- * Compliance and TCR-related information
1131
- */
1132
- compliance?: Brand.Compliance | null;
1133
- /**
1134
- * Contact information for the brand
1135
- */
1136
- contact?: Brand.Contact | null;
577
+ interface Business {
1137
578
  /**
1138
- * When the brand was created
579
+ * City
1139
580
  */
1140
- created_at?: string;
581
+ city?: string | null;
1141
582
  /**
1142
- * @deprecated Deprecated and scheduled for removal. Identifies the Campaign
1143
- * Service Provider that registered the brand, which is Sent, so the value is the
1144
- * same for every brand and every account. Nothing on your side can act on it and
1145
- * there is no replacement. Stop reading it.
583
+ * Country code (e.g., US, CA)
1146
584
  */
1147
- csp_id?: string | null;
1148
- identity_status?: 'SELF_DECLARED' | 'UNVERIFIED' | 'VERIFIED' | 'VETTED_VERIFIED' | null;
585
+ country?: string | null;
1149
586
  /**
1150
- * Whether this brand is inherited from the parent organization
587
+ * Country where the business is registered
1151
588
  */
1152
- is_inherited?: boolean;
1153
- status?: 'ACTIVE' | 'INACTIVE' | 'SUSPENDED' | null;
589
+ country_of_registration?: string | null;
1154
590
  /**
1155
- * When the brand was submitted to TCR
591
+ * Business entity type
1156
592
  */
1157
- submitted_at?: string | null;
593
+ entity_type?: string | null;
1158
594
  /**
1159
- * Whether this brand has been submitted to TCR
595
+ * Legal business name
1160
596
  */
1161
- submitted_to_tcr?: boolean;
597
+ legal_name?: string | null;
1162
598
  /**
1163
- * TCR brand ID (populated after TCR submission)
599
+ * Postal/ZIP code
1164
600
  */
1165
- tcr_brand_id?: string | null;
601
+ postal_code?: string | null;
1166
602
  /**
1167
- * Universal EIN from TCR
603
+ * State/province code
1168
604
  */
1169
- universal_ein?: string | null;
605
+ state?: string | null;
1170
606
  /**
1171
- * When the brand was last updated
607
+ * Street address
1172
608
  */
1173
- updated_at?: string | null;
1174
- }
1175
- namespace Brand {
609
+ street?: string | null;
1176
610
  /**
1177
- * Business details and address information
611
+ * Tax ID/EIN number
1178
612
  */
1179
- interface Business {
1180
- /**
1181
- * City
1182
- */
1183
- city?: string | null;
1184
- /**
1185
- * Country code (e.g., US, CA)
1186
- */
1187
- country?: string | null;
1188
- /**
1189
- * Country where the business is registered
1190
- */
1191
- country_of_registration?: string | null;
1192
- /**
1193
- * Business entity type
1194
- */
1195
- entity_type?: string | null;
1196
- /**
1197
- * Legal business name
1198
- */
1199
- legal_name?: string | null;
1200
- /**
1201
- * Postal/ZIP code
1202
- */
1203
- postal_code?: string | null;
1204
- /**
1205
- * State/province code
1206
- */
1207
- state?: string | null;
1208
- /**
1209
- * Street address
1210
- */
1211
- street?: string | null;
1212
- /**
1213
- * Tax ID/EIN number
1214
- */
1215
- tax_id?: string | null;
1216
- /**
1217
- * Type of tax ID (e.g., us_ein, ca_bn)
1218
- */
1219
- tax_id_type?: string | null;
1220
- /**
1221
- * Business website URL
1222
- */
1223
- url?: string | null;
1224
- }
613
+ tax_id?: string | null;
1225
614
  /**
1226
- * Compliance and TCR-related information
615
+ * Type of tax ID (e.g., us_ein, ca_bn)
1227
616
  */
1228
- interface Compliance {
1229
- brand_relationship?: ProfilesAPI.TcrBrandRelationship | null;
1230
- /**
1231
- * List of destination countries for messaging
1232
- */
1233
- destination_countries?: Array<ProfilesAPI.DestinationCountry>;
1234
- /**
1235
- * Whether this is a TCR (Campaign Registry) application
1236
- */
1237
- is_tcr_application?: boolean;
1238
- /**
1239
- * Additional notes about the business or use case
1240
- */
1241
- notes?: string | null;
1242
- /**
1243
- * Phone number prefix for messaging (e.g., "+1")
1244
- */
1245
- phone_number_prefix?: string | null;
1246
- /**
1247
- * @deprecated Always null. The brand's free-text primary use case is no longer
1248
- * stored: it reached neither TCR nor any decision, and its column is dropped with
1249
- * no backfill, because the values were prose and the typed equivalent is the
1250
- * campaign's MessagingUseCaseUS.
1251
- *
1252
- * Retained so existing v3 clients reading primary_use_case keep deserializing.
1253
- * Unlike the profile sharing flags, which can answer false truthfully, there is no
1254
- * value to report here — the field is present and empty rather than present and
1255
- * wrong.
1256
- */
1257
- primary_use_case?: string | null;
1258
- vertical?: ProfilesAPI.TcrVertical | null;
1259
- }
617
+ tax_id_type?: string | null;
1260
618
  /**
1261
- * Contact information for the brand
619
+ * Business website URL
1262
620
  */
1263
- interface Contact {
1264
- /**
1265
- * Business/brand name
1266
- */
1267
- business_name?: string | null;
1268
- /**
1269
- * Contact email address
1270
- */
1271
- email?: string | null;
1272
- /**
1273
- * Primary contact name
1274
- */
1275
- name?: string;
1276
- /**
1277
- * Contact phone number in E.164 format
1278
- */
1279
- phone?: string | null;
1280
- /**
1281
- * Contact phone country code (e.g., "1" for US)
1282
- */
1283
- phone_country_code?: string | null;
1284
- /**
1285
- * Contact's role in the business
1286
- */
1287
- role?: string | null;
1288
- }
621
+ url?: string | null;
1289
622
  }
1290
- }
1291
- /**
1292
- * Error information
1293
- */
1294
- interface Error {
1295
- /**
1296
- * Machine-readable error code (e.g., "RESOURCE_001")
1297
- */
1298
- code?: string;
1299
- /**
1300
- * Additional validation error details (field-level errors)
1301
- */
1302
- details?: {
1303
- [key: string]: Array<string>;
1304
- } | null;
1305
- /**
1306
- * URL to documentation about this error
1307
- */
1308
- doc_url?: string | null;
1309
- /**
1310
- * Human-readable error message
1311
- */
1312
- message?: string;
1313
- }
1314
- /**
1315
- * Request and response metadata
1316
- */
1317
- interface Meta {
1318
- /**
1319
- * Unique identifier for this request (for tracing and support)
1320
- */
1321
- request_id?: string;
1322
- /**
1323
- * Server timestamp when the response was generated
1324
- */
1325
- timestamp?: string;
1326
- /**
1327
- * API version used for this request
1328
- */
1329
- version?: string;
1330
- }
1331
- }
1332
- /**
1333
- * Standard API response envelope for all v3 endpoints
1334
- */
1335
- export interface ProfileListResponse {
1336
- /**
1337
- * The profiles in the organization.
1338
- */
1339
- data?: ProfileListResponse.Data | null;
1340
- /**
1341
- * Error information
1342
- */
1343
- error?: ProfileListResponse.Error | null;
1344
- /**
1345
- * Request and response metadata
1346
- */
1347
- meta?: ProfileListResponse.Meta;
1348
- /**
1349
- * Indicates whether the request was successful
1350
- */
1351
- success?: boolean;
1352
- }
1353
- export declare namespace ProfileListResponse {
1354
- /**
1355
- * The profiles in the organization.
1356
- */
1357
- interface Data {
1358
- /**
1359
- * Pagination metadata for list responses
1360
- */
1361
- pagination?: Data.Pagination;
1362
- /**
1363
- * The profiles on this page.
1364
- */
1365
- profiles?: Array<Data.Profile>;
1366
- }
1367
- namespace Data {
1368
623
  /**
1369
- * Pagination metadata for list responses
624
+ * Compliance and TCR-related information
1370
625
  */
1371
- interface Pagination {
1372
- /**
1373
- * @deprecated Cursor-based pagination. Never populated — see Cursors.
1374
- */
1375
- cursors?: Pagination.Cursors | null;
1376
- /**
1377
- * Whether there are more pages after this one
1378
- */
1379
- has_more?: boolean;
626
+ interface Compliance {
627
+ brand_relationship?: ProfilesAPI.TcrBrandRelationship | null;
1380
628
  /**
1381
- * Current page number (1-indexed)
629
+ * List of destination countries for messaging
1382
630
  */
1383
- page?: number;
631
+ destination_countries?: Array<ProfilesAPI.DestinationCountry>;
1384
632
  /**
1385
- * Number of items per page
633
+ * Whether this is a TCR (Campaign Registry) application
1386
634
  */
1387
- page_size?: number;
635
+ is_tcr_application?: boolean;
1388
636
  /**
1389
- * Total number of items across all pages
637
+ * Additional notes about the business or use case
1390
638
  */
1391
- total_count?: number;
639
+ notes?: string | null;
1392
640
  /**
1393
- * Total number of pages
641
+ * Phone number prefix for messaging (e.g., "+1")
1394
642
  */
1395
- total_pages?: number;
1396
- }
1397
- namespace Pagination {
643
+ phone_number_prefix?: string | null;
1398
644
  /**
1399
- * @deprecated Cursor-based pagination. Never populated — see Cursors.
645
+ * @deprecated Always null. The brand's free-text primary use case is no longer
646
+ * stored: it reached neither TCR nor any decision, and its column is dropped with
647
+ * no backfill, because the values were prose and the typed equivalent is the
648
+ * campaign's MessagingUseCaseUS.
649
+ *
650
+ * Retained so existing v3 clients reading primary_use_case keep deserializing.
651
+ * Unlike the profile sharing flags, which can answer false truthfully, there is no
652
+ * value to report here — the field is present and empty rather than present and
653
+ * wrong.
1400
654
  */
1401
- interface Cursors {
1402
- /**
1403
- * Cursor to fetch the next page.
1404
- */
1405
- after?: string | null;
1406
- /**
1407
- * Cursor to fetch the previous page.
1408
- */
1409
- before?: string | null;
1410
- }
655
+ primary_use_case?: string | null;
656
+ vertical?: ProfilesAPI.TcrVertical | null;
1411
657
  }
1412
658
  /**
1413
- * Detailed profile response for v3 API
659
+ * Contact information for the brand
1414
660
  */
1415
- interface Profile {
1416
- /**
1417
- * Profile unique identifier
1418
- */
1419
- id?: string;
1420
- /**
1421
- * @deprecated Always false. A profile no longer shares contacts with sibling
1422
- * profiles — it sees only what it owns. Retained so existing v3 clients reading
1423
- * allow_contact_sharing keep deserializing; it carries no information.
1424
- */
1425
- allow_contact_sharing?: boolean | null;
1426
- /**
1427
- * Whether number changes are allowed during onboarding
1428
- */
1429
- allow_number_change_during_onboarding?: boolean | null;
1430
- /**
1431
- * @deprecated Always false. A profile no longer shares templates with sibling
1432
- * profiles. Retained so existing v3 clients reading allow_template_sharing keep
1433
- * deserializing; it carries no information.
1434
- */
1435
- allow_template_sharing?: boolean | null;
1436
- /**
1437
- * Billing contact info returned in profile responses
1438
- */
1439
- billing_contact?: Profile.BillingContact | null;
1440
- /**
1441
- * Billing model: profile, organization, or profile_and_organization
1442
- */
1443
- billing_model?: string;
1444
- /**
1445
- * Brand response with nested contact, business, and compliance sections — mirrors
1446
- * the request structure.
1447
- */
1448
- brand?: Profile.Brand | null;
1449
- /**
1450
- * When the profile was created
1451
- */
1452
- created_at?: string;
661
+ interface Contact {
1453
662
  /**
1454
- * Profile description
663
+ * Business/brand name
1455
664
  */
1456
- description?: string | null;
665
+ business_name?: string | null;
1457
666
  /**
1458
- * Profile email (inherited from organization)
667
+ * Contact email address
1459
668
  */
1460
669
  email?: string | null;
1461
670
  /**
1462
- * Profile icon URL
1463
- */
1464
- icon?: string | null;
1465
- /**
1466
- * @deprecated Always false. A profile no longer inherits its organization's
1467
- * contacts. Retained so existing v3 clients reading inherit_contacts keep
1468
- * deserializing; it carries no information.
1469
- */
1470
- inherit_contacts?: boolean | null;
1471
- /**
1472
- * Whether this profile inherits TCR brand from the organization
1473
- */
1474
- inherit_tcr_brand?: boolean;
1475
- /**
1476
- * Whether this profile inherits TCR campaign from the organization
1477
- */
1478
- inherit_tcr_campaign?: boolean;
1479
- /**
1480
- * @deprecated Always false. A profile no longer inherits its organization's
1481
- * templates. Retained so existing v3 clients reading inherit_templates keep
1482
- * deserializing; it carries no information.
1483
- */
1484
- inherit_templates?: boolean | null;
1485
- /**
1486
- * Profile name
671
+ * Primary contact name
1487
672
  */
1488
673
  name?: string;
1489
674
  /**
1490
- * Parent organization ID
1491
- */
1492
- organization_id?: string | null;
1493
- /**
1494
- * Direct SMS phone number
1495
- */
1496
- sending_phone_number?: string | null;
1497
- /**
1498
- * @deprecated Deprecated. Always null. Sender borrowing is gone: a profile no
1499
- * longer points at another profile for its SMS sender, and every profile owns the
1500
- * sender it sends from.
1501
- *
1502
- * Kept on the wire, and never populated, because those are two different promises.
1503
- * Removing the key changes the response's shape — a generated client loses the
1504
- * property and stops compiling on the next regenerate, for a value that is now
1505
- * null for every profile in existence. Keeping it null costs a key and breaks
1506
- * nobody, and null is the honest answer rather than a placeholder: there is no
1507
- * borrowing left to report.
1508
- *
1509
- * Nothing could populate it. Migration 260813161500 dropped the column and copied
1510
- * each borrower its own channel-provider row; its Down() says outright that the
1511
- * borrower-to-lender pairing is not recoverable. The only surviving trace is a
1512
- * notes string on the copied row.
1513
- */
1514
- sending_phone_number_profile_id?: string | null;
1515
- /**
1516
- * @deprecated
1517
- */
1518
- sending_whatsapp_number_profile_id?: string | null;
1519
- /**
1520
- * Profile short name/abbreviation. 3–11 characters: letters, numbers, and spaces
1521
- * only, with at least one letter.
1522
- */
1523
- short_name?: string | null;
1524
- /**
1525
- * Profile setup status: incomplete, pending_review, approved, rejected
1526
- */
1527
- status?: string;
1528
- /**
1529
- * When the profile was last updated
1530
- */
1531
- updated_at?: string | null;
1532
- /**
1533
- * WhatsApp Business Account ID associated with this profile. Present whether the
1534
- * WABA is inherited from the organization or configured directly.
1535
- */
1536
- waba_id?: string | null;
1537
- /**
1538
- * Direct WhatsApp phone number
675
+ * Contact phone number in E.164 format
1539
676
  */
1540
- whatsapp_phone_number?: string | null;
1541
- }
1542
- namespace Profile {
677
+ phone?: string | null;
1543
678
  /**
1544
- * Billing contact info returned in profile responses
679
+ * Contact phone country code (e.g., "1" for US)
1545
680
  */
1546
- interface BillingContact {
1547
- address?: string | null;
1548
- email?: string | null;
1549
- name?: string | null;
1550
- phone?: string | null;
1551
- }
681
+ phone_country_code?: string | null;
1552
682
  /**
1553
- * Brand response with nested contact, business, and compliance sections — mirrors
1554
- * the request structure.
683
+ * Contact's role in the business
1555
684
  */
1556
- interface Brand {
1557
- /**
1558
- * Unique identifier for the brand
1559
- */
1560
- id?: string;
1561
- /**
1562
- * Business details and address information
1563
- */
1564
- business?: Brand.Business | null;
1565
- /**
1566
- * Compliance and TCR-related information
1567
- */
1568
- compliance?: Brand.Compliance | null;
1569
- /**
1570
- * Contact information for the brand
1571
- */
1572
- contact?: Brand.Contact | null;
1573
- /**
1574
- * When the brand was created
1575
- */
1576
- created_at?: string;
1577
- /**
1578
- * @deprecated Deprecated and scheduled for removal. Identifies the Campaign
1579
- * Service Provider that registered the brand, which is Sent, so the value is the
1580
- * same for every brand and every account. Nothing on your side can act on it and
1581
- * there is no replacement. Stop reading it.
1582
- */
1583
- csp_id?: string | null;
1584
- identity_status?: 'SELF_DECLARED' | 'UNVERIFIED' | 'VERIFIED' | 'VETTED_VERIFIED' | null;
1585
- /**
1586
- * Whether this brand is inherited from the parent organization
1587
- */
1588
- is_inherited?: boolean;
1589
- status?: 'ACTIVE' | 'INACTIVE' | 'SUSPENDED' | null;
1590
- /**
1591
- * When the brand was submitted to TCR
1592
- */
1593
- submitted_at?: string | null;
1594
- /**
1595
- * Whether this brand has been submitted to TCR
1596
- */
1597
- submitted_to_tcr?: boolean;
1598
- /**
1599
- * TCR brand ID (populated after TCR submission)
1600
- */
1601
- tcr_brand_id?: string | null;
1602
- /**
1603
- * Universal EIN from TCR
1604
- */
1605
- universal_ein?: string | null;
1606
- /**
1607
- * When the brand was last updated
1608
- */
1609
- updated_at?: string | null;
1610
- }
1611
- namespace Brand {
1612
- /**
1613
- * Business details and address information
1614
- */
1615
- interface Business {
1616
- /**
1617
- * City
1618
- */
1619
- city?: string | null;
1620
- /**
1621
- * Country code (e.g., US, CA)
1622
- */
1623
- country?: string | null;
1624
- /**
1625
- * Country where the business is registered
1626
- */
1627
- country_of_registration?: string | null;
1628
- /**
1629
- * Business entity type
1630
- */
1631
- entity_type?: string | null;
1632
- /**
1633
- * Legal business name
1634
- */
1635
- legal_name?: string | null;
1636
- /**
1637
- * Postal/ZIP code
1638
- */
1639
- postal_code?: string | null;
1640
- /**
1641
- * State/province code
1642
- */
1643
- state?: string | null;
1644
- /**
1645
- * Street address
1646
- */
1647
- street?: string | null;
1648
- /**
1649
- * Tax ID/EIN number
1650
- */
1651
- tax_id?: string | null;
1652
- /**
1653
- * Type of tax ID (e.g., us_ein, ca_bn)
1654
- */
1655
- tax_id_type?: string | null;
1656
- /**
1657
- * Business website URL
1658
- */
1659
- url?: string | null;
1660
- }
1661
- /**
1662
- * Compliance and TCR-related information
1663
- */
1664
- interface Compliance {
1665
- brand_relationship?: ProfilesAPI.TcrBrandRelationship | null;
1666
- /**
1667
- * List of destination countries for messaging
1668
- */
1669
- destination_countries?: Array<ProfilesAPI.DestinationCountry>;
1670
- /**
1671
- * Whether this is a TCR (Campaign Registry) application
1672
- */
1673
- is_tcr_application?: boolean;
1674
- /**
1675
- * Additional notes about the business or use case
1676
- */
1677
- notes?: string | null;
1678
- /**
1679
- * Phone number prefix for messaging (e.g., "+1")
1680
- */
1681
- phone_number_prefix?: string | null;
1682
- /**
1683
- * @deprecated Always null. The brand's free-text primary use case is no longer
1684
- * stored: it reached neither TCR nor any decision, and its column is dropped with
1685
- * no backfill, because the values were prose and the typed equivalent is the
1686
- * campaign's MessagingUseCaseUS.
1687
- *
1688
- * Retained so existing v3 clients reading primary_use_case keep deserializing.
1689
- * Unlike the profile sharing flags, which can answer false truthfully, there is no
1690
- * value to report here — the field is present and empty rather than present and
1691
- * wrong.
1692
- */
1693
- primary_use_case?: string | null;
1694
- vertical?: ProfilesAPI.TcrVertical | null;
1695
- }
1696
- /**
1697
- * Contact information for the brand
1698
- */
1699
- interface Contact {
1700
- /**
1701
- * Business/brand name
1702
- */
1703
- business_name?: string | null;
1704
- /**
1705
- * Contact email address
1706
- */
1707
- email?: string | null;
1708
- /**
1709
- * Primary contact name
1710
- */
1711
- name?: string;
1712
- /**
1713
- * Contact phone number in E.164 format
1714
- */
1715
- phone?: string | null;
1716
- /**
1717
- * Contact phone country code (e.g., "1" for US)
1718
- */
1719
- phone_country_code?: string | null;
1720
- /**
1721
- * Contact's role in the business
1722
- */
1723
- role?: string | null;
1724
- }
1725
- }
685
+ role?: string | null;
1726
686
  }
1727
687
  }
1728
- /**
1729
- * Error information
1730
- */
1731
- interface Error {
1732
- /**
1733
- * Machine-readable error code (e.g., "RESOURCE_001")
1734
- */
1735
- code?: string;
1736
- /**
1737
- * Additional validation error details (field-level errors)
1738
- */
1739
- details?: {
1740
- [key: string]: Array<string>;
1741
- } | null;
1742
- /**
1743
- * URL to documentation about this error
1744
- */
1745
- doc_url?: string | null;
1746
- /**
1747
- * Human-readable error message
1748
- */
1749
- message?: string;
1750
- }
1751
- /**
1752
- * Request and response metadata
1753
- */
1754
- interface Meta {
1755
- /**
1756
- * Unique identifier for this request (for tracing and support)
1757
- */
1758
- request_id?: string;
1759
- /**
1760
- * Server timestamp when the response was generated
1761
- */
1762
- timestamp?: string;
1763
- /**
1764
- * API version used for this request
1765
- */
1766
- version?: string;
1767
- }
1768
688
  }
689
+ export type TcrBrandRelationship = 'BASIC_ACCOUNT' | 'MEDIUM_ACCOUNT' | 'LARGE_ACCOUNT' | 'SMALL_ACCOUNT' | 'KEY_ACCOUNT';
690
+ export type TcrVertical = 'PROFESSIONAL' | 'REAL_ESTATE' | 'HEALTHCARE' | 'HUMAN_RESOURCES' | 'ENERGY' | 'ENTERTAINMENT' | 'RETAIL' | 'TRANSPORTATION' | 'AGRICULTURE' | 'INSURANCE' | 'POSTAL' | 'EDUCATION' | 'HOSPITALITY' | 'FINANCIAL' | 'POLITICAL' | 'GAMBLING' | 'LEGAL' | 'CONSTRUCTION' | 'NGO' | 'MANUFACTURING' | 'GOVERNMENT' | 'TECHNOLOGY' | 'COMMUNICATION';
1769
691
  /**
1770
692
  * Standard API response envelope for all v3 endpoints
1771
693
  */
1772
- export interface ProfileCompleteResponse {
694
+ export interface ProfileListResponse {
1773
695
  /**
1774
- * Response when a profile is already in the completed state and no further action
1775
- * is taken.
696
+ * The profiles in the organization.
1776
697
  */
1777
- data?: ProfileCompleteResponse.Data | null;
698
+ data?: ProfileListResponse.Data | null;
1778
699
  /**
1779
700
  * Error information
1780
701
  */
1781
- error?: ProfileCompleteResponse.Error | null;
702
+ error?: WebhooksAPI.ErrorDetail | null;
1782
703
  /**
1783
704
  * Request and response metadata
1784
705
  */
1785
- meta?: ProfileCompleteResponse.Meta;
706
+ meta?: WebhooksAPI.APIMeta;
1786
707
  /**
1787
708
  * Indicates whether the request was successful
1788
709
  */
1789
710
  success?: boolean;
1790
711
  }
1791
- export declare namespace ProfileCompleteResponse {
712
+ export declare namespace ProfileListResponse {
1792
713
  /**
1793
- * Response when a profile is already in the completed state and no further action
1794
- * is taken.
714
+ * The profiles in the organization.
1795
715
  */
1796
716
  interface Data {
1797
717
  /**
1798
- * Human-readable message describing the result.
718
+ * Pagination metadata for list responses
1799
719
  */
1800
- message?: string;
720
+ pagination?: WebhooksAPI.PaginationMeta;
1801
721
  /**
1802
- * Current process status of the profile (e.g., "completed", "submitted",
1803
- * "in_progress").
722
+ * The profiles on this page.
1804
723
  */
1805
- status?: string;
724
+ profiles?: Array<ProfilesAPI.ProfileDetail>;
1806
725
  }
726
+ }
727
+ /**
728
+ * Standard API response envelope for all v3 endpoints
729
+ */
730
+ export interface ProfileCompleteResponse {
1807
731
  /**
1808
- * Error information
732
+ * Response when a profile is already in the completed state and no further action
733
+ * is taken.
1809
734
  */
1810
- interface Error {
1811
- /**
1812
- * Machine-readable error code (e.g., "RESOURCE_001")
1813
- */
1814
- code?: string;
1815
- /**
1816
- * Additional validation error details (field-level errors)
1817
- */
1818
- details?: {
1819
- [key: string]: Array<string>;
1820
- } | null;
1821
- /**
1822
- * URL to documentation about this error
1823
- */
1824
- doc_url?: string | null;
1825
- /**
1826
- * Human-readable error message
1827
- */
1828
- message?: string;
1829
- }
735
+ data?: ProfileCompleteResponse.Data | null;
736
+ /**
737
+ * Error information
738
+ */
739
+ error?: WebhooksAPI.ErrorDetail | null;
1830
740
  /**
1831
741
  * Request and response metadata
1832
742
  */
1833
- interface Meta {
1834
- /**
1835
- * Unique identifier for this request (for tracing and support)
1836
- */
1837
- request_id?: string;
743
+ meta?: WebhooksAPI.APIMeta;
744
+ /**
745
+ * Indicates whether the request was successful
746
+ */
747
+ success?: boolean;
748
+ }
749
+ export declare namespace ProfileCompleteResponse {
750
+ /**
751
+ * Response when a profile is already in the completed state and no further action
752
+ * is taken.
753
+ */
754
+ interface Data {
1838
755
  /**
1839
- * Server timestamp when the response was generated
756
+ * Human-readable message describing the result.
1840
757
  */
1841
- timestamp?: string;
758
+ message?: string;
1842
759
  /**
1843
- * API version used for this request
760
+ * Current process status of the profile (e.g., "completed", "submitted",
761
+ * "in_progress").
1844
762
  */
1845
- version?: string;
763
+ status?: string;
1846
764
  }
1847
765
  }
1848
766
  export interface ProfileCreateParams {
@@ -1873,7 +791,7 @@ export interface ProfileCreateParams {
1873
791
  * Body param: Billing contact information for a profile. Required when
1874
792
  * billing_model is "profile" or "profile_and_organization".
1875
793
  */
1876
- billing_contact?: ProfileCreateParams.BillingContact | null;
794
+ billing_contact?: BillingContactInfo | null;
1877
795
  /**
1878
796
  * Body param: Billing model: profile, organization, or profile_and_organization
1879
797
  * (default: profile).
@@ -1889,7 +807,7 @@ export interface ProfileCreateParams {
1889
807
  * Body param: Brand and KYC data grouped into contact, business, and compliance
1890
808
  * sections
1891
809
  */
1892
- brand?: ProfileCreateParams.Brand | null;
810
+ brand?: BrandsBrandData | null;
1893
811
  /**
1894
812
  * Body param: Profile description (optional)
1895
813
  */
@@ -1925,7 +843,7 @@ export interface ProfileCreateParams {
1925
843
  * billing_model is "profile" or "profile_and_organization". Not persisted on our
1926
844
  * servers — forwarded to the payment processor.
1927
845
  */
1928
- payment_details?: ProfileCreateParams.PaymentDetails | null;
846
+ payment_details?: PaymentDetails | null;
1929
847
  /**
1930
848
  * Body param: Sandbox flag - when true, the operation is simulated without side
1931
849
  * effects Useful for testing integrations without actual execution
@@ -1959,169 +877,6 @@ export interface ProfileCreateParams {
1959
877
  'x-profile-id'?: string;
1960
878
  }
1961
879
  export declare namespace ProfileCreateParams {
1962
- /**
1963
- * Billing contact information for a profile. Required when billing_model is
1964
- * "profile" or "profile_and_organization".
1965
- */
1966
- interface BillingContact {
1967
- /**
1968
- * Email address where invoices will be sent (required)
1969
- */
1970
- email: string;
1971
- /**
1972
- * Full name of the billing contact or company (required)
1973
- */
1974
- name: string;
1975
- /**
1976
- * Billing address (optional). Free-form text including street, city, state, postal
1977
- * code, and country.
1978
- */
1979
- address?: string | null;
1980
- /**
1981
- * Phone number for the billing contact (optional)
1982
- */
1983
- phone?: string | null;
1984
- }
1985
- /**
1986
- * Brand and KYC data grouped into contact, business, and compliance sections
1987
- */
1988
- interface Brand {
1989
- /**
1990
- * Compliance and TCR information for brand registration
1991
- */
1992
- compliance: Brand.Compliance;
1993
- /**
1994
- * Contact information for brand KYC
1995
- */
1996
- contact: Brand.Contact;
1997
- /**
1998
- * Business details and address for brand KYC
1999
- */
2000
- business?: Brand.Business | null;
2001
- }
2002
- namespace Brand {
2003
- /**
2004
- * Compliance and TCR information for brand registration
2005
- */
2006
- interface Compliance {
2007
- brandRelationship: ProfilesAPI.TcrBrandRelationship;
2008
- vertical: ProfilesAPI.TcrVertical;
2009
- /**
2010
- * List of destination countries for messaging
2011
- */
2012
- destinationCountries?: Array<ProfilesAPI.DestinationCountry> | null;
2013
- /**
2014
- * Whether this is a TCR (Campaign Registry) application
2015
- */
2016
- isTcrApplication?: boolean | null;
2017
- /**
2018
- * Additional notes about the business or use case
2019
- */
2020
- notes?: string | null;
2021
- /**
2022
- * Phone number prefix for messaging (e.g., "+1")
2023
- */
2024
- phoneNumberPrefix?: string | null;
2025
- }
2026
- /**
2027
- * Contact information for brand KYC
2028
- */
2029
- interface Contact {
2030
- /**
2031
- * Primary contact name (required)
2032
- */
2033
- name: string;
2034
- /**
2035
- * Business/brand name
2036
- */
2037
- businessName?: string | null;
2038
- /**
2039
- * Contact email address
2040
- */
2041
- email?: string | null;
2042
- /**
2043
- * Contact phone number in E.164 format
2044
- */
2045
- phone?: string | null;
2046
- /**
2047
- * Contact phone country code (e.g., "1" for US)
2048
- */
2049
- phoneCountryCode?: string | null;
2050
- /**
2051
- * Contact's role in the business
2052
- */
2053
- role?: string | null;
2054
- }
2055
- /**
2056
- * Business details and address for brand KYC
2057
- */
2058
- interface Business {
2059
- /**
2060
- * City
2061
- */
2062
- city?: string | null;
2063
- /**
2064
- * Country code (e.g., US, CA)
2065
- */
2066
- country?: string | null;
2067
- /**
2068
- * Country where the business is registered
2069
- */
2070
- countryOfRegistration?: string | null;
2071
- entityType?: 'PRIVATE_PROFIT' | 'PUBLIC_PROFIT' | 'NON_PROFIT' | 'SOLE_PROPRIETOR' | 'GOVERNMENT' | null;
2072
- /**
2073
- * Legal business name
2074
- */
2075
- legalName?: string | null;
2076
- /**
2077
- * Postal/ZIP code
2078
- */
2079
- postalCode?: string | null;
2080
- /**
2081
- * State/province code
2082
- */
2083
- state?: string | null;
2084
- /**
2085
- * Street address
2086
- */
2087
- street?: string | null;
2088
- /**
2089
- * Tax ID/EIN number
2090
- */
2091
- taxId?: string | null;
2092
- /**
2093
- * Type of tax ID (e.g., us_ein, ca_bn)
2094
- */
2095
- taxIdType?: string | null;
2096
- /**
2097
- * Business website URL
2098
- */
2099
- url?: string | null;
2100
- }
2101
- }
2102
- /**
2103
- * Payment card details for this profile (optional). Accepted when billing_model is
2104
- * "profile" or "profile_and_organization". Not persisted on our servers —
2105
- * forwarded to the payment processor.
2106
- */
2107
- interface PaymentDetails {
2108
- /**
2109
- * Card number (digits only, 13–19 characters)
2110
- */
2111
- card_number: string;
2112
- /**
2113
- * Card security code (3–4 digits)
2114
- */
2115
- cvc: string;
2116
- /**
2117
- * Card expiry date in MM/YY format (e.g. "09/27")
2118
- */
2119
- expiry: string;
2120
- /**
2121
- * Billing ZIP / postal code associated with the card
2122
- */
2123
- zip_code: string;
2124
- }
2125
880
  /**
2126
881
  * Direct WhatsApp Business Account credentials for a profile. Use this when the
2127
882
  * profile should have its own WhatsApp Business Account instead of inheriting from
@@ -2183,7 +938,7 @@ export interface ProfileUpdateParams {
2183
938
  * Body param: Billing contact information for a profile. Required when
2184
939
  * billing_model is "profile" or "profile_and_organization".
2185
940
  */
2186
- billing_contact?: ProfileUpdateParams.BillingContact | null;
941
+ billing_contact?: BillingContactInfo | null;
2187
942
  /**
2188
943
  * Body param: Billing model: profile, organization, or profile_and_organization
2189
944
  * (optional).
@@ -2199,7 +954,7 @@ export interface ProfileUpdateParams {
2199
954
  * Body param: Brand and KYC data grouped into contact, business, and compliance
2200
955
  * sections
2201
956
  */
2202
- brand?: ProfileUpdateParams.Brand | null;
957
+ brand?: BrandsBrandData | null;
2203
958
  /**
2204
959
  * Body param: Profile description (optional)
2205
960
  */
@@ -2234,7 +989,7 @@ export interface ProfileUpdateParams {
2234
989
  * billing_model is "profile" or "profile_and_organization". Not persisted on our
2235
990
  * servers — forwarded to the payment processor.
2236
991
  */
2237
- payment_details?: ProfileUpdateParams.PaymentDetails | null;
992
+ payment_details?: PaymentDetails | null;
2238
993
  /**
2239
994
  * Body param: Sandbox flag - when true, the operation is simulated without side
2240
995
  * effects Useful for testing integrations without actual execution
@@ -2293,171 +1048,6 @@ export interface ProfileUpdateParams {
2293
1048
  */
2294
1049
  'x-profile-id'?: string;
2295
1050
  }
2296
- export declare namespace ProfileUpdateParams {
2297
- /**
2298
- * Billing contact information for a profile. Required when billing_model is
2299
- * "profile" or "profile_and_organization".
2300
- */
2301
- interface BillingContact {
2302
- /**
2303
- * Email address where invoices will be sent (required)
2304
- */
2305
- email: string;
2306
- /**
2307
- * Full name of the billing contact or company (required)
2308
- */
2309
- name: string;
2310
- /**
2311
- * Billing address (optional). Free-form text including street, city, state, postal
2312
- * code, and country.
2313
- */
2314
- address?: string | null;
2315
- /**
2316
- * Phone number for the billing contact (optional)
2317
- */
2318
- phone?: string | null;
2319
- }
2320
- /**
2321
- * Brand and KYC data grouped into contact, business, and compliance sections
2322
- */
2323
- interface Brand {
2324
- /**
2325
- * Compliance and TCR information for brand registration
2326
- */
2327
- compliance: Brand.Compliance;
2328
- /**
2329
- * Contact information for brand KYC
2330
- */
2331
- contact: Brand.Contact;
2332
- /**
2333
- * Business details and address for brand KYC
2334
- */
2335
- business?: Brand.Business | null;
2336
- }
2337
- namespace Brand {
2338
- /**
2339
- * Compliance and TCR information for brand registration
2340
- */
2341
- interface Compliance {
2342
- brandRelationship: ProfilesAPI.TcrBrandRelationship;
2343
- vertical: ProfilesAPI.TcrVertical;
2344
- /**
2345
- * List of destination countries for messaging
2346
- */
2347
- destinationCountries?: Array<ProfilesAPI.DestinationCountry> | null;
2348
- /**
2349
- * Whether this is a TCR (Campaign Registry) application
2350
- */
2351
- isTcrApplication?: boolean | null;
2352
- /**
2353
- * Additional notes about the business or use case
2354
- */
2355
- notes?: string | null;
2356
- /**
2357
- * Phone number prefix for messaging (e.g., "+1")
2358
- */
2359
- phoneNumberPrefix?: string | null;
2360
- }
2361
- /**
2362
- * Contact information for brand KYC
2363
- */
2364
- interface Contact {
2365
- /**
2366
- * Primary contact name (required)
2367
- */
2368
- name: string;
2369
- /**
2370
- * Business/brand name
2371
- */
2372
- businessName?: string | null;
2373
- /**
2374
- * Contact email address
2375
- */
2376
- email?: string | null;
2377
- /**
2378
- * Contact phone number in E.164 format
2379
- */
2380
- phone?: string | null;
2381
- /**
2382
- * Contact phone country code (e.g., "1" for US)
2383
- */
2384
- phoneCountryCode?: string | null;
2385
- /**
2386
- * Contact's role in the business
2387
- */
2388
- role?: string | null;
2389
- }
2390
- /**
2391
- * Business details and address for brand KYC
2392
- */
2393
- interface Business {
2394
- /**
2395
- * City
2396
- */
2397
- city?: string | null;
2398
- /**
2399
- * Country code (e.g., US, CA)
2400
- */
2401
- country?: string | null;
2402
- /**
2403
- * Country where the business is registered
2404
- */
2405
- countryOfRegistration?: string | null;
2406
- entityType?: 'PRIVATE_PROFIT' | 'PUBLIC_PROFIT' | 'NON_PROFIT' | 'SOLE_PROPRIETOR' | 'GOVERNMENT' | null;
2407
- /**
2408
- * Legal business name
2409
- */
2410
- legalName?: string | null;
2411
- /**
2412
- * Postal/ZIP code
2413
- */
2414
- postalCode?: string | null;
2415
- /**
2416
- * State/province code
2417
- */
2418
- state?: string | null;
2419
- /**
2420
- * Street address
2421
- */
2422
- street?: string | null;
2423
- /**
2424
- * Tax ID/EIN number
2425
- */
2426
- taxId?: string | null;
2427
- /**
2428
- * Type of tax ID (e.g., us_ein, ca_bn)
2429
- */
2430
- taxIdType?: string | null;
2431
- /**
2432
- * Business website URL
2433
- */
2434
- url?: string | null;
2435
- }
2436
- }
2437
- /**
2438
- * Payment card details for this profile (optional). Accepted when billing_model is
2439
- * "profile" or "profile_and_organization". Not persisted on our servers —
2440
- * forwarded to the payment processor.
2441
- */
2442
- interface PaymentDetails {
2443
- /**
2444
- * Card number (digits only, 13–19 characters)
2445
- */
2446
- card_number: string;
2447
- /**
2448
- * Card security code (3–4 digits)
2449
- */
2450
- cvc: string;
2451
- /**
2452
- * Card expiry date in MM/YY format (e.g. "09/27")
2453
- */
2454
- expiry: string;
2455
- /**
2456
- * Billing ZIP / postal code associated with the card
2457
- */
2458
- zip_code: string;
2459
- }
2460
- }
2461
1051
  export interface ProfileListParams {
2462
1052
  /**
2463
1053
  * Profile UUID to scope the request to a child profile. Only organization API keys
@@ -2503,7 +1093,7 @@ export interface ProfileCompleteParams {
2503
1093
  'x-profile-id'?: string;
2504
1094
  }
2505
1095
  export declare namespace Profiles {
2506
- export { type DestinationCountry as DestinationCountry, type TcrBrandRelationship as TcrBrandRelationship, type TcrVertical as TcrVertical, type ProfileCreateResponse as ProfileCreateResponse, type ProfileRetrieveResponse as ProfileRetrieveResponse, type ProfileUpdateResponse as ProfileUpdateResponse, type ProfileListResponse as ProfileListResponse, type ProfileCompleteResponse as ProfileCompleteResponse, type ProfileCreateParams as ProfileCreateParams, type ProfileRetrieveParams as ProfileRetrieveParams, type ProfileUpdateParams as ProfileUpdateParams, type ProfileListParams as ProfileListParams, type ProfileDeleteParams as ProfileDeleteParams, type ProfileCompleteParams as ProfileCompleteParams, };
2507
- export { Campaigns as Campaigns, type MessagingUseCaseUs as MessagingUseCaseUs, type CampaignCreateResponse as CampaignCreateResponse, type CampaignUpdateResponse as CampaignUpdateResponse, type CampaignListResponse as CampaignListResponse, type CampaignCreateParams as CampaignCreateParams, type CampaignUpdateParams as CampaignUpdateParams, type CampaignListParams as CampaignListParams, type CampaignDeleteParams as CampaignDeleteParams, };
1096
+ export { type APIResponseOfProfileDetail as APIResponseOfProfileDetail, type BillingContactInfo as BillingContactInfo, type BrandBusinessInfo as BrandBusinessInfo, type BrandComplianceInfo as BrandComplianceInfo, type BrandContactInfo as BrandContactInfo, type BrandsBrandData as BrandsBrandData, type DestinationCountry as DestinationCountry, type PaymentDetails as PaymentDetails, type ProfileDetail as ProfileDetail, type TcrBrandRelationship as TcrBrandRelationship, type TcrVertical as TcrVertical, type ProfileListResponse as ProfileListResponse, type ProfileCompleteResponse as ProfileCompleteResponse, type ProfileCreateParams as ProfileCreateParams, type ProfileRetrieveParams as ProfileRetrieveParams, type ProfileUpdateParams as ProfileUpdateParams, type ProfileListParams as ProfileListParams, type ProfileDeleteParams as ProfileDeleteParams, type ProfileCompleteParams as ProfileCompleteParams, };
1097
+ export { Campaigns as Campaigns, type APIResponseOfBrandCampaign as APIResponseOfBrandCampaign, type APIResponseOfListOfBrandCampaign as APIResponseOfListOfBrandCampaign, type BrandCampaign as BrandCampaign, type CampaignData as CampaignData, type CampaignUseCase as CampaignUseCase, type CampaignUseCaseData as CampaignUseCaseData, type MessagingUseCaseUs as MessagingUseCaseUs, type CampaignCreateParams as CampaignCreateParams, type CampaignUpdateParams as CampaignUpdateParams, type CampaignListParams as CampaignListParams, type CampaignDeleteParams as CampaignDeleteParams, };
2508
1098
  }
2509
1099
  //# sourceMappingURL=profiles.d.mts.map