@surgeapi/node 0.25.7 → 0.26.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +11 -0
- package/LICENSE +201 -21
- package/README.md +318 -115
- package/api-promise.d.mts +2 -0
- package/api-promise.d.mts.map +1 -0
- package/api-promise.d.ts +2 -0
- package/api-promise.d.ts.map +1 -0
- package/api-promise.js +6 -0
- package/api-promise.js.map +1 -0
- package/api-promise.mjs +2 -0
- package/api-promise.mjs.map +1 -0
- package/client.d.mts +208 -0
- package/client.d.mts.map +1 -0
- package/client.d.ts +208 -0
- package/client.d.ts.map +1 -0
- package/client.js +476 -0
- package/client.js.map +1 -0
- package/client.mjs +472 -0
- package/client.mjs.map +1 -0
- package/core/api-promise.d.mts +46 -0
- package/core/api-promise.d.mts.map +1 -0
- package/core/api-promise.d.ts +46 -0
- package/core/api-promise.d.ts.map +1 -0
- package/core/api-promise.js +74 -0
- package/core/api-promise.js.map +1 -0
- package/core/api-promise.mjs +70 -0
- package/core/api-promise.mjs.map +1 -0
- package/core/error.d.mts +46 -0
- package/core/error.d.mts.map +1 -0
- package/core/error.d.ts +46 -0
- package/core/error.d.ts.map +1 -0
- package/core/error.js +113 -0
- package/core/error.js.map +1 -0
- package/core/error.mjs +97 -0
- package/core/error.mjs.map +1 -0
- package/core/resource.d.mts +6 -0
- package/core/resource.d.mts.map +1 -0
- package/core/resource.d.ts +6 -0
- package/core/resource.d.ts.map +1 -0
- package/core/resource.js +11 -0
- package/core/resource.js.map +1 -0
- package/core/resource.mjs +7 -0
- package/core/resource.mjs.map +1 -0
- package/core/uploads.d.mts +3 -0
- package/core/uploads.d.mts.map +1 -0
- package/core/uploads.d.ts +3 -0
- package/core/uploads.d.ts.map +1 -0
- package/core/uploads.js +6 -0
- package/core/uploads.js.map +1 -0
- package/core/uploads.mjs +2 -0
- package/core/uploads.mjs.map +1 -0
- package/error.d.mts +2 -0
- package/error.d.mts.map +1 -0
- package/error.d.ts +2 -0
- package/error.d.ts.map +1 -0
- package/error.js +6 -0
- package/error.js.map +1 -0
- package/error.mjs +2 -0
- package/error.mjs.map +1 -0
- package/index.d.mts +6 -0
- package/index.d.mts.map +1 -0
- package/index.d.ts +6 -4
- package/index.d.ts.map +1 -0
- package/index.js +28 -42
- package/index.js.map +1 -0
- package/index.mjs +7 -0
- package/index.mjs.map +1 -0
- package/internal/builtin-types.d.mts +73 -0
- package/internal/builtin-types.d.mts.map +1 -0
- package/internal/builtin-types.d.ts +73 -0
- package/internal/builtin-types.d.ts.map +1 -0
- package/internal/builtin-types.js +4 -0
- package/internal/builtin-types.js.map +1 -0
- package/internal/builtin-types.mjs +3 -0
- package/internal/builtin-types.mjs.map +1 -0
- package/internal/detect-platform.d.mts +15 -0
- package/internal/detect-platform.d.mts.map +1 -0
- package/internal/detect-platform.d.ts +15 -0
- package/internal/detect-platform.d.ts.map +1 -0
- package/internal/detect-platform.js +162 -0
- package/internal/detect-platform.js.map +1 -0
- package/internal/detect-platform.mjs +157 -0
- package/internal/detect-platform.mjs.map +1 -0
- package/internal/errors.d.mts +3 -0
- package/internal/errors.d.mts.map +1 -0
- package/internal/errors.d.ts +3 -0
- package/internal/errors.d.ts.map +1 -0
- package/internal/errors.js +41 -0
- package/internal/errors.js.map +1 -0
- package/internal/errors.mjs +36 -0
- package/internal/errors.mjs.map +1 -0
- package/internal/headers.d.mts +20 -0
- package/internal/headers.d.mts.map +1 -0
- package/internal/headers.d.ts +20 -0
- package/internal/headers.d.ts.map +1 -0
- package/internal/headers.js +79 -0
- package/internal/headers.js.map +1 -0
- package/internal/headers.mjs +74 -0
- package/internal/headers.mjs.map +1 -0
- package/internal/parse.d.mts +12 -0
- package/internal/parse.d.mts.map +1 -0
- package/internal/parse.d.ts +12 -0
- package/internal/parse.d.ts.map +1 -0
- package/internal/parse.js +35 -0
- package/internal/parse.js.map +1 -0
- package/internal/parse.mjs +32 -0
- package/internal/parse.mjs.map +1 -0
- package/internal/qs/formats.d.mts +7 -0
- package/internal/qs/formats.d.mts.map +1 -0
- package/internal/qs/formats.d.ts +7 -0
- package/internal/qs/formats.d.ts.map +1 -0
- package/internal/qs/formats.js +13 -0
- package/internal/qs/formats.js.map +1 -0
- package/internal/qs/formats.mjs +9 -0
- package/internal/qs/formats.mjs.map +1 -0
- package/internal/qs/index.d.mts +10 -0
- package/internal/qs/index.d.mts.map +1 -0
- package/internal/qs/index.d.ts +10 -0
- package/internal/qs/index.d.ts.map +1 -0
- package/internal/qs/index.js +14 -0
- package/internal/qs/index.js.map +1 -0
- package/internal/qs/index.mjs +10 -0
- package/internal/qs/index.mjs.map +1 -0
- package/internal/qs/stringify.d.mts +3 -0
- package/internal/qs/stringify.d.mts.map +1 -0
- package/internal/qs/stringify.d.ts +3 -0
- package/internal/qs/stringify.d.ts.map +1 -0
- package/internal/qs/stringify.js +277 -0
- package/internal/qs/stringify.js.map +1 -0
- package/internal/qs/stringify.mjs +274 -0
- package/internal/qs/stringify.mjs.map +1 -0
- package/internal/qs/types.d.mts +57 -0
- package/internal/qs/types.d.mts.map +1 -0
- package/internal/qs/types.d.ts +57 -0
- package/internal/qs/types.d.ts.map +1 -0
- package/internal/qs/types.js +3 -0
- package/internal/qs/types.js.map +1 -0
- package/internal/qs/types.mjs +2 -0
- package/internal/qs/types.mjs.map +1 -0
- package/internal/qs/utils.d.mts +15 -0
- package/internal/qs/utils.d.mts.map +1 -0
- package/internal/qs/utils.d.ts +15 -0
- package/internal/qs/utils.d.ts.map +1 -0
- package/internal/qs/utils.js +230 -0
- package/internal/qs/utils.js.map +1 -0
- package/internal/qs/utils.mjs +217 -0
- package/internal/qs/utils.mjs.map +1 -0
- package/internal/request-options.d.mts +75 -0
- package/internal/request-options.d.mts.map +1 -0
- package/internal/request-options.d.ts +75 -0
- package/internal/request-options.d.ts.map +1 -0
- package/internal/request-options.js +14 -0
- package/internal/request-options.js.map +1 -0
- package/internal/request-options.mjs +10 -0
- package/internal/request-options.mjs.map +1 -0
- package/internal/shim-types.d.mts +17 -0
- package/internal/shim-types.d.mts.map +1 -0
- package/internal/shim-types.d.ts +17 -0
- package/internal/shim-types.d.ts.map +1 -0
- package/internal/shim-types.js +4 -0
- package/internal/shim-types.js.map +1 -0
- package/internal/shim-types.mjs +3 -0
- package/internal/shim-types.mjs.map +1 -0
- package/internal/shims.d.mts +20 -0
- package/internal/shims.d.mts.map +1 -0
- package/internal/shims.d.ts +20 -0
- package/internal/shims.d.ts.map +1 -0
- package/internal/shims.js +92 -0
- package/internal/shims.js.map +1 -0
- package/internal/shims.mjs +85 -0
- package/internal/shims.mjs.map +1 -0
- package/internal/to-file.d.mts +45 -0
- package/internal/to-file.d.mts.map +1 -0
- package/internal/to-file.d.ts +45 -0
- package/internal/to-file.d.ts.map +1 -0
- package/internal/to-file.js +91 -0
- package/internal/to-file.js.map +1 -0
- package/internal/to-file.mjs +88 -0
- package/internal/to-file.mjs.map +1 -0
- package/internal/tslib.js +81 -0
- package/internal/tslib.mjs +17 -0
- package/internal/types.d.mts +69 -0
- package/internal/types.d.mts.map +1 -0
- package/internal/types.d.ts +69 -0
- package/internal/types.d.ts.map +1 -0
- package/internal/types.js +4 -0
- package/internal/types.js.map +1 -0
- package/internal/types.mjs +3 -0
- package/internal/types.mjs.map +1 -0
- package/internal/uploads.d.mts +42 -0
- package/internal/uploads.d.mts.map +1 -0
- package/internal/uploads.d.ts +42 -0
- package/internal/uploads.d.ts.map +1 -0
- package/internal/uploads.js +141 -0
- package/internal/uploads.js.map +1 -0
- package/internal/uploads.mjs +131 -0
- package/internal/uploads.mjs.map +1 -0
- package/internal/utils/base64.d.mts +3 -0
- package/internal/utils/base64.d.mts.map +1 -0
- package/internal/utils/base64.d.ts +3 -0
- package/internal/utils/base64.d.ts.map +1 -0
- package/internal/utils/base64.js +38 -0
- package/internal/utils/base64.js.map +1 -0
- package/internal/utils/base64.mjs +33 -0
- package/internal/utils/base64.mjs.map +1 -0
- package/internal/utils/bytes.d.mts +4 -0
- package/internal/utils/bytes.d.mts.map +1 -0
- package/internal/utils/bytes.d.ts +4 -0
- package/internal/utils/bytes.d.ts.map +1 -0
- package/internal/utils/bytes.js +31 -0
- package/internal/utils/bytes.js.map +1 -0
- package/internal/utils/bytes.mjs +26 -0
- package/internal/utils/bytes.mjs.map +1 -0
- package/internal/utils/env.d.mts +9 -0
- package/internal/utils/env.d.mts.map +1 -0
- package/internal/utils/env.d.ts +9 -0
- package/internal/utils/env.d.ts.map +1 -0
- package/internal/utils/env.js +22 -0
- package/internal/utils/env.js.map +1 -0
- package/internal/utils/env.mjs +18 -0
- package/internal/utils/env.mjs.map +1 -0
- package/internal/utils/log.d.mts +37 -0
- package/internal/utils/log.d.mts.map +1 -0
- package/internal/utils/log.d.ts +37 -0
- package/internal/utils/log.d.ts.map +1 -0
- package/internal/utils/log.js +85 -0
- package/internal/utils/log.js.map +1 -0
- package/internal/utils/log.mjs +79 -0
- package/internal/utils/log.mjs.map +1 -0
- package/internal/utils/path.d.mts +15 -0
- package/internal/utils/path.d.mts.map +1 -0
- package/internal/utils/path.d.ts +15 -0
- package/internal/utils/path.d.ts.map +1 -0
- package/internal/utils/path.js +79 -0
- package/internal/utils/path.js.map +1 -0
- package/internal/utils/path.mjs +74 -0
- package/internal/utils/path.mjs.map +1 -0
- package/internal/utils/sleep.d.mts +2 -0
- package/internal/utils/sleep.d.mts.map +1 -0
- package/internal/utils/sleep.d.ts +2 -0
- package/internal/utils/sleep.d.ts.map +1 -0
- package/internal/utils/sleep.js +7 -0
- package/internal/utils/sleep.js.map +1 -0
- package/internal/utils/sleep.mjs +3 -0
- package/internal/utils/sleep.mjs.map +1 -0
- package/internal/utils/uuid.d.mts +5 -0
- package/internal/utils/uuid.d.mts.map +1 -0
- package/internal/utils/uuid.d.ts +5 -0
- package/internal/utils/uuid.d.ts.map +1 -0
- package/internal/utils/uuid.js +19 -0
- package/internal/utils/uuid.js.map +1 -0
- package/internal/utils/uuid.mjs +15 -0
- package/internal/utils/uuid.mjs.map +1 -0
- package/internal/utils/values.d.mts +18 -0
- package/internal/utils/values.d.mts.map +1 -0
- package/internal/utils/values.d.ts +18 -0
- package/internal/utils/values.d.ts.map +1 -0
- package/internal/utils/values.js +112 -0
- package/internal/utils/values.js.map +1 -0
- package/internal/utils/values.mjs +94 -0
- package/internal/utils/values.mjs.map +1 -0
- package/internal/utils.d.mts +7 -0
- package/internal/utils.d.mts.map +1 -0
- package/internal/utils.d.ts +7 -0
- package/internal/utils.d.ts.map +1 -0
- package/internal/utils.js +11 -0
- package/internal/utils.js.map +1 -0
- package/internal/utils.mjs +8 -0
- package/internal/utils.mjs.map +1 -0
- package/package.json +139 -44
- package/resource.d.mts +2 -0
- package/resource.d.mts.map +1 -0
- package/resource.d.ts +2 -0
- package/resource.d.ts.map +1 -0
- package/resource.js +6 -0
- package/resource.js.map +1 -0
- package/resource.mjs +2 -0
- package/resource.mjs.map +1 -0
- package/resources/accounts.d.mts +526 -0
- package/resources/accounts.d.mts.map +1 -0
- package/resources/accounts.d.ts +526 -0
- package/resources/accounts.d.ts.map +1 -0
- package/resources/accounts.js +49 -0
- package/resources/accounts.js.map +1 -0
- package/resources/accounts.mjs +45 -0
- package/resources/accounts.mjs.map +1 -0
- package/resources/blasts.d.mts +110 -0
- package/resources/blasts.d.mts.map +1 -0
- package/resources/blasts.d.ts +110 -0
- package/resources/blasts.d.ts.map +1 -0
- package/resources/blasts.js +23 -0
- package/resources/blasts.js.map +1 -0
- package/resources/blasts.mjs +19 -0
- package/resources/blasts.mjs.map +1 -0
- package/resources/campaigns.d.mts +346 -0
- package/resources/campaigns.d.mts.map +1 -0
- package/resources/campaigns.d.ts +346 -0
- package/resources/campaigns.d.ts.map +1 -0
- package/resources/campaigns.js +41 -0
- package/resources/campaigns.js.map +1 -0
- package/resources/campaigns.mjs +37 -0
- package/resources/campaigns.mjs.map +1 -0
- package/resources/contacts.d.mts +151 -0
- package/resources/contacts.d.mts.map +1 -0
- package/resources/contacts.d.ts +151 -0
- package/resources/contacts.d.ts.map +1 -0
- package/resources/contacts.js +52 -0
- package/resources/contacts.js.map +1 -0
- package/resources/contacts.mjs +48 -0
- package/resources/contacts.mjs.map +1 -0
- package/resources/index.d.mts +11 -0
- package/resources/index.d.mts.map +1 -0
- package/resources/index.d.ts +11 -0
- package/resources/index.d.ts.map +1 -0
- package/resources/index.js +25 -0
- package/resources/index.js.map +1 -0
- package/resources/index.mjs +12 -0
- package/resources/index.mjs.map +1 -0
- package/resources/messages.d.mts +263 -0
- package/resources/messages.d.mts.map +1 -0
- package/resources/messages.d.ts +263 -0
- package/resources/messages.d.ts.map +1 -0
- package/resources/messages.js +52 -0
- package/resources/messages.js.map +1 -0
- package/resources/messages.mjs +48 -0
- package/resources/messages.mjs.map +1 -0
- package/resources/phone-numbers.d.mts +90 -0
- package/resources/phone-numbers.d.mts.map +1 -0
- package/resources/phone-numbers.d.ts +90 -0
- package/resources/phone-numbers.d.ts.map +1 -0
- package/resources/phone-numbers.js +24 -0
- package/resources/phone-numbers.js.map +1 -0
- package/resources/phone-numbers.mjs +20 -0
- package/resources/phone-numbers.mjs.map +1 -0
- package/resources/shared.d.mts +20 -0
- package/resources/shared.d.mts.map +1 -0
- package/resources/shared.d.ts +20 -0
- package/resources/shared.d.ts.map +1 -0
- package/resources/shared.js +4 -0
- package/resources/shared.js.map +1 -0
- package/resources/shared.mjs +3 -0
- package/resources/shared.mjs.map +1 -0
- package/resources/users.d.mts +170 -0
- package/resources/users.d.mts.map +1 -0
- package/resources/users.d.ts +170 -0
- package/resources/users.d.ts.map +1 -0
- package/resources/users.js +65 -0
- package/resources/users.js.map +1 -0
- package/resources/users.mjs +61 -0
- package/resources/users.mjs.map +1 -0
- package/resources/verifications.d.mts +96 -0
- package/resources/verifications.d.mts.map +1 -0
- package/resources/verifications.d.ts +96 -0
- package/resources/verifications.d.ts.map +1 -0
- package/resources/verifications.js +37 -0
- package/resources/verifications.js.map +1 -0
- package/resources/verifications.mjs +33 -0
- package/resources/verifications.mjs.map +1 -0
- package/resources/webhooks.d.mts +484 -0
- package/resources/webhooks.d.mts.map +1 -0
- package/resources/webhooks.d.ts +484 -0
- package/resources/webhooks.d.ts.map +1 -0
- package/resources/webhooks.js +20 -0
- package/resources/webhooks.js.map +1 -0
- package/resources/webhooks.mjs +16 -0
- package/resources/webhooks.mjs.map +1 -0
- package/resources.d.mts +2 -0
- package/resources.d.mts.map +1 -0
- package/resources.d.ts +2 -0
- package/resources.d.ts.map +1 -0
- package/resources.js +5 -0
- package/resources.js.map +1 -0
- package/resources.mjs +2 -0
- package/resources.mjs.map +1 -0
- package/src/api-promise.ts +2 -0
- package/src/client.ts +874 -0
- package/src/core/README.md +3 -0
- package/src/core/api-promise.ts +92 -0
- package/src/core/error.ts +130 -0
- package/src/core/resource.ts +11 -0
- package/src/core/uploads.ts +2 -0
- package/src/error.ts +2 -0
- package/src/index.ts +22 -0
- package/src/internal/README.md +3 -0
- package/src/internal/builtin-types.ts +93 -0
- package/src/internal/detect-platform.ts +196 -0
- package/src/internal/errors.ts +33 -0
- package/src/internal/headers.ts +97 -0
- package/src/internal/parse.ts +50 -0
- package/src/internal/qs/LICENSE.md +13 -0
- package/src/internal/qs/README.md +3 -0
- package/src/internal/qs/formats.ts +10 -0
- package/src/internal/qs/index.ts +13 -0
- package/src/internal/qs/stringify.ts +385 -0
- package/src/internal/qs/types.ts +71 -0
- package/src/internal/qs/utils.ts +265 -0
- package/src/internal/request-options.ts +91 -0
- package/src/internal/shim-types.ts +26 -0
- package/src/internal/shims.ts +107 -0
- package/src/internal/to-file.ts +154 -0
- package/src/internal/types.ts +95 -0
- package/src/internal/uploads.ts +187 -0
- package/src/internal/utils/base64.ts +40 -0
- package/src/internal/utils/bytes.ts +32 -0
- package/src/internal/utils/env.ts +18 -0
- package/src/internal/utils/log.ts +126 -0
- package/src/internal/utils/path.ts +88 -0
- package/src/internal/utils/sleep.ts +3 -0
- package/src/internal/utils/uuid.ts +17 -0
- package/src/internal/utils/values.ts +105 -0
- package/src/internal/utils.ts +8 -0
- package/src/lib/.keep +4 -0
- package/src/resource.ts +2 -0
- package/src/resources/accounts.ts +778 -0
- package/src/resources/blasts.ts +140 -0
- package/src/resources/campaigns.ts +417 -0
- package/src/resources/contacts.ts +181 -0
- package/src/resources/index.ts +60 -0
- package/src/resources/messages.ts +314 -0
- package/src/resources/phone-numbers.ts +111 -0
- package/src/resources/shared.ts +21 -0
- package/src/resources/users.ts +209 -0
- package/src/resources/verifications.ts +121 -0
- package/src/resources/webhooks.ts +605 -0
- package/src/resources.ts +1 -0
- package/src/tsconfig.json +11 -0
- package/src/uploads.ts +2 -0
- package/src/version.ts +1 -0
- package/uploads.d.mts +2 -0
- package/uploads.d.mts.map +1 -0
- package/uploads.d.ts +2 -0
- package/uploads.d.ts.map +1 -0
- package/uploads.js +6 -0
- package/uploads.js.map +1 -0
- package/uploads.mjs +2 -0
- package/uploads.mjs.map +1 -0
- package/version.d.mts +2 -0
- package/version.d.mts.map +1 -0
- package/version.d.ts +2 -1
- package/version.d.ts.map +1 -0
- package/version.js +3 -2
- package/version.js.map +1 -0
- package/version.mjs +2 -0
- package/version.mjs.map +1 -0
- package/Client.d.ts +0 -49
- package/Client.js +0 -47
- package/api/errors/ConflictError.d.ts +0 -9
- package/api/errors/ConflictError.js +0 -52
- package/api/errors/UnprocessableEntityError.d.ts +0 -9
- package/api/errors/UnprocessableEntityError.js +0 -52
- package/api/errors/index.d.ts +0 -2
- package/api/errors/index.js +0 -18
- package/api/index.d.ts +0 -3
- package/api/index.js +0 -19
- package/api/resources/accounts/client/Client.d.ts +0 -59
- package/api/resources/accounts/client/Client.js +0 -179
- package/api/resources/accounts/client/index.d.ts +0 -1
- package/api/resources/accounts/client/index.js +0 -17
- package/api/resources/accounts/client/requests/CreateAccountRequest.d.ts +0 -16
- package/api/resources/accounts/client/requests/CreateAccountRequest.js +0 -5
- package/api/resources/accounts/client/requests/UpdateAccountRequest.d.ts +0 -16
- package/api/resources/accounts/client/requests/UpdateAccountRequest.js +0 -5
- package/api/resources/accounts/client/requests/index.d.ts +0 -2
- package/api/resources/accounts/client/requests/index.js +0 -2
- package/api/resources/accounts/index.d.ts +0 -1
- package/api/resources/accounts/index.js +0 -17
- package/api/resources/blasts/client/Client.d.ts +0 -50
- package/api/resources/blasts/client/Client.js +0 -128
- package/api/resources/blasts/client/index.d.ts +0 -1
- package/api/resources/blasts/client/index.js +0 -17
- package/api/resources/blasts/client/requests/BlastRequest.d.ts +0 -31
- package/api/resources/blasts/client/requests/BlastRequest.js +0 -5
- package/api/resources/blasts/client/requests/index.d.ts +0 -1
- package/api/resources/blasts/client/requests/index.js +0 -2
- package/api/resources/blasts/index.d.ts +0 -1
- package/api/resources/blasts/index.js +0 -17
- package/api/resources/contacts/client/Client.d.ts +0 -81
- package/api/resources/contacts/client/Client.js +0 -242
- package/api/resources/contacts/client/index.d.ts +0 -1
- package/api/resources/contacts/client/index.js +0 -2
- package/api/resources/contacts/index.d.ts +0 -1
- package/api/resources/contacts/index.js +0 -17
- package/api/resources/index.d.ts +0 -14
- package/api/resources/index.js +0 -53
- package/api/resources/messages/client/Client.d.ts +0 -54
- package/api/resources/messages/client/Client.js +0 -132
- package/api/resources/messages/client/index.d.ts +0 -1
- package/api/resources/messages/client/index.js +0 -17
- package/api/resources/messages/client/requests/MessageRequest.d.ts +0 -28
- package/api/resources/messages/client/requests/MessageRequest.js +0 -5
- package/api/resources/messages/client/requests/index.d.ts +0 -1
- package/api/resources/messages/client/requests/index.js +0 -2
- package/api/resources/messages/index.d.ts +0 -1
- package/api/resources/messages/index.js +0 -17
- package/api/resources/phoneNumbers/client/Client.d.ts +0 -45
- package/api/resources/phoneNumbers/client/Client.js +0 -123
- package/api/resources/phoneNumbers/client/index.d.ts +0 -1
- package/api/resources/phoneNumbers/client/index.js +0 -17
- package/api/resources/phoneNumbers/client/requests/CreatePhoneNumberRequest.d.ts +0 -17
- package/api/resources/phoneNumbers/client/requests/CreatePhoneNumberRequest.js +0 -5
- package/api/resources/phoneNumbers/client/requests/index.d.ts +0 -1
- package/api/resources/phoneNumbers/client/requests/index.js +0 -2
- package/api/resources/phoneNumbers/index.d.ts +0 -2
- package/api/resources/phoneNumbers/index.js +0 -18
- package/api/resources/phoneNumbers/types/CreatePhoneNumberRequestType.d.ts +0 -11
- package/api/resources/phoneNumbers/types/CreatePhoneNumberRequestType.js +0 -10
- package/api/resources/phoneNumbers/types/index.d.ts +0 -1
- package/api/resources/phoneNumbers/types/index.js +0 -17
- package/api/resources/users/client/Client.d.ts +0 -61
- package/api/resources/users/client/Client.js +0 -180
- package/api/resources/users/client/index.d.ts +0 -1
- package/api/resources/users/client/index.js +0 -17
- package/api/resources/users/client/requests/UserRequest.d.ts +0 -25
- package/api/resources/users/client/requests/UserRequest.js +0 -5
- package/api/resources/users/client/requests/index.d.ts +0 -1
- package/api/resources/users/client/requests/index.js +0 -2
- package/api/resources/users/index.d.ts +0 -1
- package/api/resources/users/index.js +0 -17
- package/api/resources/verifications/client/Client.d.ts +0 -60
- package/api/resources/verifications/client/Client.js +0 -188
- package/api/resources/verifications/client/index.d.ts +0 -1
- package/api/resources/verifications/client/index.js +0 -17
- package/api/resources/verifications/client/requests/VerificationCheckRequest.d.ts +0 -13
- package/api/resources/verifications/client/requests/VerificationCheckRequest.js +0 -5
- package/api/resources/verifications/client/requests/VerificationRequest.d.ts +0 -13
- package/api/resources/verifications/client/requests/VerificationRequest.js +0 -5
- package/api/resources/verifications/client/requests/index.d.ts +0 -2
- package/api/resources/verifications/client/requests/index.js +0 -2
- package/api/resources/verifications/index.d.ts +0 -1
- package/api/resources/verifications/index.js +0 -17
- package/api/types/AccountResponse.d.ts +0 -14
- package/api/types/AccountResponse.js +0 -5
- package/api/types/AttachmentParams.d.ts +0 -10
- package/api/types/AttachmentParams.js +0 -5
- package/api/types/AttachmentResponse.d.ts +0 -14
- package/api/types/AttachmentResponse.js +0 -5
- package/api/types/BlastResponse.d.ts +0 -18
- package/api/types/BlastResponse.js +0 -5
- package/api/types/BlastResponseAttachmentsItem.d.ts +0 -7
- package/api/types/BlastResponseAttachmentsItem.js +0 -5
- package/api/types/Contact.d.ts +0 -16
- package/api/types/Contact.js +0 -5
- package/api/types/ContactRequest.d.ts +0 -18
- package/api/types/ContactRequest.js +0 -5
- package/api/types/ContactResponse.d.ts +0 -20
- package/api/types/ContactResponse.js +0 -5
- package/api/types/Conversation.d.ts +0 -13
- package/api/types/Conversation.js +0 -5
- package/api/types/ConversationPhoneNumber.d.ts +0 -15
- package/api/types/ConversationPhoneNumber.js +0 -5
- package/api/types/ConversationPhoneNumberType.d.ts +0 -13
- package/api/types/ConversationPhoneNumberType.js +0 -12
- package/api/types/MessageConversationContactParams.d.ts +0 -14
- package/api/types/MessageConversationContactParams.js +0 -5
- package/api/types/MessageConversationParams.d.ts +0 -12
- package/api/types/MessageConversationParams.js +0 -5
- package/api/types/MessageResponse.d.ts +0 -15
- package/api/types/MessageResponse.js +0 -5
- package/api/types/PhoneNumber.d.ts +0 -15
- package/api/types/PhoneNumber.js +0 -5
- package/api/types/PhoneNumberType.d.ts +0 -11
- package/api/types/PhoneNumberType.js +0 -10
- package/api/types/UserResponse.d.ts +0 -18
- package/api/types/UserResponse.js +0 -5
- package/api/types/Verification.d.ts +0 -17
- package/api/types/Verification.js +0 -5
- package/api/types/VerificationCheckAlreadyVerifiedResponse.d.ts +0 -12
- package/api/types/VerificationCheckAlreadyVerifiedResponse.js +0 -5
- package/api/types/VerificationCheckAlreadyVerifiedResponseResult.d.ts +0 -14
- package/api/types/VerificationCheckAlreadyVerifiedResponseResult.js +0 -13
- package/api/types/VerificationCheckIncorrectResponse.d.ts +0 -12
- package/api/types/VerificationCheckIncorrectResponse.js +0 -5
- package/api/types/VerificationCheckIncorrectResponseResult.d.ts +0 -12
- package/api/types/VerificationCheckIncorrectResponseResult.js +0 -11
- package/api/types/VerificationCheckOkResponse.d.ts +0 -21
- package/api/types/VerificationCheckOkResponse.js +0 -5
- package/api/types/VerificationCheckOkResponseResult.d.ts +0 -21
- package/api/types/VerificationCheckOkResponseResult.js +0 -13
- package/api/types/VerificationStatus.d.ts +0 -13
- package/api/types/VerificationStatus.js +0 -12
- package/api/types/index.d.ts +0 -25
- package/api/types/index.js +0 -41
- package/core/auth/BasicAuth.d.ts +0 -8
- package/core/auth/BasicAuth.js +0 -26
- package/core/auth/BearerToken.d.ts +0 -5
- package/core/auth/BearerToken.js +0 -15
- package/core/auth/index.d.ts +0 -2
- package/core/auth/index.js +0 -7
- package/core/fetcher/APIResponse.d.ts +0 -20
- package/core/fetcher/APIResponse.js +0 -2
- package/core/fetcher/Fetcher.d.ts +0 -39
- package/core/fetcher/Fetcher.js +0 -107
- package/core/fetcher/Headers.d.ts +0 -2
- package/core/fetcher/Headers.js +0 -84
- package/core/fetcher/HttpResponsePromise.d.ts +0 -58
- package/core/fetcher/HttpResponsePromise.js +0 -103
- package/core/fetcher/RawResponse.d.ts +0 -29
- package/core/fetcher/RawResponse.js +0 -44
- package/core/fetcher/Supplier.d.ts +0 -4
- package/core/fetcher/Supplier.js +0 -22
- package/core/fetcher/createRequestUrl.d.ts +0 -1
- package/core/fetcher/createRequestUrl.js +0 -12
- package/core/fetcher/getFetchFn.d.ts +0 -4
- package/core/fetcher/getFetchFn.js +0 -68
- package/core/fetcher/getHeader.d.ts +0 -1
- package/core/fetcher/getHeader.js +0 -11
- package/core/fetcher/getRequestBody.d.ts +0 -7
- package/core/fetcher/getRequestBody.js +0 -23
- package/core/fetcher/getResponseBody.d.ts +0 -1
- package/core/fetcher/getResponseBody.js +0 -54
- package/core/fetcher/index.d.ts +0 -8
- package/core/fetcher/index.js +0 -15
- package/core/fetcher/makeRequest.d.ts +0 -1
- package/core/fetcher/makeRequest.js +0 -42
- package/core/fetcher/requestWithRetries.d.ts +0 -1
- package/core/fetcher/requestWithRetries.js +0 -40
- package/core/fetcher/signals.d.ts +0 -11
- package/core/fetcher/signals.js +0 -36
- package/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.d.ts +0 -30
- package/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.js +0 -247
- package/core/fetcher/stream-wrappers/NodePre18StreamWrapper.d.ts +0 -21
- package/core/fetcher/stream-wrappers/NodePre18StreamWrapper.js +0 -126
- package/core/fetcher/stream-wrappers/UndiciStreamWrapper.d.ts +0 -31
- package/core/fetcher/stream-wrappers/UndiciStreamWrapper.js +0 -229
- package/core/fetcher/stream-wrappers/chooseStreamWrapper.d.ts +0 -18
- package/core/fetcher/stream-wrappers/chooseStreamWrapper.js +0 -59
- package/core/index.d.ts +0 -3
- package/core/index.js +0 -19
- package/core/json.d.ts +0 -15
- package/core/json.js +0 -24
- package/core/runtime/index.d.ts +0 -1
- package/core/runtime/index.js +0 -5
- package/core/runtime/runtime.d.ts +0 -9
- package/core/runtime/runtime.js +0 -103
- package/dist/Client.d.ts +0 -49
- package/dist/Client.js +0 -47
- package/dist/api/errors/ConflictError.d.ts +0 -9
- package/dist/api/errors/ConflictError.js +0 -52
- package/dist/api/errors/UnprocessableEntityError.d.ts +0 -9
- package/dist/api/errors/UnprocessableEntityError.js +0 -52
- package/dist/api/errors/index.d.ts +0 -2
- package/dist/api/errors/index.js +0 -18
- package/dist/api/index.d.ts +0 -3
- package/dist/api/index.js +0 -19
- package/dist/api/resources/accounts/client/Client.d.ts +0 -59
- package/dist/api/resources/accounts/client/Client.js +0 -179
- package/dist/api/resources/accounts/client/index.d.ts +0 -1
- package/dist/api/resources/accounts/client/index.js +0 -17
- package/dist/api/resources/accounts/client/requests/CreateAccountRequest.d.ts +0 -16
- package/dist/api/resources/accounts/client/requests/CreateAccountRequest.js +0 -5
- package/dist/api/resources/accounts/client/requests/UpdateAccountRequest.d.ts +0 -16
- package/dist/api/resources/accounts/client/requests/UpdateAccountRequest.js +0 -5
- package/dist/api/resources/accounts/client/requests/index.d.ts +0 -2
- package/dist/api/resources/accounts/client/requests/index.js +0 -2
- package/dist/api/resources/accounts/index.d.ts +0 -1
- package/dist/api/resources/accounts/index.js +0 -17
- package/dist/api/resources/blasts/client/Client.d.ts +0 -50
- package/dist/api/resources/blasts/client/Client.js +0 -128
- package/dist/api/resources/blasts/client/index.d.ts +0 -1
- package/dist/api/resources/blasts/client/index.js +0 -17
- package/dist/api/resources/blasts/client/requests/BlastRequest.d.ts +0 -31
- package/dist/api/resources/blasts/client/requests/BlastRequest.js +0 -5
- package/dist/api/resources/blasts/client/requests/index.d.ts +0 -1
- package/dist/api/resources/blasts/client/requests/index.js +0 -2
- package/dist/api/resources/blasts/index.d.ts +0 -1
- package/dist/api/resources/blasts/index.js +0 -17
- package/dist/api/resources/contacts/client/Client.d.ts +0 -81
- package/dist/api/resources/contacts/client/Client.js +0 -242
- package/dist/api/resources/contacts/client/index.d.ts +0 -1
- package/dist/api/resources/contacts/client/index.js +0 -2
- package/dist/api/resources/contacts/index.d.ts +0 -1
- package/dist/api/resources/contacts/index.js +0 -17
- package/dist/api/resources/index.d.ts +0 -14
- package/dist/api/resources/index.js +0 -53
- package/dist/api/resources/messages/client/Client.d.ts +0 -54
- package/dist/api/resources/messages/client/Client.js +0 -132
- package/dist/api/resources/messages/client/index.d.ts +0 -1
- package/dist/api/resources/messages/client/index.js +0 -17
- package/dist/api/resources/messages/client/requests/MessageRequest.d.ts +0 -28
- package/dist/api/resources/messages/client/requests/MessageRequest.js +0 -5
- package/dist/api/resources/messages/client/requests/index.d.ts +0 -1
- package/dist/api/resources/messages/client/requests/index.js +0 -2
- package/dist/api/resources/messages/index.d.ts +0 -1
- package/dist/api/resources/messages/index.js +0 -17
- package/dist/api/resources/phoneNumbers/client/Client.d.ts +0 -45
- package/dist/api/resources/phoneNumbers/client/Client.js +0 -123
- package/dist/api/resources/phoneNumbers/client/index.d.ts +0 -1
- package/dist/api/resources/phoneNumbers/client/index.js +0 -17
- package/dist/api/resources/phoneNumbers/client/requests/CreatePhoneNumberRequest.d.ts +0 -17
- package/dist/api/resources/phoneNumbers/client/requests/CreatePhoneNumberRequest.js +0 -5
- package/dist/api/resources/phoneNumbers/client/requests/index.d.ts +0 -1
- package/dist/api/resources/phoneNumbers/client/requests/index.js +0 -2
- package/dist/api/resources/phoneNumbers/index.d.ts +0 -2
- package/dist/api/resources/phoneNumbers/index.js +0 -18
- package/dist/api/resources/phoneNumbers/types/CreatePhoneNumberRequestType.d.ts +0 -11
- package/dist/api/resources/phoneNumbers/types/CreatePhoneNumberRequestType.js +0 -10
- package/dist/api/resources/phoneNumbers/types/index.d.ts +0 -1
- package/dist/api/resources/phoneNumbers/types/index.js +0 -17
- package/dist/api/resources/users/client/Client.d.ts +0 -61
- package/dist/api/resources/users/client/Client.js +0 -180
- package/dist/api/resources/users/client/index.d.ts +0 -1
- package/dist/api/resources/users/client/index.js +0 -17
- package/dist/api/resources/users/client/requests/UserRequest.d.ts +0 -25
- package/dist/api/resources/users/client/requests/UserRequest.js +0 -5
- package/dist/api/resources/users/client/requests/index.d.ts +0 -1
- package/dist/api/resources/users/client/requests/index.js +0 -2
- package/dist/api/resources/users/index.d.ts +0 -1
- package/dist/api/resources/users/index.js +0 -17
- package/dist/api/resources/verifications/client/Client.d.ts +0 -60
- package/dist/api/resources/verifications/client/Client.js +0 -188
- package/dist/api/resources/verifications/client/index.d.ts +0 -1
- package/dist/api/resources/verifications/client/index.js +0 -17
- package/dist/api/resources/verifications/client/requests/VerificationCheckRequest.d.ts +0 -13
- package/dist/api/resources/verifications/client/requests/VerificationCheckRequest.js +0 -5
- package/dist/api/resources/verifications/client/requests/VerificationRequest.d.ts +0 -13
- package/dist/api/resources/verifications/client/requests/VerificationRequest.js +0 -5
- package/dist/api/resources/verifications/client/requests/index.d.ts +0 -2
- package/dist/api/resources/verifications/client/requests/index.js +0 -2
- package/dist/api/resources/verifications/index.d.ts +0 -1
- package/dist/api/resources/verifications/index.js +0 -17
- package/dist/api/types/AccountResponse.d.ts +0 -14
- package/dist/api/types/AccountResponse.js +0 -5
- package/dist/api/types/AttachmentParams.d.ts +0 -10
- package/dist/api/types/AttachmentParams.js +0 -5
- package/dist/api/types/AttachmentResponse.d.ts +0 -14
- package/dist/api/types/AttachmentResponse.js +0 -5
- package/dist/api/types/BlastResponse.d.ts +0 -18
- package/dist/api/types/BlastResponse.js +0 -5
- package/dist/api/types/BlastResponseAttachmentsItem.d.ts +0 -7
- package/dist/api/types/BlastResponseAttachmentsItem.js +0 -5
- package/dist/api/types/Contact.d.ts +0 -16
- package/dist/api/types/Contact.js +0 -5
- package/dist/api/types/ContactRequest.d.ts +0 -18
- package/dist/api/types/ContactRequest.js +0 -5
- package/dist/api/types/ContactResponse.d.ts +0 -20
- package/dist/api/types/ContactResponse.js +0 -5
- package/dist/api/types/Conversation.d.ts +0 -13
- package/dist/api/types/Conversation.js +0 -5
- package/dist/api/types/ConversationPhoneNumber.d.ts +0 -15
- package/dist/api/types/ConversationPhoneNumber.js +0 -5
- package/dist/api/types/ConversationPhoneNumberType.d.ts +0 -13
- package/dist/api/types/ConversationPhoneNumberType.js +0 -12
- package/dist/api/types/MessageConversationContactParams.d.ts +0 -14
- package/dist/api/types/MessageConversationContactParams.js +0 -5
- package/dist/api/types/MessageConversationParams.d.ts +0 -12
- package/dist/api/types/MessageConversationParams.js +0 -5
- package/dist/api/types/MessageResponse.d.ts +0 -15
- package/dist/api/types/MessageResponse.js +0 -5
- package/dist/api/types/PhoneNumber.d.ts +0 -15
- package/dist/api/types/PhoneNumber.js +0 -5
- package/dist/api/types/PhoneNumberType.d.ts +0 -11
- package/dist/api/types/PhoneNumberType.js +0 -10
- package/dist/api/types/UserResponse.d.ts +0 -18
- package/dist/api/types/UserResponse.js +0 -5
- package/dist/api/types/Verification.d.ts +0 -17
- package/dist/api/types/Verification.js +0 -5
- package/dist/api/types/VerificationCheckAlreadyVerifiedResponse.d.ts +0 -12
- package/dist/api/types/VerificationCheckAlreadyVerifiedResponse.js +0 -5
- package/dist/api/types/VerificationCheckAlreadyVerifiedResponseResult.d.ts +0 -14
- package/dist/api/types/VerificationCheckAlreadyVerifiedResponseResult.js +0 -13
- package/dist/api/types/VerificationCheckIncorrectResponse.d.ts +0 -12
- package/dist/api/types/VerificationCheckIncorrectResponse.js +0 -5
- package/dist/api/types/VerificationCheckIncorrectResponseResult.d.ts +0 -12
- package/dist/api/types/VerificationCheckIncorrectResponseResult.js +0 -11
- package/dist/api/types/VerificationCheckOkResponse.d.ts +0 -21
- package/dist/api/types/VerificationCheckOkResponse.js +0 -5
- package/dist/api/types/VerificationCheckOkResponseResult.d.ts +0 -21
- package/dist/api/types/VerificationCheckOkResponseResult.js +0 -13
- package/dist/api/types/VerificationStatus.d.ts +0 -13
- package/dist/api/types/VerificationStatus.js +0 -12
- package/dist/api/types/index.d.ts +0 -25
- package/dist/api/types/index.js +0 -41
- package/dist/core/auth/BasicAuth.d.ts +0 -8
- package/dist/core/auth/BasicAuth.js +0 -26
- package/dist/core/auth/BearerToken.d.ts +0 -5
- package/dist/core/auth/BearerToken.js +0 -15
- package/dist/core/auth/index.d.ts +0 -2
- package/dist/core/auth/index.js +0 -7
- package/dist/core/fetcher/APIResponse.d.ts +0 -20
- package/dist/core/fetcher/APIResponse.js +0 -2
- package/dist/core/fetcher/Fetcher.d.ts +0 -39
- package/dist/core/fetcher/Fetcher.js +0 -107
- package/dist/core/fetcher/Headers.d.ts +0 -2
- package/dist/core/fetcher/Headers.js +0 -84
- package/dist/core/fetcher/HttpResponsePromise.d.ts +0 -58
- package/dist/core/fetcher/HttpResponsePromise.js +0 -103
- package/dist/core/fetcher/RawResponse.d.ts +0 -29
- package/dist/core/fetcher/RawResponse.js +0 -44
- package/dist/core/fetcher/Supplier.d.ts +0 -4
- package/dist/core/fetcher/Supplier.js +0 -22
- package/dist/core/fetcher/createRequestUrl.d.ts +0 -1
- package/dist/core/fetcher/createRequestUrl.js +0 -12
- package/dist/core/fetcher/getFetchFn.d.ts +0 -4
- package/dist/core/fetcher/getFetchFn.js +0 -68
- package/dist/core/fetcher/getHeader.d.ts +0 -1
- package/dist/core/fetcher/getHeader.js +0 -11
- package/dist/core/fetcher/getRequestBody.d.ts +0 -7
- package/dist/core/fetcher/getRequestBody.js +0 -23
- package/dist/core/fetcher/getResponseBody.d.ts +0 -1
- package/dist/core/fetcher/getResponseBody.js +0 -54
- package/dist/core/fetcher/index.d.ts +0 -8
- package/dist/core/fetcher/index.js +0 -15
- package/dist/core/fetcher/makeRequest.d.ts +0 -1
- package/dist/core/fetcher/makeRequest.js +0 -42
- package/dist/core/fetcher/requestWithRetries.d.ts +0 -1
- package/dist/core/fetcher/requestWithRetries.js +0 -40
- package/dist/core/fetcher/signals.d.ts +0 -11
- package/dist/core/fetcher/signals.js +0 -36
- package/dist/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.d.ts +0 -30
- package/dist/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.js +0 -247
- package/dist/core/fetcher/stream-wrappers/NodePre18StreamWrapper.d.ts +0 -21
- package/dist/core/fetcher/stream-wrappers/NodePre18StreamWrapper.js +0 -126
- package/dist/core/fetcher/stream-wrappers/UndiciStreamWrapper.d.ts +0 -31
- package/dist/core/fetcher/stream-wrappers/UndiciStreamWrapper.js +0 -229
- package/dist/core/fetcher/stream-wrappers/chooseStreamWrapper.d.ts +0 -18
- package/dist/core/fetcher/stream-wrappers/chooseStreamWrapper.js +0 -59
- package/dist/core/index.d.ts +0 -3
- package/dist/core/index.js +0 -19
- package/dist/core/json.d.ts +0 -15
- package/dist/core/json.js +0 -24
- package/dist/core/runtime/index.d.ts +0 -1
- package/dist/core/runtime/index.js +0 -5
- package/dist/core/runtime/runtime.d.ts +0 -9
- package/dist/core/runtime/runtime.js +0 -103
- package/dist/environments.d.ts +0 -7
- package/dist/environments.js +0 -9
- package/dist/errors/SurgeError.d.ts +0 -15
- package/dist/errors/SurgeError.js +0 -30
- package/dist/errors/SurgeTimeoutError.d.ts +0 -6
- package/dist/errors/SurgeTimeoutError.js +0 -13
- package/dist/errors/index.d.ts +0 -2
- package/dist/errors/index.js +0 -7
- package/dist/index.d.ts +0 -4
- package/dist/index.js +0 -44
- package/dist/version.d.ts +0 -1
- package/dist/version.js +0 -4
- package/environments.d.ts +0 -7
- package/environments.js +0 -9
- package/errors/SurgeError.d.ts +0 -15
- package/errors/SurgeError.js +0 -30
- package/errors/SurgeTimeoutError.d.ts +0 -6
- package/errors/SurgeTimeoutError.js +0 -13
- package/errors/index.d.ts +0 -2
- package/errors/index.js +0 -7
- package/jest.config.mjs +0 -8
- package/reference.md +0 -896
- package/scripts/rename-to-esm-files.js +0 -115
package/README.md
CHANGED
|
@@ -1,182 +1,385 @@
|
|
|
1
|
-
# Surge TypeScript Library
|
|
1
|
+
# Surge TypeScript API Library
|
|
2
2
|
|
|
3
|
-
[](https://www.npmjs.com/package/@surgeapi/node)
|
|
3
|
+
[>)](https://npmjs.org/package/@surgeapi/node) 
|
|
5
4
|
|
|
6
|
-
|
|
5
|
+
This library provides convenient access to the Surge REST API from server-side TypeScript or JavaScript.
|
|
7
6
|
|
|
8
|
-
|
|
7
|
+
The REST API documentation can be found on [docs.surge.app](https://docs.surge.app). The full API of this library can be found in [api.md](api.md).
|
|
9
8
|
|
|
10
|
-
|
|
9
|
+
It is generated with [Stainless](https://www.stainless.com/).
|
|
11
10
|
|
|
12
11
|
## Installation
|
|
13
12
|
|
|
14
13
|
```sh
|
|
15
|
-
npm
|
|
14
|
+
npm install @surgeapi/node
|
|
16
15
|
```
|
|
17
16
|
|
|
18
|
-
##
|
|
17
|
+
## Usage
|
|
19
18
|
|
|
20
|
-
|
|
19
|
+
The full API of this library can be found in [api.md](api.md).
|
|
21
20
|
|
|
22
|
-
|
|
21
|
+
<!-- prettier-ignore -->
|
|
22
|
+
```js
|
|
23
|
+
import Surge from '@surgeapi/node';
|
|
24
|
+
|
|
25
|
+
const client = new Surge({
|
|
26
|
+
apiKey: process.env['SURGE_API_KEY'], // This is the default and can be omitted
|
|
27
|
+
});
|
|
23
28
|
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
const client = new SurgeClient({ token: "YOUR_TOKEN" });
|
|
30
|
-
await client.messages.send("acct_01j9a43avnfqzbjfch6pygv1td", {
|
|
31
|
-
attachments: [
|
|
32
|
-
{
|
|
33
|
-
url: "https://toretto.family/coronas.gif",
|
|
34
|
-
},
|
|
35
|
-
],
|
|
36
|
-
body: "Thought you could leave without saying goodbye?",
|
|
37
|
-
conversation: {
|
|
38
|
-
contact: {
|
|
39
|
-
first_name: "Dominic",
|
|
40
|
-
last_name: "Toretto",
|
|
41
|
-
phone_number: "+18015551234",
|
|
42
|
-
},
|
|
43
|
-
},
|
|
29
|
+
const message = await client.messages.create('acct_01j9a43avnfqzbjfch6pygv1td', {
|
|
30
|
+
conversation: { contact: { first_name: 'Dom', last_name: 'Toretto', phone_number: '+13235556439' } },
|
|
31
|
+
attachments: [{ url: 'https://toretto.family/coronas.gif' }],
|
|
32
|
+
body: 'Thought you could leave without saying goodbye?',
|
|
44
33
|
});
|
|
34
|
+
|
|
35
|
+
console.log(message.id);
|
|
45
36
|
```
|
|
46
37
|
|
|
47
|
-
|
|
38
|
+
### Request & Response types
|
|
48
39
|
|
|
49
|
-
|
|
50
|
-
following namespace:
|
|
40
|
+
This library includes TypeScript definitions for all request params and response fields. You may import and use them like so:
|
|
51
41
|
|
|
52
|
-
|
|
53
|
-
|
|
42
|
+
<!-- prettier-ignore -->
|
|
43
|
+
```ts
|
|
44
|
+
import Surge from '@surgeapi/node';
|
|
54
45
|
|
|
55
|
-
const
|
|
56
|
-
|
|
46
|
+
const client = new Surge({
|
|
47
|
+
apiKey: process.env['SURGE_API_KEY'], // This is the default and can be omitted
|
|
48
|
+
});
|
|
49
|
+
|
|
50
|
+
const params: Surge.MessageCreateParams = {
|
|
51
|
+
conversation: { contact: { first_name: 'Dom', last_name: 'Toretto', phone_number: '+13235556439' } },
|
|
52
|
+
attachments: [{ url: 'https://toretto.family/coronas.gif' }],
|
|
53
|
+
body: 'Thought you could leave without saying goodbye?',
|
|
57
54
|
};
|
|
55
|
+
const message: Surge.Message = await client.messages.create('acct_01j9a43avnfqzbjfch6pygv1td', params);
|
|
58
56
|
```
|
|
59
57
|
|
|
60
|
-
|
|
58
|
+
Documentation for each method, request param, and response field are available in docstrings and will appear on hover in most modern editors.
|
|
59
|
+
|
|
60
|
+
## Handling errors
|
|
61
|
+
|
|
62
|
+
When the library is unable to connect to the API,
|
|
63
|
+
or if the API returns a non-success status code (i.e., 4xx or 5xx response),
|
|
64
|
+
a subclass of `APIError` will be thrown:
|
|
65
|
+
|
|
66
|
+
<!-- prettier-ignore -->
|
|
67
|
+
```ts
|
|
68
|
+
const message = await client.messages
|
|
69
|
+
.create('acct_01j9a43avnfqzbjfch6pygv1td', {
|
|
70
|
+
conversation: { contact: { first_name: 'Dom', last_name: 'Toretto', phone_number: '+13235556439' } },
|
|
71
|
+
attachments: [{ url: 'https://toretto.family/coronas.gif' }],
|
|
72
|
+
body: 'Thought you could leave without saying goodbye?',
|
|
73
|
+
})
|
|
74
|
+
.catch(async (err) => {
|
|
75
|
+
if (err instanceof Surge.APIError) {
|
|
76
|
+
console.log(err.status); // 400
|
|
77
|
+
console.log(err.name); // BadRequestError
|
|
78
|
+
console.log(err.headers); // {server: 'nginx', ...}
|
|
79
|
+
} else {
|
|
80
|
+
throw err;
|
|
81
|
+
}
|
|
82
|
+
});
|
|
83
|
+
```
|
|
61
84
|
|
|
62
|
-
|
|
63
|
-
will be thrown.
|
|
85
|
+
Error codes are as follows:
|
|
64
86
|
|
|
65
|
-
|
|
66
|
-
|
|
87
|
+
| Status Code | Error Type |
|
|
88
|
+
| ----------- | -------------------------- |
|
|
89
|
+
| 400 | `BadRequestError` |
|
|
90
|
+
| 401 | `AuthenticationError` |
|
|
91
|
+
| 403 | `PermissionDeniedError` |
|
|
92
|
+
| 404 | `NotFoundError` |
|
|
93
|
+
| 422 | `UnprocessableEntityError` |
|
|
94
|
+
| 429 | `RateLimitError` |
|
|
95
|
+
| >=500 | `InternalServerError` |
|
|
96
|
+
| N/A | `APIConnectionError` |
|
|
67
97
|
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
98
|
+
### Retries
|
|
99
|
+
|
|
100
|
+
Certain errors will be automatically retried 2 times by default, with a short exponential backoff.
|
|
101
|
+
Connection errors (for example, due to a network connectivity problem), 408 Request Timeout, 409 Conflict,
|
|
102
|
+
429 Rate Limit, and >=500 Internal errors will all be retried by default.
|
|
103
|
+
|
|
104
|
+
You can use the `maxRetries` option to configure or disable this:
|
|
105
|
+
|
|
106
|
+
<!-- prettier-ignore -->
|
|
107
|
+
```js
|
|
108
|
+
// Configure the default for all requests:
|
|
109
|
+
const client = new Surge({
|
|
110
|
+
maxRetries: 0, // default is 2
|
|
111
|
+
});
|
|
112
|
+
|
|
113
|
+
// Or, configure per-request:
|
|
114
|
+
await client.messages.create('acct_01j9a43avnfqzbjfch6pygv1td', { conversation: { contact: { first_name: 'Dom', last_name: 'Toretto', phone_number: '+13235556439' } }, attachments: [{ url: 'https://toretto.family/coronas.gif' }], body: 'Thought you could leave without saying goodbye?' }, {
|
|
115
|
+
maxRetries: 5,
|
|
116
|
+
});
|
|
78
117
|
```
|
|
79
118
|
|
|
80
|
-
|
|
119
|
+
### Timeouts
|
|
81
120
|
|
|
82
|
-
|
|
121
|
+
Requests time out after 1 minute by default. You can configure this with a `timeout` option:
|
|
83
122
|
|
|
84
|
-
|
|
123
|
+
<!-- prettier-ignore -->
|
|
124
|
+
```ts
|
|
125
|
+
// Configure the default for all requests:
|
|
126
|
+
const client = new Surge({
|
|
127
|
+
timeout: 20 * 1000, // 20 seconds (default is 1 minute)
|
|
128
|
+
});
|
|
85
129
|
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
'X-Custom-Header': 'custom value'
|
|
90
|
-
}
|
|
130
|
+
// Override per-request:
|
|
131
|
+
await client.messages.create('acct_01j9a43avnfqzbjfch6pygv1td', { conversation: { contact: { first_name: 'Dom', last_name: 'Toretto', phone_number: '+13235556439' } }, attachments: [{ url: 'https://toretto.family/coronas.gif' }], body: 'Thought you could leave without saying goodbye?' }, {
|
|
132
|
+
timeout: 5 * 1000,
|
|
91
133
|
});
|
|
92
134
|
```
|
|
93
135
|
|
|
94
|
-
|
|
136
|
+
On timeout, an `APIConnectionTimeoutError` is thrown.
|
|
95
137
|
|
|
96
|
-
|
|
97
|
-
as the request is deemed retryable and the number of retry attempts has not grown larger than the configured
|
|
98
|
-
retry limit (default: 2).
|
|
138
|
+
Note that requests which time out will be [retried twice by default](#retries).
|
|
99
139
|
|
|
100
|
-
|
|
140
|
+
## Advanced Usage
|
|
101
141
|
|
|
102
|
-
|
|
103
|
-
- [429](https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/429) (Too Many Requests)
|
|
104
|
-
- [5XX](https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/500) (Internal Server Errors)
|
|
142
|
+
### Accessing raw Response data (e.g., headers)
|
|
105
143
|
|
|
106
|
-
|
|
144
|
+
The "raw" `Response` returned by `fetch()` can be accessed through the `.asResponse()` method on the `APIPromise` type that all methods return.
|
|
145
|
+
This method returns as soon as the headers for a successful response are received and does not consume the response body, so you are free to write custom parsing or streaming logic.
|
|
107
146
|
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
147
|
+
You can also use the `.withResponse()` method to get the raw `Response` along with the parsed data.
|
|
148
|
+
Unlike `.asResponse()` this method consumes the body, returning once it is parsed.
|
|
149
|
+
|
|
150
|
+
<!-- prettier-ignore -->
|
|
151
|
+
```ts
|
|
152
|
+
const client = new Surge();
|
|
153
|
+
|
|
154
|
+
const response = await client.messages
|
|
155
|
+
.create('acct_01j9a43avnfqzbjfch6pygv1td', {
|
|
156
|
+
conversation: { contact: { first_name: 'Dom', last_name: 'Toretto', phone_number: '+13235556439' } },
|
|
157
|
+
attachments: [{ url: 'https://toretto.family/coronas.gif' }],
|
|
158
|
+
body: 'Thought you could leave without saying goodbye?',
|
|
159
|
+
})
|
|
160
|
+
.asResponse();
|
|
161
|
+
console.log(response.headers.get('X-My-Header'));
|
|
162
|
+
console.log(response.statusText); // access the underlying Response object
|
|
163
|
+
|
|
164
|
+
const { data: message, response: raw } = await client.messages
|
|
165
|
+
.create('acct_01j9a43avnfqzbjfch6pygv1td', {
|
|
166
|
+
conversation: { contact: { first_name: 'Dom', last_name: 'Toretto', phone_number: '+13235556439' } },
|
|
167
|
+
attachments: [{ url: 'https://toretto.family/coronas.gif' }],
|
|
168
|
+
body: 'Thought you could leave without saying goodbye?',
|
|
169
|
+
})
|
|
170
|
+
.withResponse();
|
|
171
|
+
console.log(raw.headers.get('X-My-Header'));
|
|
172
|
+
console.log(message.id);
|
|
173
|
+
```
|
|
174
|
+
|
|
175
|
+
### Logging
|
|
176
|
+
|
|
177
|
+
> [!IMPORTANT]
|
|
178
|
+
> All log messages are intended for debugging only. The format and content of log messages
|
|
179
|
+
> may change between releases.
|
|
180
|
+
|
|
181
|
+
#### Log levels
|
|
182
|
+
|
|
183
|
+
The log level can be configured in two ways:
|
|
184
|
+
|
|
185
|
+
1. Via the `SURGE_LOG` environment variable
|
|
186
|
+
2. Using the `logLevel` client option (overrides the environment variable if set)
|
|
187
|
+
|
|
188
|
+
```ts
|
|
189
|
+
import Surge from '@surgeapi/node';
|
|
190
|
+
|
|
191
|
+
const client = new Surge({
|
|
192
|
+
logLevel: 'debug', // Show all log messages
|
|
111
193
|
});
|
|
112
194
|
```
|
|
113
195
|
|
|
114
|
-
|
|
196
|
+
Available log levels, from most to least verbose:
|
|
197
|
+
|
|
198
|
+
- `'debug'` - Show debug messages, info, warnings, and errors
|
|
199
|
+
- `'info'` - Show info messages, warnings, and errors
|
|
200
|
+
- `'warn'` - Show warnings and errors (default)
|
|
201
|
+
- `'error'` - Show only errors
|
|
202
|
+
- `'off'` - Disable all logging
|
|
203
|
+
|
|
204
|
+
At the `'debug'` level, all HTTP requests and responses are logged, including headers and bodies.
|
|
205
|
+
Some authentication-related headers are redacted, but sensitive data in request and response bodies
|
|
206
|
+
may still be visible.
|
|
207
|
+
|
|
208
|
+
#### Custom logger
|
|
209
|
+
|
|
210
|
+
By default, this library logs to `globalThis.console`. You can also provide a custom logger.
|
|
211
|
+
Most logging libraries are supported, including [pino](https://www.npmjs.com/package/pino), [winston](https://www.npmjs.com/package/winston), [bunyan](https://www.npmjs.com/package/bunyan), [consola](https://www.npmjs.com/package/consola), [signale](https://www.npmjs.com/package/signale), and [@std/log](https://jsr.io/@std/log). If your logger doesn't work, please open an issue.
|
|
212
|
+
|
|
213
|
+
When providing a custom logger, the `logLevel` option still controls which messages are emitted, messages
|
|
214
|
+
below the configured level will not be sent to your logger.
|
|
215
|
+
|
|
216
|
+
```ts
|
|
217
|
+
import Surge from '@surgeapi/node';
|
|
218
|
+
import pino from 'pino';
|
|
219
|
+
|
|
220
|
+
const logger = pino();
|
|
221
|
+
|
|
222
|
+
const client = new Surge({
|
|
223
|
+
logger: logger.child({ name: 'Surge' }),
|
|
224
|
+
logLevel: 'debug', // Send all messages to pino, allowing it to filter
|
|
225
|
+
});
|
|
226
|
+
```
|
|
227
|
+
|
|
228
|
+
### Making custom/undocumented requests
|
|
115
229
|
|
|
116
|
-
|
|
230
|
+
This library is typed for convenient access to the documented API. If you need to access undocumented
|
|
231
|
+
endpoints, params, or response properties, the library can still be used.
|
|
117
232
|
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
233
|
+
#### Undocumented endpoints
|
|
234
|
+
|
|
235
|
+
To make requests to undocumented endpoints, you can use `client.get`, `client.post`, and other HTTP verbs.
|
|
236
|
+
Options on the client, such as retries, will be respected when making these requests.
|
|
237
|
+
|
|
238
|
+
```ts
|
|
239
|
+
await client.post('/some/path', {
|
|
240
|
+
body: { some_prop: 'foo' },
|
|
241
|
+
query: { some_query_arg: 'bar' },
|
|
121
242
|
});
|
|
122
243
|
```
|
|
123
244
|
|
|
124
|
-
|
|
245
|
+
#### Undocumented request params
|
|
125
246
|
|
|
126
|
-
|
|
247
|
+
To make requests using undocumented parameters, you may use `// @ts-expect-error` on the undocumented
|
|
248
|
+
parameter. This library doesn't validate at runtime that the request matches the type, so any extra values you
|
|
249
|
+
send will be sent as-is.
|
|
127
250
|
|
|
128
|
-
```
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
251
|
+
```ts
|
|
252
|
+
client.messages.create({
|
|
253
|
+
// ...
|
|
254
|
+
// @ts-expect-error baz is not yet public
|
|
255
|
+
baz: 'undocumented option',
|
|
132
256
|
});
|
|
133
|
-
controller.abort(); // aborts the request
|
|
134
257
|
```
|
|
135
258
|
|
|
136
|
-
|
|
259
|
+
For requests with the `GET` verb, any extra params will be in the query, all other requests will send the
|
|
260
|
+
extra param in the body.
|
|
261
|
+
|
|
262
|
+
If you want to explicitly send an extra argument, you can do so with the `query`, `body`, and `headers` request
|
|
263
|
+
options.
|
|
137
264
|
|
|
138
|
-
|
|
139
|
-
The `.withRawResponse()` method returns a promise that results to an object with a `data` and a `rawResponse` property.
|
|
265
|
+
#### Undocumented response properties
|
|
140
266
|
|
|
141
|
-
|
|
142
|
-
|
|
267
|
+
To access undocumented response properties, you may access the response object with `// @ts-expect-error` on
|
|
268
|
+
the response object, or cast the response object to the requisite type. Like the request params, we do not
|
|
269
|
+
validate or strip extra properties from the response from the API.
|
|
143
270
|
|
|
144
|
-
|
|
145
|
-
|
|
271
|
+
### Customizing the fetch client
|
|
272
|
+
|
|
273
|
+
By default, this library expects a global `fetch` function is defined.
|
|
274
|
+
|
|
275
|
+
If you want to use a different `fetch` function, you can either polyfill the global:
|
|
276
|
+
|
|
277
|
+
```ts
|
|
278
|
+
import fetch from 'my-fetch';
|
|
279
|
+
|
|
280
|
+
globalThis.fetch = fetch;
|
|
146
281
|
```
|
|
147
282
|
|
|
148
|
-
|
|
283
|
+
Or pass it to the client:
|
|
149
284
|
|
|
150
|
-
|
|
151
|
-
|
|
285
|
+
```ts
|
|
286
|
+
import Surge from '@surgeapi/node';
|
|
287
|
+
import fetch from 'my-fetch';
|
|
152
288
|
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
- Cloudflare Workers
|
|
156
|
-
- Deno v1.25+
|
|
157
|
-
- Bun 1.0+
|
|
158
|
-
- React Native
|
|
289
|
+
const client = new Surge({ fetch });
|
|
290
|
+
```
|
|
159
291
|
|
|
160
|
-
###
|
|
292
|
+
### Fetch options
|
|
161
293
|
|
|
162
|
-
|
|
163
|
-
unsupported environment, this provides a way for you to break glass and ensure the SDK works.
|
|
294
|
+
If you want to set custom `fetch` options without overriding the `fetch` function, you can provide a `fetchOptions` object when instantiating the client or making a request. (Request-specific options override client options.)
|
|
164
295
|
|
|
165
|
-
```
|
|
166
|
-
import
|
|
296
|
+
```ts
|
|
297
|
+
import Surge from '@surgeapi/node';
|
|
167
298
|
|
|
168
|
-
const client = new
|
|
169
|
-
|
|
170
|
-
|
|
299
|
+
const client = new Surge({
|
|
300
|
+
fetchOptions: {
|
|
301
|
+
// `RequestInit` options
|
|
302
|
+
},
|
|
171
303
|
});
|
|
172
304
|
```
|
|
173
305
|
|
|
174
|
-
|
|
306
|
+
#### Configuring proxies
|
|
307
|
+
|
|
308
|
+
To modify proxy behavior, you can provide custom `fetchOptions` that add runtime-specific proxy
|
|
309
|
+
options to requests:
|
|
310
|
+
|
|
311
|
+
<img src="https://raw.githubusercontent.com/stainless-api/sdk-assets/refs/heads/main/node.svg" align="top" width="18" height="21"> **Node** <sup>[[docs](https://github.com/nodejs/undici/blob/main/docs/docs/api/ProxyAgent.md#example---proxyagent-with-fetch)]</sup>
|
|
312
|
+
|
|
313
|
+
```ts
|
|
314
|
+
import Surge from '@surgeapi/node';
|
|
315
|
+
import * as undici from 'undici';
|
|
316
|
+
|
|
317
|
+
const proxyAgent = new undici.ProxyAgent('http://localhost:8888');
|
|
318
|
+
const client = new Surge({
|
|
319
|
+
fetchOptions: {
|
|
320
|
+
dispatcher: proxyAgent,
|
|
321
|
+
},
|
|
322
|
+
});
|
|
323
|
+
```
|
|
324
|
+
|
|
325
|
+
<img src="https://raw.githubusercontent.com/stainless-api/sdk-assets/refs/heads/main/bun.svg" align="top" width="18" height="21"> **Bun** <sup>[[docs](https://bun.sh/guides/http/proxy)]</sup>
|
|
175
326
|
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
327
|
+
```ts
|
|
328
|
+
import Surge from '@surgeapi/node';
|
|
329
|
+
|
|
330
|
+
const client = new Surge({
|
|
331
|
+
fetchOptions: {
|
|
332
|
+
proxy: 'http://localhost:8888',
|
|
333
|
+
},
|
|
334
|
+
});
|
|
335
|
+
```
|
|
336
|
+
|
|
337
|
+
<img src="https://raw.githubusercontent.com/stainless-api/sdk-assets/refs/heads/main/deno.svg" align="top" width="18" height="21"> **Deno** <sup>[[docs](https://docs.deno.com/api/deno/~/Deno.createHttpClient)]</sup>
|
|
338
|
+
|
|
339
|
+
```ts
|
|
340
|
+
import Surge from 'npm:@surgeapi/node';
|
|
341
|
+
|
|
342
|
+
const httpClient = Deno.createHttpClient({ proxy: { url: 'http://localhost:8888' } });
|
|
343
|
+
const client = new Surge({
|
|
344
|
+
fetchOptions: {
|
|
345
|
+
client: httpClient,
|
|
346
|
+
},
|
|
347
|
+
});
|
|
348
|
+
```
|
|
349
|
+
|
|
350
|
+
## Frequently Asked Questions
|
|
351
|
+
|
|
352
|
+
## Semantic versioning
|
|
353
|
+
|
|
354
|
+
This package generally follows [SemVer](https://semver.org/spec/v2.0.0.html) conventions, though certain backwards-incompatible changes may be released as minor versions:
|
|
355
|
+
|
|
356
|
+
1. Changes that only affect static types, without breaking runtime behavior.
|
|
357
|
+
2. Changes to library internals which are technically public but not intended or documented for external use. _(Please open a GitHub issue to let us know if you are relying on such internals.)_
|
|
358
|
+
3. Changes that we do not expect to impact the vast majority of users in practice.
|
|
359
|
+
|
|
360
|
+
We take backwards-compatibility seriously and work hard to ensure you can rely on a smooth upgrade experience.
|
|
361
|
+
|
|
362
|
+
We are keen for your feedback; please open an [issue](https://www.github.com/surgeapi/typescript-sdk/issues) with questions, bugs, or suggestions.
|
|
363
|
+
|
|
364
|
+
## Requirements
|
|
365
|
+
|
|
366
|
+
TypeScript >= 4.9 is supported.
|
|
367
|
+
|
|
368
|
+
The following runtimes are supported:
|
|
369
|
+
|
|
370
|
+
- Web browsers (Up-to-date Chrome, Firefox, Safari, Edge, and more)
|
|
371
|
+
- Node.js 20 LTS or later ([non-EOL](https://endoflife.date/nodejs)) versions.
|
|
372
|
+
- Deno v1.28.0 or higher.
|
|
373
|
+
- Bun 1.0 or later.
|
|
374
|
+
- Cloudflare Workers.
|
|
375
|
+
- Vercel Edge Runtime.
|
|
376
|
+
- Jest 28 or greater with the `"node"` environment (`"jsdom"` is not supported at this time).
|
|
377
|
+
- Nitro v2.6 or greater.
|
|
378
|
+
|
|
379
|
+
Note that React Native is not supported at this time.
|
|
380
|
+
|
|
381
|
+
If you are interested in other runtime environments, please open or upvote an issue on GitHub.
|
|
382
|
+
|
|
383
|
+
## Contributing
|
|
181
384
|
|
|
182
|
-
|
|
385
|
+
See [the contributing documentation](./CONTRIBUTING.md).
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"api-promise.d.mts","sourceRoot":"","sources":["src/api-promise.ts"],"names":[],"mappings":""}
|
package/api-promise.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"api-promise.d.ts","sourceRoot":"","sources":["src/api-promise.ts"],"names":[],"mappings":""}
|
package/api-promise.js
ADDED
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
const tslib_1 = require("./internal/tslib.js");
|
|
4
|
+
/** @deprecated Import from ./core/api-promise instead */
|
|
5
|
+
tslib_1.__exportStar(require("./core/api-promise.js"), exports);
|
|
6
|
+
//# sourceMappingURL=api-promise.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"api-promise.js","sourceRoot":"","sources":["src/api-promise.ts"],"names":[],"mappings":";;;AAAA,yDAAyD;AACzD,gEAAmC"}
|
package/api-promise.mjs
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"api-promise.mjs","sourceRoot":"","sources":["src/api-promise.ts"],"names":[],"mappings":""}
|