@sentdm/sentdm 0.7.2 → 0.15.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.
- package/CHANGELOG.md +132 -0
- package/README.md +71 -34
- package/client.d.mts +49 -21
- package/client.d.mts.map +1 -1
- package/client.d.ts +49 -21
- package/client.d.ts.map +1 -1
- package/client.js +52 -38
- package/client.js.map +1 -1
- package/client.mjs +52 -38
- package/client.mjs.map +1 -1
- package/internal/tslib.js +17 -17
- package/internal/utils/log.d.mts.map +1 -1
- package/internal/utils/log.d.ts.map +1 -1
- package/internal/utils/log.js +0 -1
- package/internal/utils/log.js.map +1 -1
- package/internal/utils/log.mjs +0 -1
- package/internal/utils/log.mjs.map +1 -1
- package/internal/utils/query.d.mts +5 -0
- package/internal/utils/query.d.mts.map +1 -0
- package/internal/utils/query.d.ts +5 -0
- package/internal/utils/query.d.ts.map +1 -0
- package/internal/utils/query.js +23 -0
- package/internal/utils/query.js.map +1 -0
- package/internal/utils/query.mjs +20 -0
- package/internal/utils/query.mjs.map +1 -0
- package/internal/utils.d.mts +1 -0
- package/internal/utils.d.ts +1 -0
- package/internal/utils.js +1 -0
- package/internal/utils.js.map +1 -1
- package/internal/utils.mjs +1 -0
- package/package.json +7 -1
- package/resources/contacts.d.mts +243 -49
- package/resources/contacts.d.mts.map +1 -1
- package/resources/contacts.d.ts +243 -49
- package/resources/contacts.d.ts.map +1 -1
- package/resources/contacts.js +112 -15
- package/resources/contacts.js.map +1 -1
- package/resources/contacts.mjs +112 -15
- package/resources/contacts.mjs.map +1 -1
- package/resources/index.d.mts +8 -4
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +8 -4
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js +11 -3
- package/resources/index.js.map +1 -1
- package/resources/index.mjs +5 -1
- package/resources/index.mjs.map +1 -1
- package/resources/me.d.mts +269 -0
- package/resources/me.d.mts.map +1 -0
- package/resources/me.d.ts +269 -0
- package/resources/me.d.ts.map +1 -0
- package/resources/me.js +40 -0
- package/resources/me.js.map +1 -0
- package/resources/me.mjs +36 -0
- package/resources/me.mjs.map +1 -0
- package/resources/messages.d.mts +239 -133
- package/resources/messages.d.mts.map +1 -1
- package/resources/messages.d.ts +239 -133
- package/resources/messages.d.ts.map +1 -1
- package/resources/messages.js +42 -50
- package/resources/messages.js.map +1 -1
- package/resources/messages.mjs +42 -50
- package/resources/messages.mjs.map +1 -1
- package/resources/numbers.d.mts +70 -0
- package/resources/numbers.d.mts.map +1 -0
- package/resources/numbers.d.ts +70 -0
- package/resources/numbers.d.ts.map +1 -0
- package/resources/numbers.js +36 -0
- package/resources/numbers.js.map +1 -0
- package/resources/numbers.mjs +32 -0
- package/resources/numbers.mjs.map +1 -0
- package/resources/profiles/campaigns.d.mts +339 -0
- package/resources/profiles/campaigns.d.mts.map +1 -0
- package/resources/profiles/campaigns.d.ts +339 -0
- package/resources/profiles/campaigns.d.ts.map +1 -0
- package/resources/profiles/campaigns.js +148 -0
- package/resources/profiles/campaigns.js.map +1 -0
- package/resources/profiles/campaigns.mjs +144 -0
- package/resources/profiles/campaigns.mjs.map +1 -0
- package/resources/profiles/index.d.mts +3 -0
- package/resources/profiles/index.d.mts.map +1 -0
- package/resources/profiles/index.d.ts +3 -0
- package/resources/profiles/index.d.ts.map +1 -0
- package/resources/profiles/index.js +9 -0
- package/resources/profiles/index.js.map +1 -0
- package/resources/profiles/index.mjs +4 -0
- package/resources/profiles/index.mjs.map +1 -0
- package/resources/profiles/profiles.d.mts +967 -0
- package/resources/profiles/profiles.d.mts.map +1 -0
- package/resources/profiles/profiles.d.ts +967 -0
- package/resources/profiles/profiles.d.ts.map +1 -0
- package/resources/profiles/profiles.js +227 -0
- package/resources/profiles/profiles.js.map +1 -0
- package/resources/profiles/profiles.mjs +222 -0
- package/resources/profiles/profiles.mjs.map +1 -0
- package/resources/profiles.d.mts +2 -0
- package/resources/profiles.d.mts.map +1 -0
- package/resources/profiles.d.ts +2 -0
- package/resources/profiles.d.ts.map +1 -0
- package/resources/profiles.js +6 -0
- package/resources/profiles.js.map +1 -0
- package/resources/profiles.mjs +3 -0
- package/resources/profiles.mjs.map +1 -0
- package/resources/templates.d.mts +327 -191
- package/resources/templates.d.mts.map +1 -1
- package/resources/templates.d.ts +327 -191
- package/resources/templates.d.ts.map +1 -1
- package/resources/templates.js +80 -35
- package/resources/templates.js.map +1 -1
- package/resources/templates.mjs +80 -35
- package/resources/templates.mjs.map +1 -1
- package/resources/users.d.mts +251 -0
- package/resources/users.d.mts.map +1 -0
- package/resources/users.d.ts +251 -0
- package/resources/users.d.ts.map +1 -0
- package/resources/users.js +124 -0
- package/resources/users.js.map +1 -0
- package/resources/users.mjs +120 -0
- package/resources/users.mjs.map +1 -0
- package/resources/webhooks.d.mts +639 -0
- package/resources/webhooks.d.mts.map +1 -0
- package/resources/webhooks.d.ts +639 -0
- package/resources/webhooks.d.ts.map +1 -0
- package/resources/webhooks.js +237 -0
- package/resources/webhooks.js.map +1 -0
- package/resources/webhooks.mjs +233 -0
- package/resources/webhooks.mjs.map +1 -0
- package/src/client.ts +228 -80
- package/src/internal/utils/log.ts +0 -1
- package/src/internal/utils/query.ts +23 -0
- package/src/internal/utils.ts +1 -0
- package/src/resources/contacts.ts +335 -57
- package/src/resources/index.ts +81 -12
- package/src/resources/me.ts +333 -0
- package/src/resources/messages.ts +306 -147
- package/src/resources/numbers.ts +102 -0
- package/src/resources/profiles/campaigns.ts +501 -0
- package/src/resources/profiles/index.ts +38 -0
- package/src/resources/profiles/profiles.ts +1302 -0
- package/src/resources/profiles.ts +3 -0
- package/src/resources/templates.ts +424 -202
- package/src/resources/users.ts +366 -0
- package/src/resources/webhooks.ts +923 -0
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.mts.map +1 -1
- package/version.d.ts +1 -1
- package/version.d.ts.map +1 -1
- package/version.js +1 -1
- package/version.js.map +1 -1
- package/version.mjs +1 -1
- package/version.mjs.map +1 -1
- package/resources/number-lookup.d.mts +0 -59
- package/resources/number-lookup.d.mts.map +0 -1
- package/resources/number-lookup.d.ts +0 -59
- package/resources/number-lookup.d.ts.map +0 -1
- package/resources/number-lookup.js +0 -17
- package/resources/number-lookup.js.map +0 -1
- package/resources/number-lookup.mjs +0 -13
- package/resources/number-lookup.mjs.map +0 -1
- package/src/resources/number-lookup.ts +0 -80
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"contacts.mjs","sourceRoot":"","sources":["../src/resources/contacts.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;
|
|
1
|
+
{"version":3,"file":"contacts.mjs","sourceRoot":"","sources":["../src/resources/contacts.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;OAIf,EAAE,YAAY,EAAE;OAEhB,EAAE,IAAI,EAAE;AAEf;;GAEG;AACH,MAAM,OAAO,QAAS,SAAQ,WAAW;IACvC;;;;;;;;OAQG;IACH,MAAM,CAAC,MAA2B,EAAE,OAAwB;QAC1D,MAAM,EAAE,iBAAiB,EAAE,cAAc,EAAE,cAAc,EAAE,UAAU,EAAE,GAAG,IAAI,EAAE,GAAG,MAAM,CAAC;QAC1F,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,cAAc,EAAE;YACvC,IAAI;YACJ,GAAG,OAAO;YACV,OAAO,EAAE,YAAY,CAAC;gBACpB;oBACE,GAAG,CAAC,cAAc,IAAI,IAAI,CAAC,CAAC,CAAC,EAAE,iBAAiB,EAAE,cAAc,EAAE,CAAC,CAAC,CAAC,SAAS,CAAC;oBAC/E,GAAG,CAAC,UAAU,IAAI,IAAI,CAAC,CAAC,CAAC,EAAE,cAAc,EAAE,UAAU,EAAE,CAAC,CAAC,CAAC,SAAS,CAAC;iBACrE;gBACD,OAAO,EAAE,OAAO;aACjB,CAAC;SACH,CAAC,CAAC;IACL,CAAC;IAED;;;;;;;;;;;OAWG;IACH,QAAQ,CACN,EAAU,EACV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C,GAAG,CAAC,cAAc,EAAE;YACtC,KAAK;YACL,GAAG,OAAO;YACV,OAAO,EAAE,YAAY,CAAC;gBACpB,EAAE,GAAG,CAAC,UAAU,IAAI,IAAI,CAAC,CAAC,CAAC,EAAE,cAAc,EAAE,UAAU,EAAE,CAAC,CAAC,CAAC,SAAS,CAAC,EAAE;gBACxE,OAAO,EAAE,OAAO;aACjB,CAAC;SACH,CAAC,CAAC;IACL,CAAC;IAED;;;;;;;;;;;OAWG;IACH,MAAM,CAAC,EAAU,EAAE,MAA2B,EAAE,OAAwB;QACtE,MAAM,EAAE,IAAI,EAAE,cAAc,EAAE,UAAU,EAAE,GAAG,MAAM,CAAC;QACpD,OAAO,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC,IAAI,CAAA,gBAAgB,EAAE,EAAE,EAAE;YACnD,IAAI,EAAE,IAAI;YACV,GAAG,OAAO;YACV,OAAO,EAAE,YAAY,CAAC;gBACpB,EAAE,MAAM,EAAE,KAAK,EAAE,GAAG,CAAC,UAAU,IAAI,IAAI,CAAC,CAAC,CAAC,EAAE,cAAc,EAAE,UAAU,EAAE,CAAC,CAAC,CAAC,SAAS,CAAC,EAAE;gBACvF,OAAO,EAAE,OAAO;aACjB,CAAC;SACH,CAAC,CAAC;IACL,CAAC;CACF"}
|
package/resources/index.d.mts
CHANGED
|
@@ -1,5 +1,9 @@
|
|
|
1
|
-
export { Contacts, type
|
|
2
|
-
export {
|
|
3
|
-
export {
|
|
4
|
-
export {
|
|
1
|
+
export { Contacts, type APIResponseOfContact, type ContactResponse, type ContactListResponse, type ContactCreateParams, type ContactRetrieveParams, type ContactUpdateParams, type ContactListParams, type ContactDeleteParams, } from "./contacts.mjs";
|
|
2
|
+
export { Me, type ProfileSettings, type MeRetrieveResponse, type MeRetrieveParams } from "./me.mjs";
|
|
3
|
+
export { Messages, type MessageRetrieveActivitiesResponse, type MessageRetrieveStatusResponse, type MessageSendResponse, type MessageRetrieveActivitiesParams, type MessageRetrieveStatusParams, type MessageSendParams, } from "./messages.mjs";
|
|
4
|
+
export { Numbers, type NumberLookupResponse, type NumberLookupParams } from "./numbers.mjs";
|
|
5
|
+
export { Profiles, type APIResponseOfProfileDetail, type BillingContactInfo, type BrandsBrandData, type DestinationCountry, type PaymentDetails, type ProfileDetail, type SentDmServicesEndpointsCustomerApIv3ContractsRequestsBrandsBrandBusinessInfo, type SentDmServicesEndpointsCustomerApIv3ContractsRequestsBrandsBrandComplianceInfo, type SentDmServicesEndpointsCustomerApIv3ContractsRequestsBrandsBrandContactInfo, type TcrBrandRelationship, type TcrVertical, type ProfileListResponse, type ProfileCompleteResponse, type ProfileCreateParams, type ProfileRetrieveParams, type ProfileUpdateParams, type ProfileListParams, type ProfileDeleteParams, type ProfileCompleteParams, } from "./profiles/profiles.mjs";
|
|
6
|
+
export { Templates, type APIResponseTemplate, type SentDmServicesCommonContractsPocOsAuthenticationConfig, type SentDmServicesCommonContractsPocOsTemplateBody, type SentDmServicesCommonContractsPocOsTemplateButton, type SentDmServicesCommonContractsPocOsTemplateButtonProps, type SentDmServicesCommonContractsPocOsTemplateFooter, type SentDmServicesCommonContractsPocOsTemplateHeader, type Template, type TemplateBodyContent, type TemplateDefinition, type TemplateVariable, type TemplateListResponse, type TemplateCreateParams, type TemplateRetrieveParams, type TemplateUpdateParams, type TemplateListParams, type TemplateDeleteParams, } from "./templates.mjs";
|
|
7
|
+
export { Users, type APIResponseOfUser, type UserResponse, type UserListResponse, type UserRetrieveParams, type UserListParams, type UserInviteParams, type UserRemoveParams, type UserUpdateRoleParams, } from "./users.mjs";
|
|
8
|
+
export { Webhooks, type APIMeta, type APIResponseWebhook, type ErrorDetail, type MutationRequest, type PaginationMeta, type WebhookResponse, type WebhookListResponse, type WebhookListEventTypesResponse, type WebhookListEventsResponse, type WebhookRotateSecretResponse, type WebhookTestResponse, type WebhookCreateParams, type WebhookRetrieveParams, type WebhookUpdateParams, type WebhookListParams, type WebhookDeleteParams, type WebhookListEventTypesParams, type WebhookListEventsParams, type WebhookRotateSecretParams, type WebhookTestParams, type WebhookToggleStatusParams, } from "./webhooks.mjs";
|
|
5
9
|
//# sourceMappingURL=index.d.mts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.mts","sourceRoot":"","sources":["../src/resources/index.ts"],"names":[],"mappings":"OAEO,EACL,QAAQ,EACR,KAAK,eAAe,EACpB,KAAK,mBAAmB,EACxB,KAAK,iBAAiB,EACtB,KAAK,
|
|
1
|
+
{"version":3,"file":"index.d.mts","sourceRoot":"","sources":["../src/resources/index.ts"],"names":[],"mappings":"OAEO,EACL,QAAQ,EACR,KAAK,oBAAoB,EACzB,KAAK,eAAe,EACpB,KAAK,mBAAmB,EACxB,KAAK,mBAAmB,EACxB,KAAK,qBAAqB,EAC1B,KAAK,mBAAmB,EACxB,KAAK,iBAAiB,EACtB,KAAK,mBAAmB,GACzB;OACM,EAAE,EAAE,EAAE,KAAK,eAAe,EAAE,KAAK,kBAAkB,EAAE,KAAK,gBAAgB,EAAE;OAC5E,EACL,QAAQ,EACR,KAAK,iCAAiC,EACtC,KAAK,6BAA6B,EAClC,KAAK,mBAAmB,EACxB,KAAK,+BAA+B,EACpC,KAAK,2BAA2B,EAChC,KAAK,iBAAiB,GACvB;OACM,EAAE,OAAO,EAAE,KAAK,oBAAoB,EAAE,KAAK,kBAAkB,EAAE;OAC/D,EACL,QAAQ,EACR,KAAK,0BAA0B,EAC/B,KAAK,kBAAkB,EACvB,KAAK,eAAe,EACpB,KAAK,kBAAkB,EACvB,KAAK,cAAc,EACnB,KAAK,aAAa,EAClB,KAAK,4EAA4E,EACjF,KAAK,8EAA8E,EACnF,KAAK,2EAA2E,EAChF,KAAK,oBAAoB,EACzB,KAAK,WAAW,EAChB,KAAK,mBAAmB,EACxB,KAAK,uBAAuB,EAC5B,KAAK,mBAAmB,EACxB,KAAK,qBAAqB,EAC1B,KAAK,mBAAmB,EACxB,KAAK,iBAAiB,EACtB,KAAK,mBAAmB,EACxB,KAAK,qBAAqB,GAC3B;OACM,EACL,SAAS,EACT,KAAK,mBAAmB,EACxB,KAAK,sDAAsD,EAC3D,KAAK,8CAA8C,EACnD,KAAK,gDAAgD,EACrD,KAAK,qDAAqD,EAC1D,KAAK,gDAAgD,EACrD,KAAK,gDAAgD,EACrD,KAAK,QAAQ,EACb,KAAK,mBAAmB,EACxB,KAAK,kBAAkB,EACvB,KAAK,gBAAgB,EACrB,KAAK,oBAAoB,EACzB,KAAK,oBAAoB,EACzB,KAAK,sBAAsB,EAC3B,KAAK,oBAAoB,EACzB,KAAK,kBAAkB,EACvB,KAAK,oBAAoB,GAC1B;OACM,EACL,KAAK,EACL,KAAK,iBAAiB,EACtB,KAAK,YAAY,EACjB,KAAK,gBAAgB,EACrB,KAAK,kBAAkB,EACvB,KAAK,cAAc,EACnB,KAAK,gBAAgB,EACrB,KAAK,gBAAgB,EACrB,KAAK,oBAAoB,GAC1B;OACM,EACL,QAAQ,EACR,KAAK,OAAO,EACZ,KAAK,kBAAkB,EACvB,KAAK,WAAW,EAChB,KAAK,eAAe,EACpB,KAAK,cAAc,EACnB,KAAK,eAAe,EACpB,KAAK,mBAAmB,EACxB,KAAK,6BAA6B,EAClC,KAAK,yBAAyB,EAC9B,KAAK,2BAA2B,EAChC,KAAK,mBAAmB,EACxB,KAAK,mBAAmB,EACxB,KAAK,qBAAqB,EAC1B,KAAK,mBAAmB,EACxB,KAAK,iBAAiB,EACtB,KAAK,mBAAmB,EACxB,KAAK,2BAA2B,EAChC,KAAK,uBAAuB,EAC5B,KAAK,yBAAyB,EAC9B,KAAK,iBAAiB,EACtB,KAAK,yBAAyB,GAC/B"}
|
package/resources/index.d.ts
CHANGED
|
@@ -1,5 +1,9 @@
|
|
|
1
|
-
export { Contacts, type
|
|
2
|
-
export {
|
|
3
|
-
export {
|
|
4
|
-
export {
|
|
1
|
+
export { Contacts, type APIResponseOfContact, type ContactResponse, type ContactListResponse, type ContactCreateParams, type ContactRetrieveParams, type ContactUpdateParams, type ContactListParams, type ContactDeleteParams, } from "./contacts.js";
|
|
2
|
+
export { Me, type ProfileSettings, type MeRetrieveResponse, type MeRetrieveParams } from "./me.js";
|
|
3
|
+
export { Messages, type MessageRetrieveActivitiesResponse, type MessageRetrieveStatusResponse, type MessageSendResponse, type MessageRetrieveActivitiesParams, type MessageRetrieveStatusParams, type MessageSendParams, } from "./messages.js";
|
|
4
|
+
export { Numbers, type NumberLookupResponse, type NumberLookupParams } from "./numbers.js";
|
|
5
|
+
export { Profiles, type APIResponseOfProfileDetail, type BillingContactInfo, type BrandsBrandData, type DestinationCountry, type PaymentDetails, type ProfileDetail, type SentDmServicesEndpointsCustomerApIv3ContractsRequestsBrandsBrandBusinessInfo, type SentDmServicesEndpointsCustomerApIv3ContractsRequestsBrandsBrandComplianceInfo, type SentDmServicesEndpointsCustomerApIv3ContractsRequestsBrandsBrandContactInfo, type TcrBrandRelationship, type TcrVertical, type ProfileListResponse, type ProfileCompleteResponse, type ProfileCreateParams, type ProfileRetrieveParams, type ProfileUpdateParams, type ProfileListParams, type ProfileDeleteParams, type ProfileCompleteParams, } from "./profiles/profiles.js";
|
|
6
|
+
export { Templates, type APIResponseTemplate, type SentDmServicesCommonContractsPocOsAuthenticationConfig, type SentDmServicesCommonContractsPocOsTemplateBody, type SentDmServicesCommonContractsPocOsTemplateButton, type SentDmServicesCommonContractsPocOsTemplateButtonProps, type SentDmServicesCommonContractsPocOsTemplateFooter, type SentDmServicesCommonContractsPocOsTemplateHeader, type Template, type TemplateBodyContent, type TemplateDefinition, type TemplateVariable, type TemplateListResponse, type TemplateCreateParams, type TemplateRetrieveParams, type TemplateUpdateParams, type TemplateListParams, type TemplateDeleteParams, } from "./templates.js";
|
|
7
|
+
export { Users, type APIResponseOfUser, type UserResponse, type UserListResponse, type UserRetrieveParams, type UserListParams, type UserInviteParams, type UserRemoveParams, type UserUpdateRoleParams, } from "./users.js";
|
|
8
|
+
export { Webhooks, type APIMeta, type APIResponseWebhook, type ErrorDetail, type MutationRequest, type PaginationMeta, type WebhookResponse, type WebhookListResponse, type WebhookListEventTypesResponse, type WebhookListEventsResponse, type WebhookRotateSecretResponse, type WebhookTestResponse, type WebhookCreateParams, type WebhookRetrieveParams, type WebhookUpdateParams, type WebhookListParams, type WebhookDeleteParams, type WebhookListEventTypesParams, type WebhookListEventsParams, type WebhookRotateSecretParams, type WebhookTestParams, type WebhookToggleStatusParams, } from "./webhooks.js";
|
|
5
9
|
//# sourceMappingURL=index.d.ts.map
|
package/resources/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/resources/index.ts"],"names":[],"mappings":"OAEO,EACL,QAAQ,EACR,KAAK,eAAe,EACpB,KAAK,mBAAmB,EACxB,KAAK,iBAAiB,EACtB,KAAK,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/resources/index.ts"],"names":[],"mappings":"OAEO,EACL,QAAQ,EACR,KAAK,oBAAoB,EACzB,KAAK,eAAe,EACpB,KAAK,mBAAmB,EACxB,KAAK,mBAAmB,EACxB,KAAK,qBAAqB,EAC1B,KAAK,mBAAmB,EACxB,KAAK,iBAAiB,EACtB,KAAK,mBAAmB,GACzB;OACM,EAAE,EAAE,EAAE,KAAK,eAAe,EAAE,KAAK,kBAAkB,EAAE,KAAK,gBAAgB,EAAE;OAC5E,EACL,QAAQ,EACR,KAAK,iCAAiC,EACtC,KAAK,6BAA6B,EAClC,KAAK,mBAAmB,EACxB,KAAK,+BAA+B,EACpC,KAAK,2BAA2B,EAChC,KAAK,iBAAiB,GACvB;OACM,EAAE,OAAO,EAAE,KAAK,oBAAoB,EAAE,KAAK,kBAAkB,EAAE;OAC/D,EACL,QAAQ,EACR,KAAK,0BAA0B,EAC/B,KAAK,kBAAkB,EACvB,KAAK,eAAe,EACpB,KAAK,kBAAkB,EACvB,KAAK,cAAc,EACnB,KAAK,aAAa,EAClB,KAAK,4EAA4E,EACjF,KAAK,8EAA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}
|
package/resources/index.js
CHANGED
|
@@ -1,13 +1,21 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
3
3
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
-
exports.Templates = exports.
|
|
4
|
+
exports.Webhooks = exports.Users = exports.Templates = exports.Profiles = exports.Numbers = exports.Messages = exports.Me = exports.Contacts = void 0;
|
|
5
5
|
var contacts_1 = require("./contacts.js");
|
|
6
6
|
Object.defineProperty(exports, "Contacts", { enumerable: true, get: function () { return contacts_1.Contacts; } });
|
|
7
|
+
var me_1 = require("./me.js");
|
|
8
|
+
Object.defineProperty(exports, "Me", { enumerable: true, get: function () { return me_1.Me; } });
|
|
7
9
|
var messages_1 = require("./messages.js");
|
|
8
10
|
Object.defineProperty(exports, "Messages", { enumerable: true, get: function () { return messages_1.Messages; } });
|
|
9
|
-
var
|
|
10
|
-
Object.defineProperty(exports, "
|
|
11
|
+
var numbers_1 = require("./numbers.js");
|
|
12
|
+
Object.defineProperty(exports, "Numbers", { enumerable: true, get: function () { return numbers_1.Numbers; } });
|
|
13
|
+
var profiles_1 = require("./profiles/profiles.js");
|
|
14
|
+
Object.defineProperty(exports, "Profiles", { enumerable: true, get: function () { return profiles_1.Profiles; } });
|
|
11
15
|
var templates_1 = require("./templates.js");
|
|
12
16
|
Object.defineProperty(exports, "Templates", { enumerable: true, get: function () { return templates_1.Templates; } });
|
|
17
|
+
var users_1 = require("./users.js");
|
|
18
|
+
Object.defineProperty(exports, "Users", { enumerable: true, get: function () { return users_1.Users; } });
|
|
19
|
+
var webhooks_1 = require("./webhooks.js");
|
|
20
|
+
Object.defineProperty(exports, "Webhooks", { enumerable: true, get: function () { return webhooks_1.Webhooks; } });
|
|
13
21
|
//# sourceMappingURL=index.js.map
|
package/resources/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/resources/index.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/resources/index.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,0CAUoB;AATlB,oGAAA,QAAQ,OAAA;AAUV,8BAAgG;AAAvF,wFAAA,EAAE,OAAA;AACX,0CAQoB;AAPlB,oGAAA,QAAQ,OAAA;AAQV,wCAAwF;AAA/E,kGAAA,OAAO,OAAA;AAChB,mDAqB6B;AApB3B,oGAAA,QAAQ,OAAA;AAqBV,4CAmBqB;AAlBnB,sGAAA,SAAS,OAAA;AAmBX,oCAUiB;AATf,8FAAA,KAAK,OAAA;AAUP,0CAuBoB;AAtBlB,oGAAA,QAAQ,OAAA"}
|
package/resources/index.mjs
CHANGED
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
export { Contacts, } from "./contacts.mjs";
|
|
3
|
+
export { Me } from "./me.mjs";
|
|
3
4
|
export { Messages, } from "./messages.mjs";
|
|
4
|
-
export {
|
|
5
|
+
export { Numbers } from "./numbers.mjs";
|
|
6
|
+
export { Profiles, } from "./profiles/profiles.mjs";
|
|
5
7
|
export { Templates, } from "./templates.mjs";
|
|
8
|
+
export { Users, } from "./users.mjs";
|
|
9
|
+
export { Webhooks, } from "./webhooks.mjs";
|
|
6
10
|
//# sourceMappingURL=index.mjs.map
|
package/resources/index.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","sourceRoot":"","sources":["../src/resources/index.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EACL,QAAQ,
|
|
1
|
+
{"version":3,"file":"index.mjs","sourceRoot":"","sources":["../src/resources/index.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EACL,QAAQ,GAST;OACM,EAAE,EAAE,EAAwE;OAC5E,EACL,QAAQ,GAOT;OACM,EAAE,OAAO,EAAsD;OAC/D,EACL,QAAQ,GAoBT;OACM,EACL,SAAS,GAkBV;OACM,EACL,KAAK,GASN;OACM,EACL,QAAQ,GAsBT"}
|
|
@@ -0,0 +1,269 @@
|
|
|
1
|
+
import { APIResource } from "../core/resource.mjs";
|
|
2
|
+
import * as MeAPI from "./me.mjs";
|
|
3
|
+
import * as WebhooksAPI from "./webhooks.mjs";
|
|
4
|
+
import { APIPromise } from "../core/api-promise.mjs";
|
|
5
|
+
import { RequestOptions } from "../internal/request-options.mjs";
|
|
6
|
+
/**
|
|
7
|
+
* Retrieve account details
|
|
8
|
+
*/
|
|
9
|
+
export declare class Me extends APIResource {
|
|
10
|
+
/**
|
|
11
|
+
* Returns the account associated with the provided API key. The response includes
|
|
12
|
+
* account identity, contact information, messaging channel configuration, and —
|
|
13
|
+
* depending on the account type — either a list of child profiles or the profile's
|
|
14
|
+
* own settings.
|
|
15
|
+
*
|
|
16
|
+
* **Account types:**
|
|
17
|
+
*
|
|
18
|
+
* - `organization` — Has child profiles. The `profiles` array is populated.
|
|
19
|
+
* - `user` — Standalone account with no profiles.
|
|
20
|
+
* - `profile` — Child of an organization. Includes `organization_id`,
|
|
21
|
+
* `short_name`, `status`, and `settings`.
|
|
22
|
+
*
|
|
23
|
+
* **Channels:** The `channels` object always includes `sms`, `whatsapp`, and
|
|
24
|
+
* `rcs`. Each channel has a `configured` boolean. Configured channels expose
|
|
25
|
+
* additional details such as `phone_number`.
|
|
26
|
+
*/
|
|
27
|
+
retrieve(params?: MeRetrieveParams | null | undefined, options?: RequestOptions): APIPromise<MeRetrieveResponse>;
|
|
28
|
+
}
|
|
29
|
+
/**
|
|
30
|
+
* Profile configuration settings
|
|
31
|
+
*/
|
|
32
|
+
export interface ProfileSettings {
|
|
33
|
+
/**
|
|
34
|
+
* Whether contacts are shared across profiles in the organization
|
|
35
|
+
*/
|
|
36
|
+
allow_contact_sharing?: boolean | null;
|
|
37
|
+
/**
|
|
38
|
+
* Whether templates are shared across profiles in the organization
|
|
39
|
+
*/
|
|
40
|
+
allow_template_sharing?: boolean | null;
|
|
41
|
+
/**
|
|
42
|
+
* Billing model: profile, organization, or profile_and_organization
|
|
43
|
+
*/
|
|
44
|
+
billing_model?: string | null;
|
|
45
|
+
/**
|
|
46
|
+
* Whether this profile inherits contacts from the organization
|
|
47
|
+
*/
|
|
48
|
+
inherit_contacts?: boolean | null;
|
|
49
|
+
/**
|
|
50
|
+
* Whether this profile inherits TCR brand from the organization
|
|
51
|
+
*/
|
|
52
|
+
inherit_tcr_brand?: boolean | null;
|
|
53
|
+
/**
|
|
54
|
+
* Whether this profile inherits TCR campaign from the organization
|
|
55
|
+
*/
|
|
56
|
+
inherit_tcr_campaign?: boolean | null;
|
|
57
|
+
/**
|
|
58
|
+
* Whether this profile inherits templates from the organization
|
|
59
|
+
*/
|
|
60
|
+
inherit_templates?: boolean | null;
|
|
61
|
+
}
|
|
62
|
+
/**
|
|
63
|
+
* Standard API response envelope for all v3 endpoints
|
|
64
|
+
*/
|
|
65
|
+
export interface MeRetrieveResponse {
|
|
66
|
+
/**
|
|
67
|
+
* Account response for GET /v3/me endpoint. Returns organization (with profiles),
|
|
68
|
+
* user (standalone), or profile (child of an organization) data depending on the
|
|
69
|
+
* API key type. Always includes messaging channel configuration.
|
|
70
|
+
*/
|
|
71
|
+
data?: MeRetrieveResponse.Data | null;
|
|
72
|
+
/**
|
|
73
|
+
* Error information
|
|
74
|
+
*/
|
|
75
|
+
error?: WebhooksAPI.ErrorDetail | null;
|
|
76
|
+
/**
|
|
77
|
+
* Request and response metadata
|
|
78
|
+
*/
|
|
79
|
+
meta?: WebhooksAPI.APIMeta;
|
|
80
|
+
/**
|
|
81
|
+
* Indicates whether the request was successful
|
|
82
|
+
*/
|
|
83
|
+
success?: boolean;
|
|
84
|
+
}
|
|
85
|
+
export declare namespace MeRetrieveResponse {
|
|
86
|
+
/**
|
|
87
|
+
* Account response for GET /v3/me endpoint. Returns organization (with profiles),
|
|
88
|
+
* user (standalone), or profile (child of an organization) data depending on the
|
|
89
|
+
* API key type. Always includes messaging channel configuration.
|
|
90
|
+
*/
|
|
91
|
+
interface Data {
|
|
92
|
+
/**
|
|
93
|
+
* Customer ID (organization, account, or profile)
|
|
94
|
+
*/
|
|
95
|
+
id?: string;
|
|
96
|
+
/**
|
|
97
|
+
* Messaging channel configuration. All three channels are always present. Each
|
|
98
|
+
* channel has a "configured" flag; configured channels expose additional details.
|
|
99
|
+
*/
|
|
100
|
+
channels?: Data.Channels;
|
|
101
|
+
/**
|
|
102
|
+
* When the account was created
|
|
103
|
+
*/
|
|
104
|
+
created_at?: string;
|
|
105
|
+
/**
|
|
106
|
+
* Account description
|
|
107
|
+
*/
|
|
108
|
+
description?: string | null;
|
|
109
|
+
/**
|
|
110
|
+
* Contact email address
|
|
111
|
+
*/
|
|
112
|
+
email?: string | null;
|
|
113
|
+
/**
|
|
114
|
+
* Account icon URL
|
|
115
|
+
*/
|
|
116
|
+
icon?: string | null;
|
|
117
|
+
/**
|
|
118
|
+
* Account name
|
|
119
|
+
*/
|
|
120
|
+
name?: string;
|
|
121
|
+
/**
|
|
122
|
+
* Organization ID (only for profile type — the parent organization)
|
|
123
|
+
*/
|
|
124
|
+
organization_id?: string | null;
|
|
125
|
+
/**
|
|
126
|
+
* List of profiles (populated for organization type, empty for user and profile
|
|
127
|
+
* types)
|
|
128
|
+
*/
|
|
129
|
+
profiles?: Array<Data.Profile>;
|
|
130
|
+
/**
|
|
131
|
+
* Profile configuration settings
|
|
132
|
+
*/
|
|
133
|
+
settings?: MeAPI.ProfileSettings | null;
|
|
134
|
+
/**
|
|
135
|
+
* Short name / abbreviation (only for profile type)
|
|
136
|
+
*/
|
|
137
|
+
short_name?: string | null;
|
|
138
|
+
/**
|
|
139
|
+
* Profile status (only for profile type): incomplete, pending_review, approved,
|
|
140
|
+
* etc.
|
|
141
|
+
*/
|
|
142
|
+
status?: string | null;
|
|
143
|
+
/**
|
|
144
|
+
* Account type: "organization" (has profiles), "user" (no profiles), or "profile"
|
|
145
|
+
* (child of an organization)
|
|
146
|
+
*/
|
|
147
|
+
type?: string;
|
|
148
|
+
}
|
|
149
|
+
namespace Data {
|
|
150
|
+
/**
|
|
151
|
+
* Messaging channel configuration. All three channels are always present. Each
|
|
152
|
+
* channel has a "configured" flag; configured channels expose additional details.
|
|
153
|
+
*/
|
|
154
|
+
interface Channels {
|
|
155
|
+
/**
|
|
156
|
+
* RCS channel configuration. When configured, includes the RCS phone number.
|
|
157
|
+
*/
|
|
158
|
+
rcs?: Channels.Rcs;
|
|
159
|
+
/**
|
|
160
|
+
* SMS channel configuration. When configured, includes the sending phone number.
|
|
161
|
+
*/
|
|
162
|
+
sms?: Channels.SMS;
|
|
163
|
+
/**
|
|
164
|
+
* WhatsApp Business channel configuration. When configured, includes the WhatsApp
|
|
165
|
+
* phone number and business name.
|
|
166
|
+
*/
|
|
167
|
+
whatsapp?: Channels.Whatsapp;
|
|
168
|
+
}
|
|
169
|
+
namespace Channels {
|
|
170
|
+
/**
|
|
171
|
+
* RCS channel configuration. When configured, includes the RCS phone number.
|
|
172
|
+
*/
|
|
173
|
+
interface Rcs {
|
|
174
|
+
/**
|
|
175
|
+
* Whether RCS is configured for this account
|
|
176
|
+
*/
|
|
177
|
+
configured?: boolean;
|
|
178
|
+
/**
|
|
179
|
+
* RCS-enabled phone number in E.164 format
|
|
180
|
+
*/
|
|
181
|
+
phone_number?: string | null;
|
|
182
|
+
}
|
|
183
|
+
/**
|
|
184
|
+
* SMS channel configuration. When configured, includes the sending phone number.
|
|
185
|
+
*/
|
|
186
|
+
interface SMS {
|
|
187
|
+
/**
|
|
188
|
+
* Whether SMS is configured for this account
|
|
189
|
+
*/
|
|
190
|
+
configured?: boolean;
|
|
191
|
+
/**
|
|
192
|
+
* Sending phone number in E.164 format
|
|
193
|
+
*/
|
|
194
|
+
phone_number?: string | null;
|
|
195
|
+
}
|
|
196
|
+
/**
|
|
197
|
+
* WhatsApp Business channel configuration. When configured, includes the WhatsApp
|
|
198
|
+
* phone number and business name.
|
|
199
|
+
*/
|
|
200
|
+
interface Whatsapp {
|
|
201
|
+
/**
|
|
202
|
+
* WhatsApp Business display name
|
|
203
|
+
*/
|
|
204
|
+
business_name?: string | null;
|
|
205
|
+
/**
|
|
206
|
+
* Whether WhatsApp is configured for this account
|
|
207
|
+
*/
|
|
208
|
+
configured?: boolean;
|
|
209
|
+
/**
|
|
210
|
+
* WhatsApp phone number in E.164 format
|
|
211
|
+
*/
|
|
212
|
+
phone_number?: string | null;
|
|
213
|
+
}
|
|
214
|
+
}
|
|
215
|
+
/**
|
|
216
|
+
* Profile (sender profile) response for v3 API
|
|
217
|
+
*/
|
|
218
|
+
interface Profile {
|
|
219
|
+
/**
|
|
220
|
+
* Profile unique identifier
|
|
221
|
+
*/
|
|
222
|
+
id?: string;
|
|
223
|
+
/**
|
|
224
|
+
* When the profile was created
|
|
225
|
+
*/
|
|
226
|
+
created_at?: string;
|
|
227
|
+
/**
|
|
228
|
+
* Profile description
|
|
229
|
+
*/
|
|
230
|
+
description?: string | null;
|
|
231
|
+
/**
|
|
232
|
+
* Profile icon URL
|
|
233
|
+
*/
|
|
234
|
+
icon?: string | null;
|
|
235
|
+
/**
|
|
236
|
+
* Profile name
|
|
237
|
+
*/
|
|
238
|
+
name?: string;
|
|
239
|
+
/**
|
|
240
|
+
* User's role in this profile: admin, billing, developer (inherited from
|
|
241
|
+
* organization if not explicitly set)
|
|
242
|
+
*/
|
|
243
|
+
role?: string | null;
|
|
244
|
+
/**
|
|
245
|
+
* Profile configuration settings
|
|
246
|
+
*/
|
|
247
|
+
settings?: MeAPI.ProfileSettings;
|
|
248
|
+
/**
|
|
249
|
+
* Profile short name (abbreviation)
|
|
250
|
+
*/
|
|
251
|
+
short_name?: string | null;
|
|
252
|
+
/**
|
|
253
|
+
* Profile setup status: incomplete, pending_review, approved, rejected
|
|
254
|
+
*/
|
|
255
|
+
status?: string | null;
|
|
256
|
+
}
|
|
257
|
+
}
|
|
258
|
+
}
|
|
259
|
+
export interface MeRetrieveParams {
|
|
260
|
+
/**
|
|
261
|
+
* Profile UUID to scope the request to a child profile. Only organization API keys
|
|
262
|
+
* can use this header. The profile must belong to the calling organization.
|
|
263
|
+
*/
|
|
264
|
+
'x-profile-id'?: string;
|
|
265
|
+
}
|
|
266
|
+
export declare namespace Me {
|
|
267
|
+
export { type ProfileSettings as ProfileSettings, type MeRetrieveResponse as MeRetrieveResponse, type MeRetrieveParams as MeRetrieveParams, };
|
|
268
|
+
}
|
|
269
|
+
//# sourceMappingURL=me.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"me.d.mts","sourceRoot":"","sources":["../src/resources/me.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,KAAK;OACV,KAAK,WAAW;OAChB,EAAE,UAAU,EAAE;OAEd,EAAE,cAAc,EAAE;AAEzB;;GAEG;AACH,qBAAa,EAAG,SAAQ,WAAW;IACjC;;;;;;;;;;;;;;;;OAgBG;IACH,QAAQ,CACN,MAAM,GAAE,gBAAgB,GAAG,IAAI,GAAG,SAAc,EAChD,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,kBAAkB,CAAC;CAUlC;AAED;;GAEG;AACH,MAAM,WAAW,eAAe;IAC9B;;OAEG;IACH,qBAAqB,CAAC,EAAE,OAAO,GAAG,IAAI,CAAC;IAEvC;;OAEG;IACH,sBAAsB,CAAC,EAAE,OAAO,GAAG,IAAI,CAAC;IAExC;;OAEG;IACH,aAAa,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAE9B;;OAEG;IACH,gBAAgB,CAAC,EAAE,OAAO,GAAG,IAAI,CAAC;IAElC;;OAEG;IACH,iBAAiB,CAAC,EAAE,OAAO,GAAG,IAAI,CAAC;IAEnC;;OAEG;IACH,oBAAoB,CAAC,EAAE,OAAO,GAAG,IAAI,CAAC;IAEtC;;OAEG;IACH,iBAAiB,CAAC,EAAE,OAAO,GAAG,IAAI,CA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B;;eAEG;YACH,MAAM,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;SACxB;KACF;CACF;AAED,MAAM,WAAW,gBAAgB;IAC/B;;;OAGG;IACH,cAAc,CAAC,EAAE,MAAM,CAAC;CACzB;AAED,MAAM,CAAC,OAAO,WAAW,EAAE,CAAC;IAC1B,OAAO,EACL,KAAK,eAAe,IAAI,eAAe,EACvC,KAAK,kBAAkB,IAAI,kBAAkB,EAC7C,KAAK,gBAAgB,IAAI,gBAAgB,GAC1C,CAAC;CACH"}
|
|
@@ -0,0 +1,269 @@
|
|
|
1
|
+
import { APIResource } from "../core/resource.js";
|
|
2
|
+
import * as MeAPI from "./me.js";
|
|
3
|
+
import * as WebhooksAPI from "./webhooks.js";
|
|
4
|
+
import { APIPromise } from "../core/api-promise.js";
|
|
5
|
+
import { RequestOptions } from "../internal/request-options.js";
|
|
6
|
+
/**
|
|
7
|
+
* Retrieve account details
|
|
8
|
+
*/
|
|
9
|
+
export declare class Me extends APIResource {
|
|
10
|
+
/**
|
|
11
|
+
* Returns the account associated with the provided API key. The response includes
|
|
12
|
+
* account identity, contact information, messaging channel configuration, and —
|
|
13
|
+
* depending on the account type — either a list of child profiles or the profile's
|
|
14
|
+
* own settings.
|
|
15
|
+
*
|
|
16
|
+
* **Account types:**
|
|
17
|
+
*
|
|
18
|
+
* - `organization` — Has child profiles. The `profiles` array is populated.
|
|
19
|
+
* - `user` — Standalone account with no profiles.
|
|
20
|
+
* - `profile` — Child of an organization. Includes `organization_id`,
|
|
21
|
+
* `short_name`, `status`, and `settings`.
|
|
22
|
+
*
|
|
23
|
+
* **Channels:** The `channels` object always includes `sms`, `whatsapp`, and
|
|
24
|
+
* `rcs`. Each channel has a `configured` boolean. Configured channels expose
|
|
25
|
+
* additional details such as `phone_number`.
|
|
26
|
+
*/
|
|
27
|
+
retrieve(params?: MeRetrieveParams | null | undefined, options?: RequestOptions): APIPromise<MeRetrieveResponse>;
|
|
28
|
+
}
|
|
29
|
+
/**
|
|
30
|
+
* Profile configuration settings
|
|
31
|
+
*/
|
|
32
|
+
export interface ProfileSettings {
|
|
33
|
+
/**
|
|
34
|
+
* Whether contacts are shared across profiles in the organization
|
|
35
|
+
*/
|
|
36
|
+
allow_contact_sharing?: boolean | null;
|
|
37
|
+
/**
|
|
38
|
+
* Whether templates are shared across profiles in the organization
|
|
39
|
+
*/
|
|
40
|
+
allow_template_sharing?: boolean | null;
|
|
41
|
+
/**
|
|
42
|
+
* Billing model: profile, organization, or profile_and_organization
|
|
43
|
+
*/
|
|
44
|
+
billing_model?: string | null;
|
|
45
|
+
/**
|
|
46
|
+
* Whether this profile inherits contacts from the organization
|
|
47
|
+
*/
|
|
48
|
+
inherit_contacts?: boolean | null;
|
|
49
|
+
/**
|
|
50
|
+
* Whether this profile inherits TCR brand from the organization
|
|
51
|
+
*/
|
|
52
|
+
inherit_tcr_brand?: boolean | null;
|
|
53
|
+
/**
|
|
54
|
+
* Whether this profile inherits TCR campaign from the organization
|
|
55
|
+
*/
|
|
56
|
+
inherit_tcr_campaign?: boolean | null;
|
|
57
|
+
/**
|
|
58
|
+
* Whether this profile inherits templates from the organization
|
|
59
|
+
*/
|
|
60
|
+
inherit_templates?: boolean | null;
|
|
61
|
+
}
|
|
62
|
+
/**
|
|
63
|
+
* Standard API response envelope for all v3 endpoints
|
|
64
|
+
*/
|
|
65
|
+
export interface MeRetrieveResponse {
|
|
66
|
+
/**
|
|
67
|
+
* Account response for GET /v3/me endpoint. Returns organization (with profiles),
|
|
68
|
+
* user (standalone), or profile (child of an organization) data depending on the
|
|
69
|
+
* API key type. Always includes messaging channel configuration.
|
|
70
|
+
*/
|
|
71
|
+
data?: MeRetrieveResponse.Data | null;
|
|
72
|
+
/**
|
|
73
|
+
* Error information
|
|
74
|
+
*/
|
|
75
|
+
error?: WebhooksAPI.ErrorDetail | null;
|
|
76
|
+
/**
|
|
77
|
+
* Request and response metadata
|
|
78
|
+
*/
|
|
79
|
+
meta?: WebhooksAPI.APIMeta;
|
|
80
|
+
/**
|
|
81
|
+
* Indicates whether the request was successful
|
|
82
|
+
*/
|
|
83
|
+
success?: boolean;
|
|
84
|
+
}
|
|
85
|
+
export declare namespace MeRetrieveResponse {
|
|
86
|
+
/**
|
|
87
|
+
* Account response for GET /v3/me endpoint. Returns organization (with profiles),
|
|
88
|
+
* user (standalone), or profile (child of an organization) data depending on the
|
|
89
|
+
* API key type. Always includes messaging channel configuration.
|
|
90
|
+
*/
|
|
91
|
+
interface Data {
|
|
92
|
+
/**
|
|
93
|
+
* Customer ID (organization, account, or profile)
|
|
94
|
+
*/
|
|
95
|
+
id?: string;
|
|
96
|
+
/**
|
|
97
|
+
* Messaging channel configuration. All three channels are always present. Each
|
|
98
|
+
* channel has a "configured" flag; configured channels expose additional details.
|
|
99
|
+
*/
|
|
100
|
+
channels?: Data.Channels;
|
|
101
|
+
/**
|
|
102
|
+
* When the account was created
|
|
103
|
+
*/
|
|
104
|
+
created_at?: string;
|
|
105
|
+
/**
|
|
106
|
+
* Account description
|
|
107
|
+
*/
|
|
108
|
+
description?: string | null;
|
|
109
|
+
/**
|
|
110
|
+
* Contact email address
|
|
111
|
+
*/
|
|
112
|
+
email?: string | null;
|
|
113
|
+
/**
|
|
114
|
+
* Account icon URL
|
|
115
|
+
*/
|
|
116
|
+
icon?: string | null;
|
|
117
|
+
/**
|
|
118
|
+
* Account name
|
|
119
|
+
*/
|
|
120
|
+
name?: string;
|
|
121
|
+
/**
|
|
122
|
+
* Organization ID (only for profile type — the parent organization)
|
|
123
|
+
*/
|
|
124
|
+
organization_id?: string | null;
|
|
125
|
+
/**
|
|
126
|
+
* List of profiles (populated for organization type, empty for user and profile
|
|
127
|
+
* types)
|
|
128
|
+
*/
|
|
129
|
+
profiles?: Array<Data.Profile>;
|
|
130
|
+
/**
|
|
131
|
+
* Profile configuration settings
|
|
132
|
+
*/
|
|
133
|
+
settings?: MeAPI.ProfileSettings | null;
|
|
134
|
+
/**
|
|
135
|
+
* Short name / abbreviation (only for profile type)
|
|
136
|
+
*/
|
|
137
|
+
short_name?: string | null;
|
|
138
|
+
/**
|
|
139
|
+
* Profile status (only for profile type): incomplete, pending_review, approved,
|
|
140
|
+
* etc.
|
|
141
|
+
*/
|
|
142
|
+
status?: string | null;
|
|
143
|
+
/**
|
|
144
|
+
* Account type: "organization" (has profiles), "user" (no profiles), or "profile"
|
|
145
|
+
* (child of an organization)
|
|
146
|
+
*/
|
|
147
|
+
type?: string;
|
|
148
|
+
}
|
|
149
|
+
namespace Data {
|
|
150
|
+
/**
|
|
151
|
+
* Messaging channel configuration. All three channels are always present. Each
|
|
152
|
+
* channel has a "configured" flag; configured channels expose additional details.
|
|
153
|
+
*/
|
|
154
|
+
interface Channels {
|
|
155
|
+
/**
|
|
156
|
+
* RCS channel configuration. When configured, includes the RCS phone number.
|
|
157
|
+
*/
|
|
158
|
+
rcs?: Channels.Rcs;
|
|
159
|
+
/**
|
|
160
|
+
* SMS channel configuration. When configured, includes the sending phone number.
|
|
161
|
+
*/
|
|
162
|
+
sms?: Channels.SMS;
|
|
163
|
+
/**
|
|
164
|
+
* WhatsApp Business channel configuration. When configured, includes the WhatsApp
|
|
165
|
+
* phone number and business name.
|
|
166
|
+
*/
|
|
167
|
+
whatsapp?: Channels.Whatsapp;
|
|
168
|
+
}
|
|
169
|
+
namespace Channels {
|
|
170
|
+
/**
|
|
171
|
+
* RCS channel configuration. When configured, includes the RCS phone number.
|
|
172
|
+
*/
|
|
173
|
+
interface Rcs {
|
|
174
|
+
/**
|
|
175
|
+
* Whether RCS is configured for this account
|
|
176
|
+
*/
|
|
177
|
+
configured?: boolean;
|
|
178
|
+
/**
|
|
179
|
+
* RCS-enabled phone number in E.164 format
|
|
180
|
+
*/
|
|
181
|
+
phone_number?: string | null;
|
|
182
|
+
}
|
|
183
|
+
/**
|
|
184
|
+
* SMS channel configuration. When configured, includes the sending phone number.
|
|
185
|
+
*/
|
|
186
|
+
interface SMS {
|
|
187
|
+
/**
|
|
188
|
+
* Whether SMS is configured for this account
|
|
189
|
+
*/
|
|
190
|
+
configured?: boolean;
|
|
191
|
+
/**
|
|
192
|
+
* Sending phone number in E.164 format
|
|
193
|
+
*/
|
|
194
|
+
phone_number?: string | null;
|
|
195
|
+
}
|
|
196
|
+
/**
|
|
197
|
+
* WhatsApp Business channel configuration. When configured, includes the WhatsApp
|
|
198
|
+
* phone number and business name.
|
|
199
|
+
*/
|
|
200
|
+
interface Whatsapp {
|
|
201
|
+
/**
|
|
202
|
+
* WhatsApp Business display name
|
|
203
|
+
*/
|
|
204
|
+
business_name?: string | null;
|
|
205
|
+
/**
|
|
206
|
+
* Whether WhatsApp is configured for this account
|
|
207
|
+
*/
|
|
208
|
+
configured?: boolean;
|
|
209
|
+
/**
|
|
210
|
+
* WhatsApp phone number in E.164 format
|
|
211
|
+
*/
|
|
212
|
+
phone_number?: string | null;
|
|
213
|
+
}
|
|
214
|
+
}
|
|
215
|
+
/**
|
|
216
|
+
* Profile (sender profile) response for v3 API
|
|
217
|
+
*/
|
|
218
|
+
interface Profile {
|
|
219
|
+
/**
|
|
220
|
+
* Profile unique identifier
|
|
221
|
+
*/
|
|
222
|
+
id?: string;
|
|
223
|
+
/**
|
|
224
|
+
* When the profile was created
|
|
225
|
+
*/
|
|
226
|
+
created_at?: string;
|
|
227
|
+
/**
|
|
228
|
+
* Profile description
|
|
229
|
+
*/
|
|
230
|
+
description?: string | null;
|
|
231
|
+
/**
|
|
232
|
+
* Profile icon URL
|
|
233
|
+
*/
|
|
234
|
+
icon?: string | null;
|
|
235
|
+
/**
|
|
236
|
+
* Profile name
|
|
237
|
+
*/
|
|
238
|
+
name?: string;
|
|
239
|
+
/**
|
|
240
|
+
* User's role in this profile: admin, billing, developer (inherited from
|
|
241
|
+
* organization if not explicitly set)
|
|
242
|
+
*/
|
|
243
|
+
role?: string | null;
|
|
244
|
+
/**
|
|
245
|
+
* Profile configuration settings
|
|
246
|
+
*/
|
|
247
|
+
settings?: MeAPI.ProfileSettings;
|
|
248
|
+
/**
|
|
249
|
+
* Profile short name (abbreviation)
|
|
250
|
+
*/
|
|
251
|
+
short_name?: string | null;
|
|
252
|
+
/**
|
|
253
|
+
* Profile setup status: incomplete, pending_review, approved, rejected
|
|
254
|
+
*/
|
|
255
|
+
status?: string | null;
|
|
256
|
+
}
|
|
257
|
+
}
|
|
258
|
+
}
|
|
259
|
+
export interface MeRetrieveParams {
|
|
260
|
+
/**
|
|
261
|
+
* Profile UUID to scope the request to a child profile. Only organization API keys
|
|
262
|
+
* can use this header. The profile must belong to the calling organization.
|
|
263
|
+
*/
|
|
264
|
+
'x-profile-id'?: string;
|
|
265
|
+
}
|
|
266
|
+
export declare namespace Me {
|
|
267
|
+
export { type ProfileSettings as ProfileSettings, type MeRetrieveResponse as MeRetrieveResponse, type MeRetrieveParams as MeRetrieveParams, };
|
|
268
|
+
}
|
|
269
|
+
//# sourceMappingURL=me.d.ts.map
|