@stigg/typescript 0.1.0-beta.1 → 0.1.0-beta.10
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 +90 -0
- package/api-promise.d.mts +1 -0
- package/api-promise.d.mts.map +1 -1
- package/api-promise.d.ts +1 -0
- package/api-promise.d.ts.map +1 -1
- package/api-promise.mjs +1 -0
- package/api-promise.mjs.map +1 -1
- package/client.d.mts +3 -0
- package/client.d.mts.map +1 -1
- package/client.d.ts +3 -0
- package/client.d.ts.map +1 -1
- package/client.js +3 -0
- package/client.js.map +1 -1
- package/client.mjs +3 -0
- package/client.mjs.map +1 -1
- package/core/api-promise.d.mts.map +1 -1
- package/core/api-promise.d.ts.map +1 -1
- package/core/api-promise.mjs.map +1 -1
- package/core/error.mjs.map +1 -1
- package/core/pagination.d.mts.map +1 -1
- package/core/pagination.d.ts.map +1 -1
- package/core/pagination.mjs.map +1 -1
- package/core/resource.d.mts.map +1 -1
- package/core/resource.d.ts.map +1 -1
- package/core/uploads.d.mts.map +1 -1
- package/core/uploads.d.ts.map +1 -1
- package/core/uploads.mjs.map +1 -1
- package/error.d.mts +1 -0
- package/error.d.mts.map +1 -1
- package/error.d.ts +1 -0
- package/error.d.ts.map +1 -1
- package/error.mjs +1 -0
- package/error.mjs.map +1 -1
- package/index.d.mts.map +1 -1
- package/index.d.ts.map +1 -1
- package/index.mjs.map +1 -1
- package/internal/detect-platform.mjs.map +1 -1
- package/internal/headers.mjs.map +1 -1
- package/internal/parse.d.mts.map +1 -1
- package/internal/parse.d.ts.map +1 -1
- package/internal/parse.mjs.map +1 -1
- package/internal/qs/formats.d.mts.map +1 -1
- package/internal/qs/formats.d.ts.map +1 -1
- package/internal/qs/index.d.mts +2 -2
- package/internal/qs/index.d.mts.map +1 -1
- package/internal/qs/index.d.ts +2 -2
- package/internal/qs/index.d.ts.map +1 -1
- package/internal/qs/index.mjs.map +1 -1
- package/internal/qs/stringify.d.mts.map +1 -1
- package/internal/qs/stringify.d.ts.map +1 -1
- package/internal/qs/stringify.mjs.map +1 -1
- package/internal/qs/utils.d.mts.map +1 -1
- package/internal/qs/utils.d.ts.map +1 -1
- package/internal/qs/utils.mjs.map +1 -1
- package/internal/request-options.d.mts.map +1 -1
- package/internal/request-options.d.ts.map +1 -1
- package/internal/shims.d.mts +6 -0
- package/internal/shims.d.mts.map +1 -1
- package/internal/shims.d.ts +6 -0
- package/internal/shims.d.ts.map +1 -1
- package/internal/to-file.d.mts.map +1 -1
- package/internal/to-file.d.ts.map +1 -1
- package/internal/to-file.mjs.map +1 -1
- package/internal/types.d.mts +4 -4
- package/internal/types.d.mts.map +1 -1
- package/internal/types.d.ts +4 -4
- package/internal/types.d.ts.map +1 -1
- package/internal/uploads.d.mts.map +1 -1
- package/internal/uploads.d.ts.map +1 -1
- package/internal/uploads.mjs.map +1 -1
- package/internal/utils/base64.mjs.map +1 -1
- package/internal/utils/log.d.mts.map +1 -1
- package/internal/utils/log.d.ts.map +1 -1
- package/internal/utils/log.mjs.map +1 -1
- package/internal/utils/path.mjs.map +1 -1
- package/internal/utils/query.mjs.map +1 -1
- package/internal/utils/values.mjs.map +1 -1
- package/internal/utils.d.mts.map +1 -1
- package/internal/utils.d.ts.map +1 -1
- package/internal/utils.mjs.map +1 -1
- package/package.json +1 -1
- package/pagination.d.mts +1 -0
- package/pagination.d.mts.map +1 -1
- package/pagination.d.ts +1 -0
- package/pagination.d.ts.map +1 -1
- package/pagination.mjs +1 -0
- package/pagination.mjs.map +1 -1
- package/resource.d.mts +1 -0
- package/resource.d.mts.map +1 -1
- package/resource.d.ts +1 -0
- package/resource.d.ts.map +1 -1
- package/resource.mjs +1 -0
- package/resource.mjs.map +1 -1
- package/resources/index.d.mts +1 -0
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +1 -0
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js +3 -1
- package/resources/index.js.map +1 -1
- package/resources/index.mjs +1 -0
- package/resources/index.mjs.map +1 -1
- package/resources/v1/addons/addons.d.mts +198 -1
- package/resources/v1/addons/addons.d.mts.map +1 -1
- package/resources/v1/addons/addons.d.ts +198 -1
- package/resources/v1/addons/addons.d.ts.map +1 -1
- package/resources/v1/addons/addons.js +9 -0
- package/resources/v1/addons/addons.js.map +1 -1
- package/resources/v1/addons/addons.mjs +9 -0
- package/resources/v1/addons/addons.mjs.map +1 -1
- package/resources/v1/addons/entitlements.d.mts.map +1 -1
- package/resources/v1/addons/entitlements.d.ts.map +1 -1
- package/resources/v1/addons/entitlements.mjs.map +1 -1
- package/resources/v1/addons/index.d.mts +1 -1
- package/resources/v1/addons/index.d.mts.map +1 -1
- package/resources/v1/addons/index.d.ts +1 -1
- package/resources/v1/addons/index.d.ts.map +1 -1
- package/resources/v1/addons/index.js.map +1 -1
- package/resources/v1/addons/index.mjs.map +1 -1
- package/resources/v1/addons.d.mts.map +1 -1
- package/resources/v1/addons.d.ts.map +1 -1
- package/resources/v1/addons.mjs.map +1 -1
- package/resources/v1/coupons.d.mts.map +1 -1
- package/resources/v1/coupons.d.ts.map +1 -1
- package/resources/v1/coupons.mjs.map +1 -1
- package/resources/v1/{events/credits → credits}/credits.d.mts +32 -10
- package/resources/v1/credits/credits.d.mts.map +1 -0
- package/resources/v1/{events/credits → credits}/credits.d.ts +32 -10
- package/resources/v1/credits/credits.d.ts.map +1 -0
- package/resources/v1/{events/credits → credits}/credits.js +3 -3
- package/resources/v1/credits/credits.js.map +1 -0
- package/resources/v1/{events/credits → credits}/credits.mjs +2 -2
- package/resources/v1/credits/credits.mjs.map +1 -0
- package/resources/v1/{events/credits → credits}/custom-currencies.d.mts +12 -219
- package/resources/v1/credits/custom-currencies.d.mts.map +1 -0
- package/resources/v1/{events/credits → credits}/custom-currencies.d.ts +12 -219
- package/resources/v1/credits/custom-currencies.d.ts.map +1 -0
- package/resources/v1/{events/credits → credits}/custom-currencies.js +3 -3
- package/resources/v1/credits/custom-currencies.js.map +1 -0
- package/resources/v1/{events/credits → credits}/custom-currencies.mjs +3 -3
- package/resources/v1/credits/custom-currencies.mjs.map +1 -0
- package/resources/v1/{events/credits → credits}/grants.d.mts +4 -4
- package/resources/v1/credits/grants.d.mts.map +1 -0
- package/resources/v1/{events/credits → credits}/grants.d.ts +4 -4
- package/resources/v1/credits/grants.d.ts.map +1 -0
- package/resources/v1/{events/credits → credits}/grants.js +3 -3
- package/resources/v1/credits/grants.js.map +1 -0
- package/resources/v1/{events/credits → credits}/grants.mjs +3 -3
- package/resources/v1/credits/grants.mjs.map +1 -0
- package/resources/v1/credits/index.d.mts +4 -0
- package/resources/v1/credits/index.d.mts.map +1 -0
- package/resources/v1/credits/index.d.ts +4 -0
- package/resources/v1/credits/index.d.ts.map +1 -0
- package/resources/v1/credits/index.js.map +1 -0
- package/resources/v1/credits/index.mjs.map +1 -0
- package/resources/v1/credits.d.mts.map +1 -0
- package/resources/v1/credits.d.ts.map +1 -0
- package/resources/v1/{events/credits.js → credits.js} +1 -1
- package/resources/v1/credits.js.map +1 -0
- package/resources/v1/credits.mjs.map +1 -0
- package/resources/v1/customers/customers.d.mts.map +1 -1
- package/resources/v1/customers/customers.d.ts.map +1 -1
- package/resources/v1/customers/customers.mjs.map +1 -1
- package/resources/v1/customers/index.d.mts.map +1 -1
- package/resources/v1/customers/index.d.ts.map +1 -1
- package/resources/v1/customers/index.mjs.map +1 -1
- package/resources/v1/customers/integrations.d.mts.map +1 -1
- package/resources/v1/customers/integrations.d.ts.map +1 -1
- package/resources/v1/customers/integrations.mjs.map +1 -1
- package/resources/v1/customers/payment-method.d.mts.map +1 -1
- package/resources/v1/customers/payment-method.d.ts.map +1 -1
- package/resources/v1/customers/payment-method.mjs.map +1 -1
- package/resources/v1/customers/promotional-entitlements.d.mts.map +1 -1
- package/resources/v1/customers/promotional-entitlements.d.ts.map +1 -1
- package/resources/v1/customers/promotional-entitlements.mjs.map +1 -1
- package/resources/v1/customers.d.mts.map +1 -1
- package/resources/v1/customers.d.ts.map +1 -1
- package/resources/v1/customers.mjs.map +1 -1
- package/resources/v1/events.d.mts +65 -1
- package/resources/v1/events.d.mts.map +1 -1
- package/resources/v1/events.d.ts +65 -1
- package/resources/v1/events.d.ts.map +1 -1
- package/resources/v1/events.js +15 -2
- package/resources/v1/events.js.map +1 -1
- package/resources/v1/events.mjs +13 -1
- package/resources/v1/events.mjs.map +1 -1
- package/resources/v1/features.d.mts.map +1 -1
- package/resources/v1/features.d.ts.map +1 -1
- package/resources/v1/features.mjs.map +1 -1
- package/resources/v1/index.d.mts +4 -3
- package/resources/v1/index.d.mts.map +1 -1
- package/resources/v1/index.d.ts +4 -3
- package/resources/v1/index.d.ts.map +1 -1
- package/resources/v1/index.js +7 -5
- package/resources/v1/index.js.map +1 -1
- package/resources/v1/index.mjs +2 -1
- package/resources/v1/index.mjs.map +1 -1
- package/resources/v1/plans/entitlements.d.mts.map +1 -1
- package/resources/v1/plans/entitlements.d.ts.map +1 -1
- package/resources/v1/plans/entitlements.mjs.map +1 -1
- package/resources/v1/plans/index.d.mts +1 -1
- package/resources/v1/plans/index.d.mts.map +1 -1
- package/resources/v1/plans/index.d.ts +1 -1
- package/resources/v1/plans/index.d.ts.map +1 -1
- package/resources/v1/plans/index.js.map +1 -1
- package/resources/v1/plans/index.mjs.map +1 -1
- package/resources/v1/plans/plans.d.mts +16 -1
- package/resources/v1/plans/plans.d.mts.map +1 -1
- package/resources/v1/plans/plans.d.ts +16 -1
- package/resources/v1/plans/plans.d.ts.map +1 -1
- package/resources/v1/plans/plans.js +12 -0
- package/resources/v1/plans/plans.js.map +1 -1
- package/resources/v1/plans/plans.mjs +12 -0
- package/resources/v1/plans/plans.mjs.map +1 -1
- package/resources/v1/plans.d.mts.map +1 -1
- package/resources/v1/plans.d.ts.map +1 -1
- package/resources/v1/plans.mjs.map +1 -1
- package/resources/v1/products.d.mts.map +1 -1
- package/resources/v1/products.d.ts.map +1 -1
- package/resources/v1/products.mjs.map +1 -1
- package/resources/v1/subscriptions/future-update.d.mts.map +1 -1
- package/resources/v1/subscriptions/future-update.d.ts.map +1 -1
- package/resources/v1/subscriptions/future-update.mjs.map +1 -1
- package/resources/v1/subscriptions/index.d.mts.map +1 -1
- package/resources/v1/subscriptions/index.d.ts.map +1 -1
- package/resources/v1/subscriptions/index.mjs.map +1 -1
- package/resources/v1/subscriptions/invoice.d.mts.map +1 -1
- package/resources/v1/subscriptions/invoice.d.ts.map +1 -1
- package/resources/v1/subscriptions/invoice.mjs.map +1 -1
- package/resources/v1/subscriptions/subscriptions.d.mts +12 -9
- package/resources/v1/subscriptions/subscriptions.d.mts.map +1 -1
- package/resources/v1/subscriptions/subscriptions.d.ts +12 -9
- package/resources/v1/subscriptions/subscriptions.d.ts.map +1 -1
- package/resources/v1/subscriptions/subscriptions.js.map +1 -1
- package/resources/v1/subscriptions/subscriptions.mjs.map +1 -1
- package/resources/v1/subscriptions/usage.d.mts.map +1 -1
- package/resources/v1/subscriptions/usage.d.ts.map +1 -1
- package/resources/v1/subscriptions/usage.mjs.map +1 -1
- package/resources/v1/subscriptions.d.mts.map +1 -1
- package/resources/v1/subscriptions.d.ts.map +1 -1
- package/resources/v1/subscriptions.mjs.map +1 -1
- package/resources/v1/usage.d.mts.map +1 -1
- package/resources/v1/usage.d.ts.map +1 -1
- package/resources/v1/usage.mjs.map +1 -1
- package/resources/v1/v1.d.mts +10 -6
- package/resources/v1/v1.d.mts.map +1 -1
- package/resources/v1/v1.d.ts +10 -6
- package/resources/v1/v1.d.ts.map +1 -1
- package/resources/v1/v1.js +6 -2
- package/resources/v1/v1.js.map +1 -1
- package/resources/v1/v1.mjs +6 -2
- package/resources/v1/v1.mjs.map +1 -1
- package/resources/v1-beta/customers/assignments.d.mts +175 -0
- package/resources/v1-beta/customers/assignments.d.mts.map +1 -0
- package/resources/v1-beta/customers/assignments.d.ts +175 -0
- package/resources/v1-beta/customers/assignments.d.ts.map +1 -0
- package/resources/v1-beta/customers/assignments.js +59 -0
- package/resources/v1-beta/customers/assignments.js.map +1 -0
- package/resources/v1-beta/customers/assignments.mjs +55 -0
- package/resources/v1-beta/customers/assignments.mjs.map +1 -0
- package/resources/v1-beta/customers/customers.d.mts +18 -0
- package/resources/v1-beta/customers/customers.d.mts.map +1 -0
- package/resources/v1-beta/customers/customers.d.ts +18 -0
- package/resources/v1-beta/customers/customers.d.ts.map +1 -0
- package/resources/v1-beta/customers/customers.js +25 -0
- package/resources/v1-beta/customers/customers.js.map +1 -0
- package/resources/v1-beta/customers/customers.mjs +20 -0
- package/resources/v1-beta/customers/customers.mjs.map +1 -0
- package/resources/v1-beta/customers/entities.d.mts +284 -0
- package/resources/v1-beta/customers/entities.d.mts.map +1 -0
- package/resources/v1-beta/customers/entities.d.ts +284 -0
- package/resources/v1-beta/customers/entities.d.ts.map +1 -0
- package/resources/v1-beta/customers/entities.js +96 -0
- package/resources/v1-beta/customers/entities.js.map +1 -0
- package/resources/v1-beta/customers/entities.mjs +92 -0
- package/resources/v1-beta/customers/entities.mjs.map +1 -0
- package/resources/v1-beta/customers/entitlements.d.mts +236 -0
- package/resources/v1-beta/customers/entitlements.d.mts.map +1 -0
- package/resources/v1-beta/customers/entitlements.d.ts +236 -0
- package/resources/v1-beta/customers/entitlements.d.ts.map +1 -0
- package/resources/v1-beta/customers/entitlements.js +24 -0
- package/resources/v1-beta/customers/entitlements.js.map +1 -0
- package/resources/v1-beta/customers/entitlements.mjs +20 -0
- package/resources/v1-beta/customers/entitlements.mjs.map +1 -0
- package/resources/v1-beta/customers/index.d.mts +5 -0
- package/resources/v1-beta/customers/index.d.mts.map +1 -0
- package/resources/v1-beta/customers/index.d.ts +5 -0
- package/resources/v1-beta/customers/index.d.ts.map +1 -0
- package/resources/v1-beta/customers/index.js +13 -0
- package/resources/v1-beta/customers/index.js.map +1 -0
- package/resources/v1-beta/customers/index.mjs +6 -0
- package/resources/v1-beta/customers/index.mjs.map +1 -0
- package/resources/v1-beta/customers.d.mts +2 -0
- package/resources/v1-beta/customers.d.mts.map +1 -0
- package/resources/v1-beta/customers.d.ts +2 -0
- package/resources/v1-beta/customers.d.ts.map +1 -0
- package/resources/v1-beta/customers.js +6 -0
- package/resources/v1-beta/customers.js.map +1 -0
- package/resources/v1-beta/customers.mjs +3 -0
- package/resources/v1-beta/customers.mjs.map +1 -0
- package/resources/v1-beta/entity-types.d.mts +143 -0
- package/resources/v1-beta/entity-types.d.mts.map +1 -0
- package/resources/v1-beta/entity-types.d.ts +143 -0
- package/resources/v1-beta/entity-types.d.ts.map +1 -0
- package/resources/v1-beta/entity-types.js +55 -0
- package/resources/v1-beta/entity-types.js.map +1 -0
- package/resources/v1-beta/entity-types.mjs +51 -0
- package/resources/v1-beta/entity-types.mjs.map +1 -0
- package/resources/v1-beta/index.d.mts +4 -0
- package/resources/v1-beta/index.d.mts.map +1 -0
- package/resources/v1-beta/index.d.ts +4 -0
- package/resources/v1-beta/index.d.ts.map +1 -0
- package/resources/v1-beta/index.js +11 -0
- package/resources/v1-beta/index.js.map +1 -0
- package/resources/v1-beta/index.mjs +5 -0
- package/resources/v1-beta/index.mjs.map +1 -0
- package/resources/v1-beta/v1-beta.d.mts +14 -0
- package/resources/v1-beta/v1-beta.d.mts.map +1 -0
- package/resources/v1-beta/v1-beta.d.ts +14 -0
- package/resources/v1-beta/v1-beta.d.ts.map +1 -0
- package/resources/v1-beta/v1-beta.js +21 -0
- package/resources/v1-beta/v1-beta.js.map +1 -0
- package/resources/v1-beta/v1-beta.mjs +16 -0
- package/resources/v1-beta/v1-beta.mjs.map +1 -0
- package/resources/v1-beta.d.mts +2 -0
- package/resources/v1-beta.d.mts.map +1 -0
- package/resources/v1-beta.d.ts +2 -0
- package/resources/v1-beta.d.ts.map +1 -0
- package/resources/v1-beta.js +6 -0
- package/resources/v1-beta.js.map +1 -0
- package/resources/v1-beta.mjs +3 -0
- package/resources/v1-beta.mjs.map +1 -0
- package/resources/v1.d.mts.map +1 -1
- package/resources/v1.d.ts.map +1 -1
- package/resources/v1.mjs.map +1 -1
- package/resources.d.mts.map +1 -1
- package/resources.d.ts.map +1 -1
- package/resources.mjs.map +1 -1
- package/src/client.ts +5 -0
- package/src/resources/index.ts +1 -0
- package/src/resources/v1/addons/addons.ts +595 -0
- package/src/resources/v1/addons/index.ts +3 -0
- package/src/resources/v1/{events/credits → credits}/credits.ts +36 -16
- package/src/resources/v1/{events/credits → credits}/custom-currencies.ts +13 -256
- package/src/resources/v1/{events/credits → credits}/grants.ts +5 -5
- package/src/resources/v1/{events/credits → credits}/index.ts +1 -4
- package/src/resources/v1/events.ts +75 -1
- package/src/resources/v1/index.ts +16 -1
- package/src/resources/v1/plans/index.ts +2 -0
- package/src/resources/v1/plans/plans.ts +40 -0
- package/src/resources/v1/subscriptions/subscriptions.ts +12 -9
- package/src/resources/v1/v1.ts +36 -2
- package/src/resources/v1-beta/customers/assignments.ts +225 -0
- package/src/resources/v1-beta/customers/customers.ts +71 -0
- package/src/resources/v1-beta/customers/entities.ts +360 -0
- package/src/resources/v1-beta/customers/entitlements.ts +325 -0
- package/src/resources/v1-beta/customers/index.ts +26 -0
- package/src/resources/v1-beta/customers.ts +3 -0
- package/src/resources/v1-beta/entity-types.ts +179 -0
- package/src/resources/v1-beta/index.ts +12 -0
- package/src/resources/v1-beta/v1-beta.ts +35 -0
- package/src/resources/v1-beta.ts +3 -0
- package/src/version.ts +1 -1
- package/uploads.d.mts +1 -0
- package/uploads.d.mts.map +1 -1
- package/uploads.d.ts +1 -0
- package/uploads.d.ts.map +1 -1
- package/uploads.mjs +1 -0
- package/uploads.mjs.map +1 -1
- package/version.d.mts +1 -1
- package/version.d.mts.map +1 -1
- package/version.d.ts +1 -1
- package/version.d.ts.map +1 -1
- package/version.js +1 -1
- package/version.js.map +1 -1
- package/version.mjs +1 -1
- package/version.mjs.map +1 -1
- package/resources/v1/events/credits/credits.d.mts.map +0 -1
- package/resources/v1/events/credits/credits.d.ts.map +0 -1
- package/resources/v1/events/credits/credits.js.map +0 -1
- package/resources/v1/events/credits/credits.mjs.map +0 -1
- package/resources/v1/events/credits/custom-currencies.d.mts.map +0 -1
- package/resources/v1/events/credits/custom-currencies.d.ts.map +0 -1
- package/resources/v1/events/credits/custom-currencies.js.map +0 -1
- package/resources/v1/events/credits/custom-currencies.mjs.map +0 -1
- package/resources/v1/events/credits/grants.d.mts.map +0 -1
- package/resources/v1/events/credits/grants.d.ts.map +0 -1
- package/resources/v1/events/credits/grants.js.map +0 -1
- package/resources/v1/events/credits/grants.mjs.map +0 -1
- package/resources/v1/events/credits/index.d.mts +0 -4
- package/resources/v1/events/credits/index.d.mts.map +0 -1
- package/resources/v1/events/credits/index.d.ts +0 -4
- package/resources/v1/events/credits/index.d.ts.map +0 -1
- package/resources/v1/events/credits/index.js.map +0 -1
- package/resources/v1/events/credits/index.mjs.map +0 -1
- package/resources/v1/events/credits.d.mts.map +0 -1
- package/resources/v1/events/credits.d.ts.map +0 -1
- package/resources/v1/events/credits.js.map +0 -1
- package/resources/v1/events/credits.mjs.map +0 -1
- package/resources/v1/events/events.d.mts +0 -70
- package/resources/v1/events/events.d.mts.map +0 -1
- package/resources/v1/events/events.d.ts +0 -70
- package/resources/v1/events/events.d.ts.map +0 -1
- package/resources/v1/events/events.js +0 -27
- package/resources/v1/events/events.js.map +0 -1
- package/resources/v1/events/events.mjs +0 -22
- package/resources/v1/events/events.mjs.map +0 -1
- package/resources/v1/events/index.d.mts +0 -3
- package/resources/v1/events/index.d.mts.map +0 -1
- package/resources/v1/events/index.d.ts +0 -3
- package/resources/v1/events/index.d.ts.map +0 -1
- package/resources/v1/events/index.js +0 -9
- package/resources/v1/events/index.js.map +0 -1
- package/resources/v1/events/index.mjs +0 -4
- package/resources/v1/events/index.mjs.map +0 -1
- package/src/resources/v1/events/events.ts +0 -103
- package/src/resources/v1/events/index.ts +0 -13
- /package/resources/v1/{events/credits → credits}/index.js +0 -0
- /package/resources/v1/{events/credits → credits}/index.mjs +0 -0
- /package/resources/v1/{events/credits.d.mts → credits.d.mts} +0 -0
- /package/resources/v1/{events/credits.d.ts → credits.d.ts} +0 -0
- /package/resources/v1/{events/credits.mjs → credits.mjs} +0 -0
- /package/src/resources/v1/{events/credits.ts → credits.ts} +0 -0
|
@@ -1,19 +1,16 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
|
|
3
|
-
import { APIResource } from '
|
|
3
|
+
import { APIResource } from '../../../core/resource';
|
|
4
4
|
import * as CustomCurrenciesAPI from './custom-currencies';
|
|
5
5
|
import {
|
|
6
6
|
CustomCurrencies,
|
|
7
|
-
CustomCurrencyArchiveResponse,
|
|
8
7
|
CustomCurrencyCreateParams,
|
|
9
|
-
CustomCurrencyCreateResponse,
|
|
10
8
|
CustomCurrencyListAssociatedEntitiesResponse,
|
|
11
9
|
CustomCurrencyListParams,
|
|
12
10
|
CustomCurrencyListResponse,
|
|
13
11
|
CustomCurrencyListResponsesMyCursorIDPage,
|
|
14
|
-
|
|
12
|
+
CustomCurrencyResponse,
|
|
15
13
|
CustomCurrencyUpdateParams,
|
|
16
|
-
CustomCurrencyUpdateResponse,
|
|
17
14
|
} from './custom-currencies';
|
|
18
15
|
import * as GrantsAPI from './grants';
|
|
19
16
|
import {
|
|
@@ -24,9 +21,9 @@ import {
|
|
|
24
21
|
GrantListResponsesMyCursorIDPage,
|
|
25
22
|
Grants,
|
|
26
23
|
} from './grants';
|
|
27
|
-
import { APIPromise } from '
|
|
28
|
-
import { MyCursorIDPage, type MyCursorIDPageParams, PagePromise } from '
|
|
29
|
-
import { RequestOptions } from '
|
|
24
|
+
import { APIPromise } from '../../../core/api-promise';
|
|
25
|
+
import { MyCursorIDPage, type MyCursorIDPageParams, PagePromise } from '../../../core/pagination';
|
|
26
|
+
import { RequestOptions } from '../../../internal/request-options';
|
|
30
27
|
|
|
31
28
|
export class Credits extends APIResource {
|
|
32
29
|
grants: GrantsAPI.Grants = new GrantsAPI.Grants(this._client);
|
|
@@ -203,14 +200,14 @@ export namespace CreditGetUsageResponse {
|
|
|
203
200
|
*/
|
|
204
201
|
export interface Series {
|
|
205
202
|
/**
|
|
206
|
-
* The feature ID
|
|
203
|
+
* The feature ID; null when grouping by dimensions only
|
|
207
204
|
*/
|
|
208
|
-
featureId: string;
|
|
205
|
+
featureId: string | null;
|
|
209
206
|
|
|
210
207
|
/**
|
|
211
|
-
* The display name of the feature
|
|
208
|
+
* The display name of the feature; null when grouping by dimensions only
|
|
212
209
|
*/
|
|
213
|
-
featureName: string;
|
|
210
|
+
featureName: string | null;
|
|
214
211
|
|
|
215
212
|
/**
|
|
216
213
|
* Time-series data points for this feature
|
|
@@ -221,6 +218,11 @@ export namespace CreditGetUsageResponse {
|
|
|
221
218
|
* Total credits consumed by this feature in the time range
|
|
222
219
|
*/
|
|
223
220
|
totalCredits: number;
|
|
221
|
+
|
|
222
|
+
/**
|
|
223
|
+
* Dimension key/value pairs identifying this series when groupBy is applied
|
|
224
|
+
*/
|
|
225
|
+
tags?: Array<Series.Tag>;
|
|
224
226
|
}
|
|
225
227
|
|
|
226
228
|
export namespace Series {
|
|
@@ -238,6 +240,21 @@ export namespace CreditGetUsageResponse {
|
|
|
238
240
|
*/
|
|
239
241
|
value: number;
|
|
240
242
|
}
|
|
243
|
+
|
|
244
|
+
/**
|
|
245
|
+
* Dimension key/value pair identifying a credit usage series
|
|
246
|
+
*/
|
|
247
|
+
export interface Tag {
|
|
248
|
+
/**
|
|
249
|
+
* The dimension key
|
|
250
|
+
*/
|
|
251
|
+
key: string;
|
|
252
|
+
|
|
253
|
+
/**
|
|
254
|
+
* The dimension value for this series
|
|
255
|
+
*/
|
|
256
|
+
value: string;
|
|
257
|
+
}
|
|
241
258
|
}
|
|
242
259
|
}
|
|
243
260
|
}
|
|
@@ -328,6 +345,12 @@ export interface CreditGetUsageParams {
|
|
|
328
345
|
*/
|
|
329
346
|
endDate?: string;
|
|
330
347
|
|
|
348
|
+
/**
|
|
349
|
+
* Comma-separated list of feature dimension keys to group usage series by (up to
|
|
350
|
+
* 3). Each key matches /^[a-zA-Z0-9_$-]+$/
|
|
351
|
+
*/
|
|
352
|
+
groupBy?: string;
|
|
353
|
+
|
|
331
354
|
/**
|
|
332
355
|
* Filter by resource ID
|
|
333
356
|
*/
|
|
@@ -388,12 +411,9 @@ export declare namespace Credits {
|
|
|
388
411
|
|
|
389
412
|
export {
|
|
390
413
|
CustomCurrencies as CustomCurrencies,
|
|
391
|
-
type
|
|
392
|
-
type CustomCurrencyUpdateResponse as CustomCurrencyUpdateResponse,
|
|
414
|
+
type CustomCurrencyResponse as CustomCurrencyResponse,
|
|
393
415
|
type CustomCurrencyListResponse as CustomCurrencyListResponse,
|
|
394
|
-
type CustomCurrencyArchiveResponse as CustomCurrencyArchiveResponse,
|
|
395
416
|
type CustomCurrencyListAssociatedEntitiesResponse as CustomCurrencyListAssociatedEntitiesResponse,
|
|
396
|
-
type CustomCurrencyUnarchiveResponse as CustomCurrencyUnarchiveResponse,
|
|
397
417
|
type CustomCurrencyListResponsesMyCursorIDPage as CustomCurrencyListResponsesMyCursorIDPage,
|
|
398
418
|
type CustomCurrencyCreateParams as CustomCurrencyCreateParams,
|
|
399
419
|
type CustomCurrencyUpdateParams as CustomCurrencyUpdateParams,
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
|
|
3
|
-
import { APIResource } from '
|
|
4
|
-
import { APIPromise } from '
|
|
5
|
-
import { MyCursorIDPage, type MyCursorIDPageParams, PagePromise } from '
|
|
6
|
-
import { RequestOptions } from '
|
|
7
|
-
import { path } from '
|
|
3
|
+
import { APIResource } from '../../../core/resource';
|
|
4
|
+
import { APIPromise } from '../../../core/api-promise';
|
|
5
|
+
import { MyCursorIDPage, type MyCursorIDPageParams, PagePromise } from '../../../core/pagination';
|
|
6
|
+
import { RequestOptions } from '../../../internal/request-options';
|
|
7
|
+
import { path } from '../../../internal/utils/path';
|
|
8
8
|
|
|
9
9
|
/**
|
|
10
10
|
* Operations related to custom currencies
|
|
@@ -13,10 +13,7 @@ export class CustomCurrencies extends APIResource {
|
|
|
13
13
|
/**
|
|
14
14
|
* Creates a new custom currency in the environment.
|
|
15
15
|
*/
|
|
16
|
-
create(
|
|
17
|
-
body: CustomCurrencyCreateParams,
|
|
18
|
-
options?: RequestOptions,
|
|
19
|
-
): APIPromise<CustomCurrencyCreateResponse> {
|
|
16
|
+
create(body: CustomCurrencyCreateParams, options?: RequestOptions): APIPromise<CustomCurrencyResponse> {
|
|
20
17
|
return this._client.post('/api/v1/credits/custom-currencies', { body, ...options });
|
|
21
18
|
}
|
|
22
19
|
|
|
@@ -27,7 +24,7 @@ export class CustomCurrencies extends APIResource {
|
|
|
27
24
|
currencyID: string,
|
|
28
25
|
body: CustomCurrencyUpdateParams,
|
|
29
26
|
options?: RequestOptions,
|
|
30
|
-
): APIPromise<
|
|
27
|
+
): APIPromise<CustomCurrencyResponse> {
|
|
31
28
|
return this._client.patch(path`/api/v1/credits/custom-currencies/${currencyID}`, { body, ...options });
|
|
32
29
|
}
|
|
33
30
|
|
|
@@ -52,7 +49,7 @@ export class CustomCurrencies extends APIResource {
|
|
|
52
49
|
* active plan or addon — use the associated-entities endpoint first to inspect
|
|
53
50
|
* dependencies.
|
|
54
51
|
*/
|
|
55
|
-
archive(currencyID: string, options?: RequestOptions): APIPromise<
|
|
52
|
+
archive(currencyID: string, options?: RequestOptions): APIPromise<CustomCurrencyResponse> {
|
|
56
53
|
return this._client.post(path`/api/v1/credits/custom-currencies/${currencyID}/archive`, options);
|
|
57
54
|
}
|
|
58
55
|
|
|
@@ -74,7 +71,7 @@ export class CustomCurrencies extends APIResource {
|
|
|
74
71
|
* Restores a previously archived custom currency. Fails if another active currency
|
|
75
72
|
* with the same ID already exists.
|
|
76
73
|
*/
|
|
77
|
-
unarchive(currencyID: string, options?: RequestOptions): APIPromise<
|
|
74
|
+
unarchive(currencyID: string, options?: RequestOptions): APIPromise<CustomCurrencyResponse> {
|
|
78
75
|
return this._client.post(path`/api/v1/credits/custom-currencies/${currencyID}/unarchive`, options);
|
|
79
76
|
}
|
|
80
77
|
}
|
|
@@ -84,93 +81,14 @@ export type CustomCurrencyListResponsesMyCursorIDPage = MyCursorIDPage<CustomCur
|
|
|
84
81
|
/**
|
|
85
82
|
* Response object
|
|
86
83
|
*/
|
|
87
|
-
export interface
|
|
84
|
+
export interface CustomCurrencyResponse {
|
|
88
85
|
/**
|
|
89
86
|
* A custom currency used to denominate credit-based entitlements and pricing
|
|
90
87
|
*/
|
|
91
|
-
data:
|
|
88
|
+
data: CustomCurrencyResponse.Data;
|
|
92
89
|
}
|
|
93
90
|
|
|
94
|
-
export namespace
|
|
95
|
-
/**
|
|
96
|
-
* A custom currency used to denominate credit-based entitlements and pricing
|
|
97
|
-
*/
|
|
98
|
-
export interface Data {
|
|
99
|
-
/**
|
|
100
|
-
* The unique identifier for the custom currency
|
|
101
|
-
*/
|
|
102
|
-
id: string;
|
|
103
|
-
|
|
104
|
-
/**
|
|
105
|
-
* Timestamp of when the record was deleted
|
|
106
|
-
*/
|
|
107
|
-
archivedAt: string | null;
|
|
108
|
-
|
|
109
|
-
/**
|
|
110
|
-
* Timestamp of when the record was created
|
|
111
|
-
*/
|
|
112
|
-
createdAt: string;
|
|
113
|
-
|
|
114
|
-
/**
|
|
115
|
-
* Description of the currency
|
|
116
|
-
*/
|
|
117
|
-
description: string | null;
|
|
118
|
-
|
|
119
|
-
/**
|
|
120
|
-
* The display name of the custom currency
|
|
121
|
-
*/
|
|
122
|
-
displayName: string;
|
|
123
|
-
|
|
124
|
-
/**
|
|
125
|
-
* Metadata associated with the entity
|
|
126
|
-
*/
|
|
127
|
-
metadata: { [key: string]: string };
|
|
128
|
-
|
|
129
|
-
/**
|
|
130
|
-
* The symbol used to represent the custom currency
|
|
131
|
-
*/
|
|
132
|
-
symbol: string | null;
|
|
133
|
-
|
|
134
|
-
/**
|
|
135
|
-
* Singular and plural unit labels for a custom currency
|
|
136
|
-
*/
|
|
137
|
-
units: Data.Units | null;
|
|
138
|
-
|
|
139
|
-
/**
|
|
140
|
-
* Timestamp of when the record was last updated
|
|
141
|
-
*/
|
|
142
|
-
updatedAt: string;
|
|
143
|
-
}
|
|
144
|
-
|
|
145
|
-
export namespace Data {
|
|
146
|
-
/**
|
|
147
|
-
* Singular and plural unit labels for a custom currency
|
|
148
|
-
*/
|
|
149
|
-
export interface Units {
|
|
150
|
-
/**
|
|
151
|
-
* Plural form of the unit label
|
|
152
|
-
*/
|
|
153
|
-
plural: string | null;
|
|
154
|
-
|
|
155
|
-
/**
|
|
156
|
-
* Singular form of the unit label
|
|
157
|
-
*/
|
|
158
|
-
singular: string | null;
|
|
159
|
-
}
|
|
160
|
-
}
|
|
161
|
-
}
|
|
162
|
-
|
|
163
|
-
/**
|
|
164
|
-
* Response object
|
|
165
|
-
*/
|
|
166
|
-
export interface CustomCurrencyUpdateResponse {
|
|
167
|
-
/**
|
|
168
|
-
* A custom currency used to denominate credit-based entitlements and pricing
|
|
169
|
-
*/
|
|
170
|
-
data: CustomCurrencyUpdateResponse.Data;
|
|
171
|
-
}
|
|
172
|
-
|
|
173
|
-
export namespace CustomCurrencyUpdateResponse {
|
|
91
|
+
export namespace CustomCurrencyResponse {
|
|
174
92
|
/**
|
|
175
93
|
* A custom currency used to denominate credit-based entitlements and pricing
|
|
176
94
|
*/
|
|
@@ -306,85 +224,6 @@ export namespace CustomCurrencyListResponse {
|
|
|
306
224
|
}
|
|
307
225
|
}
|
|
308
226
|
|
|
309
|
-
/**
|
|
310
|
-
* Response object
|
|
311
|
-
*/
|
|
312
|
-
export interface CustomCurrencyArchiveResponse {
|
|
313
|
-
/**
|
|
314
|
-
* A custom currency used to denominate credit-based entitlements and pricing
|
|
315
|
-
*/
|
|
316
|
-
data: CustomCurrencyArchiveResponse.Data;
|
|
317
|
-
}
|
|
318
|
-
|
|
319
|
-
export namespace CustomCurrencyArchiveResponse {
|
|
320
|
-
/**
|
|
321
|
-
* A custom currency used to denominate credit-based entitlements and pricing
|
|
322
|
-
*/
|
|
323
|
-
export interface Data {
|
|
324
|
-
/**
|
|
325
|
-
* The unique identifier for the custom currency
|
|
326
|
-
*/
|
|
327
|
-
id: string;
|
|
328
|
-
|
|
329
|
-
/**
|
|
330
|
-
* Timestamp of when the record was deleted
|
|
331
|
-
*/
|
|
332
|
-
archivedAt: string | null;
|
|
333
|
-
|
|
334
|
-
/**
|
|
335
|
-
* Timestamp of when the record was created
|
|
336
|
-
*/
|
|
337
|
-
createdAt: string;
|
|
338
|
-
|
|
339
|
-
/**
|
|
340
|
-
* Description of the currency
|
|
341
|
-
*/
|
|
342
|
-
description: string | null;
|
|
343
|
-
|
|
344
|
-
/**
|
|
345
|
-
* The display name of the custom currency
|
|
346
|
-
*/
|
|
347
|
-
displayName: string;
|
|
348
|
-
|
|
349
|
-
/**
|
|
350
|
-
* Metadata associated with the entity
|
|
351
|
-
*/
|
|
352
|
-
metadata: { [key: string]: string };
|
|
353
|
-
|
|
354
|
-
/**
|
|
355
|
-
* The symbol used to represent the custom currency
|
|
356
|
-
*/
|
|
357
|
-
symbol: string | null;
|
|
358
|
-
|
|
359
|
-
/**
|
|
360
|
-
* Singular and plural unit labels for a custom currency
|
|
361
|
-
*/
|
|
362
|
-
units: Data.Units | null;
|
|
363
|
-
|
|
364
|
-
/**
|
|
365
|
-
* Timestamp of when the record was last updated
|
|
366
|
-
*/
|
|
367
|
-
updatedAt: string;
|
|
368
|
-
}
|
|
369
|
-
|
|
370
|
-
export namespace Data {
|
|
371
|
-
/**
|
|
372
|
-
* Singular and plural unit labels for a custom currency
|
|
373
|
-
*/
|
|
374
|
-
export interface Units {
|
|
375
|
-
/**
|
|
376
|
-
* Plural form of the unit label
|
|
377
|
-
*/
|
|
378
|
-
plural: string | null;
|
|
379
|
-
|
|
380
|
-
/**
|
|
381
|
-
* Singular form of the unit label
|
|
382
|
-
*/
|
|
383
|
-
singular: string | null;
|
|
384
|
-
}
|
|
385
|
-
}
|
|
386
|
-
}
|
|
387
|
-
|
|
388
227
|
/**
|
|
389
228
|
* List of entities (plans or addons) that reference a custom currency
|
|
390
229
|
*/
|
|
@@ -414,85 +253,6 @@ export namespace CustomCurrencyListAssociatedEntitiesResponse {
|
|
|
414
253
|
}
|
|
415
254
|
}
|
|
416
255
|
|
|
417
|
-
/**
|
|
418
|
-
* Response object
|
|
419
|
-
*/
|
|
420
|
-
export interface CustomCurrencyUnarchiveResponse {
|
|
421
|
-
/**
|
|
422
|
-
* A custom currency used to denominate credit-based entitlements and pricing
|
|
423
|
-
*/
|
|
424
|
-
data: CustomCurrencyUnarchiveResponse.Data;
|
|
425
|
-
}
|
|
426
|
-
|
|
427
|
-
export namespace CustomCurrencyUnarchiveResponse {
|
|
428
|
-
/**
|
|
429
|
-
* A custom currency used to denominate credit-based entitlements and pricing
|
|
430
|
-
*/
|
|
431
|
-
export interface Data {
|
|
432
|
-
/**
|
|
433
|
-
* The unique identifier for the custom currency
|
|
434
|
-
*/
|
|
435
|
-
id: string;
|
|
436
|
-
|
|
437
|
-
/**
|
|
438
|
-
* Timestamp of when the record was deleted
|
|
439
|
-
*/
|
|
440
|
-
archivedAt: string | null;
|
|
441
|
-
|
|
442
|
-
/**
|
|
443
|
-
* Timestamp of when the record was created
|
|
444
|
-
*/
|
|
445
|
-
createdAt: string;
|
|
446
|
-
|
|
447
|
-
/**
|
|
448
|
-
* Description of the currency
|
|
449
|
-
*/
|
|
450
|
-
description: string | null;
|
|
451
|
-
|
|
452
|
-
/**
|
|
453
|
-
* The display name of the custom currency
|
|
454
|
-
*/
|
|
455
|
-
displayName: string;
|
|
456
|
-
|
|
457
|
-
/**
|
|
458
|
-
* Metadata associated with the entity
|
|
459
|
-
*/
|
|
460
|
-
metadata: { [key: string]: string };
|
|
461
|
-
|
|
462
|
-
/**
|
|
463
|
-
* The symbol used to represent the custom currency
|
|
464
|
-
*/
|
|
465
|
-
symbol: string | null;
|
|
466
|
-
|
|
467
|
-
/**
|
|
468
|
-
* Singular and plural unit labels for a custom currency
|
|
469
|
-
*/
|
|
470
|
-
units: Data.Units | null;
|
|
471
|
-
|
|
472
|
-
/**
|
|
473
|
-
* Timestamp of when the record was last updated
|
|
474
|
-
*/
|
|
475
|
-
updatedAt: string;
|
|
476
|
-
}
|
|
477
|
-
|
|
478
|
-
export namespace Data {
|
|
479
|
-
/**
|
|
480
|
-
* Singular and plural unit labels for a custom currency
|
|
481
|
-
*/
|
|
482
|
-
export interface Units {
|
|
483
|
-
/**
|
|
484
|
-
* Plural form of the unit label
|
|
485
|
-
*/
|
|
486
|
-
plural: string | null;
|
|
487
|
-
|
|
488
|
-
/**
|
|
489
|
-
* Singular form of the unit label
|
|
490
|
-
*/
|
|
491
|
-
singular: string | null;
|
|
492
|
-
}
|
|
493
|
-
}
|
|
494
|
-
}
|
|
495
|
-
|
|
496
256
|
export interface CustomCurrencyCreateParams {
|
|
497
257
|
/**
|
|
498
258
|
* The unique identifier for the new custom currency
|
|
@@ -601,12 +361,9 @@ export interface CustomCurrencyListParams extends MyCursorIDPageParams {
|
|
|
601
361
|
|
|
602
362
|
export declare namespace CustomCurrencies {
|
|
603
363
|
export {
|
|
604
|
-
type
|
|
605
|
-
type CustomCurrencyUpdateResponse as CustomCurrencyUpdateResponse,
|
|
364
|
+
type CustomCurrencyResponse as CustomCurrencyResponse,
|
|
606
365
|
type CustomCurrencyListResponse as CustomCurrencyListResponse,
|
|
607
|
-
type CustomCurrencyArchiveResponse as CustomCurrencyArchiveResponse,
|
|
608
366
|
type CustomCurrencyListAssociatedEntitiesResponse as CustomCurrencyListAssociatedEntitiesResponse,
|
|
609
|
-
type CustomCurrencyUnarchiveResponse as CustomCurrencyUnarchiveResponse,
|
|
610
367
|
type CustomCurrencyListResponsesMyCursorIDPage as CustomCurrencyListResponsesMyCursorIDPage,
|
|
611
368
|
type CustomCurrencyCreateParams as CustomCurrencyCreateParams,
|
|
612
369
|
type CustomCurrencyUpdateParams as CustomCurrencyUpdateParams,
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
|
|
3
|
-
import { APIResource } from '
|
|
4
|
-
import { APIPromise } from '
|
|
5
|
-
import { MyCursorIDPage, type MyCursorIDPageParams, PagePromise } from '
|
|
6
|
-
import { RequestOptions } from '
|
|
7
|
-
import { path } from '
|
|
3
|
+
import { APIResource } from '../../../core/resource';
|
|
4
|
+
import { APIPromise } from '../../../core/api-promise';
|
|
5
|
+
import { MyCursorIDPage, type MyCursorIDPageParams, PagePromise } from '../../../core/pagination';
|
|
6
|
+
import { RequestOptions } from '../../../internal/request-options';
|
|
7
|
+
import { path } from '../../../internal/utils/path';
|
|
8
8
|
|
|
9
9
|
/**
|
|
10
10
|
* Operations related to credit grants
|
|
@@ -12,12 +12,9 @@ export {
|
|
|
12
12
|
} from './credits';
|
|
13
13
|
export {
|
|
14
14
|
CustomCurrencies,
|
|
15
|
-
type
|
|
16
|
-
type CustomCurrencyUpdateResponse,
|
|
15
|
+
type CustomCurrencyResponse,
|
|
17
16
|
type CustomCurrencyListResponse,
|
|
18
|
-
type CustomCurrencyArchiveResponse,
|
|
19
17
|
type CustomCurrencyListAssociatedEntitiesResponse,
|
|
20
|
-
type CustomCurrencyUnarchiveResponse,
|
|
21
18
|
type CustomCurrencyCreateParams,
|
|
22
19
|
type CustomCurrencyUpdateParams,
|
|
23
20
|
type CustomCurrencyListParams,
|
|
@@ -1,3 +1,77 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
import { APIResource } from '../../core/resource';
|
|
4
|
+
import { APIPromise } from '../../core/api-promise';
|
|
5
|
+
import { RequestOptions } from '../../internal/request-options';
|
|
6
|
+
|
|
7
|
+
/**
|
|
8
|
+
* Operations related to usage & metering
|
|
9
|
+
*/
|
|
10
|
+
export class Events extends APIResource {
|
|
11
|
+
/**
|
|
12
|
+
* Reports raw usage events for event-based metering. Events are ingested
|
|
13
|
+
* asynchronously and aggregated into usage totals.
|
|
14
|
+
*/
|
|
15
|
+
report(body: EventReportParams, options?: RequestOptions): APIPromise<EventReportResponse> {
|
|
16
|
+
return this._client.post('/api/v1/events', { body, ...options });
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
/**
|
|
21
|
+
* Response object
|
|
22
|
+
*/
|
|
23
|
+
export interface EventReportResponse {
|
|
24
|
+
/**
|
|
25
|
+
* Empty success response confirming that events were successfully ingested and
|
|
26
|
+
* queued for processing by Stigg's metering system.
|
|
27
|
+
*/
|
|
28
|
+
data: unknown;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
export interface EventReportParams {
|
|
32
|
+
/**
|
|
33
|
+
* A list of usage events to report
|
|
34
|
+
*/
|
|
35
|
+
events: Array<EventReportParams.Event>;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
export namespace EventReportParams {
|
|
39
|
+
/**
|
|
40
|
+
* Raw usage event
|
|
41
|
+
*/
|
|
42
|
+
export interface Event {
|
|
43
|
+
/**
|
|
44
|
+
* Customer id
|
|
45
|
+
*/
|
|
46
|
+
customerId: string;
|
|
47
|
+
|
|
48
|
+
/**
|
|
49
|
+
* The name of the usage event
|
|
50
|
+
*/
|
|
51
|
+
eventName: string;
|
|
52
|
+
|
|
53
|
+
/**
|
|
54
|
+
* Idempotency key
|
|
55
|
+
*/
|
|
56
|
+
idempotencyKey: string;
|
|
57
|
+
|
|
58
|
+
/**
|
|
59
|
+
* Dimensions associated with the usage event
|
|
60
|
+
*/
|
|
61
|
+
dimensions?: { [key: string]: string | number | boolean };
|
|
62
|
+
|
|
63
|
+
/**
|
|
64
|
+
* Resource id
|
|
65
|
+
*/
|
|
66
|
+
resourceId?: string | null;
|
|
67
|
+
|
|
68
|
+
/**
|
|
69
|
+
* Timestamp
|
|
70
|
+
*/
|
|
71
|
+
timestamp?: string;
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
export declare namespace Events {
|
|
76
|
+
export { type EventReportResponse as EventReportResponse, type EventReportParams as EventReportParams };
|
|
77
|
+
}
|
|
@@ -3,14 +3,17 @@
|
|
|
3
3
|
export {
|
|
4
4
|
Addons,
|
|
5
5
|
type Addon,
|
|
6
|
+
type ChargeList,
|
|
6
7
|
type AddonListResponse,
|
|
7
8
|
type AddonPublishResponse,
|
|
8
9
|
type AddonRemoveDraftResponse,
|
|
9
10
|
type AddonCreateParams,
|
|
10
11
|
type AddonUpdateParams,
|
|
11
12
|
type AddonListParams,
|
|
13
|
+
type AddonListChargesParams,
|
|
12
14
|
type AddonPublishParams,
|
|
13
15
|
type AddonListResponsesMyCursorIDPage,
|
|
16
|
+
type ChargeListDataMyCursorIDPage,
|
|
14
17
|
} from './addons/index';
|
|
15
18
|
export {
|
|
16
19
|
Coupons,
|
|
@@ -21,6 +24,16 @@ export {
|
|
|
21
24
|
type CouponUpdateCouponParams,
|
|
22
25
|
type CouponListResponsesMyCursorIDPage,
|
|
23
26
|
} from './coupons';
|
|
27
|
+
export {
|
|
28
|
+
Credits,
|
|
29
|
+
type CreditGetAutoRechargeResponse,
|
|
30
|
+
type CreditGetUsageResponse,
|
|
31
|
+
type CreditListLedgerResponse,
|
|
32
|
+
type CreditGetAutoRechargeParams,
|
|
33
|
+
type CreditGetUsageParams,
|
|
34
|
+
type CreditListLedgerParams,
|
|
35
|
+
type CreditListLedgerResponsesMyCursorIDPage,
|
|
36
|
+
} from './credits/index';
|
|
24
37
|
export {
|
|
25
38
|
Customers,
|
|
26
39
|
type CustomerIntegrationResponse,
|
|
@@ -40,7 +53,7 @@ export {
|
|
|
40
53
|
type CustomerListResponsesMyCursorIDPage,
|
|
41
54
|
type CustomerListResourcesResponsesMyCursorIDPage,
|
|
42
55
|
} from './customers/index';
|
|
43
|
-
export { Events, type EventReportResponse, type EventReportParams } from './events
|
|
56
|
+
export { Events, type EventReportResponse, type EventReportParams } from './events';
|
|
44
57
|
export {
|
|
45
58
|
Features,
|
|
46
59
|
type Feature,
|
|
@@ -59,6 +72,8 @@ export {
|
|
|
59
72
|
type PlanCreateParams,
|
|
60
73
|
type PlanUpdateParams,
|
|
61
74
|
type PlanListParams,
|
|
75
|
+
type PlanListChargesParams,
|
|
76
|
+
type PlanListOverageChargesParams,
|
|
62
77
|
type PlanPublishParams,
|
|
63
78
|
type PlanListResponsesMyCursorIDPage,
|
|
64
79
|
} from './plans/index';
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
|
|
3
3
|
import { APIResource } from '../../../core/resource';
|
|
4
|
+
import * as AddonsAPI from '../addons/addons';
|
|
5
|
+
import { ChargeListDataMyCursorIDPage } from '../addons/addons';
|
|
4
6
|
import * as EntitlementsAPI from './entitlements';
|
|
5
7
|
import {
|
|
6
8
|
EntitlementCreateParams,
|
|
@@ -69,6 +71,36 @@ export class Plans extends APIResource {
|
|
|
69
71
|
return this._client.post(path`/api/v1/plans/${id}/draft`, options);
|
|
70
72
|
}
|
|
71
73
|
|
|
74
|
+
/**
|
|
75
|
+
* Retrieves the list of charges configured on a plan.
|
|
76
|
+
*/
|
|
77
|
+
listCharges(
|
|
78
|
+
id: string,
|
|
79
|
+
query: PlanListChargesParams | null | undefined = {},
|
|
80
|
+
options?: RequestOptions,
|
|
81
|
+
): PagePromise<ChargeListDataMyCursorIDPage, AddonsAPI.ChargeList.Data> {
|
|
82
|
+
return this._client.getAPIList(
|
|
83
|
+
path`/api/v1/plans/${id}/charges`,
|
|
84
|
+
MyCursorIDPage<AddonsAPI.ChargeList.Data>,
|
|
85
|
+
{ query, ...options },
|
|
86
|
+
);
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
/**
|
|
90
|
+
* Retrieves the list of overage charges configured on a plan.
|
|
91
|
+
*/
|
|
92
|
+
listOverageCharges(
|
|
93
|
+
id: string,
|
|
94
|
+
query: PlanListOverageChargesParams | null | undefined = {},
|
|
95
|
+
options?: RequestOptions,
|
|
96
|
+
): PagePromise<ChargeListDataMyCursorIDPage, AddonsAPI.ChargeList.Data> {
|
|
97
|
+
return this._client.getAPIList(
|
|
98
|
+
path`/api/v1/plans/${id}/overage-charges`,
|
|
99
|
+
MyCursorIDPage<AddonsAPI.ChargeList.Data>,
|
|
100
|
+
{ query, ...options },
|
|
101
|
+
);
|
|
102
|
+
}
|
|
103
|
+
|
|
72
104
|
/**
|
|
73
105
|
* Publishes a draft plan, making it available for use in subscriptions.
|
|
74
106
|
*/
|
|
@@ -1995,6 +2027,10 @@ export namespace PlanListParams {
|
|
|
1995
2027
|
}
|
|
1996
2028
|
}
|
|
1997
2029
|
|
|
2030
|
+
export interface PlanListChargesParams extends MyCursorIDPageParams {}
|
|
2031
|
+
|
|
2032
|
+
export interface PlanListOverageChargesParams extends MyCursorIDPageParams {}
|
|
2033
|
+
|
|
1998
2034
|
export interface PlanPublishParams {
|
|
1999
2035
|
/**
|
|
2000
2036
|
* The migration type of the package
|
|
@@ -2014,6 +2050,8 @@ export declare namespace Plans {
|
|
|
2014
2050
|
type PlanCreateParams as PlanCreateParams,
|
|
2015
2051
|
type PlanUpdateParams as PlanUpdateParams,
|
|
2016
2052
|
type PlanListParams as PlanListParams,
|
|
2053
|
+
type PlanListChargesParams as PlanListChargesParams,
|
|
2054
|
+
type PlanListOverageChargesParams as PlanListOverageChargesParams,
|
|
2017
2055
|
type PlanPublishParams as PlanPublishParams,
|
|
2018
2056
|
};
|
|
2019
2057
|
|
|
@@ -2027,3 +2065,5 @@ export declare namespace Plans {
|
|
|
2027
2065
|
type EntitlementDeleteParams as EntitlementDeleteParams,
|
|
2028
2066
|
};
|
|
2029
2067
|
}
|
|
2068
|
+
|
|
2069
|
+
export { type ChargeListDataMyCursorIDPage };
|