@stigg/typescript 0.1.0-alpha.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +40 -0
- package/LICENSE +201 -0
- package/README.md +362 -0
- 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 +186 -0
- package/client.d.mts.map +1 -0
- package/client.d.ts +186 -0
- package/client.d.ts.map +1 -0
- package/client.js +469 -0
- package/client.js.map +1 -0
- package/client.mjs +465 -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/pagination.d.mts +55 -0
- package/core/pagination.d.mts.map +1 -0
- package/core/pagination.d.ts +55 -0
- package/core/pagination.d.ts.map +1 -0
- package/core/pagination.js +115 -0
- package/core/pagination.js.map +1 -0
- package/core/pagination.mjs +109 -0
- package/core/pagination.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 +7 -0
- package/index.d.mts.map +1 -0
- package/index.d.ts +7 -0
- package/index.d.ts.map +1 -0
- package/index.js +32 -0
- package/index.js.map +1 -0
- package/index.mjs +8 -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/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 +86 -0
- package/internal/utils/log.js.map +1 -0
- package/internal/utils/log.mjs +80 -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 +148 -0
- package/pagination.d.mts +2 -0
- package/pagination.d.mts.map +1 -0
- package/pagination.d.ts +2 -0
- package/pagination.d.ts.map +1 -0
- package/pagination.js +6 -0
- package/pagination.js.map +1 -0
- package/pagination.mjs +2 -0
- package/pagination.mjs.map +1 -0
- 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/index.d.mts +2 -0
- package/resources/index.d.mts.map +1 -0
- package/resources/index.d.ts +2 -0
- package/resources/index.d.ts.map +1 -0
- package/resources/index.js +7 -0
- package/resources/index.js.map +1 -0
- package/resources/index.mjs +3 -0
- package/resources/index.mjs.map +1 -0
- package/resources/v1/coupons.d.mts +294 -0
- package/resources/v1/coupons.d.mts.map +1 -0
- package/resources/v1/coupons.d.ts +294 -0
- package/resources/v1/coupons.d.ts.map +1 -0
- package/resources/v1/coupons.js +28 -0
- package/resources/v1/coupons.js.map +1 -0
- package/resources/v1/coupons.mjs +24 -0
- package/resources/v1/coupons.mjs.map +1 -0
- package/resources/v1/customers/customers.d.mts +352 -0
- package/resources/v1/customers/customers.d.mts.map +1 -0
- package/resources/v1/customers/customers.d.ts +352 -0
- package/resources/v1/customers/customers.d.ts.map +1 -0
- package/resources/v1/customers/customers.js +58 -0
- package/resources/v1/customers/customers.js.map +1 -0
- package/resources/v1/customers/customers.mjs +53 -0
- package/resources/v1/customers/customers.mjs.map +1 -0
- package/resources/v1/customers/index.d.mts +4 -0
- package/resources/v1/customers/index.d.mts.map +1 -0
- package/resources/v1/customers/index.d.ts +4 -0
- package/resources/v1/customers/index.d.ts.map +1 -0
- package/resources/v1/customers/index.js +11 -0
- package/resources/v1/customers/index.js.map +1 -0
- package/resources/v1/customers/index.mjs +5 -0
- package/resources/v1/customers/index.mjs.map +1 -0
- package/resources/v1/customers/payment-method.d.mts +33 -0
- package/resources/v1/customers/payment-method.d.mts.map +1 -0
- package/resources/v1/customers/payment-method.d.ts +33 -0
- package/resources/v1/customers/payment-method.d.ts.map +1 -0
- package/resources/v1/customers/payment-method.js +22 -0
- package/resources/v1/customers/payment-method.js.map +1 -0
- package/resources/v1/customers/payment-method.mjs +18 -0
- package/resources/v1/customers/payment-method.mjs.map +1 -0
- package/resources/v1/customers/usage.d.mts +98 -0
- package/resources/v1/customers/usage.d.mts.map +1 -0
- package/resources/v1/customers/usage.d.ts +98 -0
- package/resources/v1/customers/usage.d.ts.map +1 -0
- package/resources/v1/customers/usage.js +20 -0
- package/resources/v1/customers/usage.js.map +1 -0
- package/resources/v1/customers/usage.mjs +16 -0
- package/resources/v1/customers/usage.mjs.map +1 -0
- package/resources/v1/customers.d.mts +2 -0
- package/resources/v1/customers.d.mts.map +1 -0
- package/resources/v1/customers.d.ts +2 -0
- package/resources/v1/customers.d.ts.map +1 -0
- package/resources/v1/customers.js +6 -0
- package/resources/v1/customers.js.map +1 -0
- package/resources/v1/customers.mjs +3 -0
- package/resources/v1/customers.mjs.map +1 -0
- package/resources/v1/index.d.mts +5 -0
- package/resources/v1/index.d.mts.map +1 -0
- package/resources/v1/index.d.ts +5 -0
- package/resources/v1/index.d.ts.map +1 -0
- package/resources/v1/index.js +13 -0
- package/resources/v1/index.js.map +1 -0
- package/resources/v1/index.mjs +6 -0
- package/resources/v1/index.mjs.map +1 -0
- package/resources/v1/subscriptions/future-update.d.mts +39 -0
- package/resources/v1/subscriptions/future-update.d.mts.map +1 -0
- package/resources/v1/subscriptions/future-update.d.ts +39 -0
- package/resources/v1/subscriptions/future-update.d.ts.map +1 -0
- package/resources/v1/subscriptions/future-update.js +22 -0
- package/resources/v1/subscriptions/future-update.js.map +1 -0
- package/resources/v1/subscriptions/future-update.mjs +18 -0
- package/resources/v1/subscriptions/future-update.mjs.map +1 -0
- package/resources/v1/subscriptions/index.d.mts +3 -0
- package/resources/v1/subscriptions/index.d.mts.map +1 -0
- package/resources/v1/subscriptions/index.d.ts +3 -0
- package/resources/v1/subscriptions/index.d.ts.map +1 -0
- package/resources/v1/subscriptions/index.js +9 -0
- package/resources/v1/subscriptions/index.js.map +1 -0
- package/resources/v1/subscriptions/index.mjs +4 -0
- package/resources/v1/subscriptions/index.mjs.map +1 -0
- package/resources/v1/subscriptions/subscriptions.d.mts +949 -0
- package/resources/v1/subscriptions/subscriptions.d.mts.map +1 -0
- package/resources/v1/subscriptions/subscriptions.d.ts +949 -0
- package/resources/v1/subscriptions/subscriptions.d.ts.map +1 -0
- package/resources/v1/subscriptions/subscriptions.js +60 -0
- package/resources/v1/subscriptions/subscriptions.js.map +1 -0
- package/resources/v1/subscriptions/subscriptions.mjs +55 -0
- package/resources/v1/subscriptions/subscriptions.mjs.map +1 -0
- package/resources/v1/subscriptions.d.mts +2 -0
- package/resources/v1/subscriptions.d.mts.map +1 -0
- package/resources/v1/subscriptions.d.ts +2 -0
- package/resources/v1/subscriptions.d.ts.map +1 -0
- package/resources/v1/subscriptions.js +6 -0
- package/resources/v1/subscriptions.js.map +1 -0
- package/resources/v1/subscriptions.mjs +3 -0
- package/resources/v1/subscriptions.mjs.map +1 -0
- package/resources/v1/v1.d.mts +161 -0
- package/resources/v1/v1.d.mts.map +1 -0
- package/resources/v1/v1.d.ts +161 -0
- package/resources/v1/v1.d.ts.map +1 -0
- package/resources/v1/v1.js +37 -0
- package/resources/v1/v1.js.map +1 -0
- package/resources/v1/v1.mjs +32 -0
- package/resources/v1/v1.mjs.map +1 -0
- package/resources/v1.d.mts +2 -0
- package/resources/v1.d.mts.map +1 -0
- package/resources/v1.d.ts +2 -0
- package/resources/v1.d.ts.map +1 -0
- package/resources/v1.js +6 -0
- package/resources/v1.js.map +1 -0
- package/resources/v1.mjs +3 -0
- package/resources/v1.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 +765 -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/pagination.ts +177 -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 +23 -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/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 +127 -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/pagination.ts +2 -0
- package/src/resource.ts +2 -0
- package/src/resources/index.ts +9 -0
- package/src/resources/v1/coupons.ts +843 -0
- package/src/resources/v1/customers/customers.ts +489 -0
- package/src/resources/v1/customers/index.ts +12 -0
- package/src/resources/v1/customers/payment-method.ts +177 -0
- package/src/resources/v1/customers/usage.ts +132 -0
- package/src/resources/v1/customers.ts +3 -0
- package/src/resources/v1/index.ts +41 -0
- package/src/resources/v1/subscriptions/future-update.ts +58 -0
- package/src/resources/v1/subscriptions/index.ts +23 -0
- package/src/resources/v1/subscriptions/subscriptions.ts +1464 -0
- package/src/resources/v1/subscriptions.ts +3 -0
- package/src/resources/v1/v1.ts +264 -0
- package/src/resources/v1.ts +3 -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 -0
- package/version.d.ts.map +1 -0
- package/version.js +5 -0
- package/version.js.map +1 -0
- package/version.mjs +2 -0
- package/version.mjs.map +1 -0
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
import { APIResource } from "../../../core/resource.mjs";
|
|
3
|
+
import { path } from "../../../internal/utils/path.mjs";
|
|
4
|
+
export class PaymentMethod extends APIResource {
|
|
5
|
+
/**
|
|
6
|
+
* Perform payment-method attachment on a Customer
|
|
7
|
+
*/
|
|
8
|
+
attach(id, body, options) {
|
|
9
|
+
return this._client.post(path `/api/v1/customers/${id}/payment-method`, { body, ...options });
|
|
10
|
+
}
|
|
11
|
+
/**
|
|
12
|
+
* Perform payment-method detachment on a Customer
|
|
13
|
+
*/
|
|
14
|
+
detach(id, options) {
|
|
15
|
+
return this._client.delete(path `/api/v1/customers/${id}/payment-method`, options);
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
//# sourceMappingURL=payment-method.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"payment-method.mjs","sourceRoot":"","sources":["../../../src/resources/v1/customers/payment-method.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;OAIf,EAAE,IAAI,EAAE;AAEf,MAAM,OAAO,aAAc,SAAQ,WAAW;IAC5C;;OAEG;IACH,MAAM,CACJ,EAAU,EACV,IAA+B,EAC/B,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,IAAI,CAAA,qBAAqB,EAAE,iBAAiB,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IAC/F,CAAC;IAED;;OAEG;IACH,MAAM,CAAC,EAAU,EAAE,OAAwB;QACzC,OAAO,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC,IAAI,CAAA,qBAAqB,EAAE,iBAAiB,EAAE,OAAO,CAAC,CAAC;IACpF,CAAC;CACF"}
|
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
import { APIResource } from "../../../core/resource.mjs";
|
|
2
|
+
import { APIPromise } from "../../../core/api-promise.mjs";
|
|
3
|
+
import { RequestOptions } from "../../../internal/request-options.mjs";
|
|
4
|
+
export declare class Usage extends APIResource {
|
|
5
|
+
/**
|
|
6
|
+
* Perform retrieval on a Usage history
|
|
7
|
+
*/
|
|
8
|
+
retrieve(featureID: string, params: UsageRetrieveParams, options?: RequestOptions): APIPromise<UsageRetrieveResponse>;
|
|
9
|
+
}
|
|
10
|
+
export interface UsageRetrieveResponse {
|
|
11
|
+
data: UsageRetrieveResponse.Data;
|
|
12
|
+
}
|
|
13
|
+
export declare namespace UsageRetrieveResponse {
|
|
14
|
+
interface Data {
|
|
15
|
+
/**
|
|
16
|
+
* Markers for events that affecting feature usage
|
|
17
|
+
*/
|
|
18
|
+
markers: Array<Data.Marker>;
|
|
19
|
+
/**
|
|
20
|
+
* Series of usage history
|
|
21
|
+
*/
|
|
22
|
+
series: Array<Data.Series>;
|
|
23
|
+
}
|
|
24
|
+
namespace Data {
|
|
25
|
+
interface Marker {
|
|
26
|
+
/**
|
|
27
|
+
* Timestamp of the marker
|
|
28
|
+
*/
|
|
29
|
+
timestamp: string;
|
|
30
|
+
/**
|
|
31
|
+
* Type of marker for a usage history point
|
|
32
|
+
*/
|
|
33
|
+
type: 'PERIODIC_RESET' | 'SUBSCRIPTION_CHANGE_RESET';
|
|
34
|
+
}
|
|
35
|
+
interface Series {
|
|
36
|
+
/**
|
|
37
|
+
* Points in the usage history series
|
|
38
|
+
*/
|
|
39
|
+
points: Array<Series.Point>;
|
|
40
|
+
/**
|
|
41
|
+
* Tags for the usage history series
|
|
42
|
+
*/
|
|
43
|
+
tags: Array<Series.Tag>;
|
|
44
|
+
}
|
|
45
|
+
namespace Series {
|
|
46
|
+
interface Point {
|
|
47
|
+
/**
|
|
48
|
+
* Indicates whether there was usage reset in this point, see `markers` for details
|
|
49
|
+
*/
|
|
50
|
+
isResetPoint: boolean;
|
|
51
|
+
/**
|
|
52
|
+
* Timestamp of the usage history point
|
|
53
|
+
*/
|
|
54
|
+
timestamp: string;
|
|
55
|
+
/**
|
|
56
|
+
* Value of the usage history point
|
|
57
|
+
*/
|
|
58
|
+
value: number;
|
|
59
|
+
}
|
|
60
|
+
interface Tag {
|
|
61
|
+
/**
|
|
62
|
+
* Key of the tag
|
|
63
|
+
*/
|
|
64
|
+
key: string;
|
|
65
|
+
/**
|
|
66
|
+
* Value of the tag
|
|
67
|
+
*/
|
|
68
|
+
value: string;
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
export interface UsageRetrieveParams {
|
|
74
|
+
/**
|
|
75
|
+
* Path param: Customer id
|
|
76
|
+
*/
|
|
77
|
+
customerId: string;
|
|
78
|
+
/**
|
|
79
|
+
* Query param: The start date of the range
|
|
80
|
+
*/
|
|
81
|
+
startDate: string;
|
|
82
|
+
/**
|
|
83
|
+
* Query param: The end date of the range
|
|
84
|
+
*/
|
|
85
|
+
endDate?: string;
|
|
86
|
+
/**
|
|
87
|
+
* Query param
|
|
88
|
+
*/
|
|
89
|
+
groupBy?: string;
|
|
90
|
+
/**
|
|
91
|
+
* Query param: Resource id
|
|
92
|
+
*/
|
|
93
|
+
resourceId?: string | null;
|
|
94
|
+
}
|
|
95
|
+
export declare namespace Usage {
|
|
96
|
+
export { type UsageRetrieveResponse as UsageRetrieveResponse, type UsageRetrieveParams as UsageRetrieveParams, };
|
|
97
|
+
}
|
|
98
|
+
//# sourceMappingURL=usage.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"usage.d.mts","sourceRoot":"","sources":["../../../src/resources/v1/customers/usage.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,EAAE,UAAU,EAAE;OACd,EAAE,cAAc,EAAE;AAGzB,qBAAa,KAAM,SAAQ,WAAW;IACpC;;OAEG;IACH,QAAQ,CACN,SAAS,EAAE,MAAM,EACjB,MAAM,EAAE,mBAAmB,EAC3B,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,qBAAqB,CAAC;CAOrC;AAED,MAAM,WAAW,qBAAqB;IACpC,IAAI,EAAE,qBAAqB,CAAC,IAAI,CAAC;CAClC;AAED,yBAAiB,qBAAqB,CAAC;IACrC,UAAiB,IAAI;QACnB;;WAEG;QACH,OAAO,EAAE,KAAK,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;QAE5B;;WAEG;QACH,MAAM,EAAE,KAAK,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;KAC5B;IAED,UAAiB,IAAI,CAAC;QACpB,UAAiB,MAAM;YACrB;;eAEG;YACH,SAAS,EAAE,MAAM,CAAC;YAElB;;eAEG;YACH,IAAI,EAAE,gBAAgB,GAAG,2BAA2B,CAAC;SACtD;QAED,UAAiB,MAAM;YACrB;;eAEG;YACH,MAAM,EAAE,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;YAE5B;;eAEG;YACH,IAAI,EAAE,KAAK,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC;SACzB;QAED,UAAiB,MAAM,CAAC;YACtB,UAAiB,KAAK;gBACpB;;mBAEG;gBACH,YAAY,EAAE,OAAO,CAAC;gBAEtB;;mBAEG;gBACH,SAAS,EAAE,MAAM,CAAC;gBAElB;;mBAEG;gBACH,KAAK,EAAE,MAAM,CAAC;aACf;YAED,UAAiB,GAAG;gBAClB;;mBAEG;gBACH,GAAG,EAAE,MAAM,CAAC;gBAEZ;;mBAEG;gBACH,KAAK,EAAE,MAAM,CAAC;aACf;SACF;KACF;CACF;AAED,MAAM,WAAW,mBAAmB;IAClC;;OAEG;IACH,UAAU,EAAE,MAAM,CAAC;IAEnB;;OAEG;IACH,SAAS,EAAE,MAAM,CAAC;IAElB;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IAEjB;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IAEjB;;OAEG;IACH,UAAU,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;CAC5B;AAED,MAAM,CAAC,OAAO,WAAW,KAAK,CAAC;IAC7B,OAAO,EACL,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,mBAAmB,IAAI,mBAAmB,GAChD,CAAC;CACH"}
|
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
import { APIResource } from "../../../core/resource.js";
|
|
2
|
+
import { APIPromise } from "../../../core/api-promise.js";
|
|
3
|
+
import { RequestOptions } from "../../../internal/request-options.js";
|
|
4
|
+
export declare class Usage extends APIResource {
|
|
5
|
+
/**
|
|
6
|
+
* Perform retrieval on a Usage history
|
|
7
|
+
*/
|
|
8
|
+
retrieve(featureID: string, params: UsageRetrieveParams, options?: RequestOptions): APIPromise<UsageRetrieveResponse>;
|
|
9
|
+
}
|
|
10
|
+
export interface UsageRetrieveResponse {
|
|
11
|
+
data: UsageRetrieveResponse.Data;
|
|
12
|
+
}
|
|
13
|
+
export declare namespace UsageRetrieveResponse {
|
|
14
|
+
interface Data {
|
|
15
|
+
/**
|
|
16
|
+
* Markers for events that affecting feature usage
|
|
17
|
+
*/
|
|
18
|
+
markers: Array<Data.Marker>;
|
|
19
|
+
/**
|
|
20
|
+
* Series of usage history
|
|
21
|
+
*/
|
|
22
|
+
series: Array<Data.Series>;
|
|
23
|
+
}
|
|
24
|
+
namespace Data {
|
|
25
|
+
interface Marker {
|
|
26
|
+
/**
|
|
27
|
+
* Timestamp of the marker
|
|
28
|
+
*/
|
|
29
|
+
timestamp: string;
|
|
30
|
+
/**
|
|
31
|
+
* Type of marker for a usage history point
|
|
32
|
+
*/
|
|
33
|
+
type: 'PERIODIC_RESET' | 'SUBSCRIPTION_CHANGE_RESET';
|
|
34
|
+
}
|
|
35
|
+
interface Series {
|
|
36
|
+
/**
|
|
37
|
+
* Points in the usage history series
|
|
38
|
+
*/
|
|
39
|
+
points: Array<Series.Point>;
|
|
40
|
+
/**
|
|
41
|
+
* Tags for the usage history series
|
|
42
|
+
*/
|
|
43
|
+
tags: Array<Series.Tag>;
|
|
44
|
+
}
|
|
45
|
+
namespace Series {
|
|
46
|
+
interface Point {
|
|
47
|
+
/**
|
|
48
|
+
* Indicates whether there was usage reset in this point, see `markers` for details
|
|
49
|
+
*/
|
|
50
|
+
isResetPoint: boolean;
|
|
51
|
+
/**
|
|
52
|
+
* Timestamp of the usage history point
|
|
53
|
+
*/
|
|
54
|
+
timestamp: string;
|
|
55
|
+
/**
|
|
56
|
+
* Value of the usage history point
|
|
57
|
+
*/
|
|
58
|
+
value: number;
|
|
59
|
+
}
|
|
60
|
+
interface Tag {
|
|
61
|
+
/**
|
|
62
|
+
* Key of the tag
|
|
63
|
+
*/
|
|
64
|
+
key: string;
|
|
65
|
+
/**
|
|
66
|
+
* Value of the tag
|
|
67
|
+
*/
|
|
68
|
+
value: string;
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
export interface UsageRetrieveParams {
|
|
74
|
+
/**
|
|
75
|
+
* Path param: Customer id
|
|
76
|
+
*/
|
|
77
|
+
customerId: string;
|
|
78
|
+
/**
|
|
79
|
+
* Query param: The start date of the range
|
|
80
|
+
*/
|
|
81
|
+
startDate: string;
|
|
82
|
+
/**
|
|
83
|
+
* Query param: The end date of the range
|
|
84
|
+
*/
|
|
85
|
+
endDate?: string;
|
|
86
|
+
/**
|
|
87
|
+
* Query param
|
|
88
|
+
*/
|
|
89
|
+
groupBy?: string;
|
|
90
|
+
/**
|
|
91
|
+
* Query param: Resource id
|
|
92
|
+
*/
|
|
93
|
+
resourceId?: string | null;
|
|
94
|
+
}
|
|
95
|
+
export declare namespace Usage {
|
|
96
|
+
export { type UsageRetrieveResponse as UsageRetrieveResponse, type UsageRetrieveParams as UsageRetrieveParams, };
|
|
97
|
+
}
|
|
98
|
+
//# sourceMappingURL=usage.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"usage.d.ts","sourceRoot":"","sources":["../../../src/resources/v1/customers/usage.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,EAAE,UAAU,EAAE;OACd,EAAE,cAAc,EAAE;AAGzB,qBAAa,KAAM,SAAQ,WAAW;IACpC;;OAEG;IACH,QAAQ,CACN,SAAS,EAAE,MAAM,EACjB,MAAM,EAAE,mBAAmB,EAC3B,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,qBAAqB,CAAC;CAOrC;AAED,MAAM,WAAW,qBAAqB;IACpC,IAAI,EAAE,qBAAqB,CAAC,IAAI,CAAC;CAClC;AAED,yBAAiB,qBAAqB,CAAC;IACrC,UAAiB,IAAI;QACnB;;WAEG;QACH,OAAO,EAAE,KAAK,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;QAE5B;;WAEG;QACH,MAAM,EAAE,KAAK,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;KAC5B;IAED,UAAiB,IAAI,CAAC;QACpB,UAAiB,MAAM;YACrB;;eAEG;YACH,SAAS,EAAE,MAAM,CAAC;YAElB;;eAEG;YACH,IAAI,EAAE,gBAAgB,GAAG,2BAA2B,CAAC;SACtD;QAED,UAAiB,MAAM;YACrB;;eAEG;YACH,MAAM,EAAE,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;YAE5B;;eAEG;YACH,IAAI,EAAE,KAAK,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC;SACzB;QAED,UAAiB,MAAM,CAAC;YACtB,UAAiB,KAAK;gBACpB;;mBAEG;gBACH,YAAY,EAAE,OAAO,CAAC;gBAEtB;;mBAEG;gBACH,SAAS,EAAE,MAAM,CAAC;gBAElB;;mBAEG;gBACH,KAAK,EAAE,MAAM,CAAC;aACf;YAED,UAAiB,GAAG;gBAClB;;mBAEG;gBACH,GAAG,EAAE,MAAM,CAAC;gBAEZ;;mBAEG;gBACH,KAAK,EAAE,MAAM,CAAC;aACf;SACF;KACF;CACF;AAED,MAAM,WAAW,mBAAmB;IAClC;;OAEG;IACH,UAAU,EAAE,MAAM,CAAC;IAEnB;;OAEG;IACH,SAAS,EAAE,MAAM,CAAC;IAElB;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IAEjB;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IAEjB;;OAEG;IACH,UAAU,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;CAC5B;AAED,MAAM,CAAC,OAAO,WAAW,KAAK,CAAC;IAC7B,OAAO,EACL,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,mBAAmB,IAAI,mBAAmB,GAChD,CAAC;CACH"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.Usage = void 0;
|
|
5
|
+
const resource_1 = require("../../../core/resource.js");
|
|
6
|
+
const path_1 = require("../../../internal/utils/path.js");
|
|
7
|
+
class Usage extends resource_1.APIResource {
|
|
8
|
+
/**
|
|
9
|
+
* Perform retrieval on a Usage history
|
|
10
|
+
*/
|
|
11
|
+
retrieve(featureID, params, options) {
|
|
12
|
+
const { customerId, ...query } = params;
|
|
13
|
+
return this._client.get((0, path_1.path) `/api/v1/customers/${customerId}/usage/features/${featureID}`, {
|
|
14
|
+
query,
|
|
15
|
+
...options,
|
|
16
|
+
});
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
exports.Usage = Usage;
|
|
20
|
+
//# sourceMappingURL=usage.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"usage.js","sourceRoot":"","sources":["../../../src/resources/v1/customers/usage.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,wDAAqD;AAGrD,0DAAoD;AAEpD,MAAa,KAAM,SAAQ,sBAAW;IACpC;;OAEG;IACH,QAAQ,CACN,SAAiB,EACjB,MAA2B,EAC3B,OAAwB;QAExB,MAAM,EAAE,UAAU,EAAE,GAAG,KAAK,EAAE,GAAG,MAAM,CAAC;QACxC,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAA,WAAI,EAAA,qBAAqB,UAAU,mBAAmB,SAAS,EAAE,EAAE;YACzF,KAAK;YACL,GAAG,OAAO;SACX,CAAC,CAAC;IACL,CAAC;CACF;AAfD,sBAeC"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
import { APIResource } from "../../../core/resource.mjs";
|
|
3
|
+
import { path } from "../../../internal/utils/path.mjs";
|
|
4
|
+
export class Usage extends APIResource {
|
|
5
|
+
/**
|
|
6
|
+
* Perform retrieval on a Usage history
|
|
7
|
+
*/
|
|
8
|
+
retrieve(featureID, params, options) {
|
|
9
|
+
const { customerId, ...query } = params;
|
|
10
|
+
return this._client.get(path `/api/v1/customers/${customerId}/usage/features/${featureID}`, {
|
|
11
|
+
query,
|
|
12
|
+
...options,
|
|
13
|
+
});
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
//# sourceMappingURL=usage.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"usage.mjs","sourceRoot":"","sources":["../../../src/resources/v1/customers/usage.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;OAGf,EAAE,IAAI,EAAE;AAEf,MAAM,OAAO,KAAM,SAAQ,WAAW;IACpC;;OAEG;IACH,QAAQ,CACN,SAAiB,EACjB,MAA2B,EAC3B,OAAwB;QAExB,MAAM,EAAE,UAAU,EAAE,GAAG,KAAK,EAAE,GAAG,MAAM,CAAC;QACxC,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,CAAA,qBAAqB,UAAU,mBAAmB,SAAS,EAAE,EAAE;YACzF,KAAK;YACL,GAAG,OAAO;SACX,CAAC,CAAC;IACL,CAAC;CACF"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"customers.d.mts","sourceRoot":"","sources":["../../src/resources/v1/customers.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"customers.d.ts","sourceRoot":"","sources":["../../src/resources/v1/customers.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
const tslib_1 = require("../../internal/tslib.js");
|
|
5
|
+
tslib_1.__exportStar(require("./customers/index.js"), exports);
|
|
6
|
+
//# sourceMappingURL=customers.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"customers.js","sourceRoot":"","sources":["../../src/resources/v1/customers.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,+DAAkC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"customers.mjs","sourceRoot":"","sources":["../../src/resources/v1/customers.ts"],"names":[],"mappings":"AAAA,sFAAsF"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export { Coupons, type CouponCreateResponse, type CouponRetrieveResponse, type CouponListResponse, type CouponCreateParams, type CouponListParams, } from "./coupons.mjs";
|
|
2
|
+
export { Customers, type CustomerResponse, type CustomerListResponse, type CustomerCreateParams, type CustomerUpdateParams, type CustomerListParams, } from "./customers/index.mjs";
|
|
3
|
+
export { Subscriptions, type SubscriptionCreateResponse, type SubscriptionRetrieveResponse, type SubscriptionListResponse, type SubscriptionDelegateResponse, type SubscriptionMigrateResponse, type SubscriptionPreviewResponse, type SubscriptionTransferResponse, type SubscriptionCreateParams, type SubscriptionListParams, type SubscriptionDelegateParams, type SubscriptionMigrateParams, type SubscriptionPreviewParams, type SubscriptionTransferParams, } from "./subscriptions/index.mjs";
|
|
4
|
+
export { V1, type V1CreateEventResponse, type V1CreateUsageResponse, type V1CreateEventParams, type V1CreateUsageParams, } from "./v1.mjs";
|
|
5
|
+
//# sourceMappingURL=index.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.mts","sourceRoot":"","sources":["../../src/resources/v1/index.ts"],"names":[],"mappings":"OAEO,EACL,OAAO,EACP,KAAK,oBAAoB,EACzB,KAAK,sBAAsB,EAC3B,KAAK,kBAAkB,EACvB,KAAK,kBAAkB,EACvB,KAAK,gBAAgB,GACtB;OACM,EACL,SAAS,EACT,KAAK,gBAAgB,EACrB,KAAK,oBAAoB,EACzB,KAAK,oBAAoB,EACzB,KAAK,oBAAoB,EACzB,KAAK,kBAAkB,GACxB;OACM,EACL,aAAa,EACb,KAAK,0BAA0B,EAC/B,KAAK,4BAA4B,EACjC,KAAK,wBAAwB,EAC7B,KAAK,4BAA4B,EACjC,KAAK,2BAA2B,EAChC,KAAK,2BAA2B,EAChC,KAAK,4BAA4B,EACjC,KAAK,wBAAwB,EAC7B,KAAK,sBAAsB,EAC3B,KAAK,0BAA0B,EAC/B,KAAK,yBAAyB,EAC9B,KAAK,yBAAyB,EAC9B,KAAK,0BAA0B,GAChC;OACM,EACL,EAAE,EACF,KAAK,qBAAqB,EAC1B,KAAK,qBAAqB,EAC1B,KAAK,mBAAmB,EACxB,KAAK,mBAAmB,GACzB"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export { Coupons, type CouponCreateResponse, type CouponRetrieveResponse, type CouponListResponse, type CouponCreateParams, type CouponListParams, } from "./coupons.js";
|
|
2
|
+
export { Customers, type CustomerResponse, type CustomerListResponse, type CustomerCreateParams, type CustomerUpdateParams, type CustomerListParams, } from "./customers/index.js";
|
|
3
|
+
export { Subscriptions, type SubscriptionCreateResponse, type SubscriptionRetrieveResponse, type SubscriptionListResponse, type SubscriptionDelegateResponse, type SubscriptionMigrateResponse, type SubscriptionPreviewResponse, type SubscriptionTransferResponse, type SubscriptionCreateParams, type SubscriptionListParams, type SubscriptionDelegateParams, type SubscriptionMigrateParams, type SubscriptionPreviewParams, type SubscriptionTransferParams, } from "./subscriptions/index.js";
|
|
4
|
+
export { V1, type V1CreateEventResponse, type V1CreateUsageResponse, type V1CreateEventParams, type V1CreateUsageParams, } from "./v1.js";
|
|
5
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/resources/v1/index.ts"],"names":[],"mappings":"OAEO,EACL,OAAO,EACP,KAAK,oBAAoB,EACzB,KAAK,sBAAsB,EAC3B,KAAK,kBAAkB,EACvB,KAAK,kBAAkB,EACvB,KAAK,gBAAgB,GACtB;OACM,EACL,SAAS,EACT,KAAK,gBAAgB,EACrB,KAAK,oBAAoB,EACzB,KAAK,oBAAoB,EACzB,KAAK,oBAAoB,EACzB,KAAK,kBAAkB,GACxB;OACM,EACL,aAAa,EACb,KAAK,0BAA0B,EAC/B,KAAK,4BAA4B,EACjC,KAAK,wBAAwB,EAC7B,KAAK,4BAA4B,EACjC,KAAK,2BAA2B,EAChC,KAAK,2BAA2B,EAChC,KAAK,4BAA4B,EACjC,KAAK,wBAAwB,EAC7B,KAAK,sBAAsB,EAC3B,KAAK,0BAA0B,EAC/B,KAAK,yBAAyB,EAC9B,KAAK,yBAAyB,EAC9B,KAAK,0BAA0B,GAChC;OACM,EACL,EAAE,EACF,KAAK,qBAAqB,EAC1B,KAAK,qBAAqB,EAC1B,KAAK,mBAAmB,EACxB,KAAK,mBAAmB,GACzB"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.V1 = exports.Subscriptions = exports.Customers = exports.Coupons = void 0;
|
|
5
|
+
var coupons_1 = require("./coupons.js");
|
|
6
|
+
Object.defineProperty(exports, "Coupons", { enumerable: true, get: function () { return coupons_1.Coupons; } });
|
|
7
|
+
var index_1 = require("./customers/index.js");
|
|
8
|
+
Object.defineProperty(exports, "Customers", { enumerable: true, get: function () { return index_1.Customers; } });
|
|
9
|
+
var index_2 = require("./subscriptions/index.js");
|
|
10
|
+
Object.defineProperty(exports, "Subscriptions", { enumerable: true, get: function () { return index_2.Subscriptions; } });
|
|
11
|
+
var v1_1 = require("./v1.js");
|
|
12
|
+
Object.defineProperty(exports, "V1", { enumerable: true, get: function () { return v1_1.V1; } });
|
|
13
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/resources/v1/index.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,wCAOmB;AANjB,kGAAA,OAAO,OAAA;AAOT,8CAO2B;AANzB,kGAAA,SAAS,OAAA;AAOX,kDAe+B;AAd7B,sGAAA,aAAa,OAAA;AAef,8BAMc;AALZ,wFAAA,EAAE,OAAA"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
export { Coupons, } from "./coupons.mjs";
|
|
3
|
+
export { Customers, } from "./customers/index.mjs";
|
|
4
|
+
export { Subscriptions, } from "./subscriptions/index.mjs";
|
|
5
|
+
export { V1, } from "./v1.mjs";
|
|
6
|
+
//# sourceMappingURL=index.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.mjs","sourceRoot":"","sources":["../../src/resources/v1/index.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EACL,OAAO,GAMR;OACM,EACL,SAAS,GAMV;OACM,EACL,aAAa,GAcd;OACM,EACL,EAAE,GAKH"}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { APIResource } from "../../../core/resource.mjs";
|
|
2
|
+
import { APIPromise } from "../../../core/api-promise.mjs";
|
|
3
|
+
import { RequestOptions } from "../../../internal/request-options.mjs";
|
|
4
|
+
export declare class FutureUpdate extends APIResource {
|
|
5
|
+
/**
|
|
6
|
+
* Perform cancel future update on a Subscription
|
|
7
|
+
*/
|
|
8
|
+
cancelPendingPayment(id: string, options?: RequestOptions): APIPromise<FutureUpdateCancelPendingPaymentResponse>;
|
|
9
|
+
/**
|
|
10
|
+
* Perform cancel future update on a Subscription
|
|
11
|
+
*/
|
|
12
|
+
cancelSchedule(id: string, options?: RequestOptions): APIPromise<FutureUpdateCancelScheduleResponse>;
|
|
13
|
+
}
|
|
14
|
+
export interface FutureUpdateCancelPendingPaymentResponse {
|
|
15
|
+
data: FutureUpdateCancelPendingPaymentResponse.Data;
|
|
16
|
+
}
|
|
17
|
+
export declare namespace FutureUpdateCancelPendingPaymentResponse {
|
|
18
|
+
interface Data {
|
|
19
|
+
/**
|
|
20
|
+
* Subscription ID
|
|
21
|
+
*/
|
|
22
|
+
id: string;
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
export interface FutureUpdateCancelScheduleResponse {
|
|
26
|
+
data: FutureUpdateCancelScheduleResponse.Data;
|
|
27
|
+
}
|
|
28
|
+
export declare namespace FutureUpdateCancelScheduleResponse {
|
|
29
|
+
interface Data {
|
|
30
|
+
/**
|
|
31
|
+
* Subscription ID
|
|
32
|
+
*/
|
|
33
|
+
id: string;
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
export declare namespace FutureUpdate {
|
|
37
|
+
export { type FutureUpdateCancelPendingPaymentResponse as FutureUpdateCancelPendingPaymentResponse, type FutureUpdateCancelScheduleResponse as FutureUpdateCancelScheduleResponse, };
|
|
38
|
+
}
|
|
39
|
+
//# sourceMappingURL=future-update.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"future-update.d.mts","sourceRoot":"","sources":["../../../src/resources/v1/subscriptions/future-update.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,EAAE,UAAU,EAAE;OACd,EAAE,cAAc,EAAE;AAGzB,qBAAa,YAAa,SAAQ,WAAW;IAC3C;;OAEG;IACH,oBAAoB,CAClB,EAAE,EAAE,MAAM,EACV,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,wCAAwC,CAAC;IAIvD;;OAEG;IACH,cAAc,CAAC,EAAE,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,kCAAkC,CAAC;CAGrG;AAED,MAAM,WAAW,wCAAwC;IACvD,IAAI,EAAE,wCAAwC,CAAC,IAAI,CAAC;CACrD;AAED,yBAAiB,wCAAwC,CAAC;IACxD,UAAiB,IAAI;QACnB;;WAEG;QACH,EAAE,EAAE,MAAM,CAAC;KACZ;CACF;AAED,MAAM,WAAW,kCAAkC;IACjD,IAAI,EAAE,kCAAkC,CAAC,IAAI,CAAC;CAC/C;AAED,yBAAiB,kCAAkC,CAAC;IAClD,UAAiB,IAAI;QACnB;;WAEG;QACH,EAAE,EAAE,MAAM,CAAC;KACZ;CACF;AAED,MAAM,CAAC,OAAO,WAAW,YAAY,CAAC;IACpC,OAAO,EACL,KAAK,wCAAwC,IAAI,wCAAwC,EACzF,KAAK,kCAAkC,IAAI,kCAAkC,GAC9E,CAAC;CACH"}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { APIResource } from "../../../core/resource.js";
|
|
2
|
+
import { APIPromise } from "../../../core/api-promise.js";
|
|
3
|
+
import { RequestOptions } from "../../../internal/request-options.js";
|
|
4
|
+
export declare class FutureUpdate extends APIResource {
|
|
5
|
+
/**
|
|
6
|
+
* Perform cancel future update on a Subscription
|
|
7
|
+
*/
|
|
8
|
+
cancelPendingPayment(id: string, options?: RequestOptions): APIPromise<FutureUpdateCancelPendingPaymentResponse>;
|
|
9
|
+
/**
|
|
10
|
+
* Perform cancel future update on a Subscription
|
|
11
|
+
*/
|
|
12
|
+
cancelSchedule(id: string, options?: RequestOptions): APIPromise<FutureUpdateCancelScheduleResponse>;
|
|
13
|
+
}
|
|
14
|
+
export interface FutureUpdateCancelPendingPaymentResponse {
|
|
15
|
+
data: FutureUpdateCancelPendingPaymentResponse.Data;
|
|
16
|
+
}
|
|
17
|
+
export declare namespace FutureUpdateCancelPendingPaymentResponse {
|
|
18
|
+
interface Data {
|
|
19
|
+
/**
|
|
20
|
+
* Subscription ID
|
|
21
|
+
*/
|
|
22
|
+
id: string;
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
export interface FutureUpdateCancelScheduleResponse {
|
|
26
|
+
data: FutureUpdateCancelScheduleResponse.Data;
|
|
27
|
+
}
|
|
28
|
+
export declare namespace FutureUpdateCancelScheduleResponse {
|
|
29
|
+
interface Data {
|
|
30
|
+
/**
|
|
31
|
+
* Subscription ID
|
|
32
|
+
*/
|
|
33
|
+
id: string;
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
export declare namespace FutureUpdate {
|
|
37
|
+
export { type FutureUpdateCancelPendingPaymentResponse as FutureUpdateCancelPendingPaymentResponse, type FutureUpdateCancelScheduleResponse as FutureUpdateCancelScheduleResponse, };
|
|
38
|
+
}
|
|
39
|
+
//# sourceMappingURL=future-update.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"future-update.d.ts","sourceRoot":"","sources":["../../../src/resources/v1/subscriptions/future-update.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,EAAE,UAAU,EAAE;OACd,EAAE,cAAc,EAAE;AAGzB,qBAAa,YAAa,SAAQ,WAAW;IAC3C;;OAEG;IACH,oBAAoB,CAClB,EAAE,EAAE,MAAM,EACV,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,wCAAwC,CAAC;IAIvD;;OAEG;IACH,cAAc,CAAC,EAAE,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,kCAAkC,CAAC;CAGrG;AAED,MAAM,WAAW,wCAAwC;IACvD,IAAI,EAAE,wCAAwC,CAAC,IAAI,CAAC;CACrD;AAED,yBAAiB,wCAAwC,CAAC;IACxD,UAAiB,IAAI;QACnB;;WAEG;QACH,EAAE,EAAE,MAAM,CAAC;KACZ;CACF;AAED,MAAM,WAAW,kCAAkC;IACjD,IAAI,EAAE,kCAAkC,CAAC,IAAI,CAAC;CAC/C;AAED,yBAAiB,kCAAkC,CAAC;IAClD,UAAiB,IAAI;QACnB;;WAEG;QACH,EAAE,EAAE,MAAM,CAAC;KACZ;CACF;AAED,MAAM,CAAC,OAAO,WAAW,YAAY,CAAC;IACpC,OAAO,EACL,KAAK,wCAAwC,IAAI,wCAAwC,EACzF,KAAK,kCAAkC,IAAI,kCAAkC,GAC9E,CAAC;CACH"}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.FutureUpdate = void 0;
|
|
5
|
+
const resource_1 = require("../../../core/resource.js");
|
|
6
|
+
const path_1 = require("../../../internal/utils/path.js");
|
|
7
|
+
class FutureUpdate extends resource_1.APIResource {
|
|
8
|
+
/**
|
|
9
|
+
* Perform cancel future update on a Subscription
|
|
10
|
+
*/
|
|
11
|
+
cancelPendingPayment(id, options) {
|
|
12
|
+
return this._client.delete((0, path_1.path) `/api/v1/subscriptions/${id}/future-update/pending-payment`, options);
|
|
13
|
+
}
|
|
14
|
+
/**
|
|
15
|
+
* Perform cancel future update on a Subscription
|
|
16
|
+
*/
|
|
17
|
+
cancelSchedule(id, options) {
|
|
18
|
+
return this._client.delete((0, path_1.path) `/api/v1/subscriptions/${id}/future-update/schedule`, options);
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
exports.FutureUpdate = FutureUpdate;
|
|
22
|
+
//# sourceMappingURL=future-update.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"future-update.js","sourceRoot":"","sources":["../../../src/resources/v1/subscriptions/future-update.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,wDAAqD;AAGrD,0DAAoD;AAEpD,MAAa,YAAa,SAAQ,sBAAW;IAC3C;;OAEG;IACH,oBAAoB,CAClB,EAAU,EACV,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC,IAAA,WAAI,EAAA,yBAAyB,EAAE,gCAAgC,EAAE,OAAO,CAAC,CAAC;IACvG,CAAC;IAED;;OAEG;IACH,cAAc,CAAC,EAAU,EAAE,OAAwB;QACjD,OAAO,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC,IAAA,WAAI,EAAA,yBAAyB,EAAE,yBAAyB,EAAE,OAAO,CAAC,CAAC;IAChG,CAAC;CACF;AAjBD,oCAiBC"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
import { APIResource } from "../../../core/resource.mjs";
|
|
3
|
+
import { path } from "../../../internal/utils/path.mjs";
|
|
4
|
+
export class FutureUpdate extends APIResource {
|
|
5
|
+
/**
|
|
6
|
+
* Perform cancel future update on a Subscription
|
|
7
|
+
*/
|
|
8
|
+
cancelPendingPayment(id, options) {
|
|
9
|
+
return this._client.delete(path `/api/v1/subscriptions/${id}/future-update/pending-payment`, options);
|
|
10
|
+
}
|
|
11
|
+
/**
|
|
12
|
+
* Perform cancel future update on a Subscription
|
|
13
|
+
*/
|
|
14
|
+
cancelSchedule(id, options) {
|
|
15
|
+
return this._client.delete(path `/api/v1/subscriptions/${id}/future-update/schedule`, options);
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
//# sourceMappingURL=future-update.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"future-update.mjs","sourceRoot":"","sources":["../../../src/resources/v1/subscriptions/future-update.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;OAGf,EAAE,IAAI,EAAE;AAEf,MAAM,OAAO,YAAa,SAAQ,WAAW;IAC3C;;OAEG;IACH,oBAAoB,CAClB,EAAU,EACV,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC,IAAI,CAAA,yBAAyB,EAAE,gCAAgC,EAAE,OAAO,CAAC,CAAC;IACvG,CAAC;IAED;;OAEG;IACH,cAAc,CAAC,EAAU,EAAE,OAAwB;QACjD,OAAO,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC,IAAI,CAAA,yBAAyB,EAAE,yBAAyB,EAAE,OAAO,CAAC,CAAC;IAChG,CAAC;CACF"}
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
export { FutureUpdate, type FutureUpdateCancelPendingPaymentResponse, type FutureUpdateCancelScheduleResponse, } from "./future-update.mjs";
|
|
2
|
+
export { Subscriptions, type SubscriptionCreateResponse, type SubscriptionRetrieveResponse, type SubscriptionListResponse, type SubscriptionDelegateResponse, type SubscriptionMigrateResponse, type SubscriptionPreviewResponse, type SubscriptionTransferResponse, type SubscriptionCreateParams, type SubscriptionListParams, type SubscriptionDelegateParams, type SubscriptionMigrateParams, type SubscriptionPreviewParams, type SubscriptionTransferParams, } from "./subscriptions.mjs";
|
|
3
|
+
//# sourceMappingURL=index.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.mts","sourceRoot":"","sources":["../../../src/resources/v1/subscriptions/index.ts"],"names":[],"mappings":"OAEO,EACL,YAAY,EACZ,KAAK,wCAAwC,EAC7C,KAAK,kCAAkC,GACxC;OACM,EACL,aAAa,EACb,KAAK,0BAA0B,EAC/B,KAAK,4BAA4B,EACjC,KAAK,wBAAwB,EAC7B,KAAK,4BAA4B,EACjC,KAAK,2BAA2B,EAChC,KAAK,2BAA2B,EAChC,KAAK,4BAA4B,EACjC,KAAK,wBAAwB,EAC7B,KAAK,sBAAsB,EAC3B,KAAK,0BAA0B,EAC/B,KAAK,yBAAyB,EAC9B,KAAK,yBAAyB,EAC9B,KAAK,0BAA0B,GAChC"}
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
export { FutureUpdate, type FutureUpdateCancelPendingPaymentResponse, type FutureUpdateCancelScheduleResponse, } from "./future-update.js";
|
|
2
|
+
export { Subscriptions, type SubscriptionCreateResponse, type SubscriptionRetrieveResponse, type SubscriptionListResponse, type SubscriptionDelegateResponse, type SubscriptionMigrateResponse, type SubscriptionPreviewResponse, type SubscriptionTransferResponse, type SubscriptionCreateParams, type SubscriptionListParams, type SubscriptionDelegateParams, type SubscriptionMigrateParams, type SubscriptionPreviewParams, type SubscriptionTransferParams, } from "./subscriptions.js";
|
|
3
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/resources/v1/subscriptions/index.ts"],"names":[],"mappings":"OAEO,EACL,YAAY,EACZ,KAAK,wCAAwC,EAC7C,KAAK,kCAAkC,GACxC;OACM,EACL,aAAa,EACb,KAAK,0BAA0B,EAC/B,KAAK,4BAA4B,EACjC,KAAK,wBAAwB,EAC7B,KAAK,4BAA4B,EACjC,KAAK,2BAA2B,EAChC,KAAK,2BAA2B,EAChC,KAAK,4BAA4B,EACjC,KAAK,wBAAwB,EAC7B,KAAK,sBAAsB,EAC3B,KAAK,0BAA0B,EAC/B,KAAK,yBAAyB,EAC9B,KAAK,yBAAyB,EAC9B,KAAK,0BAA0B,GAChC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.Subscriptions = exports.FutureUpdate = void 0;
|
|
5
|
+
var future_update_1 = require("./future-update.js");
|
|
6
|
+
Object.defineProperty(exports, "FutureUpdate", { enumerable: true, get: function () { return future_update_1.FutureUpdate; } });
|
|
7
|
+
var subscriptions_1 = require("./subscriptions.js");
|
|
8
|
+
Object.defineProperty(exports, "Subscriptions", { enumerable: true, get: function () { return subscriptions_1.Subscriptions; } });
|
|
9
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/resources/v1/subscriptions/index.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,oDAIyB;AAHvB,6GAAA,YAAY,OAAA;AAId,oDAeyB;AAdvB,8GAAA,aAAa,OAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.mjs","sourceRoot":"","sources":["../../../src/resources/v1/subscriptions/index.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EACL,YAAY,GAGb;OACM,EACL,aAAa,GAcd"}
|