@surgeapi/node 0.26.0 → 0.27.1
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.
- package/CHANGELOG.md +44 -0
- package/client.d.mts +16 -16
- package/client.d.mts.map +1 -1
- package/client.d.ts +16 -16
- package/client.d.ts.map +1 -1
- package/client.js.map +1 -1
- package/client.mjs +2 -2
- package/client.mjs.map +1 -1
- package/internal/to-file.d.mts +1 -1
- package/internal/to-file.d.ts +1 -1
- package/internal/to-file.js +1 -1
- package/internal/to-file.mjs +1 -1
- package/package.json +1 -1
- package/resources/accounts.d.mts +306 -191
- package/resources/accounts.d.mts.map +1 -1
- package/resources/accounts.d.ts +306 -191
- package/resources/accounts.d.ts.map +1 -1
- package/resources/blasts.d.mts +11 -32
- package/resources/blasts.d.mts.map +1 -1
- package/resources/blasts.d.ts +11 -32
- package/resources/blasts.d.ts.map +1 -1
- package/resources/blasts.js.map +1 -1
- package/resources/blasts.mjs.map +1 -1
- package/resources/campaigns.d.mts +108 -201
- package/resources/campaigns.d.mts.map +1 -1
- package/resources/campaigns.d.ts +108 -201
- package/resources/campaigns.d.ts.map +1 -1
- package/resources/contacts.d.mts +1 -28
- package/resources/contacts.d.mts.map +1 -1
- package/resources/contacts.d.ts +1 -28
- package/resources/contacts.d.ts.map +1 -1
- package/resources/index.d.mts +8 -8
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +8 -8
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js.map +1 -1
- package/resources/index.mjs +2 -2
- package/resources/index.mjs.map +1 -1
- package/resources/messages.d.mts +49 -81
- package/resources/messages.d.mts.map +1 -1
- package/resources/messages.d.ts +49 -81
- package/resources/messages.d.ts.map +1 -1
- package/resources/messages.js.map +1 -1
- package/resources/messages.mjs.map +1 -1
- package/resources/phone-numbers.d.mts +0 -30
- package/resources/phone-numbers.d.mts.map +1 -1
- package/resources/phone-numbers.d.ts +0 -30
- package/resources/phone-numbers.d.ts.map +1 -1
- package/resources/users.d.mts +1 -33
- package/resources/users.d.mts.map +1 -1
- package/resources/users.d.ts +1 -33
- package/resources/users.d.ts.map +1 -1
- package/resources/verifications.d.mts +1 -19
- package/resources/verifications.d.mts.map +1 -1
- package/resources/verifications.d.ts +1 -19
- package/resources/verifications.d.ts.map +1 -1
- package/resources/webhooks.d.mts +60 -41
- package/resources/webhooks.d.mts.map +1 -1
- package/resources/webhooks.d.ts +60 -41
- package/resources/webhooks.d.ts.map +1 -1
- package/src/client.ts +12 -43
- package/src/internal/to-file.ts +1 -1
- package/src/resources/accounts.ts +489 -284
- package/src/resources/blasts.ts +11 -42
- package/src/resources/campaigns.ts +121 -234
- package/src/resources/contacts.ts +0 -31
- package/src/resources/index.ts +8 -23
- package/src/resources/messages.ts +54 -99
- package/src/resources/phone-numbers.ts +0 -34
- package/src/resources/users.ts +0 -37
- package/src/resources/verifications.ts +1 -22
- package/src/resources/webhooks.ts +72 -39
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
|
@@ -89,38 +89,6 @@ export interface Account {
|
|
|
89
89
|
time_zone: string | null;
|
|
90
90
|
}
|
|
91
91
|
|
|
92
|
-
/**
|
|
93
|
-
* Parameters for creating a new account.
|
|
94
|
-
*/
|
|
95
|
-
export interface AccountParams {
|
|
96
|
-
/**
|
|
97
|
-
* The name of the account that will be visible for your internal organizational
|
|
98
|
-
* purposes. This will also be the default public-facing brand name unless you also
|
|
99
|
-
* set a `brand_name`, but otherwise the account name will never be displayed
|
|
100
|
-
* anywhere outside of Surge HQ, and may include your ID for the account or
|
|
101
|
-
* anything else that may help you.
|
|
102
|
-
*/
|
|
103
|
-
name: string;
|
|
104
|
-
|
|
105
|
-
/**
|
|
106
|
-
* The name by which the people this account communicates with know it. If not
|
|
107
|
-
* provided, this will match the name field.
|
|
108
|
-
*/
|
|
109
|
-
brand_name?: string | null;
|
|
110
|
-
|
|
111
|
-
/**
|
|
112
|
-
* Parameters describing the legal entity on whose behalf the account will be
|
|
113
|
-
* operated.
|
|
114
|
-
*/
|
|
115
|
-
organization?: OrganizationParams;
|
|
116
|
-
|
|
117
|
-
/**
|
|
118
|
-
* This is the time zone in which the account is headquartered. This time zone may
|
|
119
|
-
* be used for compliance with TCPA restrictions on when messages may be sent.
|
|
120
|
-
*/
|
|
121
|
-
time_zone?: string;
|
|
122
|
-
}
|
|
123
|
-
|
|
124
92
|
/**
|
|
125
93
|
* Response containing account status information
|
|
126
94
|
*/
|
|
@@ -175,37 +143,6 @@ export namespace AccountStatus {
|
|
|
175
143
|
}
|
|
176
144
|
}
|
|
177
145
|
|
|
178
|
-
/**
|
|
179
|
-
* Parameters for updating an existing account.
|
|
180
|
-
*/
|
|
181
|
-
export interface AccountUpdateParams {
|
|
182
|
-
/**
|
|
183
|
-
* The name by which the people this account communicates with know it. If not
|
|
184
|
-
* provided, this will match the name field.
|
|
185
|
-
*/
|
|
186
|
-
brand_name?: string;
|
|
187
|
-
|
|
188
|
-
/**
|
|
189
|
-
* The name of the account that will be visible for your internal organizational
|
|
190
|
-
* purposes. This will also be the default public-facing brand name unless you also
|
|
191
|
-
* set a `brand_name`, but otherwise the account name will never be displayed
|
|
192
|
-
* anywhere outside of Surge HQ, and may include your ID for the account or
|
|
193
|
-
* anything else that may help you.
|
|
194
|
-
*/
|
|
195
|
-
name?: string;
|
|
196
|
-
|
|
197
|
-
/**
|
|
198
|
-
* Parameters describing the legal entity on whose behalf the account will be
|
|
199
|
-
* operated.
|
|
200
|
-
*/
|
|
201
|
-
organization?: OrganizationParams;
|
|
202
|
-
|
|
203
|
-
/**
|
|
204
|
-
* The time zone for the account
|
|
205
|
-
*/
|
|
206
|
-
time_zone?: string | null;
|
|
207
|
-
}
|
|
208
|
-
|
|
209
146
|
/**
|
|
210
147
|
* The legal entity on whose behalf the account will be operated.
|
|
211
148
|
*/
|
|
@@ -454,282 +391,291 @@ export namespace Organization {
|
|
|
454
391
|
}
|
|
455
392
|
}
|
|
456
393
|
|
|
457
|
-
|
|
458
|
-
* Parameters describing the legal entity on whose behalf the account will be
|
|
459
|
-
* operated.
|
|
460
|
-
*/
|
|
461
|
-
export interface OrganizationParams {
|
|
462
|
-
/**
|
|
463
|
-
* The address of the organization's headquarters.
|
|
464
|
-
*/
|
|
465
|
-
address?: OrganizationParams.Address;
|
|
466
|
-
|
|
467
|
-
/**
|
|
468
|
-
* An object representing an individual who can be contacted if the carriers have
|
|
469
|
-
* any questions about the business.
|
|
470
|
-
*/
|
|
471
|
-
contact?: OrganizationParams.Contact | null;
|
|
472
|
-
|
|
473
|
-
/**
|
|
474
|
-
* The two character ISO 3166 country code for the country in which the
|
|
475
|
-
* organization is headquartered.
|
|
476
|
-
*/
|
|
477
|
-
country?: string | null;
|
|
478
|
-
|
|
479
|
-
/**
|
|
480
|
-
* For publicly traded companies, an email for a representative of the company to
|
|
481
|
-
* whom a verification email will be sent. This must be an email on the same domain
|
|
482
|
-
* as the company's website (e.g. with a website domain of
|
|
483
|
-
* `https://dtprecisionauto.com`, the email must use the same
|
|
484
|
-
* `@dtprecisionauto.com`)
|
|
485
|
-
*/
|
|
486
|
-
email?: string | null;
|
|
487
|
-
|
|
488
|
-
/**
|
|
489
|
-
* The value of the identifier whose type is specified in the identifier_type
|
|
490
|
-
* field. Typically this will be an EIN, and can be formatted with or without the
|
|
491
|
-
* hyphen.
|
|
492
|
-
*/
|
|
493
|
-
identifier?: string | null;
|
|
494
|
-
|
|
495
|
-
/**
|
|
496
|
-
* The type of identifier being provided for the organization. Support for more
|
|
497
|
-
* values will be added in the future.
|
|
498
|
-
*/
|
|
499
|
-
identifier_type?: 'ein' | null;
|
|
500
|
-
|
|
501
|
-
/**
|
|
502
|
-
* The industry in which the organization operates.
|
|
503
|
-
*/
|
|
504
|
-
industry?:
|
|
505
|
-
| 'agriculture'
|
|
506
|
-
| 'automotive'
|
|
507
|
-
| 'banking'
|
|
508
|
-
| 'construction'
|
|
509
|
-
| 'consumer'
|
|
510
|
-
| 'education'
|
|
511
|
-
| 'electronics'
|
|
512
|
-
| 'energy'
|
|
513
|
-
| 'engineering'
|
|
514
|
-
| 'fast_moving_consumer_goods'
|
|
515
|
-
| 'financial'
|
|
516
|
-
| 'fintech'
|
|
517
|
-
| 'food_and_beverage'
|
|
518
|
-
| 'government'
|
|
519
|
-
| 'healthcare'
|
|
520
|
-
| 'hospitality'
|
|
521
|
-
| 'insurance'
|
|
522
|
-
| 'jewelry'
|
|
523
|
-
| 'legal'
|
|
524
|
-
| 'manufacturing'
|
|
525
|
-
| 'media'
|
|
526
|
-
| 'not_for_profit'
|
|
527
|
-
| 'oil_and_gas'
|
|
528
|
-
| 'online'
|
|
529
|
-
| 'professional_services'
|
|
530
|
-
| 'raw_materials'
|
|
531
|
-
| 'real_estate'
|
|
532
|
-
| 'religion'
|
|
533
|
-
| 'retail'
|
|
534
|
-
| 'technology'
|
|
535
|
-
| 'telecommunications'
|
|
536
|
-
| 'transportation'
|
|
537
|
-
| 'travel'
|
|
538
|
-
| null;
|
|
539
|
-
|
|
540
|
-
/**
|
|
541
|
-
* For sole proprietors, this must be a valid US mobile phone number to which a
|
|
542
|
-
* verification text message will be sent. (E.164 format)
|
|
543
|
-
*/
|
|
544
|
-
mobile_number?: string | null;
|
|
545
|
-
|
|
394
|
+
export interface AccountCreateParams {
|
|
546
395
|
/**
|
|
547
|
-
*
|
|
396
|
+
* The name of the account that will be visible for your internal organizational
|
|
397
|
+
* purposes. This will also be the default public-facing brand name unless you also
|
|
398
|
+
* set a `brand_name`, but otherwise the account name will never be displayed
|
|
399
|
+
* anywhere outside of Surge HQ, and may include your ID for the account or
|
|
400
|
+
* anything else that may help you.
|
|
548
401
|
*/
|
|
549
|
-
|
|
550
|
-
'africa' | 'asia' | 'australia' | 'europe' | 'latin_america' | 'usa_and_canada'
|
|
551
|
-
> | null;
|
|
402
|
+
name: string;
|
|
552
403
|
|
|
553
404
|
/**
|
|
554
|
-
* The
|
|
555
|
-
*
|
|
556
|
-
* records and should include all punctuation and everything else as well.
|
|
405
|
+
* The name by which the people this account communicates with know it. If not
|
|
406
|
+
* provided, this will match the name field.
|
|
557
407
|
*/
|
|
558
|
-
|
|
408
|
+
brand_name?: string | null;
|
|
559
409
|
|
|
560
410
|
/**
|
|
561
|
-
*
|
|
562
|
-
*
|
|
411
|
+
* Parameters describing the legal entity on whose behalf the account will be
|
|
412
|
+
* operated.
|
|
563
413
|
*/
|
|
564
|
-
|
|
565
|
-
| 'amex'
|
|
566
|
-
| 'amx'
|
|
567
|
-
| 'asx'
|
|
568
|
-
| 'b3'
|
|
569
|
-
| 'bme'
|
|
570
|
-
| 'bse'
|
|
571
|
-
| 'fra'
|
|
572
|
-
| 'icex'
|
|
573
|
-
| 'jpx'
|
|
574
|
-
| 'jse'
|
|
575
|
-
| 'krx'
|
|
576
|
-
| 'lon'
|
|
577
|
-
| 'nasdaq'
|
|
578
|
-
| 'none'
|
|
579
|
-
| 'nyse'
|
|
580
|
-
| 'nse'
|
|
581
|
-
| 'omx'
|
|
582
|
-
| 'other'
|
|
583
|
-
| 'sehk'
|
|
584
|
-
| 'sgx'
|
|
585
|
-
| 'sse'
|
|
586
|
-
| 'sto'
|
|
587
|
-
| 'swx'
|
|
588
|
-
| 'szse'
|
|
589
|
-
| 'tsx'
|
|
590
|
-
| 'twse'
|
|
591
|
-
| 'vse'
|
|
592
|
-
| null;
|
|
414
|
+
organization?: AccountCreateParams.Organization;
|
|
593
415
|
|
|
594
416
|
/**
|
|
595
|
-
*
|
|
417
|
+
* This is the time zone in which the account is headquartered. This time zone may
|
|
418
|
+
* be used for compliance with TCPA restrictions on when messages may be sent.
|
|
596
419
|
*/
|
|
597
|
-
|
|
420
|
+
time_zone?: string;
|
|
421
|
+
}
|
|
598
422
|
|
|
423
|
+
export namespace AccountCreateParams {
|
|
599
424
|
/**
|
|
600
|
-
*
|
|
425
|
+
* Parameters describing the legal entity on whose behalf the account will be
|
|
426
|
+
* operated.
|
|
601
427
|
*/
|
|
602
|
-
|
|
603
|
-
|
|
604
|
-
|
|
605
|
-
|
|
606
|
-
|
|
607
|
-
| 'partnership'
|
|
608
|
-
| 'private_corporation'
|
|
609
|
-
| 'public_corporation'
|
|
610
|
-
| 'sole_proprietor'
|
|
611
|
-
| null;
|
|
428
|
+
export interface Organization {
|
|
429
|
+
/**
|
|
430
|
+
* The address of the organization's headquarters.
|
|
431
|
+
*/
|
|
432
|
+
address?: Organization.Address;
|
|
612
433
|
|
|
613
|
-
|
|
614
|
-
|
|
615
|
-
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
|
|
619
|
-
|
|
434
|
+
/**
|
|
435
|
+
* An object representing an individual who can be contacted if Surge or our
|
|
436
|
+
* carrier partners have any questions about the business. If you are registering
|
|
437
|
+
* on behalf of your customer, this must be a contact from your customer's company
|
|
438
|
+
* rather than your own. The individual will likely never be contacted unless there
|
|
439
|
+
* are issues with spam.
|
|
440
|
+
*/
|
|
441
|
+
contact?: Organization.Contact | null;
|
|
620
442
|
|
|
621
|
-
export namespace OrganizationParams {
|
|
622
|
-
/**
|
|
623
|
-
* The address of the organization's headquarters.
|
|
624
|
-
*/
|
|
625
|
-
export interface Address {
|
|
626
443
|
/**
|
|
627
|
-
* The two character ISO 3166 country code
|
|
628
|
-
*
|
|
444
|
+
* The two character ISO 3166 country code for the country in which the
|
|
445
|
+
* organization is headquartered.
|
|
629
446
|
*/
|
|
630
447
|
country?: string | null;
|
|
631
448
|
|
|
632
449
|
/**
|
|
633
|
-
*
|
|
450
|
+
* For publicly traded companies, an email for a representative of the company to
|
|
451
|
+
* whom a verification email will be sent. This must be an email on the same domain
|
|
452
|
+
* as the company's website (e.g. with a website domain of
|
|
453
|
+
* `https://dtprecisionauto.com`, the email must use the same
|
|
454
|
+
* `@dtprecisionauto.com`)
|
|
634
455
|
*/
|
|
635
|
-
|
|
456
|
+
email?: string | null;
|
|
636
457
|
|
|
637
458
|
/**
|
|
638
|
-
* The
|
|
459
|
+
* The value of the identifier whose type is specified in the identifier_type
|
|
460
|
+
* field. Typically this will be an EIN, and can be formatted with or without the
|
|
461
|
+
* hyphen.
|
|
639
462
|
*/
|
|
640
|
-
|
|
463
|
+
identifier?: string | null;
|
|
641
464
|
|
|
642
465
|
/**
|
|
643
|
-
* The
|
|
466
|
+
* The type of identifier being provided for the organization. Support for more
|
|
467
|
+
* values will be added in the future.
|
|
644
468
|
*/
|
|
645
|
-
|
|
469
|
+
identifier_type?: 'ein' | null;
|
|
646
470
|
|
|
647
471
|
/**
|
|
648
|
-
* The
|
|
649
|
-
* default to the organization's registered_name
|
|
472
|
+
* The industry in which the organization operates.
|
|
650
473
|
*/
|
|
651
|
-
|
|
474
|
+
industry?:
|
|
475
|
+
| 'agriculture'
|
|
476
|
+
| 'automotive'
|
|
477
|
+
| 'banking'
|
|
478
|
+
| 'construction'
|
|
479
|
+
| 'consumer'
|
|
480
|
+
| 'education'
|
|
481
|
+
| 'electronics'
|
|
482
|
+
| 'energy'
|
|
483
|
+
| 'engineering'
|
|
484
|
+
| 'fast_moving_consumer_goods'
|
|
485
|
+
| 'financial'
|
|
486
|
+
| 'fintech'
|
|
487
|
+
| 'food_and_beverage'
|
|
488
|
+
| 'government'
|
|
489
|
+
| 'healthcare'
|
|
490
|
+
| 'hospitality'
|
|
491
|
+
| 'insurance'
|
|
492
|
+
| 'jewelry'
|
|
493
|
+
| 'legal'
|
|
494
|
+
| 'manufacturing'
|
|
495
|
+
| 'media'
|
|
496
|
+
| 'not_for_profit'
|
|
497
|
+
| 'oil_and_gas'
|
|
498
|
+
| 'online'
|
|
499
|
+
| 'professional_services'
|
|
500
|
+
| 'raw_materials'
|
|
501
|
+
| 'real_estate'
|
|
502
|
+
| 'religion'
|
|
503
|
+
| 'retail'
|
|
504
|
+
| 'technology'
|
|
505
|
+
| 'telecommunications'
|
|
506
|
+
| 'transportation'
|
|
507
|
+
| 'travel'
|
|
508
|
+
| null;
|
|
652
509
|
|
|
653
510
|
/**
|
|
654
|
-
*
|
|
511
|
+
* For sole proprietors, this must be a valid US mobile phone number to which a
|
|
512
|
+
* verification text message will be sent. (E.164 format)
|
|
655
513
|
*/
|
|
656
|
-
|
|
514
|
+
mobile_number?: string | null;
|
|
657
515
|
|
|
658
516
|
/**
|
|
659
|
-
*
|
|
517
|
+
* An array of regions in which the organization operates.
|
|
660
518
|
*/
|
|
661
|
-
|
|
662
|
-
|
|
519
|
+
regions_of_operation?: Array<
|
|
520
|
+
'africa' | 'asia' | 'australia' | 'europe' | 'latin_america' | 'usa_and_canada'
|
|
521
|
+
> | null;
|
|
663
522
|
|
|
664
|
-
/**
|
|
665
|
-
* An object representing an individual who can be contacted if the carriers have
|
|
666
|
-
* any questions about the business.
|
|
667
|
-
*/
|
|
668
|
-
export interface Contact {
|
|
669
523
|
/**
|
|
670
|
-
*
|
|
671
|
-
*
|
|
672
|
-
*
|
|
673
|
-
* `dom@dtprecisionauto.com` will be preferred over one like
|
|
674
|
-
* `dom@anothergarage.com` or `dom.toretto@gmail.com`)
|
|
524
|
+
* The legal name of the organization as registered with the IRS or other relevant
|
|
525
|
+
* authorities. For some applications, this will be matched against government
|
|
526
|
+
* records and should include all punctuation and everything else as well.
|
|
675
527
|
*/
|
|
676
|
-
|
|
528
|
+
registered_name?: string | null;
|
|
677
529
|
|
|
678
530
|
/**
|
|
679
|
-
*
|
|
531
|
+
* For publicly traded companies, this is the exchange on which the company's stock
|
|
532
|
+
* is traded.
|
|
680
533
|
*/
|
|
681
|
-
|
|
534
|
+
stock_exchange?:
|
|
535
|
+
| 'amex'
|
|
536
|
+
| 'amx'
|
|
537
|
+
| 'asx'
|
|
538
|
+
| 'b3'
|
|
539
|
+
| 'bme'
|
|
540
|
+
| 'bse'
|
|
541
|
+
| 'fra'
|
|
542
|
+
| 'icex'
|
|
543
|
+
| 'jpx'
|
|
544
|
+
| 'jse'
|
|
545
|
+
| 'krx'
|
|
546
|
+
| 'lon'
|
|
547
|
+
| 'nasdaq'
|
|
548
|
+
| 'none'
|
|
549
|
+
| 'nyse'
|
|
550
|
+
| 'nse'
|
|
551
|
+
| 'omx'
|
|
552
|
+
| 'other'
|
|
553
|
+
| 'sehk'
|
|
554
|
+
| 'sgx'
|
|
555
|
+
| 'sse'
|
|
556
|
+
| 'sto'
|
|
557
|
+
| 'swx'
|
|
558
|
+
| 'szse'
|
|
559
|
+
| 'tsx'
|
|
560
|
+
| 'twse'
|
|
561
|
+
| 'vse'
|
|
562
|
+
| null;
|
|
682
563
|
|
|
683
564
|
/**
|
|
684
|
-
*
|
|
565
|
+
* For publicly traded companies, the ticker symbol for the company's stock
|
|
685
566
|
*/
|
|
686
|
-
|
|
567
|
+
stock_symbol?: string | null;
|
|
687
568
|
|
|
688
569
|
/**
|
|
689
|
-
*
|
|
570
|
+
* The type of organization
|
|
690
571
|
*/
|
|
691
|
-
|
|
572
|
+
type?:
|
|
573
|
+
| 'co_op'
|
|
574
|
+
| 'government'
|
|
575
|
+
| 'llc'
|
|
576
|
+
| 'non_profit'
|
|
577
|
+
| 'partnership'
|
|
578
|
+
| 'private_corporation'
|
|
579
|
+
| 'public_corporation'
|
|
580
|
+
| 'sole_proprietor'
|
|
581
|
+
| null;
|
|
692
582
|
|
|
693
583
|
/**
|
|
694
|
-
* The
|
|
584
|
+
* The URL of the website for this organization. The website should be publicly
|
|
585
|
+
* available, clearly reflect the organization's purpose, and the URL should start
|
|
586
|
+
* with `https://`
|
|
695
587
|
*/
|
|
696
|
-
|
|
588
|
+
website?: string | null;
|
|
589
|
+
}
|
|
697
590
|
|
|
591
|
+
export namespace Organization {
|
|
698
592
|
/**
|
|
699
|
-
*
|
|
700
|
-
* provide the title of the individual
|
|
593
|
+
* The address of the organization's headquarters.
|
|
701
594
|
*/
|
|
702
|
-
|
|
703
|
-
|
|
704
|
-
|
|
595
|
+
export interface Address {
|
|
596
|
+
/**
|
|
597
|
+
* The two character ISO 3166 country code. If none is provided, the organization's
|
|
598
|
+
* country code will be used.
|
|
599
|
+
*/
|
|
600
|
+
country?: string | null;
|
|
705
601
|
|
|
706
|
-
|
|
707
|
-
|
|
708
|
-
|
|
709
|
-
|
|
710
|
-
* set a `brand_name`, but otherwise the account name will never be displayed
|
|
711
|
-
* anywhere outside of Surge HQ, and may include your ID for the account or
|
|
712
|
-
* anything else that may help you.
|
|
713
|
-
*/
|
|
714
|
-
name: string;
|
|
602
|
+
/**
|
|
603
|
+
* The first line of the address, typically the number and street name
|
|
604
|
+
*/
|
|
605
|
+
line1?: string | null;
|
|
715
606
|
|
|
716
|
-
|
|
717
|
-
|
|
718
|
-
|
|
719
|
-
|
|
720
|
-
brand_name?: string | null;
|
|
607
|
+
/**
|
|
608
|
+
* The second line of the address if needed, typically an apartment or suite number
|
|
609
|
+
*/
|
|
610
|
+
line2?: string | null;
|
|
721
611
|
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
|
|
726
|
-
organization?: OrganizationParams;
|
|
612
|
+
/**
|
|
613
|
+
* The city or locality
|
|
614
|
+
*/
|
|
615
|
+
locality?: string | null;
|
|
727
616
|
|
|
728
|
-
|
|
729
|
-
|
|
730
|
-
|
|
731
|
-
|
|
732
|
-
|
|
617
|
+
/**
|
|
618
|
+
* The name to which any mail should be addressed. If none is provided, this will
|
|
619
|
+
* default to the organization's registered_name
|
|
620
|
+
*/
|
|
621
|
+
name?: string | null;
|
|
622
|
+
|
|
623
|
+
/**
|
|
624
|
+
* The postal code
|
|
625
|
+
*/
|
|
626
|
+
postal_code?: string | null;
|
|
627
|
+
|
|
628
|
+
/**
|
|
629
|
+
* The state or region
|
|
630
|
+
*/
|
|
631
|
+
region?: string | null;
|
|
632
|
+
}
|
|
633
|
+
|
|
634
|
+
/**
|
|
635
|
+
* An object representing an individual who can be contacted if Surge or our
|
|
636
|
+
* carrier partners have any questions about the business. If you are registering
|
|
637
|
+
* on behalf of your customer, this must be a contact from your customer's company
|
|
638
|
+
* rather than your own. The individual will likely never be contacted unless there
|
|
639
|
+
* are issues with spam.
|
|
640
|
+
*/
|
|
641
|
+
export interface Contact {
|
|
642
|
+
/**
|
|
643
|
+
* An email address at which the individual can be reached. Typically an email
|
|
644
|
+
* using the same domain name as the website URL will be preferred (e.g. with a
|
|
645
|
+
* website domain of `https://dtprecisionauto.com`, an email like
|
|
646
|
+
* `dom@dtprecisionauto.com` will be preferred over one like
|
|
647
|
+
* `dom@anothergarage.com` or `dom.toretto@gmail.com`. `dtprecisionauto@gmail.com`
|
|
648
|
+
* would also be acceptable, but not preferred)
|
|
649
|
+
*/
|
|
650
|
+
email?: string | null;
|
|
651
|
+
|
|
652
|
+
/**
|
|
653
|
+
* The first name (or given name) of the individual
|
|
654
|
+
*/
|
|
655
|
+
first_name?: string | null;
|
|
656
|
+
|
|
657
|
+
/**
|
|
658
|
+
* The last name (or family name) of the individual
|
|
659
|
+
*/
|
|
660
|
+
last_name?: string | null;
|
|
661
|
+
|
|
662
|
+
/**
|
|
663
|
+
* A phone number at which the individual can be reached (E.164 format)
|
|
664
|
+
*/
|
|
665
|
+
phone_number?: string | null;
|
|
666
|
+
|
|
667
|
+
/**
|
|
668
|
+
* The job title of the individual.
|
|
669
|
+
*/
|
|
670
|
+
title?: 'ceo' | 'cfo' | 'director' | 'gm' | 'vp' | 'general_counsel' | 'other' | null;
|
|
671
|
+
|
|
672
|
+
/**
|
|
673
|
+
* If `other` is provided for the `title` field, this field should be used to
|
|
674
|
+
* provide the title of the individual
|
|
675
|
+
*/
|
|
676
|
+
title_other?: string | null;
|
|
677
|
+
}
|
|
678
|
+
}
|
|
733
679
|
}
|
|
734
680
|
|
|
735
681
|
export interface AccountUpdateParams {
|
|
@@ -752,7 +698,7 @@ export interface AccountUpdateParams {
|
|
|
752
698
|
* Parameters describing the legal entity on whose behalf the account will be
|
|
753
699
|
* operated.
|
|
754
700
|
*/
|
|
755
|
-
organization?:
|
|
701
|
+
organization?: AccountUpdateParams.Organization;
|
|
756
702
|
|
|
757
703
|
/**
|
|
758
704
|
* The time zone for the account
|
|
@@ -760,19 +706,278 @@ export interface AccountUpdateParams {
|
|
|
760
706
|
time_zone?: string | null;
|
|
761
707
|
}
|
|
762
708
|
|
|
709
|
+
export namespace AccountUpdateParams {
|
|
710
|
+
/**
|
|
711
|
+
* Parameters describing the legal entity on whose behalf the account will be
|
|
712
|
+
* operated.
|
|
713
|
+
*/
|
|
714
|
+
export interface Organization {
|
|
715
|
+
/**
|
|
716
|
+
* The address of the organization's headquarters.
|
|
717
|
+
*/
|
|
718
|
+
address?: Organization.Address;
|
|
719
|
+
|
|
720
|
+
/**
|
|
721
|
+
* An object representing an individual who can be contacted if Surge or our
|
|
722
|
+
* carrier partners have any questions about the business. If you are registering
|
|
723
|
+
* on behalf of your customer, this must be a contact from your customer's company
|
|
724
|
+
* rather than your own. The individual will likely never be contacted unless there
|
|
725
|
+
* are issues with spam.
|
|
726
|
+
*/
|
|
727
|
+
contact?: Organization.Contact | null;
|
|
728
|
+
|
|
729
|
+
/**
|
|
730
|
+
* The two character ISO 3166 country code for the country in which the
|
|
731
|
+
* organization is headquartered.
|
|
732
|
+
*/
|
|
733
|
+
country?: string | null;
|
|
734
|
+
|
|
735
|
+
/**
|
|
736
|
+
* For publicly traded companies, an email for a representative of the company to
|
|
737
|
+
* whom a verification email will be sent. This must be an email on the same domain
|
|
738
|
+
* as the company's website (e.g. with a website domain of
|
|
739
|
+
* `https://dtprecisionauto.com`, the email must use the same
|
|
740
|
+
* `@dtprecisionauto.com`)
|
|
741
|
+
*/
|
|
742
|
+
email?: string | null;
|
|
743
|
+
|
|
744
|
+
/**
|
|
745
|
+
* The value of the identifier whose type is specified in the identifier_type
|
|
746
|
+
* field. Typically this will be an EIN, and can be formatted with or without the
|
|
747
|
+
* hyphen.
|
|
748
|
+
*/
|
|
749
|
+
identifier?: string | null;
|
|
750
|
+
|
|
751
|
+
/**
|
|
752
|
+
* The type of identifier being provided for the organization. Support for more
|
|
753
|
+
* values will be added in the future.
|
|
754
|
+
*/
|
|
755
|
+
identifier_type?: 'ein' | null;
|
|
756
|
+
|
|
757
|
+
/**
|
|
758
|
+
* The industry in which the organization operates.
|
|
759
|
+
*/
|
|
760
|
+
industry?:
|
|
761
|
+
| 'agriculture'
|
|
762
|
+
| 'automotive'
|
|
763
|
+
| 'banking'
|
|
764
|
+
| 'construction'
|
|
765
|
+
| 'consumer'
|
|
766
|
+
| 'education'
|
|
767
|
+
| 'electronics'
|
|
768
|
+
| 'energy'
|
|
769
|
+
| 'engineering'
|
|
770
|
+
| 'fast_moving_consumer_goods'
|
|
771
|
+
| 'financial'
|
|
772
|
+
| 'fintech'
|
|
773
|
+
| 'food_and_beverage'
|
|
774
|
+
| 'government'
|
|
775
|
+
| 'healthcare'
|
|
776
|
+
| 'hospitality'
|
|
777
|
+
| 'insurance'
|
|
778
|
+
| 'jewelry'
|
|
779
|
+
| 'legal'
|
|
780
|
+
| 'manufacturing'
|
|
781
|
+
| 'media'
|
|
782
|
+
| 'not_for_profit'
|
|
783
|
+
| 'oil_and_gas'
|
|
784
|
+
| 'online'
|
|
785
|
+
| 'professional_services'
|
|
786
|
+
| 'raw_materials'
|
|
787
|
+
| 'real_estate'
|
|
788
|
+
| 'religion'
|
|
789
|
+
| 'retail'
|
|
790
|
+
| 'technology'
|
|
791
|
+
| 'telecommunications'
|
|
792
|
+
| 'transportation'
|
|
793
|
+
| 'travel'
|
|
794
|
+
| null;
|
|
795
|
+
|
|
796
|
+
/**
|
|
797
|
+
* For sole proprietors, this must be a valid US mobile phone number to which a
|
|
798
|
+
* verification text message will be sent. (E.164 format)
|
|
799
|
+
*/
|
|
800
|
+
mobile_number?: string | null;
|
|
801
|
+
|
|
802
|
+
/**
|
|
803
|
+
* An array of regions in which the organization operates.
|
|
804
|
+
*/
|
|
805
|
+
regions_of_operation?: Array<
|
|
806
|
+
'africa' | 'asia' | 'australia' | 'europe' | 'latin_america' | 'usa_and_canada'
|
|
807
|
+
> | null;
|
|
808
|
+
|
|
809
|
+
/**
|
|
810
|
+
* The legal name of the organization as registered with the IRS or other relevant
|
|
811
|
+
* authorities. For some applications, this will be matched against government
|
|
812
|
+
* records and should include all punctuation and everything else as well.
|
|
813
|
+
*/
|
|
814
|
+
registered_name?: string | null;
|
|
815
|
+
|
|
816
|
+
/**
|
|
817
|
+
* For publicly traded companies, this is the exchange on which the company's stock
|
|
818
|
+
* is traded.
|
|
819
|
+
*/
|
|
820
|
+
stock_exchange?:
|
|
821
|
+
| 'amex'
|
|
822
|
+
| 'amx'
|
|
823
|
+
| 'asx'
|
|
824
|
+
| 'b3'
|
|
825
|
+
| 'bme'
|
|
826
|
+
| 'bse'
|
|
827
|
+
| 'fra'
|
|
828
|
+
| 'icex'
|
|
829
|
+
| 'jpx'
|
|
830
|
+
| 'jse'
|
|
831
|
+
| 'krx'
|
|
832
|
+
| 'lon'
|
|
833
|
+
| 'nasdaq'
|
|
834
|
+
| 'none'
|
|
835
|
+
| 'nyse'
|
|
836
|
+
| 'nse'
|
|
837
|
+
| 'omx'
|
|
838
|
+
| 'other'
|
|
839
|
+
| 'sehk'
|
|
840
|
+
| 'sgx'
|
|
841
|
+
| 'sse'
|
|
842
|
+
| 'sto'
|
|
843
|
+
| 'swx'
|
|
844
|
+
| 'szse'
|
|
845
|
+
| 'tsx'
|
|
846
|
+
| 'twse'
|
|
847
|
+
| 'vse'
|
|
848
|
+
| null;
|
|
849
|
+
|
|
850
|
+
/**
|
|
851
|
+
* For publicly traded companies, the ticker symbol for the company's stock
|
|
852
|
+
*/
|
|
853
|
+
stock_symbol?: string | null;
|
|
854
|
+
|
|
855
|
+
/**
|
|
856
|
+
* The type of organization
|
|
857
|
+
*/
|
|
858
|
+
type?:
|
|
859
|
+
| 'co_op'
|
|
860
|
+
| 'government'
|
|
861
|
+
| 'llc'
|
|
862
|
+
| 'non_profit'
|
|
863
|
+
| 'partnership'
|
|
864
|
+
| 'private_corporation'
|
|
865
|
+
| 'public_corporation'
|
|
866
|
+
| 'sole_proprietor'
|
|
867
|
+
| null;
|
|
868
|
+
|
|
869
|
+
/**
|
|
870
|
+
* The URL of the website for this organization. The website should be publicly
|
|
871
|
+
* available, clearly reflect the organization's purpose, and the URL should start
|
|
872
|
+
* with `https://`
|
|
873
|
+
*/
|
|
874
|
+
website?: string | null;
|
|
875
|
+
}
|
|
876
|
+
|
|
877
|
+
export namespace Organization {
|
|
878
|
+
/**
|
|
879
|
+
* The address of the organization's headquarters.
|
|
880
|
+
*/
|
|
881
|
+
export interface Address {
|
|
882
|
+
/**
|
|
883
|
+
* The two character ISO 3166 country code. If none is provided, the organization's
|
|
884
|
+
* country code will be used.
|
|
885
|
+
*/
|
|
886
|
+
country?: string | null;
|
|
887
|
+
|
|
888
|
+
/**
|
|
889
|
+
* The first line of the address, typically the number and street name
|
|
890
|
+
*/
|
|
891
|
+
line1?: string | null;
|
|
892
|
+
|
|
893
|
+
/**
|
|
894
|
+
* The second line of the address if needed, typically an apartment or suite number
|
|
895
|
+
*/
|
|
896
|
+
line2?: string | null;
|
|
897
|
+
|
|
898
|
+
/**
|
|
899
|
+
* The city or locality
|
|
900
|
+
*/
|
|
901
|
+
locality?: string | null;
|
|
902
|
+
|
|
903
|
+
/**
|
|
904
|
+
* The name to which any mail should be addressed. If none is provided, this will
|
|
905
|
+
* default to the organization's registered_name
|
|
906
|
+
*/
|
|
907
|
+
name?: string | null;
|
|
908
|
+
|
|
909
|
+
/**
|
|
910
|
+
* The postal code
|
|
911
|
+
*/
|
|
912
|
+
postal_code?: string | null;
|
|
913
|
+
|
|
914
|
+
/**
|
|
915
|
+
* The state or region
|
|
916
|
+
*/
|
|
917
|
+
region?: string | null;
|
|
918
|
+
}
|
|
919
|
+
|
|
920
|
+
/**
|
|
921
|
+
* An object representing an individual who can be contacted if Surge or our
|
|
922
|
+
* carrier partners have any questions about the business. If you are registering
|
|
923
|
+
* on behalf of your customer, this must be a contact from your customer's company
|
|
924
|
+
* rather than your own. The individual will likely never be contacted unless there
|
|
925
|
+
* are issues with spam.
|
|
926
|
+
*/
|
|
927
|
+
export interface Contact {
|
|
928
|
+
/**
|
|
929
|
+
* An email address at which the individual can be reached. Typically an email
|
|
930
|
+
* using the same domain name as the website URL will be preferred (e.g. with a
|
|
931
|
+
* website domain of `https://dtprecisionauto.com`, an email like
|
|
932
|
+
* `dom@dtprecisionauto.com` will be preferred over one like
|
|
933
|
+
* `dom@anothergarage.com` or `dom.toretto@gmail.com`. `dtprecisionauto@gmail.com`
|
|
934
|
+
* would also be acceptable, but not preferred)
|
|
935
|
+
*/
|
|
936
|
+
email?: string | null;
|
|
937
|
+
|
|
938
|
+
/**
|
|
939
|
+
* The first name (or given name) of the individual
|
|
940
|
+
*/
|
|
941
|
+
first_name?: string | null;
|
|
942
|
+
|
|
943
|
+
/**
|
|
944
|
+
* The last name (or family name) of the individual
|
|
945
|
+
*/
|
|
946
|
+
last_name?: string | null;
|
|
947
|
+
|
|
948
|
+
/**
|
|
949
|
+
* A phone number at which the individual can be reached (E.164 format)
|
|
950
|
+
*/
|
|
951
|
+
phone_number?: string | null;
|
|
952
|
+
|
|
953
|
+
/**
|
|
954
|
+
* The job title of the individual.
|
|
955
|
+
*/
|
|
956
|
+
title?: 'ceo' | 'cfo' | 'director' | 'gm' | 'vp' | 'general_counsel' | 'other' | null;
|
|
957
|
+
|
|
958
|
+
/**
|
|
959
|
+
* If `other` is provided for the `title` field, this field should be used to
|
|
960
|
+
* provide the title of the individual
|
|
961
|
+
*/
|
|
962
|
+
title_other?: string | null;
|
|
963
|
+
}
|
|
964
|
+
}
|
|
965
|
+
}
|
|
966
|
+
|
|
763
967
|
export interface AccountRetrieveStatusParams {
|
|
968
|
+
/**
|
|
969
|
+
* capabilities about which to check the status
|
|
970
|
+
*/
|
|
764
971
|
capabilities?: Array<'local_messaging'>;
|
|
765
972
|
}
|
|
766
973
|
|
|
767
974
|
export declare namespace Accounts {
|
|
768
975
|
export {
|
|
769
976
|
type Account as Account,
|
|
770
|
-
type AccountParams as AccountParams,
|
|
771
977
|
type AccountStatus as AccountStatus,
|
|
772
|
-
type AccountUpdateParams as AccountUpdateParams,
|
|
773
978
|
type Organization as Organization,
|
|
774
|
-
type OrganizationParams as OrganizationParams,
|
|
775
979
|
type AccountCreateParams as AccountCreateParams,
|
|
980
|
+
type AccountUpdateParams as AccountUpdateParams,
|
|
776
981
|
type AccountRetrieveStatusParams as AccountRetrieveStatusParams,
|
|
777
982
|
};
|
|
778
983
|
}
|