@metronome/sdk 0.3.0 → 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +48 -28
- package/README.md +123 -51
- 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/bin/cli +53 -0
- package/bin/migration-config.json +6 -0
- package/client.d.mts +232 -0
- package/client.d.mts.map +1 -0
- package/client.d.ts +232 -0
- package/client.d.ts.map +1 -0
- package/client.js +464 -0
- package/client.js.map +1 -0
- package/client.mjs +460 -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 +137 -0
- package/core/pagination.d.mts.map +1 -0
- package/core/pagination.d.ts +137 -0
- package/core/pagination.d.ts.map +1 -0
- package/core/pagination.js +158 -0
- package/core/pagination.js.map +1 -0
- package/core/pagination.mjs +150 -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 +1 -46
- package/error.d.ts.map +1 -1
- package/error.js +3 -110
- package/error.js.map +1 -1
- package/error.mjs +1 -96
- package/error.mjs.map +1 -1
- package/index.d.mts +7 -144
- package/index.d.mts.map +1 -0
- package/index.d.ts +6 -143
- package/index.d.ts.map +1 -1
- package/index.js +14 -120
- package/index.js.map +1 -1
- package/index.mjs +6 -93
- package/index.mjs.map +1 -1
- 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 +26 -0
- package/internal/headers.d.mts.map +1 -0
- package/internal/headers.d.ts +26 -0
- package/internal/headers.d.ts.map +1 -0
- package/internal/headers.js +120 -0
- package/internal/headers.js.map +1 -0
- package/internal/headers.mjs +112 -0
- package/internal/headers.mjs.map +1 -0
- package/internal/parse.d.mts +12 -0
- package/internal/parse.d.mts.map +1 -0
- package/internal/parse.d.ts +12 -0
- package/internal/parse.d.ts.map +1 -0
- package/internal/parse.js +35 -0
- package/internal/parse.js.map +1 -0
- package/internal/parse.mjs +32 -0
- package/internal/parse.mjs.map +1 -0
- package/internal/qs/formats.d.mts +7 -0
- package/internal/qs/formats.d.mts.map +1 -0
- package/internal/qs/formats.d.ts +1 -0
- package/internal/qs/formats.d.ts.map +1 -1
- package/internal/qs/formats.js +4 -2
- package/internal/qs/formats.js.map +1 -1
- package/internal/qs/formats.mjs +2 -1
- package/internal/qs/formats.mjs.map +1 -1
- package/internal/qs/index.d.mts +10 -0
- package/internal/qs/index.d.mts.map +1 -0
- package/internal/qs/index.d.ts.map +1 -1
- package/internal/qs/stringify.d.mts +3 -0
- package/internal/qs/stringify.d.mts.map +1 -0
- package/internal/qs/stringify.d.ts.map +1 -1
- package/internal/qs/stringify.js +16 -19
- package/internal/qs/stringify.js.map +1 -1
- package/internal/qs/stringify.mjs +17 -19
- package/internal/qs/stringify.mjs.map +1 -1
- package/internal/qs/types.d.mts +57 -0
- package/internal/qs/types.d.mts.map +1 -0
- package/internal/qs/utils.d.mts +15 -0
- package/internal/qs/utils.d.mts.map +1 -0
- package/internal/qs/utils.d.ts +1 -0
- package/internal/qs/utils.d.ts.map +1 -1
- package/internal/qs/utils.js +22 -21
- package/internal/qs/utils.js.map +1 -1
- package/internal/qs/utils.mjs +12 -12
- package/internal/qs/utils.mjs.map +1 -1
- package/internal/request-options.d.mts +75 -0
- package/internal/request-options.d.mts.map +1 -0
- package/internal/request-options.d.ts +75 -0
- package/internal/request-options.d.ts.map +1 -0
- package/internal/request-options.js +14 -0
- package/internal/request-options.js.map +1 -0
- package/internal/request-options.mjs +10 -0
- package/internal/request-options.mjs.map +1 -0
- package/internal/shim-types.d.mts +17 -0
- package/internal/shim-types.d.mts.map +1 -0
- package/internal/shim-types.d.ts +17 -0
- package/internal/shim-types.d.ts.map +1 -0
- package/internal/shim-types.js +4 -0
- package/internal/shim-types.js.map +1 -0
- package/internal/shim-types.mjs +3 -0
- package/internal/shim-types.mjs.map +1 -0
- package/internal/shims.d.mts +20 -0
- package/internal/shims.d.mts.map +1 -0
- package/internal/shims.d.ts +20 -0
- package/internal/shims.d.ts.map +1 -0
- package/internal/shims.js +92 -0
- package/internal/shims.js.map +1 -0
- package/internal/shims.mjs +85 -0
- package/internal/shims.mjs.map +1 -0
- package/internal/to-file.d.mts +45 -0
- package/internal/to-file.d.mts.map +1 -0
- package/internal/to-file.d.ts +45 -0
- package/internal/to-file.d.ts.map +1 -0
- package/internal/to-file.js +91 -0
- package/internal/to-file.js.map +1 -0
- package/internal/to-file.mjs +88 -0
- package/internal/to-file.mjs.map +1 -0
- package/internal/tslib.js +81 -0
- package/internal/tslib.mjs +17 -0
- package/internal/types.d.mts +69 -0
- package/internal/types.d.mts.map +1 -0
- package/internal/types.d.ts +69 -0
- package/internal/types.d.ts.map +1 -0
- package/internal/types.js +4 -0
- package/internal/types.js.map +1 -0
- package/internal/types.mjs +3 -0
- package/internal/types.mjs.map +1 -0
- package/internal/uploads.d.mts +42 -0
- package/internal/uploads.d.mts.map +1 -0
- package/internal/uploads.d.ts +42 -0
- package/internal/uploads.d.ts.map +1 -0
- package/internal/uploads.js +141 -0
- package/internal/uploads.js.map +1 -0
- package/internal/uploads.mjs +131 -0
- package/internal/uploads.mjs.map +1 -0
- package/internal/utils/base64.d.mts +3 -0
- package/internal/utils/base64.d.mts.map +1 -0
- package/internal/utils/base64.d.ts +3 -0
- package/internal/utils/base64.d.ts.map +1 -0
- package/internal/utils/base64.js +38 -0
- package/internal/utils/base64.js.map +1 -0
- package/internal/utils/base64.mjs +33 -0
- package/internal/utils/base64.mjs.map +1 -0
- package/internal/utils/bytes.d.mts +4 -0
- package/internal/utils/bytes.d.mts.map +1 -0
- package/internal/utils/bytes.d.ts +4 -0
- package/internal/utils/bytes.d.ts.map +1 -0
- package/internal/utils/bytes.js +31 -0
- package/internal/utils/bytes.js.map +1 -0
- package/internal/utils/bytes.mjs +26 -0
- package/internal/utils/bytes.mjs.map +1 -0
- package/internal/utils/env.d.mts +9 -0
- package/internal/utils/env.d.mts.map +1 -0
- package/internal/utils/env.d.ts +9 -0
- package/internal/utils/env.d.ts.map +1 -0
- package/internal/utils/env.js +22 -0
- package/internal/utils/env.js.map +1 -0
- package/internal/utils/env.mjs +18 -0
- package/internal/utils/env.mjs.map +1 -0
- package/internal/utils/log.d.mts +37 -0
- package/internal/utils/log.d.mts.map +1 -0
- package/internal/utils/log.d.ts +37 -0
- package/internal/utils/log.d.ts.map +1 -0
- package/internal/utils/log.js +85 -0
- package/internal/utils/log.js.map +1 -0
- package/internal/utils/log.mjs +79 -0
- package/internal/utils/log.mjs.map +1 -0
- package/internal/utils/path.d.mts +15 -0
- package/internal/utils/path.d.mts.map +1 -0
- package/internal/utils/path.d.ts +15 -0
- package/internal/utils/path.d.ts.map +1 -0
- package/internal/utils/path.js +79 -0
- package/internal/utils/path.js.map +1 -0
- package/internal/utils/path.mjs +74 -0
- package/internal/utils/path.mjs.map +1 -0
- package/internal/utils/sleep.d.mts +2 -0
- package/internal/utils/sleep.d.mts.map +1 -0
- package/internal/utils/sleep.d.ts +2 -0
- package/internal/utils/sleep.d.ts.map +1 -0
- package/internal/utils/sleep.js +7 -0
- package/internal/utils/sleep.js.map +1 -0
- package/internal/utils/sleep.mjs +3 -0
- package/internal/utils/sleep.mjs.map +1 -0
- package/internal/utils/uuid.d.mts +5 -0
- package/internal/utils/uuid.d.mts.map +1 -0
- package/internal/utils/uuid.d.ts +5 -0
- package/internal/utils/uuid.d.ts.map +1 -0
- package/internal/utils/uuid.js +19 -0
- package/internal/utils/uuid.js.map +1 -0
- package/internal/utils/uuid.mjs +15 -0
- package/internal/utils/uuid.mjs.map +1 -0
- package/internal/utils/values.d.mts +18 -0
- package/internal/utils/values.d.mts.map +1 -0
- package/internal/utils/values.d.ts +18 -0
- package/internal/utils/values.d.ts.map +1 -0
- package/internal/utils/values.js +112 -0
- package/internal/utils/values.js.map +1 -0
- package/internal/utils/values.mjs +94 -0
- package/internal/utils/values.mjs.map +1 -0
- package/internal/utils.d.mts +7 -0
- package/internal/utils.d.mts.map +1 -0
- package/internal/utils.d.ts +7 -0
- package/internal/utils.d.ts.map +1 -0
- package/internal/utils.js +11 -0
- package/internal/utils.js.map +1 -0
- package/internal/utils.mjs +8 -0
- package/internal/utils.mjs.map +1 -0
- package/package.json +113 -64
- package/pagination.d.mts +2 -0
- package/pagination.d.mts.map +1 -0
- package/pagination.d.ts +1 -36
- package/pagination.d.ts.map +1 -1
- package/pagination.js +3 -40
- package/pagination.js.map +1 -1
- package/pagination.mjs +1 -38
- package/pagination.mjs.map +1 -1
- package/resource.d.mts +2 -0
- package/resource.d.mts.map +1 -0
- package/resource.d.ts +1 -5
- package/resource.d.ts.map +1 -1
- package/resource.js +3 -8
- package/resource.js.map +1 -1
- package/resource.mjs +1 -6
- package/resource.mjs.map +1 -1
- package/resources/index.d.mts +5 -0
- package/resources/index.d.mts.map +1 -0
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js +2 -15
- package/resources/index.js.map +1 -1
- package/resources/shared.d.mts +2239 -0
- package/resources/shared.d.mts.map +1 -0
- package/resources/shared.d.ts +1404 -523
- package/resources/shared.d.ts.map +1 -1
- package/resources/v1/alerts.d.mts +203 -0
- package/resources/v1/alerts.d.mts.map +1 -0
- package/resources/v1/alerts.d.ts +78 -7
- package/resources/v1/alerts.d.ts.map +1 -1
- package/resources/v1/alerts.js +73 -3
- package/resources/v1/alerts.js.map +1 -1
- package/resources/v1/alerts.mjs +73 -3
- package/resources/v1/alerts.mjs.map +1 -1
- package/resources/v1/audit-logs.d.mts +108 -0
- package/resources/v1/audit-logs.d.mts.map +1 -0
- package/resources/v1/audit-logs.d.ts +45 -12
- package/resources/v1/audit-logs.d.ts.map +1 -1
- package/resources/v1/audit-logs.js +53 -12
- package/resources/v1/audit-logs.js.map +1 -1
- package/resources/v1/audit-logs.mjs +52 -10
- package/resources/v1/audit-logs.mjs.map +1 -1
- package/resources/v1/billable-metrics.d.mts +293 -0
- package/resources/v1/billable-metrics.d.mts.map +1 -0
- package/resources/v1/billable-metrics.d.ts +70 -15
- package/resources/v1/billable-metrics.d.ts.map +1 -1
- package/resources/v1/billable-metrics.js +70 -16
- package/resources/v1/billable-metrics.js.map +1 -1
- package/resources/v1/billable-metrics.mjs +69 -14
- package/resources/v1/billable-metrics.mjs.map +1 -1
- package/resources/v1/contracts/contracts.d.mts +2984 -0
- package/resources/v1/contracts/contracts.d.mts.map +1 -0
- package/resources/v1/contracts/contracts.d.ts +401 -1294
- package/resources/v1/contracts/contracts.d.ts.map +1 -1
- package/resources/v1/contracts/contracts.js +268 -50
- package/resources/v1/contracts/contracts.js.map +1 -1
- package/resources/v1/contracts/contracts.mjs +266 -26
- package/resources/v1/contracts/contracts.mjs.map +1 -1
- package/resources/v1/contracts/index.d.mts +5 -0
- package/resources/v1/contracts/index.d.mts.map +1 -0
- package/resources/v1/contracts/index.d.ts +3 -3
- package/resources/v1/contracts/index.d.ts.map +1 -1
- package/resources/v1/contracts/index.js +1 -3
- package/resources/v1/contracts/index.js.map +1 -1
- package/resources/v1/contracts/index.mjs +2 -2
- package/resources/v1/contracts/index.mjs.map +1 -1
- package/resources/v1/contracts/named-schedules.d.mts +82 -0
- package/resources/v1/contracts/named-schedules.d.mts.map +1 -0
- package/resources/v1/contracts/named-schedules.d.ts +5 -4
- package/resources/v1/contracts/named-schedules.d.ts.map +1 -1
- package/resources/v1/contracts/named-schedules.js +3 -2
- package/resources/v1/contracts/named-schedules.js.map +1 -1
- package/resources/v1/contracts/named-schedules.mjs +3 -2
- package/resources/v1/contracts/named-schedules.mjs.map +1 -1
- package/resources/v1/contracts/products.d.mts +502 -0
- package/resources/v1/contracts/products.d.mts.map +1 -0
- package/resources/v1/contracts/products.d.ts +44 -17
- package/resources/v1/contracts/products.d.ts.map +1 -1
- package/resources/v1/contracts/products.js +41 -17
- package/resources/v1/contracts/products.js.map +1 -1
- package/resources/v1/contracts/products.mjs +40 -15
- package/resources/v1/contracts/products.mjs.map +1 -1
- package/resources/v1/contracts/rate-cards/index.d.mts +5 -0
- package/resources/v1/contracts/rate-cards/index.d.mts.map +1 -0
- package/resources/v1/contracts/rate-cards/index.d.ts +2 -2
- package/resources/v1/contracts/rate-cards/index.d.ts.map +1 -1
- package/resources/v1/contracts/rate-cards/index.js +1 -3
- package/resources/v1/contracts/rate-cards/index.js.map +1 -1
- package/resources/v1/contracts/rate-cards/index.mjs +2 -2
- package/resources/v1/contracts/rate-cards/index.mjs.map +1 -1
- package/resources/v1/contracts/rate-cards/named-schedules.d.mts +94 -0
- package/resources/v1/contracts/rate-cards/named-schedules.d.mts.map +1 -0
- package/resources/v1/contracts/rate-cards/named-schedules.d.ts +5 -4
- package/resources/v1/contracts/rate-cards/named-schedules.d.ts.map +1 -1
- package/resources/v1/contracts/rate-cards/named-schedules.js +3 -2
- package/resources/v1/contracts/rate-cards/named-schedules.js.map +1 -1
- package/resources/v1/contracts/rate-cards/named-schedules.mjs +3 -2
- package/resources/v1/contracts/rate-cards/named-schedules.mjs.map +1 -1
- package/resources/v1/contracts/rate-cards/product-orders.d.mts +85 -0
- package/resources/v1/contracts/rate-cards/product-orders.d.mts.map +1 -0
- package/resources/v1/contracts/rate-cards/product-orders.d.ts +12 -6
- package/resources/v1/contracts/rate-cards/product-orders.d.ts.map +1 -1
- package/resources/v1/contracts/rate-cards/product-orders.js +8 -3
- package/resources/v1/contracts/rate-cards/product-orders.js.map +1 -1
- package/resources/v1/contracts/rate-cards/product-orders.mjs +8 -3
- package/resources/v1/contracts/rate-cards/product-orders.mjs.map +1 -1
- package/resources/v1/contracts/rate-cards/rate-cards.d.mts +452 -0
- package/resources/v1/contracts/rate-cards/rate-cards.d.mts.map +1 -0
- package/resources/v1/contracts/rate-cards/rate-cards.d.ts +134 -41
- package/resources/v1/contracts/rate-cards/rate-cards.d.ts.map +1 -1
- package/resources/v1/contracts/rate-cards/rate-cards.js +127 -47
- package/resources/v1/contracts/rate-cards/rate-cards.js.map +1 -1
- package/resources/v1/contracts/rate-cards/rate-cards.mjs +123 -20
- package/resources/v1/contracts/rate-cards/rate-cards.mjs.map +1 -1
- package/resources/v1/contracts/rate-cards/rates.d.mts +382 -0
- package/resources/v1/contracts/rate-cards/rates.d.mts.map +1 -0
- package/resources/v1/contracts/rate-cards/rates.d.ts +25 -82
- package/resources/v1/contracts/rate-cards/rates.d.ts.map +1 -1
- package/resources/v1/contracts/rate-cards/rates.js +13 -9
- package/resources/v1/contracts/rate-cards/rates.js.map +1 -1
- package/resources/v1/contracts/rate-cards/rates.mjs +12 -7
- package/resources/v1/contracts/rate-cards/rates.mjs.map +1 -1
- package/resources/v1/contracts/rate-cards.d.mts +2 -0
- package/resources/v1/contracts/rate-cards.d.mts.map +1 -0
- package/resources/v1/contracts/rate-cards.d.ts.map +1 -1
- package/resources/v1/contracts/rate-cards.js +2 -15
- package/resources/v1/contracts/rate-cards.js.map +1 -1
- package/resources/v1/contracts.d.mts +2 -0
- package/resources/v1/contracts.d.mts.map +1 -0
- package/resources/v1/contracts.d.ts.map +1 -1
- package/resources/v1/contracts.js +2 -15
- package/resources/v1/contracts.js.map +1 -1
- package/resources/v1/credit-grants.d.mts +505 -0
- package/resources/v1/credit-grants.d.mts.map +1 -0
- package/resources/v1/credit-grants.d.ts +73 -74
- package/resources/v1/credit-grants.d.ts.map +1 -1
- package/resources/v1/credit-grants.js +52 -18
- package/resources/v1/credit-grants.js.map +1 -1
- package/resources/v1/credit-grants.mjs +51 -16
- package/resources/v1/credit-grants.mjs.map +1 -1
- package/resources/v1/custom-fields.d.mts +151 -0
- package/resources/v1/custom-fields.d.mts.map +1 -0
- package/resources/v1/custom-fields.d.ts +69 -38
- package/resources/v1/custom-fields.d.ts.map +1 -1
- package/resources/v1/custom-fields.js +66 -22
- package/resources/v1/custom-fields.js.map +1 -1
- package/resources/v1/custom-fields.mjs +66 -22
- package/resources/v1/custom-fields.mjs.map +1 -1
- package/resources/v1/customers/alerts.d.mts +288 -0
- package/resources/v1/customers/alerts.d.mts.map +1 -0
- package/resources/v1/customers/alerts.d.ts +128 -23
- package/resources/v1/customers/alerts.d.ts.map +1 -1
- package/resources/v1/customers/alerts.js +112 -10
- package/resources/v1/customers/alerts.js.map +1 -1
- package/resources/v1/customers/alerts.mjs +112 -10
- package/resources/v1/customers/alerts.mjs.map +1 -1
- package/resources/v1/customers/billing-config.d.mts +125 -0
- package/resources/v1/customers/billing-config.d.mts.map +1 -0
- package/resources/v1/customers/billing-config.d.ts +8 -7
- package/resources/v1/customers/billing-config.d.ts.map +1 -1
- package/resources/v1/customers/billing-config.js +8 -6
- package/resources/v1/customers/billing-config.js.map +1 -1
- package/resources/v1/customers/billing-config.mjs +8 -6
- package/resources/v1/customers/billing-config.mjs.map +1 -1
- package/resources/v1/customers/commits.d.mts +456 -0
- package/resources/v1/customers/commits.d.mts.map +1 -0
- package/resources/v1/customers/commits.d.ts +139 -47
- package/resources/v1/customers/commits.d.ts.map +1 -1
- package/resources/v1/customers/commits.js +131 -12
- package/resources/v1/customers/commits.js.map +1 -1
- package/resources/v1/customers/commits.mjs +131 -12
- package/resources/v1/customers/commits.mjs.map +1 -1
- package/resources/v1/customers/credits.d.mts +310 -0
- package/resources/v1/customers/credits.d.mts.map +1 -0
- package/resources/v1/customers/credits.d.ts +124 -46
- package/resources/v1/customers/credits.d.ts.map +1 -1
- package/resources/v1/customers/credits.js +116 -11
- package/resources/v1/customers/credits.js.map +1 -1
- package/resources/v1/customers/credits.mjs +116 -11
- package/resources/v1/customers/credits.mjs.map +1 -1
- package/resources/v1/customers/customers.d.mts +818 -0
- package/resources/v1/customers/customers.d.mts.map +1 -0
- package/resources/v1/customers/customers.d.ts +304 -41
- package/resources/v1/customers/customers.d.ts.map +1 -1
- package/resources/v1/customers/customers.js +214 -73
- package/resources/v1/customers/customers.js.map +1 -1
- package/resources/v1/customers/customers.mjs +207 -41
- package/resources/v1/customers/customers.mjs.map +1 -1
- package/resources/v1/customers/index.d.mts +9 -0
- package/resources/v1/customers/index.d.mts.map +1 -0
- package/resources/v1/customers/index.d.ts +6 -6
- package/resources/v1/customers/index.d.ts.map +1 -1
- package/resources/v1/customers/index.js +1 -8
- package/resources/v1/customers/index.js.map +1 -1
- package/resources/v1/customers/index.mjs +3 -3
- package/resources/v1/customers/index.mjs.map +1 -1
- package/resources/v1/customers/invoices.d.mts +710 -0
- package/resources/v1/customers/invoices.d.mts.map +1 -0
- package/resources/v1/customers/invoices.d.ts +193 -24
- package/resources/v1/customers/invoices.d.ts.map +1 -1
- package/resources/v1/customers/invoices.js +131 -22
- package/resources/v1/customers/invoices.js.map +1 -1
- package/resources/v1/customers/invoices.mjs +130 -19
- package/resources/v1/customers/invoices.mjs.map +1 -1
- package/resources/v1/customers/named-schedules.d.mts +82 -0
- package/resources/v1/customers/named-schedules.d.mts.map +1 -0
- package/resources/v1/customers/named-schedules.d.ts +5 -4
- package/resources/v1/customers/named-schedules.d.ts.map +1 -1
- package/resources/v1/customers/named-schedules.js +3 -2
- package/resources/v1/customers/named-schedules.js.map +1 -1
- package/resources/v1/customers/named-schedules.mjs +3 -2
- package/resources/v1/customers/named-schedules.mjs.map +1 -1
- package/resources/v1/customers/plans.d.mts +281 -0
- package/resources/v1/customers/plans.d.mts.map +1 -0
- package/resources/v1/customers/plans.d.ts +14 -12
- package/resources/v1/customers/plans.d.ts.map +1 -1
- package/resources/v1/customers/plans.js +8 -15
- package/resources/v1/customers/plans.js.map +1 -1
- package/resources/v1/customers/plans.mjs +7 -12
- package/resources/v1/customers/plans.mjs.map +1 -1
- package/resources/v1/customers.d.mts +2 -0
- package/resources/v1/customers.d.mts.map +1 -0
- package/resources/v1/customers.d.ts.map +1 -1
- package/resources/v1/customers.js +2 -15
- package/resources/v1/customers.js.map +1 -1
- package/resources/v1/dashboards.d.mts +133 -0
- package/resources/v1/dashboards.d.mts.map +1 -0
- package/resources/v1/dashboards.d.ts +33 -6
- package/resources/v1/dashboards.d.ts.map +1 -1
- package/resources/v1/dashboards.js +30 -4
- package/resources/v1/dashboards.js.map +1 -1
- package/resources/v1/dashboards.mjs +30 -4
- package/resources/v1/dashboards.mjs.map +1 -1
- package/resources/v1/index.d.mts +15 -0
- package/resources/v1/index.d.mts.map +1 -0
- package/resources/v1/index.d.ts +9 -9
- package/resources/v1/index.d.ts.map +1 -1
- package/resources/v1/index.js +1 -12
- package/resources/v1/index.js.map +1 -1
- package/resources/v1/index.mjs +7 -7
- package/resources/v1/index.mjs.map +1 -1
- package/resources/v1/invoices.d.mts +83 -0
- package/resources/v1/invoices.d.mts.map +1 -0
- package/resources/v1/invoices.d.ts +28 -6
- package/resources/v1/invoices.d.ts.map +1 -1
- package/resources/v1/invoices.js +24 -3
- package/resources/v1/invoices.js.map +1 -1
- package/resources/v1/invoices.mjs +24 -3
- package/resources/v1/invoices.mjs.map +1 -1
- package/resources/v1/plans.d.mts +240 -0
- package/resources/v1/plans.d.mts.map +1 -0
- package/resources/v1/plans.d.ts +24 -15
- package/resources/v1/plans.d.ts.map +1 -1
- package/resources/v1/plans.js +19 -26
- package/resources/v1/plans.js.map +1 -1
- package/resources/v1/plans.mjs +18 -22
- package/resources/v1/plans.mjs.map +1 -1
- package/resources/v1/pricing-units.d.mts +34 -0
- package/resources/v1/pricing-units.d.mts.map +1 -0
- package/resources/v1/pricing-units.d.ts +12 -9
- package/resources/v1/pricing-units.d.ts.map +1 -1
- package/resources/v1/pricing-units.js +20 -12
- package/resources/v1/pricing-units.js.map +1 -1
- package/resources/v1/pricing-units.mjs +19 -10
- package/resources/v1/pricing-units.mjs.map +1 -1
- package/resources/v1/services.d.mts +33 -0
- package/resources/v1/services.d.mts.map +1 -0
- package/resources/v1/services.d.ts +10 -7
- package/resources/v1/services.d.ts.map +1 -1
- package/resources/v1/services.js +7 -5
- package/resources/v1/services.js.map +1 -1
- package/resources/v1/services.mjs +7 -5
- package/resources/v1/services.mjs.map +1 -1
- package/resources/v1/usage.d.mts +488 -0
- package/resources/v1/usage.d.mts.map +1 -0
- package/resources/v1/usage.d.ts +220 -57
- package/resources/v1/usage.d.ts.map +1 -1
- package/resources/v1/usage.js +212 -26
- package/resources/v1/usage.js.map +1 -1
- package/resources/v1/usage.mjs +211 -24
- package/resources/v1/usage.mjs.map +1 -1
- package/resources/v1/v1.d.mts +58 -0
- package/resources/v1/v1.d.mts.map +1 -0
- package/resources/v1/v1.d.ts +15 -15
- package/resources/v1/v1.d.ts.map +1 -1
- package/resources/v1/v1.js +15 -48
- package/resources/v1/v1.js.map +1 -1
- package/resources/v1/v1.mjs +8 -19
- package/resources/v1/v1.mjs.map +1 -1
- package/resources/v1.d.mts +2 -0
- package/resources/v1.d.mts.map +1 -0
- package/resources/v1.d.ts.map +1 -1
- package/resources/v1.js +2 -15
- package/resources/v1.js.map +1 -1
- package/resources/v2/contracts.d.mts +2794 -0
- package/resources/v2/contracts.d.mts.map +1 -0
- package/resources/v2/contracts.d.ts +333 -3870
- package/resources/v2/contracts.d.ts.map +1 -1
- package/resources/v2/contracts.js +102 -12
- package/resources/v2/contracts.js.map +1 -1
- package/resources/v2/contracts.mjs +102 -12
- package/resources/v2/contracts.mjs.map +1 -1
- package/resources/v2/index.d.mts +3 -0
- package/resources/v2/index.d.mts.map +1 -0
- package/resources/v2/index.d.ts.map +1 -1
- package/resources/v2/v2.d.mts +10 -0
- package/resources/v2/v2.d.mts.map +1 -0
- package/resources/v2/v2.d.ts +1 -1
- package/resources/v2/v2.d.ts.map +1 -1
- package/resources/v2/v2.js +3 -25
- package/resources/v2/v2.js.map +1 -1
- package/resources/v2/v2.mjs +1 -1
- package/resources/v2.d.mts +2 -0
- package/resources/v2.d.mts.map +1 -0
- package/resources/v2.d.ts.map +1 -1
- package/resources/v2.js +2 -15
- package/resources/v2.js.map +1 -1
- package/resources/webhooks.d.mts +22 -0
- package/resources/webhooks.d.mts.map +1 -0
- package/resources/webhooks.d.ts +1 -1
- package/resources/webhooks.d.ts.map +1 -1
- package/resources/webhooks.js +3 -3
- package/resources/webhooks.js.map +1 -1
- package/resources/webhooks.mjs +1 -1
- package/resources/webhooks.mjs.map +1 -1
- package/resources.d.mts +2 -0
- package/resources.d.mts.map +1 -0
- package/resources.d.ts.map +1 -1
- package/resources.js +2 -15
- package/resources.js.map +1 -1
- package/src/api-promise.ts +2 -0
- package/src/client.ts +809 -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 +319 -0
- package/src/core/resource.ts +11 -0
- package/src/core/uploads.ts +2 -0
- package/src/error.ts +2 -130
- package/src/index.ts +6 -221
- 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 +144 -0
- package/src/internal/parse.ts +50 -0
- package/src/internal/qs/formats.ts +3 -2
- package/src/internal/qs/index.ts +3 -3
- package/src/internal/qs/stringify.ts +18 -21
- package/src/internal/qs/utils.ts +16 -16
- package/src/internal/request-options.ts +91 -0
- package/src/internal/shim-types.ts +26 -0
- package/src/internal/shims.ts +107 -0
- package/src/internal/to-file.ts +154 -0
- package/src/internal/types.ts +95 -0
- package/src/internal/uploads.ts +187 -0
- package/src/internal/utils/base64.ts +40 -0
- package/src/internal/utils/bytes.ts +32 -0
- package/src/internal/utils/env.ts +18 -0
- package/src/internal/utils/log.ts +126 -0
- package/src/internal/utils/path.ts +88 -0
- package/src/internal/utils/sleep.ts +3 -0
- package/src/internal/utils/uuid.ts +17 -0
- package/src/internal/utils/values.ts +105 -0
- package/src/internal/utils.ts +8 -0
- package/src/pagination.ts +2 -82
- package/src/resource.ts +2 -11
- package/src/resources/index.ts +4 -4
- package/src/resources/shared.ts +1794 -534
- package/src/resources/v1/alerts.ts +79 -8
- package/src/resources/v1/audit-logs.ts +48 -26
- package/src/resources/v1/billable-metrics.ts +79 -34
- package/src/resources/v1/contracts/contracts.ts +465 -1633
- package/src/resources/v1/contracts/index.ts +7 -6
- package/src/resources/v1/contracts/named-schedules.ts +8 -6
- package/src/resources/v1/contracts/products.ts +50 -38
- package/src/resources/v1/contracts/rate-cards/index.ts +6 -6
- package/src/resources/v1/contracts/rate-cards/named-schedules.ts +8 -6
- package/src/resources/v1/contracts/rate-cards/product-orders.ts +13 -10
- package/src/resources/v1/contracts/rate-cards/rate-cards.ts +145 -72
- package/src/resources/v1/contracts/rate-cards/rates.ts +28 -98
- package/src/resources/v1/contracts/rate-cards.ts +1 -1
- package/src/resources/v1/contracts.ts +1 -1
- package/src/resources/v1/credit-grants.ts +100 -112
- package/src/resources/v1/custom-fields.ts +106 -74
- package/src/resources/v1/customers/alerts.ts +147 -28
- package/src/resources/v1/customers/billing-config.ts +27 -13
- package/src/resources/v1/customers/commits.ts +146 -54
- package/src/resources/v1/customers/credits.ts +131 -53
- package/src/resources/v1/customers/customers.ts +390 -101
- package/src/resources/v1/customers/index.ts +19 -18
- package/src/resources/v1/customers/invoices.ts +202 -42
- package/src/resources/v1/customers/named-schedules.ts +8 -6
- package/src/resources/v1/customers/plans.ts +24 -22
- package/src/resources/v1/customers.ts +1 -1
- package/src/resources/v1/dashboards.ts +34 -7
- package/src/resources/v1/index.ts +32 -25
- package/src/resources/v1/invoices.ts +28 -9
- package/src/resources/v1/plans.ts +42 -43
- package/src/resources/v1/pricing-units.ts +15 -23
- package/src/resources/v1/services.ts +10 -7
- package/src/resources/v1/usage.ts +244 -72
- package/src/resources/v1/v1.ts +52 -49
- package/src/resources/v1.ts +1 -1
- package/src/resources/v2/contracts.ts +420 -5022
- package/src/resources/v2/index.ts +2 -2
- package/src/resources/v2/v2.ts +3 -3
- package/src/resources/v2.ts +1 -1
- package/src/resources/webhooks.ts +2 -2
- package/src/resources.ts +1 -1
- package/src/tsconfig.json +2 -2
- package/src/uploads.ts +2 -255
- package/src/version.ts +1 -1
- package/uploads.d.mts +2 -0
- package/uploads.d.mts.map +1 -0
- package/uploads.d.ts +1 -74
- package/uploads.d.ts.map +1 -1
- package/uploads.js +3 -168
- package/uploads.js.map +1 -1
- package/uploads.mjs +1 -157
- package/uploads.mjs.map +1 -1
- package/version.d.mts +2 -0
- package/version.d.mts.map +1 -0
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
- package/_shims/MultipartBody.d.ts +0 -9
- package/_shims/MultipartBody.d.ts.map +0 -1
- package/_shims/MultipartBody.js +0 -16
- package/_shims/MultipartBody.js.map +0 -1
- package/_shims/MultipartBody.mjs +0 -12
- package/_shims/MultipartBody.mjs.map +0 -1
- package/_shims/README.md +0 -46
- package/_shims/auto/runtime-bun.d.ts +0 -5
- package/_shims/auto/runtime-bun.d.ts.map +0 -1
- package/_shims/auto/runtime-bun.js +0 -21
- package/_shims/auto/runtime-bun.js.map +0 -1
- package/_shims/auto/runtime-bun.mjs +0 -2
- package/_shims/auto/runtime-bun.mjs.map +0 -1
- package/_shims/auto/runtime-node.d.ts +0 -5
- package/_shims/auto/runtime-node.d.ts.map +0 -1
- package/_shims/auto/runtime-node.js +0 -21
- package/_shims/auto/runtime-node.js.map +0 -1
- package/_shims/auto/runtime-node.mjs +0 -2
- package/_shims/auto/runtime-node.mjs.map +0 -1
- package/_shims/auto/runtime.d.ts +0 -5
- package/_shims/auto/runtime.d.ts.map +0 -1
- package/_shims/auto/runtime.js +0 -21
- package/_shims/auto/runtime.js.map +0 -1
- package/_shims/auto/runtime.mjs +0 -2
- package/_shims/auto/runtime.mjs.map +0 -1
- package/_shims/auto/types-node.d.ts +0 -5
- package/_shims/auto/types-node.d.ts.map +0 -1
- package/_shims/auto/types-node.js +0 -21
- package/_shims/auto/types-node.js.map +0 -1
- package/_shims/auto/types-node.mjs +0 -2
- package/_shims/auto/types-node.mjs.map +0 -1
- package/_shims/auto/types.d.ts +0 -101
- package/_shims/auto/types.js +0 -3
- package/_shims/auto/types.mjs +0 -3
- package/_shims/bun-runtime.d.ts +0 -6
- package/_shims/bun-runtime.d.ts.map +0 -1
- package/_shims/bun-runtime.js +0 -14
- package/_shims/bun-runtime.js.map +0 -1
- package/_shims/bun-runtime.mjs +0 -10
- package/_shims/bun-runtime.mjs.map +0 -1
- package/_shims/index.d.ts +0 -83
- package/_shims/index.js +0 -17
- package/_shims/index.mjs +0 -11
- package/_shims/manual-types.d.ts +0 -12
- package/_shims/manual-types.js +0 -3
- package/_shims/manual-types.mjs +0 -3
- package/_shims/node-runtime.d.ts +0 -3
- package/_shims/node-runtime.d.ts.map +0 -1
- package/_shims/node-runtime.js +0 -89
- package/_shims/node-runtime.js.map +0 -1
- package/_shims/node-runtime.mjs +0 -56
- package/_shims/node-runtime.mjs.map +0 -1
- package/_shims/node-types.d.ts +0 -42
- package/_shims/node-types.js +0 -3
- package/_shims/node-types.mjs +0 -3
- package/_shims/registry.d.ts +0 -37
- package/_shims/registry.d.ts.map +0 -1
- package/_shims/registry.js +0 -41
- package/_shims/registry.js.map +0 -1
- package/_shims/registry.mjs +0 -37
- package/_shims/registry.mjs.map +0 -1
- package/_shims/web-runtime.d.ts +0 -5
- package/_shims/web-runtime.d.ts.map +0 -1
- package/_shims/web-runtime.js +0 -78
- package/_shims/web-runtime.js.map +0 -1
- package/_shims/web-runtime.mjs +0 -71
- package/_shims/web-runtime.mjs.map +0 -1
- package/_shims/web-types.d.ts +0 -83
- package/_shims/web-types.js +0 -3
- package/_shims/web-types.mjs +0 -3
- package/core.d.ts +0 -255
- package/core.d.ts.map +0 -1
- package/core.js +0 -924
- package/core.js.map +0 -1
- package/core.mjs +0 -892
- package/core.mjs.map +0 -1
- package/shims/node.d.ts +0 -30
- package/shims/node.d.ts.map +0 -1
- package/shims/node.js +0 -31
- package/shims/node.js.map +0 -1
- package/shims/node.mjs +0 -5
- package/shims/node.mjs.map +0 -1
- package/shims/web.d.ts +0 -26
- package/shims/web.d.ts.map +0 -1
- package/shims/web.js +0 -31
- package/shims/web.js.map +0 -1
- package/shims/web.mjs +0 -5
- package/shims/web.mjs.map +0 -1
- package/src/_shims/MultipartBody.ts +0 -9
- package/src/_shims/README.md +0 -46
- package/src/_shims/auto/runtime-bun.ts +0 -4
- package/src/_shims/auto/runtime-node.ts +0 -4
- package/src/_shims/auto/runtime.ts +0 -4
- package/src/_shims/auto/types-node.ts +0 -4
- package/src/_shims/auto/types.d.ts +0 -101
- package/src/_shims/auto/types.js +0 -3
- package/src/_shims/auto/types.mjs +0 -3
- package/src/_shims/bun-runtime.ts +0 -14
- package/src/_shims/index.d.ts +0 -83
- package/src/_shims/index.js +0 -17
- package/src/_shims/index.mjs +0 -11
- package/src/_shims/manual-types.d.ts +0 -12
- package/src/_shims/manual-types.js +0 -3
- package/src/_shims/manual-types.mjs +0 -3
- package/src/_shims/node-runtime.ts +0 -81
- package/src/_shims/node-types.d.ts +0 -42
- package/src/_shims/node-types.js +0 -3
- package/src/_shims/node-types.mjs +0 -3
- package/src/_shims/registry.ts +0 -67
- package/src/_shims/web-runtime.ts +0 -103
- package/src/_shims/web-types.d.ts +0 -83
- package/src/_shims/web-types.js +0 -3
- package/src/_shims/web-types.mjs +0 -3
- package/src/core.ts +0 -1236
- package/src/shims/node.ts +0 -50
- package/src/shims/web.ts +0 -50
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import { APIResource } from "../../../resource.js";
|
|
2
|
-
import * as Core from "../../../core.js";
|
|
1
|
+
import { APIResource } from "../../../core/resource.js";
|
|
3
2
|
import * as Shared from "../../shared.js";
|
|
4
3
|
import * as NamedSchedulesAPI from "./named-schedules.js";
|
|
5
4
|
import { NamedScheduleRetrieveParams, NamedScheduleRetrieveResponse, NamedScheduleUpdateParams, NamedSchedules } from "./named-schedules.js";
|
|
@@ -8,12 +7,137 @@ import { ProductArchiveParams, ProductArchiveResponse, ProductCreateParams, Prod
|
|
|
8
7
|
import * as InvoicesAPI from "../customers/invoices.js";
|
|
9
8
|
import * as RateCardsAPI from "./rate-cards/rate-cards.js";
|
|
10
9
|
import { RateCardArchiveParams, RateCardArchiveResponse, RateCardCreateParams, RateCardCreateResponse, RateCardListParams, RateCardListResponse, RateCardListResponsesCursorPage, RateCardRetrieveParams, RateCardRetrieveRateScheduleParams, RateCardRetrieveRateScheduleResponse, RateCardRetrieveResponse, RateCardUpdateParams, RateCardUpdateResponse, RateCards } from "./rate-cards/rate-cards.js";
|
|
10
|
+
import { APIPromise } from "../../../core/api-promise.js";
|
|
11
|
+
import { BodyCursorPage, type BodyCursorPageParams, PagePromise } from "../../../core/pagination.js";
|
|
12
|
+
import { RequestOptions } from "../../../internal/request-options.js";
|
|
11
13
|
export declare class Contracts extends APIResource {
|
|
12
14
|
products: ProductsAPI.Products;
|
|
13
15
|
rateCards: RateCardsAPI.RateCards;
|
|
14
16
|
namedSchedules: NamedSchedulesAPI.NamedSchedules;
|
|
15
17
|
/**
|
|
16
|
-
*
|
|
18
|
+
* Contracts define a customer's products, pricing, discounts, access duration, and
|
|
19
|
+
* billing configuration. Contracts serve as the central billing agreement for both
|
|
20
|
+
* PLG and Enterprise customers, you can automatically customers access to your
|
|
21
|
+
* products and services directly from your product or CRM.
|
|
22
|
+
*
|
|
23
|
+
* ### Use this endpoint to:
|
|
24
|
+
*
|
|
25
|
+
* - PLG onboarding: Automatically provision new self-serve customers with
|
|
26
|
+
* contracts when they sign up.
|
|
27
|
+
* - Enterprise sales: Push negotiated contracts from Salesforce with custom
|
|
28
|
+
* pricing and commitments
|
|
29
|
+
* - Promotional pricing: Implement time-limited discounts and free trials through
|
|
30
|
+
* overrides
|
|
31
|
+
*
|
|
32
|
+
* ### Key components:
|
|
33
|
+
*
|
|
34
|
+
* #### Contract Term and Billing Schedule
|
|
35
|
+
*
|
|
36
|
+
* - Set contract duration using `starting_at` and `ending_before` fields. PLG
|
|
37
|
+
* contracts typically use perpetual agreements (no end date), while Enterprise
|
|
38
|
+
* contracts have fixed end dates which can be edited over time in the case of
|
|
39
|
+
* co-term upsells.
|
|
40
|
+
*
|
|
41
|
+
* #### Rate Card
|
|
42
|
+
*
|
|
43
|
+
* If you are offering usage based pricing, you can set a rate card for the
|
|
44
|
+
* contract to reference through `rate_card_id` or `rate_card_alias`. The rate card
|
|
45
|
+
* is a store of all of your usage based products and their centralized pricing.
|
|
46
|
+
* Any new products or price changes on the rate card can be set to automatically
|
|
47
|
+
* propagate to all associated contracts - this ensures consistent pricing and
|
|
48
|
+
* product launches flow to contracts without manual updates and migrations. The
|
|
49
|
+
* `usage_statement_schedule` determines the cadence on which Metronome will
|
|
50
|
+
* finalize a usage invoice for the customer. This defaults to monthly on the 1st,
|
|
51
|
+
* with options for custom dates, quarterly, or annual cadences. Note: Most usage
|
|
52
|
+
* based billing companies align usage statements to be evaluated aligned to the
|
|
53
|
+
* first of the month. Read more about
|
|
54
|
+
* [Rate Cards](https://docs.metronome.com/pricing-packaging/create-manage-rate-cards/).
|
|
55
|
+
*
|
|
56
|
+
* #### Overrides and discounts
|
|
57
|
+
*
|
|
58
|
+
* Customize pricing on the contract through time-bounded overrides that can target
|
|
59
|
+
* specific products, product families, or complex usage scenarios. Overrides
|
|
60
|
+
* enable two key capabilities:
|
|
61
|
+
*
|
|
62
|
+
* - Discounts: Apply percentage discounts, fixed rate reductions, or
|
|
63
|
+
* quantity-based pricing tiers
|
|
64
|
+
* - Entitlements: Provide special pricing or access to specific products for
|
|
65
|
+
* negotiated deals
|
|
66
|
+
*
|
|
67
|
+
* Read more about
|
|
68
|
+
* [Contract Overrides](https://docs.metronome.com/manage-product-access/add-contract-override/).
|
|
69
|
+
*
|
|
70
|
+
* #### Commits and Credits
|
|
71
|
+
*
|
|
72
|
+
* Using commits, configure prepaid or postpaid spending commitments where
|
|
73
|
+
* customers promise to spend a certain amount over the contract period paid in
|
|
74
|
+
* advance or in arrears. Use credits to provide free spending allowances. Under
|
|
75
|
+
* the hood these are the same mechanisms, however, credits are typically offered
|
|
76
|
+
* for free (SLA or promotional) or as a part of an allotment associated with a
|
|
77
|
+
* Subscription.
|
|
78
|
+
*
|
|
79
|
+
* In Metronome, you can set commits and credits to only be applicable for a subset
|
|
80
|
+
* of usage. Use `applicable_product_ids` or `applicable_product_tags` to create
|
|
81
|
+
* product or product-family specific commits or credits, or you can build complex
|
|
82
|
+
* boolean logic specifiers to target usage based on pricing and presentation group
|
|
83
|
+
* values using `override_specifiers`.
|
|
84
|
+
*
|
|
85
|
+
* These objects can also also be configured to have a recurrence schedule to
|
|
86
|
+
* easily model customer packaging which includes recurring monthly or quarterly
|
|
87
|
+
* allotments.
|
|
88
|
+
*
|
|
89
|
+
* Commits support rollover settings (`rollover_fraction`) to transfer unused
|
|
90
|
+
* balances between contract periods, either entirely or as a percentage.
|
|
91
|
+
*
|
|
92
|
+
* Read more about
|
|
93
|
+
* [Credits and Commits](https://docs.metronome.com/pricing-packaging/apply-credits-commits/).
|
|
94
|
+
*
|
|
95
|
+
* #### Subscriptions
|
|
96
|
+
*
|
|
97
|
+
* You can add a fixed recurring charge to a contract, like monthly licenses or
|
|
98
|
+
* seat-based fees, using the subscription charge. Subscription charges are defined
|
|
99
|
+
* on your rate card and you can select which subscription is applicable to add to
|
|
100
|
+
* each contract. When you add a subscription to a contract you need to:
|
|
101
|
+
*
|
|
102
|
+
* - Define whether the subscription is paid for in-advance or in-arrears
|
|
103
|
+
* (`collection_schedule`)
|
|
104
|
+
* - Define the proration behavior (`proration`)
|
|
105
|
+
* - Specify an initial quantity (`initial_quantity`)
|
|
106
|
+
* - Define which subscription rate on the rate card should be used
|
|
107
|
+
* (`subscription_rate`)
|
|
108
|
+
*
|
|
109
|
+
* Read more about
|
|
110
|
+
* [Subscriptions](https://docs.metronome.com/manage-product-access/create-subscription/).
|
|
111
|
+
*
|
|
112
|
+
* #### Scheduled Charges
|
|
113
|
+
*
|
|
114
|
+
* Set up one-time, recurring, or entirely custom charges that occur on specific
|
|
115
|
+
* dates, separate from usage-based billing or commitments. These can be used to
|
|
116
|
+
* model non-recurring platform charges or professional services.
|
|
117
|
+
*
|
|
118
|
+
* #### Threshold Billing
|
|
119
|
+
*
|
|
120
|
+
* Metronome allows you to configure automatic billing triggers when customers
|
|
121
|
+
* reach spending thresholds to prevent fraud and manage risk. You can use
|
|
122
|
+
* `spend_threshold_configuration` to trigger an invoice to cover current charges
|
|
123
|
+
* whenever the threshold is reached or you can ensure the customer maintains a
|
|
124
|
+
* minimum prepaid balance using the `prepaid_balance_configuration`.
|
|
125
|
+
*
|
|
126
|
+
* Read more about
|
|
127
|
+
* [Spend Threshold](https://docs.metronome.com/manage-product-access/spend-thresholds/)
|
|
128
|
+
* and
|
|
129
|
+
* [Prepaid Balance Thresholds](https://docs.metronome.com/manage-product-access/prepaid-balance-thresholds/).
|
|
130
|
+
*
|
|
131
|
+
* ### Usage guidelines:
|
|
132
|
+
*
|
|
133
|
+
* - You can always
|
|
134
|
+
* [Edit Contracts](https://docs.metronome.com/manage-product-access/edit-contract/)
|
|
135
|
+
* after it has been created, using the `editContract` endpoint. Metronome keeps
|
|
136
|
+
* track of all edits, both in the audit log and over the `getEditHistory`
|
|
137
|
+
* endpoint.
|
|
138
|
+
* - Customers in Metronome can have multiple concurrent contracts at one time. Use
|
|
139
|
+
* `usage_filters` to route the correct usage to each contract.
|
|
140
|
+
* [Read more about usage filters](https://docs.metronome.com/manage-product-access/provision-customer/#create-a-usage-filter).
|
|
17
141
|
*
|
|
18
142
|
* @example
|
|
19
143
|
* ```ts
|
|
@@ -28,7 +152,7 @@ export declare class Contracts extends APIResource {
|
|
|
28
152
|
* });
|
|
29
153
|
* ```
|
|
30
154
|
*/
|
|
31
|
-
create(body: ContractCreateParams, options?:
|
|
155
|
+
create(body: ContractCreateParams, options?: RequestOptions): APIPromise<ContractCreateResponse>;
|
|
32
156
|
/**
|
|
33
157
|
* This is the v1 endpoint to get a contract. New clients should implement using
|
|
34
158
|
* the v2 endpoint.
|
|
@@ -41,10 +165,15 @@ export declare class Contracts extends APIResource {
|
|
|
41
165
|
* });
|
|
42
166
|
* ```
|
|
43
167
|
*/
|
|
44
|
-
retrieve(body: ContractRetrieveParams, options?:
|
|
168
|
+
retrieve(body: ContractRetrieveParams, options?: RequestOptions): APIPromise<ContractRetrieveResponse>;
|
|
45
169
|
/**
|
|
46
|
-
*
|
|
47
|
-
*
|
|
170
|
+
* Retrieves all contracts for a specific customer, including pricing, terms,
|
|
171
|
+
* credits, and commitments. Use this to view a customer's contract history and
|
|
172
|
+
* current agreements for billing management. Returns contract details with
|
|
173
|
+
* optional ledgers and balance information.
|
|
174
|
+
*
|
|
175
|
+
* ⚠️ Note: This is the legacy v1 endpoint - new integrations should use the v2
|
|
176
|
+
* endpoint for enhanced features.
|
|
48
177
|
*
|
|
49
178
|
* @example
|
|
50
179
|
* ```ts
|
|
@@ -53,9 +182,26 @@ export declare class Contracts extends APIResource {
|
|
|
53
182
|
* });
|
|
54
183
|
* ```
|
|
55
184
|
*/
|
|
56
|
-
list(body: ContractListParams, options?:
|
|
185
|
+
list(body: ContractListParams, options?: RequestOptions): APIPromise<ContractListResponse>;
|
|
57
186
|
/**
|
|
58
|
-
*
|
|
187
|
+
* Manually adjust the available balance on a commit or credit. This entry is
|
|
188
|
+
* appended to the commit ledger as a new event. Optionally include a description
|
|
189
|
+
* that provides the reasoning for the entry.
|
|
190
|
+
*
|
|
191
|
+
* ### Use this endpoint to:
|
|
192
|
+
*
|
|
193
|
+
* - Address incorrect usage burn-down caused by malformed usage or invalid config
|
|
194
|
+
* - Decrease available balance to account for outages where usage may have not
|
|
195
|
+
* been tracked or sent to Metronome
|
|
196
|
+
* - Issue credits to customers in the form of increased balance on existing commit
|
|
197
|
+
* or credit
|
|
198
|
+
*
|
|
199
|
+
* ### Usage guidelines:
|
|
200
|
+
*
|
|
201
|
+
* Manual ledger entries can be extremely useful for resolving discrepancies in
|
|
202
|
+
* Metronome. However, most corrections to inaccurate billings can be modified
|
|
203
|
+
* upstream of the commit, whether that is via contract editing, rate editing, or
|
|
204
|
+
* other actions that cause an invoice to be recalculated.
|
|
59
205
|
*
|
|
60
206
|
* @example
|
|
61
207
|
* ```ts
|
|
@@ -69,10 +215,10 @@ export declare class Contracts extends APIResource {
|
|
|
69
215
|
* });
|
|
70
216
|
* ```
|
|
71
217
|
*/
|
|
72
|
-
addManualBalanceEntry(body: ContractAddManualBalanceEntryParams, options?:
|
|
218
|
+
addManualBalanceEntry(body: ContractAddManualBalanceEntryParams, options?: RequestOptions): APIPromise<void>;
|
|
73
219
|
/**
|
|
74
220
|
* Amendments will be replaced by Contract editing. New clients should implement
|
|
75
|
-
* using the editContract endpoint. Read more about the migration to contract
|
|
221
|
+
* using the `editContract` endpoint. Read more about the migration to contract
|
|
76
222
|
* editing [here](https://docs.metronome.com/migrate-amendments-to-edits/) and
|
|
77
223
|
* reach out to your Metronome representative for more details. Once contract
|
|
78
224
|
* editing is enabled, access to this endpoint will be removed.
|
|
@@ -86,9 +232,28 @@ export declare class Contracts extends APIResource {
|
|
|
86
232
|
* });
|
|
87
233
|
* ```
|
|
88
234
|
*/
|
|
89
|
-
amend(body: ContractAmendParams, options?:
|
|
235
|
+
amend(body: ContractAmendParams, options?: RequestOptions): APIPromise<ContractAmendResponse>;
|
|
90
236
|
/**
|
|
91
|
-
*
|
|
237
|
+
* Permanently end and archive a contract along with all its terms. Any draft
|
|
238
|
+
* invoices will be canceled, and all upcoming scheduled invoices will be
|
|
239
|
+
* voided–also all finalized invoices can optionally be voided. Use this in the
|
|
240
|
+
* event a contract was incorrectly created and needed to be removed from a
|
|
241
|
+
* customer.
|
|
242
|
+
*
|
|
243
|
+
* #### Impact on commits and credits:
|
|
244
|
+
*
|
|
245
|
+
* When archiving a contract, all associated commits and credits are also archived.
|
|
246
|
+
* For prepaid commits with active segments, Metronome automatically generates
|
|
247
|
+
* expiration ledger entries to close out any remaining balances, ensuring accurate
|
|
248
|
+
* accounting of unused prepaid amounts. These ledger entries will appear in the
|
|
249
|
+
* commit's transaction history with type `PREPAID_COMMIT_EXPIRATION`.
|
|
250
|
+
*
|
|
251
|
+
* #### Archived contract visibility:
|
|
252
|
+
*
|
|
253
|
+
* Archived contracts remain accessible for historical reporting and audit
|
|
254
|
+
* purposes. They can be retrieved using the `ListContracts` endpoint by setting
|
|
255
|
+
* the `include_archived` parameter to `true` or in the Metronome UI when the "Show
|
|
256
|
+
* archived" option is enabled.
|
|
92
257
|
*
|
|
93
258
|
* @example
|
|
94
259
|
* ```ts
|
|
@@ -99,9 +264,13 @@ export declare class Contracts extends APIResource {
|
|
|
99
264
|
* });
|
|
100
265
|
* ```
|
|
101
266
|
*/
|
|
102
|
-
archive(body: ContractArchiveParams, options?:
|
|
267
|
+
archive(body: ContractArchiveParams, options?: RequestOptions): APIPromise<ContractArchiveResponse>;
|
|
103
268
|
/**
|
|
104
|
-
*
|
|
269
|
+
* Create historical usage invoices for past billing periods on specific contracts.
|
|
270
|
+
* Use this endpoint to generate retroactive invoices with custom usage line items,
|
|
271
|
+
* quantities, and date ranges. Supports preview mode to validate invoice data
|
|
272
|
+
* before creation. Ideal for billing migrations or correcting past billing
|
|
273
|
+
* periods.
|
|
105
274
|
*
|
|
106
275
|
* @example
|
|
107
276
|
* ```ts
|
|
@@ -132,22 +301,66 @@ export declare class Contracts extends APIResource {
|
|
|
132
301
|
* });
|
|
133
302
|
* ```
|
|
134
303
|
*/
|
|
135
|
-
createHistoricalInvoices(body: ContractCreateHistoricalInvoicesParams, options?:
|
|
304
|
+
createHistoricalInvoices(body: ContractCreateHistoricalInvoicesParams, options?: RequestOptions): APIPromise<ContractCreateHistoricalInvoicesResponse>;
|
|
136
305
|
/**
|
|
137
|
-
*
|
|
306
|
+
* Retrieve a comprehensive view of all available balances (commits and credits)
|
|
307
|
+
* for a customer. This endpoint provides real-time visibility into prepaid funds,
|
|
308
|
+
* postpaid commitments, promotional credits, and other balance types that can
|
|
309
|
+
* offset usage charges, helping you build transparent billing experiences.
|
|
310
|
+
*
|
|
311
|
+
* ### Use this endpoint to:
|
|
312
|
+
*
|
|
313
|
+
* - Display current available balances in customer dashboards
|
|
314
|
+
* - Verify available funds before approving high-usage operations
|
|
315
|
+
* - Generate balance reports for finance teams
|
|
316
|
+
* - Filter balances by contract or date ranges
|
|
317
|
+
*
|
|
318
|
+
* ### Key response fields:
|
|
319
|
+
*
|
|
320
|
+
* An array of balance objects (all credits and commits) containing:
|
|
321
|
+
*
|
|
322
|
+
* - Balance details: Current available amount for each commit or credit
|
|
323
|
+
* - Metadata: Product associations, priorities, applicable date ranges
|
|
324
|
+
* - Optional ledger entries: Detailed transaction history (if
|
|
325
|
+
* `include_ledgers=true`)
|
|
326
|
+
* - Balance calculations: Including pending transactions and future-dated entries
|
|
327
|
+
* - Custom fields: Any additional metadata attached to balances
|
|
328
|
+
*
|
|
329
|
+
* ### Usage guidelines:
|
|
330
|
+
*
|
|
331
|
+
* - Date filtering: Use `effective_before` to include only balances with access
|
|
332
|
+
* before a specific date (exclusive)
|
|
333
|
+
* - Set `include_balance=true` for calculated balance amounts on each commit or
|
|
334
|
+
* credit
|
|
335
|
+
* - Set `include_ledgers=true` for full transaction history
|
|
336
|
+
* - Set `include_contract_balances = true` to see contract level balances
|
|
337
|
+
* - Balance logic: Reflects currently accessible amounts, excluding expired/future
|
|
338
|
+
* segments
|
|
339
|
+
* - Manual adjustments: Includes all manual ledger entries, even future-dated ones
|
|
138
340
|
*
|
|
139
341
|
* @example
|
|
140
342
|
* ```ts
|
|
141
|
-
*
|
|
142
|
-
*
|
|
143
|
-
*
|
|
144
|
-
*
|
|
145
|
-
*
|
|
343
|
+
* // Automatically fetches more pages as needed.
|
|
344
|
+
* for await (const contractListBalancesResponse of client.v1.contracts.listBalances(
|
|
345
|
+
* {
|
|
346
|
+
* customer_id: '13117714-3f05-48e5-a6e9-a66093f13b4d',
|
|
347
|
+
* id: '6162d87b-e5db-4a33-b7f2-76ce6ead4e85',
|
|
348
|
+
* include_ledgers: true,
|
|
349
|
+
* },
|
|
350
|
+
* )) {
|
|
351
|
+
* // ...
|
|
352
|
+
* }
|
|
146
353
|
* ```
|
|
147
354
|
*/
|
|
148
|
-
listBalances(body: ContractListBalancesParams, options?:
|
|
355
|
+
listBalances(body: ContractListBalancesParams, options?: RequestOptions): PagePromise<ContractListBalancesResponsesBodyCursorPage, ContractListBalancesResponse>;
|
|
149
356
|
/**
|
|
150
|
-
*
|
|
357
|
+
* For a specific customer and contract, get the rates at a specific point in time.
|
|
358
|
+
* This endpoint takes the contract's rate card into consideration, including
|
|
359
|
+
* scheduled changes. It also takes into account overrides on the contract.
|
|
360
|
+
*
|
|
361
|
+
* For example, if you want to show your customer a summary of the prices they are
|
|
362
|
+
* paying, inclusive of any negotiated discounts or promotions, use this endpoint.
|
|
363
|
+
* This endpoint only returns rates that are entitled.
|
|
151
364
|
*
|
|
152
365
|
* @example
|
|
153
366
|
* ```ts
|
|
@@ -168,10 +381,18 @@ export declare class Contracts extends APIResource {
|
|
|
168
381
|
* });
|
|
169
382
|
* ```
|
|
170
383
|
*/
|
|
171
|
-
retrieveRateSchedule(params: ContractRetrieveRateScheduleParams, options?:
|
|
384
|
+
retrieveRateSchedule(params: ContractRetrieveRateScheduleParams, options?: RequestOptions): APIPromise<ContractRetrieveRateScheduleResponse>;
|
|
172
385
|
/**
|
|
173
|
-
*
|
|
174
|
-
*
|
|
386
|
+
* Get the history of subscription quantities and prices over time for a given
|
|
387
|
+
* `subscription_id`. This endpoint can be used to power an in-product experience
|
|
388
|
+
* where you show a customer their historical changes to seat count. Future changes
|
|
389
|
+
* are not included in this endpoint - use the `getContract` endpoint to view the
|
|
390
|
+
* future scheduled changes to a subscription's quantity.
|
|
391
|
+
*
|
|
392
|
+
* Subscriptions are used to model fixed recurring fees as well as seat-based
|
|
393
|
+
* recurring fees. To model changes to the number of seats in Metronome, you can
|
|
394
|
+
* increment or decrement the quantity on a subscription at any point in the past
|
|
395
|
+
* or future.
|
|
175
396
|
*
|
|
176
397
|
* @example
|
|
177
398
|
* ```ts
|
|
@@ -186,7 +407,7 @@ export declare class Contracts extends APIResource {
|
|
|
186
407
|
* );
|
|
187
408
|
* ```
|
|
188
409
|
*/
|
|
189
|
-
retrieveSubscriptionQuantityHistory(body: ContractRetrieveSubscriptionQuantityHistoryParams, options?:
|
|
410
|
+
retrieveSubscriptionQuantityHistory(body: ContractRetrieveSubscriptionQuantityHistoryParams, options?: RequestOptions): APIPromise<ContractRetrieveSubscriptionQuantityHistoryResponse>;
|
|
190
411
|
/**
|
|
191
412
|
* Create a new scheduled invoice for Professional Services terms on a contract.
|
|
192
413
|
* This endpoint's availability is dependent on your client's configuration.
|
|
@@ -207,9 +428,26 @@ export declare class Contracts extends APIResource {
|
|
|
207
428
|
* });
|
|
208
429
|
* ```
|
|
209
430
|
*/
|
|
210
|
-
scheduleProServicesInvoice(body: ContractScheduleProServicesInvoiceParams, options?:
|
|
431
|
+
scheduleProServicesInvoice(body: ContractScheduleProServicesInvoiceParams, options?: RequestOptions): APIPromise<ContractScheduleProServicesInvoiceResponse>;
|
|
211
432
|
/**
|
|
212
|
-
*
|
|
433
|
+
* If a customer has multiple contracts with overlapping rates, the usage filter
|
|
434
|
+
* routes usage to the appropriate contract based on a predefined group key.
|
|
435
|
+
*
|
|
436
|
+
* As an example, imagine you have a customer associated with two projects. Each
|
|
437
|
+
* project is associated with its own contract. You can create a usage filter with
|
|
438
|
+
* group key `project_id` on each contract, and route usage for `project_1` to the
|
|
439
|
+
* first contract and `project_2` to the second contract.
|
|
440
|
+
*
|
|
441
|
+
* ### Use this endpoint to:
|
|
442
|
+
*
|
|
443
|
+
* - Support enterprise contracting scenarios where multiple contracts are
|
|
444
|
+
* associated to the same customer with the same rates.
|
|
445
|
+
* - Update the usage filter associated with the contract over time.
|
|
446
|
+
*
|
|
447
|
+
* ### Usage guidelines:
|
|
448
|
+
*
|
|
449
|
+
* To use usage filters, the `group_key` must be defined on the billable metrics
|
|
450
|
+
* underlying the rate card on the contracts.
|
|
213
451
|
*
|
|
214
452
|
* @example
|
|
215
453
|
* ```ts
|
|
@@ -222,9 +460,13 @@ export declare class Contracts extends APIResource {
|
|
|
222
460
|
* });
|
|
223
461
|
* ```
|
|
224
462
|
*/
|
|
225
|
-
setUsageFilter(body: ContractSetUsageFilterParams, options?:
|
|
463
|
+
setUsageFilter(body: ContractSetUsageFilterParams, options?: RequestOptions): APIPromise<void>;
|
|
226
464
|
/**
|
|
227
|
-
* Update
|
|
465
|
+
* Update or and an end date to a contract. Ending a contract early will impact
|
|
466
|
+
* draft usage statements, truncate any terms, and remove upcoming scheduled
|
|
467
|
+
* invoices. Moving the date into the future will only extend the contract length.
|
|
468
|
+
* Terms and scheduled invoices are not extended. Use this if a contract's end date
|
|
469
|
+
* has changed or if a perpetual contract ends.
|
|
228
470
|
*
|
|
229
471
|
* @example
|
|
230
472
|
* ```ts
|
|
@@ -235,748 +477,17 @@ export declare class Contracts extends APIResource {
|
|
|
235
477
|
* });
|
|
236
478
|
* ```
|
|
237
479
|
*/
|
|
238
|
-
updateEndDate(body: ContractUpdateEndDateParams, options?:
|
|
480
|
+
updateEndDate(body: ContractUpdateEndDateParams, options?: RequestOptions): APIPromise<ContractUpdateEndDateResponse>;
|
|
239
481
|
}
|
|
482
|
+
export type ContractListBalancesResponsesBodyCursorPage = BodyCursorPage<ContractListBalancesResponse>;
|
|
240
483
|
export interface ContractCreateResponse {
|
|
241
484
|
data: Shared.ID;
|
|
242
485
|
}
|
|
243
486
|
export interface ContractRetrieveResponse {
|
|
244
|
-
data:
|
|
245
|
-
}
|
|
246
|
-
export declare namespace ContractRetrieveResponse {
|
|
247
|
-
interface Data {
|
|
248
|
-
id: string;
|
|
249
|
-
amendments: Array<Data.Amendment>;
|
|
250
|
-
current: Shared.ContractWithoutAmendments;
|
|
251
|
-
customer_id: string;
|
|
252
|
-
initial: Shared.ContractWithoutAmendments;
|
|
253
|
-
/**
|
|
254
|
-
* RFC 3339 timestamp indicating when the contract was archived. If not returned,
|
|
255
|
-
* the contract is not archived.
|
|
256
|
-
*/
|
|
257
|
-
archived_at?: string;
|
|
258
|
-
custom_fields?: {
|
|
259
|
-
[key: string]: string;
|
|
260
|
-
};
|
|
261
|
-
/**
|
|
262
|
-
* The billing provider configuration associated with a contract.
|
|
263
|
-
*/
|
|
264
|
-
customer_billing_provider_configuration?: Data.CustomerBillingProviderConfiguration;
|
|
265
|
-
prepaid_balance_threshold_configuration?: Data.PrepaidBalanceThresholdConfiguration;
|
|
266
|
-
/**
|
|
267
|
-
* Priority of the contract.
|
|
268
|
-
*/
|
|
269
|
-
priority?: number;
|
|
270
|
-
/**
|
|
271
|
-
* Determines which scheduled and commit charges to consolidate onto the Contract's
|
|
272
|
-
* usage invoice. The charge's `timestamp` must match the usage invoice's
|
|
273
|
-
* `ending_before` date for consolidation to occur. This field cannot be modified
|
|
274
|
-
* after a Contract has been created. If this field is omitted, charges will appear
|
|
275
|
-
* on a separate invoice from usage charges.
|
|
276
|
-
*/
|
|
277
|
-
scheduled_charges_on_usage_invoices?: 'ALL';
|
|
278
|
-
spend_threshold_configuration?: Data.SpendThresholdConfiguration;
|
|
279
|
-
/**
|
|
280
|
-
* List of subscriptions on the contract.
|
|
281
|
-
*/
|
|
282
|
-
subscriptions?: Array<Data.Subscription>;
|
|
283
|
-
/**
|
|
284
|
-
* Prevents the creation of duplicates. If a request to create a record is made
|
|
285
|
-
* with a previously used uniqueness key, a new record will not be created and the
|
|
286
|
-
* request will fail with a 409 error.
|
|
287
|
-
*/
|
|
288
|
-
uniqueness_key?: string;
|
|
289
|
-
}
|
|
290
|
-
namespace Data {
|
|
291
|
-
interface Amendment {
|
|
292
|
-
id: string;
|
|
293
|
-
commits: Array<Shared.Commit>;
|
|
294
|
-
created_at: string;
|
|
295
|
-
created_by: string;
|
|
296
|
-
overrides: Array<Shared.Override>;
|
|
297
|
-
scheduled_charges: Array<Shared.ScheduledCharge>;
|
|
298
|
-
starting_at: string;
|
|
299
|
-
credits?: Array<Shared.Credit>;
|
|
300
|
-
/**
|
|
301
|
-
* This field's availability is dependent on your client's configuration.
|
|
302
|
-
*/
|
|
303
|
-
discounts?: Array<Shared.Discount>;
|
|
304
|
-
/**
|
|
305
|
-
* This field's availability is dependent on your client's configuration.
|
|
306
|
-
*/
|
|
307
|
-
netsuite_sales_order_id?: string;
|
|
308
|
-
/**
|
|
309
|
-
* This field's availability is dependent on your client's configuration.
|
|
310
|
-
*/
|
|
311
|
-
professional_services?: Array<Shared.ProService>;
|
|
312
|
-
/**
|
|
313
|
-
* This field's availability is dependent on your client's configuration.
|
|
314
|
-
*/
|
|
315
|
-
reseller_royalties?: Array<Amendment.ResellerRoyalty>;
|
|
316
|
-
/**
|
|
317
|
-
* This field's availability is dependent on your client's configuration.
|
|
318
|
-
*/
|
|
319
|
-
salesforce_opportunity_id?: string;
|
|
320
|
-
}
|
|
321
|
-
namespace Amendment {
|
|
322
|
-
interface ResellerRoyalty {
|
|
323
|
-
reseller_type: 'AWS' | 'AWS_PRO_SERVICE' | 'GCP' | 'GCP_PRO_SERVICE';
|
|
324
|
-
aws_account_number?: string;
|
|
325
|
-
aws_offer_id?: string;
|
|
326
|
-
aws_payer_reference_id?: string;
|
|
327
|
-
ending_before?: string | null;
|
|
328
|
-
fraction?: number;
|
|
329
|
-
gcp_account_id?: string;
|
|
330
|
-
gcp_offer_id?: string;
|
|
331
|
-
netsuite_reseller_id?: string;
|
|
332
|
-
reseller_contract_value?: number;
|
|
333
|
-
starting_at?: string;
|
|
334
|
-
}
|
|
335
|
-
}
|
|
336
|
-
/**
|
|
337
|
-
* The billing provider configuration associated with a contract.
|
|
338
|
-
*/
|
|
339
|
-
interface CustomerBillingProviderConfiguration {
|
|
340
|
-
billing_provider: 'aws_marketplace' | 'stripe' | 'netsuite' | 'custom' | 'azure_marketplace' | 'quickbooks_online' | 'workday' | 'gcp_marketplace';
|
|
341
|
-
delivery_method: 'direct_to_billing_provider' | 'aws_sqs' | 'tackle' | 'aws_sns';
|
|
342
|
-
id?: string;
|
|
343
|
-
/**
|
|
344
|
-
* Configuration for the billing provider. The structure of this object is specific
|
|
345
|
-
* to the billing provider.
|
|
346
|
-
*/
|
|
347
|
-
configuration?: {
|
|
348
|
-
[key: string]: unknown;
|
|
349
|
-
};
|
|
350
|
-
}
|
|
351
|
-
interface PrepaidBalanceThresholdConfiguration {
|
|
352
|
-
commit: PrepaidBalanceThresholdConfiguration.Commit;
|
|
353
|
-
/**
|
|
354
|
-
* When set to false, the contract will not be evaluated against the
|
|
355
|
-
* threshold_amount. Toggling to true will result an immediate evaluation,
|
|
356
|
-
* regardless of prior state.
|
|
357
|
-
*/
|
|
358
|
-
is_enabled: boolean;
|
|
359
|
-
payment_gate_config: PrepaidBalanceThresholdConfiguration.PaymentGateConfig;
|
|
360
|
-
/**
|
|
361
|
-
* Specify the amount the balance should be recharged to.
|
|
362
|
-
*/
|
|
363
|
-
recharge_to_amount: number;
|
|
364
|
-
/**
|
|
365
|
-
* Specify the threshold amount for the contract. Each time the contract's prepaid
|
|
366
|
-
* balance lowers to this amount, a threshold charge will be initiated.
|
|
367
|
-
*/
|
|
368
|
-
threshold_amount: number;
|
|
369
|
-
/**
|
|
370
|
-
* If provided, the threshold, recharge-to amount, and the resulting threshold
|
|
371
|
-
* commit amount will be in terms of this credit type instead of the fiat currency.
|
|
372
|
-
*/
|
|
373
|
-
custom_credit_type_id?: string;
|
|
374
|
-
}
|
|
375
|
-
namespace PrepaidBalanceThresholdConfiguration {
|
|
376
|
-
interface Commit {
|
|
377
|
-
/**
|
|
378
|
-
* The commit product that will be used to generate the line item for commit
|
|
379
|
-
* payment.
|
|
380
|
-
*/
|
|
381
|
-
product_id: string;
|
|
382
|
-
/**
|
|
383
|
-
* Which products the threshold commit applies to. If applicable_product_ids,
|
|
384
|
-
* applicable_product_tags or specifiers are not provided, the commit applies to
|
|
385
|
-
* all products.
|
|
386
|
-
*/
|
|
387
|
-
applicable_product_ids?: Array<string>;
|
|
388
|
-
/**
|
|
389
|
-
* Which tags the threshold commit applies to. If applicable_product_ids,
|
|
390
|
-
* applicable_product_tags or specifiers are not provided, the commit applies to
|
|
391
|
-
* all products.
|
|
392
|
-
*/
|
|
393
|
-
applicable_product_tags?: Array<string>;
|
|
394
|
-
description?: string;
|
|
395
|
-
/**
|
|
396
|
-
* Specify the name of the line item for the threshold charge. If left blank, it
|
|
397
|
-
* will default to the commit product name.
|
|
398
|
-
*/
|
|
399
|
-
name?: string;
|
|
400
|
-
/**
|
|
401
|
-
* List of filters that determine what kind of customer usage draws down a commit
|
|
402
|
-
* or credit. A customer's usage needs to meet the condition of at least one of the
|
|
403
|
-
* specifiers to contribute to a commit's or credit's drawdown. This field cannot
|
|
404
|
-
* be used together with `applicable_product_ids` or `applicable_product_tags`.
|
|
405
|
-
*/
|
|
406
|
-
specifiers?: Array<Commit.Specifier>;
|
|
407
|
-
}
|
|
408
|
-
namespace Commit {
|
|
409
|
-
interface Specifier {
|
|
410
|
-
presentation_group_values?: {
|
|
411
|
-
[key: string]: string;
|
|
412
|
-
};
|
|
413
|
-
pricing_group_values?: {
|
|
414
|
-
[key: string]: string;
|
|
415
|
-
};
|
|
416
|
-
/**
|
|
417
|
-
* If provided, the specifier will only apply to the product with the specified ID.
|
|
418
|
-
*/
|
|
419
|
-
product_id?: string;
|
|
420
|
-
/**
|
|
421
|
-
* If provided, the specifier will only apply to products with all the specified
|
|
422
|
-
* tags.
|
|
423
|
-
*/
|
|
424
|
-
product_tags?: Array<string>;
|
|
425
|
-
}
|
|
426
|
-
}
|
|
427
|
-
interface PaymentGateConfig {
|
|
428
|
-
/**
|
|
429
|
-
* Gate access to the commit balance based on successful collection of payment.
|
|
430
|
-
* Select STRIPE for Metronome to facilitate payment via Stripe. Select EXTERNAL to
|
|
431
|
-
* facilitate payment using your own payment integration. Select NONE if you do not
|
|
432
|
-
* wish to payment gate the commit balance.
|
|
433
|
-
*/
|
|
434
|
-
payment_gate_type: 'NONE' | 'STRIPE' | 'EXTERNAL';
|
|
435
|
-
/**
|
|
436
|
-
* Only applicable if using PRECALCULATED as your tax type.
|
|
437
|
-
*/
|
|
438
|
-
precalculated_tax_config?: PaymentGateConfig.PrecalculatedTaxConfig;
|
|
439
|
-
/**
|
|
440
|
-
* Only applicable if using STRIPE as your payment gate type.
|
|
441
|
-
*/
|
|
442
|
-
stripe_config?: PaymentGateConfig.StripeConfig;
|
|
443
|
-
/**
|
|
444
|
-
* Stripe tax is only supported for Stripe payment gateway. Select NONE if you do
|
|
445
|
-
* not wish Metronome to calculate tax on your behalf. Leaving this field blank
|
|
446
|
-
* will default to NONE.
|
|
447
|
-
*/
|
|
448
|
-
tax_type?: 'NONE' | 'STRIPE' | 'ANROK' | 'PRECALCULATED';
|
|
449
|
-
}
|
|
450
|
-
namespace PaymentGateConfig {
|
|
451
|
-
/**
|
|
452
|
-
* Only applicable if using PRECALCULATED as your tax type.
|
|
453
|
-
*/
|
|
454
|
-
interface PrecalculatedTaxConfig {
|
|
455
|
-
/**
|
|
456
|
-
* Amount of tax to be applied. This should be in the same currency and
|
|
457
|
-
* denomination as the commit's invoice schedule
|
|
458
|
-
*/
|
|
459
|
-
tax_amount: number;
|
|
460
|
-
/**
|
|
461
|
-
* Name of the tax to be applied. This may be used in an invoice line item
|
|
462
|
-
* description.
|
|
463
|
-
*/
|
|
464
|
-
tax_name?: string;
|
|
465
|
-
}
|
|
466
|
-
/**
|
|
467
|
-
* Only applicable if using STRIPE as your payment gate type.
|
|
468
|
-
*/
|
|
469
|
-
interface StripeConfig {
|
|
470
|
-
/**
|
|
471
|
-
* If left blank, will default to INVOICE
|
|
472
|
-
*/
|
|
473
|
-
payment_type: 'INVOICE' | 'PAYMENT_INTENT';
|
|
474
|
-
/**
|
|
475
|
-
* Metadata to be added to the Stripe invoice. Only applicable if using INVOICE as
|
|
476
|
-
* your payment type.
|
|
477
|
-
*/
|
|
478
|
-
invoice_metadata?: {
|
|
479
|
-
[key: string]: string;
|
|
480
|
-
};
|
|
481
|
-
}
|
|
482
|
-
}
|
|
483
|
-
}
|
|
484
|
-
interface SpendThresholdConfiguration {
|
|
485
|
-
commit: SpendThresholdConfiguration.Commit;
|
|
486
|
-
/**
|
|
487
|
-
* When set to false, the contract will not be evaluated against the
|
|
488
|
-
* threshold_amount. Toggling to true will result an immediate evaluation,
|
|
489
|
-
* regardless of prior state.
|
|
490
|
-
*/
|
|
491
|
-
is_enabled: boolean;
|
|
492
|
-
payment_gate_config: SpendThresholdConfiguration.PaymentGateConfig;
|
|
493
|
-
/**
|
|
494
|
-
* Specify the threshold amount for the contract. Each time the contract's usage
|
|
495
|
-
* hits this amount, a threshold charge will be initiated.
|
|
496
|
-
*/
|
|
497
|
-
threshold_amount: number;
|
|
498
|
-
}
|
|
499
|
-
namespace SpendThresholdConfiguration {
|
|
500
|
-
interface Commit {
|
|
501
|
-
/**
|
|
502
|
-
* The commit product that will be used to generate the line item for commit
|
|
503
|
-
* payment.
|
|
504
|
-
*/
|
|
505
|
-
product_id: string;
|
|
506
|
-
description?: string;
|
|
507
|
-
/**
|
|
508
|
-
* Specify the name of the line item for the threshold charge. If left blank, it
|
|
509
|
-
* will default to the commit product name.
|
|
510
|
-
*/
|
|
511
|
-
name?: string;
|
|
512
|
-
}
|
|
513
|
-
interface PaymentGateConfig {
|
|
514
|
-
/**
|
|
515
|
-
* Gate access to the commit balance based on successful collection of payment.
|
|
516
|
-
* Select STRIPE for Metronome to facilitate payment via Stripe. Select EXTERNAL to
|
|
517
|
-
* facilitate payment using your own payment integration. Select NONE if you do not
|
|
518
|
-
* wish to payment gate the commit balance.
|
|
519
|
-
*/
|
|
520
|
-
payment_gate_type: 'NONE' | 'STRIPE' | 'EXTERNAL';
|
|
521
|
-
/**
|
|
522
|
-
* Only applicable if using PRECALCULATED as your tax type.
|
|
523
|
-
*/
|
|
524
|
-
precalculated_tax_config?: PaymentGateConfig.PrecalculatedTaxConfig;
|
|
525
|
-
/**
|
|
526
|
-
* Only applicable if using STRIPE as your payment gate type.
|
|
527
|
-
*/
|
|
528
|
-
stripe_config?: PaymentGateConfig.StripeConfig;
|
|
529
|
-
/**
|
|
530
|
-
* Stripe tax is only supported for Stripe payment gateway. Select NONE if you do
|
|
531
|
-
* not wish Metronome to calculate tax on your behalf. Leaving this field blank
|
|
532
|
-
* will default to NONE.
|
|
533
|
-
*/
|
|
534
|
-
tax_type?: 'NONE' | 'STRIPE' | 'ANROK' | 'PRECALCULATED';
|
|
535
|
-
}
|
|
536
|
-
namespace PaymentGateConfig {
|
|
537
|
-
/**
|
|
538
|
-
* Only applicable if using PRECALCULATED as your tax type.
|
|
539
|
-
*/
|
|
540
|
-
interface PrecalculatedTaxConfig {
|
|
541
|
-
/**
|
|
542
|
-
* Amount of tax to be applied. This should be in the same currency and
|
|
543
|
-
* denomination as the commit's invoice schedule
|
|
544
|
-
*/
|
|
545
|
-
tax_amount: number;
|
|
546
|
-
/**
|
|
547
|
-
* Name of the tax to be applied. This may be used in an invoice line item
|
|
548
|
-
* description.
|
|
549
|
-
*/
|
|
550
|
-
tax_name?: string;
|
|
551
|
-
}
|
|
552
|
-
/**
|
|
553
|
-
* Only applicable if using STRIPE as your payment gate type.
|
|
554
|
-
*/
|
|
555
|
-
interface StripeConfig {
|
|
556
|
-
/**
|
|
557
|
-
* If left blank, will default to INVOICE
|
|
558
|
-
*/
|
|
559
|
-
payment_type: 'INVOICE' | 'PAYMENT_INTENT';
|
|
560
|
-
/**
|
|
561
|
-
* Metadata to be added to the Stripe invoice. Only applicable if using INVOICE as
|
|
562
|
-
* your payment type.
|
|
563
|
-
*/
|
|
564
|
-
invoice_metadata?: {
|
|
565
|
-
[key: string]: string;
|
|
566
|
-
};
|
|
567
|
-
}
|
|
568
|
-
}
|
|
569
|
-
}
|
|
570
|
-
interface Subscription {
|
|
571
|
-
collection_schedule: 'ADVANCE' | 'ARREARS';
|
|
572
|
-
proration: Subscription.Proration;
|
|
573
|
-
/**
|
|
574
|
-
* List of quantity schedule items for the subscription. Only includes the current
|
|
575
|
-
* quantity and future quantity changes.
|
|
576
|
-
*/
|
|
577
|
-
quantity_schedule: Array<Subscription.QuantitySchedule>;
|
|
578
|
-
starting_at: string;
|
|
579
|
-
subscription_rate: Subscription.SubscriptionRate;
|
|
580
|
-
id?: string;
|
|
581
|
-
custom_fields?: {
|
|
582
|
-
[key: string]: string;
|
|
583
|
-
};
|
|
584
|
-
description?: string;
|
|
585
|
-
ending_before?: string;
|
|
586
|
-
fiat_credit_type_id?: string;
|
|
587
|
-
name?: string;
|
|
588
|
-
}
|
|
589
|
-
namespace Subscription {
|
|
590
|
-
interface Proration {
|
|
591
|
-
invoice_behavior: 'BILL_IMMEDIATELY' | 'BILL_ON_NEXT_COLLECTION_DATE';
|
|
592
|
-
is_prorated: boolean;
|
|
593
|
-
}
|
|
594
|
-
interface QuantitySchedule {
|
|
595
|
-
quantity: number;
|
|
596
|
-
starting_at: string;
|
|
597
|
-
ending_before?: string;
|
|
598
|
-
}
|
|
599
|
-
interface SubscriptionRate {
|
|
600
|
-
billing_frequency: 'MONTHLY' | 'QUARTERLY' | 'ANNUAL' | 'WEEKLY';
|
|
601
|
-
product: SubscriptionRate.Product;
|
|
602
|
-
}
|
|
603
|
-
namespace SubscriptionRate {
|
|
604
|
-
interface Product {
|
|
605
|
-
id: string;
|
|
606
|
-
name: string;
|
|
607
|
-
}
|
|
608
|
-
}
|
|
609
|
-
}
|
|
610
|
-
}
|
|
487
|
+
data: Shared.Contract;
|
|
611
488
|
}
|
|
612
489
|
export interface ContractListResponse {
|
|
613
|
-
data: Array<
|
|
614
|
-
}
|
|
615
|
-
export declare namespace ContractListResponse {
|
|
616
|
-
interface Data {
|
|
617
|
-
id: string;
|
|
618
|
-
amendments: Array<Data.Amendment>;
|
|
619
|
-
current: Shared.ContractWithoutAmendments;
|
|
620
|
-
customer_id: string;
|
|
621
|
-
initial: Shared.ContractWithoutAmendments;
|
|
622
|
-
/**
|
|
623
|
-
* RFC 3339 timestamp indicating when the contract was archived. If not returned,
|
|
624
|
-
* the contract is not archived.
|
|
625
|
-
*/
|
|
626
|
-
archived_at?: string;
|
|
627
|
-
custom_fields?: {
|
|
628
|
-
[key: string]: string;
|
|
629
|
-
};
|
|
630
|
-
/**
|
|
631
|
-
* The billing provider configuration associated with a contract.
|
|
632
|
-
*/
|
|
633
|
-
customer_billing_provider_configuration?: Data.CustomerBillingProviderConfiguration;
|
|
634
|
-
prepaid_balance_threshold_configuration?: Data.PrepaidBalanceThresholdConfiguration;
|
|
635
|
-
/**
|
|
636
|
-
* Priority of the contract.
|
|
637
|
-
*/
|
|
638
|
-
priority?: number;
|
|
639
|
-
/**
|
|
640
|
-
* Determines which scheduled and commit charges to consolidate onto the Contract's
|
|
641
|
-
* usage invoice. The charge's `timestamp` must match the usage invoice's
|
|
642
|
-
* `ending_before` date for consolidation to occur. This field cannot be modified
|
|
643
|
-
* after a Contract has been created. If this field is omitted, charges will appear
|
|
644
|
-
* on a separate invoice from usage charges.
|
|
645
|
-
*/
|
|
646
|
-
scheduled_charges_on_usage_invoices?: 'ALL';
|
|
647
|
-
spend_threshold_configuration?: Data.SpendThresholdConfiguration;
|
|
648
|
-
/**
|
|
649
|
-
* List of subscriptions on the contract.
|
|
650
|
-
*/
|
|
651
|
-
subscriptions?: Array<Data.Subscription>;
|
|
652
|
-
/**
|
|
653
|
-
* Prevents the creation of duplicates. If a request to create a record is made
|
|
654
|
-
* with a previously used uniqueness key, a new record will not be created and the
|
|
655
|
-
* request will fail with a 409 error.
|
|
656
|
-
*/
|
|
657
|
-
uniqueness_key?: string;
|
|
658
|
-
}
|
|
659
|
-
namespace Data {
|
|
660
|
-
interface Amendment {
|
|
661
|
-
id: string;
|
|
662
|
-
commits: Array<Shared.Commit>;
|
|
663
|
-
created_at: string;
|
|
664
|
-
created_by: string;
|
|
665
|
-
overrides: Array<Shared.Override>;
|
|
666
|
-
scheduled_charges: Array<Shared.ScheduledCharge>;
|
|
667
|
-
starting_at: string;
|
|
668
|
-
credits?: Array<Shared.Credit>;
|
|
669
|
-
/**
|
|
670
|
-
* This field's availability is dependent on your client's configuration.
|
|
671
|
-
*/
|
|
672
|
-
discounts?: Array<Shared.Discount>;
|
|
673
|
-
/**
|
|
674
|
-
* This field's availability is dependent on your client's configuration.
|
|
675
|
-
*/
|
|
676
|
-
netsuite_sales_order_id?: string;
|
|
677
|
-
/**
|
|
678
|
-
* This field's availability is dependent on your client's configuration.
|
|
679
|
-
*/
|
|
680
|
-
professional_services?: Array<Shared.ProService>;
|
|
681
|
-
/**
|
|
682
|
-
* This field's availability is dependent on your client's configuration.
|
|
683
|
-
*/
|
|
684
|
-
reseller_royalties?: Array<Amendment.ResellerRoyalty>;
|
|
685
|
-
/**
|
|
686
|
-
* This field's availability is dependent on your client's configuration.
|
|
687
|
-
*/
|
|
688
|
-
salesforce_opportunity_id?: string;
|
|
689
|
-
}
|
|
690
|
-
namespace Amendment {
|
|
691
|
-
interface ResellerRoyalty {
|
|
692
|
-
reseller_type: 'AWS' | 'AWS_PRO_SERVICE' | 'GCP' | 'GCP_PRO_SERVICE';
|
|
693
|
-
aws_account_number?: string;
|
|
694
|
-
aws_offer_id?: string;
|
|
695
|
-
aws_payer_reference_id?: string;
|
|
696
|
-
ending_before?: string | null;
|
|
697
|
-
fraction?: number;
|
|
698
|
-
gcp_account_id?: string;
|
|
699
|
-
gcp_offer_id?: string;
|
|
700
|
-
netsuite_reseller_id?: string;
|
|
701
|
-
reseller_contract_value?: number;
|
|
702
|
-
starting_at?: string;
|
|
703
|
-
}
|
|
704
|
-
}
|
|
705
|
-
/**
|
|
706
|
-
* The billing provider configuration associated with a contract.
|
|
707
|
-
*/
|
|
708
|
-
interface CustomerBillingProviderConfiguration {
|
|
709
|
-
billing_provider: 'aws_marketplace' | 'stripe' | 'netsuite' | 'custom' | 'azure_marketplace' | 'quickbooks_online' | 'workday' | 'gcp_marketplace';
|
|
710
|
-
delivery_method: 'direct_to_billing_provider' | 'aws_sqs' | 'tackle' | 'aws_sns';
|
|
711
|
-
id?: string;
|
|
712
|
-
/**
|
|
713
|
-
* Configuration for the billing provider. The structure of this object is specific
|
|
714
|
-
* to the billing provider.
|
|
715
|
-
*/
|
|
716
|
-
configuration?: {
|
|
717
|
-
[key: string]: unknown;
|
|
718
|
-
};
|
|
719
|
-
}
|
|
720
|
-
interface PrepaidBalanceThresholdConfiguration {
|
|
721
|
-
commit: PrepaidBalanceThresholdConfiguration.Commit;
|
|
722
|
-
/**
|
|
723
|
-
* When set to false, the contract will not be evaluated against the
|
|
724
|
-
* threshold_amount. Toggling to true will result an immediate evaluation,
|
|
725
|
-
* regardless of prior state.
|
|
726
|
-
*/
|
|
727
|
-
is_enabled: boolean;
|
|
728
|
-
payment_gate_config: PrepaidBalanceThresholdConfiguration.PaymentGateConfig;
|
|
729
|
-
/**
|
|
730
|
-
* Specify the amount the balance should be recharged to.
|
|
731
|
-
*/
|
|
732
|
-
recharge_to_amount: number;
|
|
733
|
-
/**
|
|
734
|
-
* Specify the threshold amount for the contract. Each time the contract's prepaid
|
|
735
|
-
* balance lowers to this amount, a threshold charge will be initiated.
|
|
736
|
-
*/
|
|
737
|
-
threshold_amount: number;
|
|
738
|
-
/**
|
|
739
|
-
* If provided, the threshold, recharge-to amount, and the resulting threshold
|
|
740
|
-
* commit amount will be in terms of this credit type instead of the fiat currency.
|
|
741
|
-
*/
|
|
742
|
-
custom_credit_type_id?: string;
|
|
743
|
-
}
|
|
744
|
-
namespace PrepaidBalanceThresholdConfiguration {
|
|
745
|
-
interface Commit {
|
|
746
|
-
/**
|
|
747
|
-
* The commit product that will be used to generate the line item for commit
|
|
748
|
-
* payment.
|
|
749
|
-
*/
|
|
750
|
-
product_id: string;
|
|
751
|
-
/**
|
|
752
|
-
* Which products the threshold commit applies to. If applicable_product_ids,
|
|
753
|
-
* applicable_product_tags or specifiers are not provided, the commit applies to
|
|
754
|
-
* all products.
|
|
755
|
-
*/
|
|
756
|
-
applicable_product_ids?: Array<string>;
|
|
757
|
-
/**
|
|
758
|
-
* Which tags the threshold commit applies to. If applicable_product_ids,
|
|
759
|
-
* applicable_product_tags or specifiers are not provided, the commit applies to
|
|
760
|
-
* all products.
|
|
761
|
-
*/
|
|
762
|
-
applicable_product_tags?: Array<string>;
|
|
763
|
-
description?: string;
|
|
764
|
-
/**
|
|
765
|
-
* Specify the name of the line item for the threshold charge. If left blank, it
|
|
766
|
-
* will default to the commit product name.
|
|
767
|
-
*/
|
|
768
|
-
name?: string;
|
|
769
|
-
/**
|
|
770
|
-
* List of filters that determine what kind of customer usage draws down a commit
|
|
771
|
-
* or credit. A customer's usage needs to meet the condition of at least one of the
|
|
772
|
-
* specifiers to contribute to a commit's or credit's drawdown. This field cannot
|
|
773
|
-
* be used together with `applicable_product_ids` or `applicable_product_tags`.
|
|
774
|
-
*/
|
|
775
|
-
specifiers?: Array<Commit.Specifier>;
|
|
776
|
-
}
|
|
777
|
-
namespace Commit {
|
|
778
|
-
interface Specifier {
|
|
779
|
-
presentation_group_values?: {
|
|
780
|
-
[key: string]: string;
|
|
781
|
-
};
|
|
782
|
-
pricing_group_values?: {
|
|
783
|
-
[key: string]: string;
|
|
784
|
-
};
|
|
785
|
-
/**
|
|
786
|
-
* If provided, the specifier will only apply to the product with the specified ID.
|
|
787
|
-
*/
|
|
788
|
-
product_id?: string;
|
|
789
|
-
/**
|
|
790
|
-
* If provided, the specifier will only apply to products with all the specified
|
|
791
|
-
* tags.
|
|
792
|
-
*/
|
|
793
|
-
product_tags?: Array<string>;
|
|
794
|
-
}
|
|
795
|
-
}
|
|
796
|
-
interface PaymentGateConfig {
|
|
797
|
-
/**
|
|
798
|
-
* Gate access to the commit balance based on successful collection of payment.
|
|
799
|
-
* Select STRIPE for Metronome to facilitate payment via Stripe. Select EXTERNAL to
|
|
800
|
-
* facilitate payment using your own payment integration. Select NONE if you do not
|
|
801
|
-
* wish to payment gate the commit balance.
|
|
802
|
-
*/
|
|
803
|
-
payment_gate_type: 'NONE' | 'STRIPE' | 'EXTERNAL';
|
|
804
|
-
/**
|
|
805
|
-
* Only applicable if using PRECALCULATED as your tax type.
|
|
806
|
-
*/
|
|
807
|
-
precalculated_tax_config?: PaymentGateConfig.PrecalculatedTaxConfig;
|
|
808
|
-
/**
|
|
809
|
-
* Only applicable if using STRIPE as your payment gate type.
|
|
810
|
-
*/
|
|
811
|
-
stripe_config?: PaymentGateConfig.StripeConfig;
|
|
812
|
-
/**
|
|
813
|
-
* Stripe tax is only supported for Stripe payment gateway. Select NONE if you do
|
|
814
|
-
* not wish Metronome to calculate tax on your behalf. Leaving this field blank
|
|
815
|
-
* will default to NONE.
|
|
816
|
-
*/
|
|
817
|
-
tax_type?: 'NONE' | 'STRIPE' | 'ANROK' | 'PRECALCULATED';
|
|
818
|
-
}
|
|
819
|
-
namespace PaymentGateConfig {
|
|
820
|
-
/**
|
|
821
|
-
* Only applicable if using PRECALCULATED as your tax type.
|
|
822
|
-
*/
|
|
823
|
-
interface PrecalculatedTaxConfig {
|
|
824
|
-
/**
|
|
825
|
-
* Amount of tax to be applied. This should be in the same currency and
|
|
826
|
-
* denomination as the commit's invoice schedule
|
|
827
|
-
*/
|
|
828
|
-
tax_amount: number;
|
|
829
|
-
/**
|
|
830
|
-
* Name of the tax to be applied. This may be used in an invoice line item
|
|
831
|
-
* description.
|
|
832
|
-
*/
|
|
833
|
-
tax_name?: string;
|
|
834
|
-
}
|
|
835
|
-
/**
|
|
836
|
-
* Only applicable if using STRIPE as your payment gate type.
|
|
837
|
-
*/
|
|
838
|
-
interface StripeConfig {
|
|
839
|
-
/**
|
|
840
|
-
* If left blank, will default to INVOICE
|
|
841
|
-
*/
|
|
842
|
-
payment_type: 'INVOICE' | 'PAYMENT_INTENT';
|
|
843
|
-
/**
|
|
844
|
-
* Metadata to be added to the Stripe invoice. Only applicable if using INVOICE as
|
|
845
|
-
* your payment type.
|
|
846
|
-
*/
|
|
847
|
-
invoice_metadata?: {
|
|
848
|
-
[key: string]: string;
|
|
849
|
-
};
|
|
850
|
-
}
|
|
851
|
-
}
|
|
852
|
-
}
|
|
853
|
-
interface SpendThresholdConfiguration {
|
|
854
|
-
commit: SpendThresholdConfiguration.Commit;
|
|
855
|
-
/**
|
|
856
|
-
* When set to false, the contract will not be evaluated against the
|
|
857
|
-
* threshold_amount. Toggling to true will result an immediate evaluation,
|
|
858
|
-
* regardless of prior state.
|
|
859
|
-
*/
|
|
860
|
-
is_enabled: boolean;
|
|
861
|
-
payment_gate_config: SpendThresholdConfiguration.PaymentGateConfig;
|
|
862
|
-
/**
|
|
863
|
-
* Specify the threshold amount for the contract. Each time the contract's usage
|
|
864
|
-
* hits this amount, a threshold charge will be initiated.
|
|
865
|
-
*/
|
|
866
|
-
threshold_amount: number;
|
|
867
|
-
}
|
|
868
|
-
namespace SpendThresholdConfiguration {
|
|
869
|
-
interface Commit {
|
|
870
|
-
/**
|
|
871
|
-
* The commit product that will be used to generate the line item for commit
|
|
872
|
-
* payment.
|
|
873
|
-
*/
|
|
874
|
-
product_id: string;
|
|
875
|
-
description?: string;
|
|
876
|
-
/**
|
|
877
|
-
* Specify the name of the line item for the threshold charge. If left blank, it
|
|
878
|
-
* will default to the commit product name.
|
|
879
|
-
*/
|
|
880
|
-
name?: string;
|
|
881
|
-
}
|
|
882
|
-
interface PaymentGateConfig {
|
|
883
|
-
/**
|
|
884
|
-
* Gate access to the commit balance based on successful collection of payment.
|
|
885
|
-
* Select STRIPE for Metronome to facilitate payment via Stripe. Select EXTERNAL to
|
|
886
|
-
* facilitate payment using your own payment integration. Select NONE if you do not
|
|
887
|
-
* wish to payment gate the commit balance.
|
|
888
|
-
*/
|
|
889
|
-
payment_gate_type: 'NONE' | 'STRIPE' | 'EXTERNAL';
|
|
890
|
-
/**
|
|
891
|
-
* Only applicable if using PRECALCULATED as your tax type.
|
|
892
|
-
*/
|
|
893
|
-
precalculated_tax_config?: PaymentGateConfig.PrecalculatedTaxConfig;
|
|
894
|
-
/**
|
|
895
|
-
* Only applicable if using STRIPE as your payment gate type.
|
|
896
|
-
*/
|
|
897
|
-
stripe_config?: PaymentGateConfig.StripeConfig;
|
|
898
|
-
/**
|
|
899
|
-
* Stripe tax is only supported for Stripe payment gateway. Select NONE if you do
|
|
900
|
-
* not wish Metronome to calculate tax on your behalf. Leaving this field blank
|
|
901
|
-
* will default to NONE.
|
|
902
|
-
*/
|
|
903
|
-
tax_type?: 'NONE' | 'STRIPE' | 'ANROK' | 'PRECALCULATED';
|
|
904
|
-
}
|
|
905
|
-
namespace PaymentGateConfig {
|
|
906
|
-
/**
|
|
907
|
-
* Only applicable if using PRECALCULATED as your tax type.
|
|
908
|
-
*/
|
|
909
|
-
interface PrecalculatedTaxConfig {
|
|
910
|
-
/**
|
|
911
|
-
* Amount of tax to be applied. This should be in the same currency and
|
|
912
|
-
* denomination as the commit's invoice schedule
|
|
913
|
-
*/
|
|
914
|
-
tax_amount: number;
|
|
915
|
-
/**
|
|
916
|
-
* Name of the tax to be applied. This may be used in an invoice line item
|
|
917
|
-
* description.
|
|
918
|
-
*/
|
|
919
|
-
tax_name?: string;
|
|
920
|
-
}
|
|
921
|
-
/**
|
|
922
|
-
* Only applicable if using STRIPE as your payment gate type.
|
|
923
|
-
*/
|
|
924
|
-
interface StripeConfig {
|
|
925
|
-
/**
|
|
926
|
-
* If left blank, will default to INVOICE
|
|
927
|
-
*/
|
|
928
|
-
payment_type: 'INVOICE' | 'PAYMENT_INTENT';
|
|
929
|
-
/**
|
|
930
|
-
* Metadata to be added to the Stripe invoice. Only applicable if using INVOICE as
|
|
931
|
-
* your payment type.
|
|
932
|
-
*/
|
|
933
|
-
invoice_metadata?: {
|
|
934
|
-
[key: string]: string;
|
|
935
|
-
};
|
|
936
|
-
}
|
|
937
|
-
}
|
|
938
|
-
}
|
|
939
|
-
interface Subscription {
|
|
940
|
-
collection_schedule: 'ADVANCE' | 'ARREARS';
|
|
941
|
-
proration: Subscription.Proration;
|
|
942
|
-
/**
|
|
943
|
-
* List of quantity schedule items for the subscription. Only includes the current
|
|
944
|
-
* quantity and future quantity changes.
|
|
945
|
-
*/
|
|
946
|
-
quantity_schedule: Array<Subscription.QuantitySchedule>;
|
|
947
|
-
starting_at: string;
|
|
948
|
-
subscription_rate: Subscription.SubscriptionRate;
|
|
949
|
-
id?: string;
|
|
950
|
-
custom_fields?: {
|
|
951
|
-
[key: string]: string;
|
|
952
|
-
};
|
|
953
|
-
description?: string;
|
|
954
|
-
ending_before?: string;
|
|
955
|
-
fiat_credit_type_id?: string;
|
|
956
|
-
name?: string;
|
|
957
|
-
}
|
|
958
|
-
namespace Subscription {
|
|
959
|
-
interface Proration {
|
|
960
|
-
invoice_behavior: 'BILL_IMMEDIATELY' | 'BILL_ON_NEXT_COLLECTION_DATE';
|
|
961
|
-
is_prorated: boolean;
|
|
962
|
-
}
|
|
963
|
-
interface QuantitySchedule {
|
|
964
|
-
quantity: number;
|
|
965
|
-
starting_at: string;
|
|
966
|
-
ending_before?: string;
|
|
967
|
-
}
|
|
968
|
-
interface SubscriptionRate {
|
|
969
|
-
billing_frequency: 'MONTHLY' | 'QUARTERLY' | 'ANNUAL' | 'WEEKLY';
|
|
970
|
-
product: SubscriptionRate.Product;
|
|
971
|
-
}
|
|
972
|
-
namespace SubscriptionRate {
|
|
973
|
-
interface Product {
|
|
974
|
-
id: string;
|
|
975
|
-
name: string;
|
|
976
|
-
}
|
|
977
|
-
}
|
|
978
|
-
}
|
|
979
|
-
}
|
|
490
|
+
data: Array<Shared.Contract>;
|
|
980
491
|
}
|
|
981
492
|
export interface ContractAmendResponse {
|
|
982
493
|
data: Shared.ID;
|
|
@@ -987,10 +498,7 @@ export interface ContractArchiveResponse {
|
|
|
987
498
|
export interface ContractCreateHistoricalInvoicesResponse {
|
|
988
499
|
data: Array<InvoicesAPI.Invoice>;
|
|
989
500
|
}
|
|
990
|
-
export
|
|
991
|
-
data: Array<Shared.Commit | Shared.Credit>;
|
|
992
|
-
next_page: string | null;
|
|
993
|
-
}
|
|
501
|
+
export type ContractListBalancesResponse = Shared.Commit | Shared.Credit;
|
|
994
502
|
export interface ContractRetrieveRateScheduleResponse {
|
|
995
503
|
data: Array<ContractRetrieveRateScheduleResponse.Data>;
|
|
996
504
|
next_page?: string | null;
|
|
@@ -999,6 +507,9 @@ export declare namespace ContractRetrieveRateScheduleResponse {
|
|
|
999
507
|
interface Data {
|
|
1000
508
|
entitled: boolean;
|
|
1001
509
|
list_rate: Shared.Rate;
|
|
510
|
+
/**
|
|
511
|
+
* Custom fields to be added eg. { "key1": "value1", "key2": "value2" }
|
|
512
|
+
*/
|
|
1002
513
|
product_custom_fields: {
|
|
1003
514
|
[key: string]: string;
|
|
1004
515
|
};
|
|
@@ -1012,30 +523,13 @@ export declare namespace ContractRetrieveRateScheduleResponse {
|
|
|
1012
523
|
* A distinct rate on the rate card. You can choose to use this rate rather than
|
|
1013
524
|
* list rate when consuming a credit or commit.
|
|
1014
525
|
*/
|
|
1015
|
-
commit_rate?:
|
|
526
|
+
commit_rate?: Shared.CommitRate;
|
|
1016
527
|
ending_before?: string;
|
|
1017
528
|
override_rate?: Shared.Rate;
|
|
1018
529
|
pricing_group_values?: {
|
|
1019
530
|
[key: string]: string;
|
|
1020
531
|
};
|
|
1021
532
|
}
|
|
1022
|
-
namespace Data {
|
|
1023
|
-
/**
|
|
1024
|
-
* A distinct rate on the rate card. You can choose to use this rate rather than
|
|
1025
|
-
* list rate when consuming a credit or commit.
|
|
1026
|
-
*/
|
|
1027
|
-
interface CommitRate {
|
|
1028
|
-
rate_type: 'FLAT' | 'PERCENTAGE' | 'SUBSCRIPTION' | 'TIERED' | 'CUSTOM';
|
|
1029
|
-
/**
|
|
1030
|
-
* Commit rate price. For FLAT rate_type, this must be >=0.
|
|
1031
|
-
*/
|
|
1032
|
-
price?: number;
|
|
1033
|
-
/**
|
|
1034
|
-
* Only set for TIERED rate_type.
|
|
1035
|
-
*/
|
|
1036
|
-
tiers?: Array<Shared.Tier>;
|
|
1037
|
-
}
|
|
1038
|
-
}
|
|
1039
533
|
}
|
|
1040
534
|
export interface ContractRetrieveSubscriptionQuantityHistoryResponse {
|
|
1041
535
|
data: ContractRetrieveSubscriptionQuantityHistoryResponse.Data;
|
|
@@ -1079,6 +573,9 @@ export interface ContractCreateParams {
|
|
|
1079
573
|
billing_provider_configuration?: ContractCreateParams.BillingProviderConfiguration;
|
|
1080
574
|
commits?: Array<ContractCreateParams.Commit>;
|
|
1081
575
|
credits?: Array<ContractCreateParams.Credit>;
|
|
576
|
+
/**
|
|
577
|
+
* Custom fields to be added eg. { "key1": "value1", "key2": "value2" }
|
|
578
|
+
*/
|
|
1082
579
|
custom_fields?: {
|
|
1083
580
|
[key: string]: string;
|
|
1084
581
|
};
|
|
@@ -1105,7 +602,7 @@ export interface ContractCreateParams {
|
|
|
1105
602
|
*/
|
|
1106
603
|
netsuite_sales_order_id?: string;
|
|
1107
604
|
overrides?: Array<ContractCreateParams.Override>;
|
|
1108
|
-
prepaid_balance_threshold_configuration?:
|
|
605
|
+
prepaid_balance_threshold_configuration?: Shared.PrepaidBalanceThresholdConfiguration;
|
|
1109
606
|
/**
|
|
1110
607
|
* Priority of the contract.
|
|
1111
608
|
*/
|
|
@@ -1139,7 +636,7 @@ export interface ContractCreateParams {
|
|
|
1139
636
|
* on a separate invoice from usage charges.
|
|
1140
637
|
*/
|
|
1141
638
|
scheduled_charges_on_usage_invoices?: 'ALL';
|
|
1142
|
-
spend_threshold_configuration?:
|
|
639
|
+
spend_threshold_configuration?: Shared.SpendThresholdConfiguration;
|
|
1143
640
|
/**
|
|
1144
641
|
* Optional list of
|
|
1145
642
|
* [subscriptions](https://docs.metronome.com/manage-product-access/create-subscription/)
|
|
@@ -1206,6 +703,9 @@ export declare namespace ContractCreateParams {
|
|
|
1206
703
|
* all products.
|
|
1207
704
|
*/
|
|
1208
705
|
applicable_product_tags?: Array<string>;
|
|
706
|
+
/**
|
|
707
|
+
* Custom fields to be added eg. { "key1": "value1", "key2": "value2" }
|
|
708
|
+
*/
|
|
1209
709
|
custom_fields?: {
|
|
1210
710
|
[key: string]: string;
|
|
1211
711
|
};
|
|
@@ -1216,7 +716,7 @@ export declare namespace ContractCreateParams {
|
|
|
1216
716
|
/**
|
|
1217
717
|
* Optional configuration for commit hierarchy access control
|
|
1218
718
|
*/
|
|
1219
|
-
hierarchy_configuration?:
|
|
719
|
+
hierarchy_configuration?: Shared.CommitHierarchyConfiguration;
|
|
1220
720
|
/**
|
|
1221
721
|
* Required for "POSTPAID" commits: the true up invoice will be generated at this
|
|
1222
722
|
* time and only one schedule item is allowed; the total must match access_schedule
|
|
@@ -1252,7 +752,7 @@ export declare namespace ContractCreateParams {
|
|
|
1252
752
|
* specifiers to contribute to a commit's or credit's drawdown. This field cannot
|
|
1253
753
|
* be used together with `applicable_product_ids` or `applicable_product_tags`.
|
|
1254
754
|
*/
|
|
1255
|
-
specifiers?: Array<
|
|
755
|
+
specifiers?: Array<Shared.CommitSpecifierInput>;
|
|
1256
756
|
/**
|
|
1257
757
|
* A temporary ID for the commit that can be used to reference the commit for
|
|
1258
758
|
* commit specific overrides.
|
|
@@ -1285,24 +785,6 @@ export declare namespace ContractCreateParams {
|
|
|
1285
785
|
starting_at: string;
|
|
1286
786
|
}
|
|
1287
787
|
}
|
|
1288
|
-
/**
|
|
1289
|
-
* Optional configuration for commit hierarchy access control
|
|
1290
|
-
*/
|
|
1291
|
-
interface HierarchyConfiguration {
|
|
1292
|
-
child_access: HierarchyConfiguration.CommitHierarchyChildAccessAll | HierarchyConfiguration.CommitHierarchyChildAccessNone | HierarchyConfiguration.CommitHierarchyChildAccessContractIDs;
|
|
1293
|
-
}
|
|
1294
|
-
namespace HierarchyConfiguration {
|
|
1295
|
-
interface CommitHierarchyChildAccessAll {
|
|
1296
|
-
type: 'ALL';
|
|
1297
|
-
}
|
|
1298
|
-
interface CommitHierarchyChildAccessNone {
|
|
1299
|
-
type: 'NONE';
|
|
1300
|
-
}
|
|
1301
|
-
interface CommitHierarchyChildAccessContractIDs {
|
|
1302
|
-
contract_ids: Array<string>;
|
|
1303
|
-
type: 'CONTRACT_IDS';
|
|
1304
|
-
}
|
|
1305
|
-
}
|
|
1306
788
|
/**
|
|
1307
789
|
* Required for "POSTPAID" commits: the true up invoice will be generated at this
|
|
1308
790
|
* time and only one schedule item is allowed; the total must match access_schedule
|
|
@@ -1461,23 +943,6 @@ export declare namespace ContractCreateParams {
|
|
|
1461
943
|
on_session_payment?: boolean;
|
|
1462
944
|
}
|
|
1463
945
|
}
|
|
1464
|
-
interface Specifier {
|
|
1465
|
-
presentation_group_values?: {
|
|
1466
|
-
[key: string]: string;
|
|
1467
|
-
};
|
|
1468
|
-
pricing_group_values?: {
|
|
1469
|
-
[key: string]: string;
|
|
1470
|
-
};
|
|
1471
|
-
/**
|
|
1472
|
-
* If provided, the specifier will only apply to the product with the specified ID.
|
|
1473
|
-
*/
|
|
1474
|
-
product_id?: string;
|
|
1475
|
-
/**
|
|
1476
|
-
* If provided, the specifier will only apply to products with all the specified
|
|
1477
|
-
* tags.
|
|
1478
|
-
*/
|
|
1479
|
-
product_tags?: Array<string>;
|
|
1480
|
-
}
|
|
1481
946
|
}
|
|
1482
947
|
interface Credit {
|
|
1483
948
|
/**
|
|
@@ -1495,6 +960,9 @@ export declare namespace ContractCreateParams {
|
|
|
1495
960
|
* applicable_product_tags are not provided, the credit applies to all products.
|
|
1496
961
|
*/
|
|
1497
962
|
applicable_product_tags?: Array<string>;
|
|
963
|
+
/**
|
|
964
|
+
* Custom fields to be added eg. { "key1": "value1", "key2": "value2" }
|
|
965
|
+
*/
|
|
1498
966
|
custom_fields?: {
|
|
1499
967
|
[key: string]: string;
|
|
1500
968
|
};
|
|
@@ -1505,7 +973,7 @@ export declare namespace ContractCreateParams {
|
|
|
1505
973
|
/**
|
|
1506
974
|
* Optional configuration for credit hierarchy access control
|
|
1507
975
|
*/
|
|
1508
|
-
hierarchy_configuration?:
|
|
976
|
+
hierarchy_configuration?: Shared.CommitHierarchyConfiguration;
|
|
1509
977
|
/**
|
|
1510
978
|
* displayed on invoices
|
|
1511
979
|
*/
|
|
@@ -1526,7 +994,7 @@ export declare namespace ContractCreateParams {
|
|
|
1526
994
|
* specifiers to contribute to a commit's or credit's drawdown. This field cannot
|
|
1527
995
|
* be used together with `applicable_product_ids` or `applicable_product_tags`.
|
|
1528
996
|
*/
|
|
1529
|
-
specifiers?: Array<
|
|
997
|
+
specifiers?: Array<Shared.CommitSpecifierInput>;
|
|
1530
998
|
}
|
|
1531
999
|
namespace Credit {
|
|
1532
1000
|
/**
|
|
@@ -1552,41 +1020,6 @@ export declare namespace ContractCreateParams {
|
|
|
1552
1020
|
starting_at: string;
|
|
1553
1021
|
}
|
|
1554
1022
|
}
|
|
1555
|
-
/**
|
|
1556
|
-
* Optional configuration for credit hierarchy access control
|
|
1557
|
-
*/
|
|
1558
|
-
interface HierarchyConfiguration {
|
|
1559
|
-
child_access: HierarchyConfiguration.CommitHierarchyChildAccessAll | HierarchyConfiguration.CommitHierarchyChildAccessNone | HierarchyConfiguration.CommitHierarchyChildAccessContractIDs;
|
|
1560
|
-
}
|
|
1561
|
-
namespace HierarchyConfiguration {
|
|
1562
|
-
interface CommitHierarchyChildAccessAll {
|
|
1563
|
-
type: 'ALL';
|
|
1564
|
-
}
|
|
1565
|
-
interface CommitHierarchyChildAccessNone {
|
|
1566
|
-
type: 'NONE';
|
|
1567
|
-
}
|
|
1568
|
-
interface CommitHierarchyChildAccessContractIDs {
|
|
1569
|
-
contract_ids: Array<string>;
|
|
1570
|
-
type: 'CONTRACT_IDS';
|
|
1571
|
-
}
|
|
1572
|
-
}
|
|
1573
|
-
interface Specifier {
|
|
1574
|
-
presentation_group_values?: {
|
|
1575
|
-
[key: string]: string;
|
|
1576
|
-
};
|
|
1577
|
-
pricing_group_values?: {
|
|
1578
|
-
[key: string]: string;
|
|
1579
|
-
};
|
|
1580
|
-
/**
|
|
1581
|
-
* If provided, the specifier will only apply to the product with the specified ID.
|
|
1582
|
-
*/
|
|
1583
|
-
product_id?: string;
|
|
1584
|
-
/**
|
|
1585
|
-
* If provided, the specifier will only apply to products with all the specified
|
|
1586
|
-
* tags.
|
|
1587
|
-
*/
|
|
1588
|
-
product_tags?: Array<string>;
|
|
1589
|
-
}
|
|
1590
1023
|
}
|
|
1591
1024
|
interface Discount {
|
|
1592
1025
|
product_id: string;
|
|
@@ -1594,6 +1027,9 @@ export declare namespace ContractCreateParams {
|
|
|
1594
1027
|
* Must provide either schedule_items or recurring_schedule.
|
|
1595
1028
|
*/
|
|
1596
1029
|
schedule: Discount.Schedule;
|
|
1030
|
+
/**
|
|
1031
|
+
* Custom fields to be added eg. { "key1": "value1", "key2": "value2" }
|
|
1032
|
+
*/
|
|
1597
1033
|
custom_fields?: {
|
|
1598
1034
|
[key: string]: string;
|
|
1599
1035
|
};
|
|
@@ -1769,8 +1205,8 @@ export declare namespace ContractCreateParams {
|
|
|
1769
1205
|
billing_frequency?: 'MONTHLY' | 'QUARTERLY' | 'ANNUAL' | 'WEEKLY';
|
|
1770
1206
|
/**
|
|
1771
1207
|
* Can only be used for commit specific overrides. Must be used in conjunction with
|
|
1772
|
-
* one of product_id
|
|
1773
|
-
* presentation_group_values
|
|
1208
|
+
* one of `product_id`, `product_tags`, `pricing_group_values`, or
|
|
1209
|
+
* `presentation_group_values`. If provided, the override will only apply to the
|
|
1774
1210
|
* specified commits. If not provided, the override will apply to all commits.
|
|
1775
1211
|
*/
|
|
1776
1212
|
commit_ids?: Array<string>;
|
|
@@ -1799,187 +1235,54 @@ export declare namespace ContractCreateParams {
|
|
|
1799
1235
|
product_tags?: Array<string>;
|
|
1800
1236
|
/**
|
|
1801
1237
|
* Can only be used for commit specific overrides. Must be used in conjunction with
|
|
1802
|
-
* one of product_id
|
|
1803
|
-
* presentation_group_values
|
|
1804
|
-
* created by the specified recurring commit ids.
|
|
1238
|
+
* one of `product_id`, `product_tags`, `pricing_group_values`, or
|
|
1239
|
+
* `presentation_group_values`. If provided, the override will only apply to
|
|
1240
|
+
* commits created by the specified recurring commit ids.
|
|
1805
1241
|
*/
|
|
1806
1242
|
recurring_commit_ids?: Array<string>;
|
|
1807
1243
|
/**
|
|
1808
|
-
* Can only be used for commit specific overrides. Must be used in conjunction with
|
|
1809
|
-
* one of product_id
|
|
1810
|
-
* presentation_group_values
|
|
1811
|
-
* created by the specified recurring credit ids.
|
|
1812
|
-
*/
|
|
1813
|
-
recurring_credit_ids?: Array<string>;
|
|
1814
|
-
}
|
|
1815
|
-
/**
|
|
1816
|
-
* Required for OVERWRITE type.
|
|
1817
|
-
*/
|
|
1818
|
-
interface OverwriteRate {
|
|
1819
|
-
rate_type: 'FLAT' | 'PERCENTAGE' | 'SUBSCRIPTION' | 'TIERED' | 'CUSTOM';
|
|
1820
|
-
credit_type_id?: string;
|
|
1821
|
-
/**
|
|
1822
|
-
* Only set for CUSTOM rate_type. This field is interpreted by custom rate
|
|
1823
|
-
* processors.
|
|
1824
|
-
*/
|
|
1825
|
-
custom_rate?: {
|
|
1826
|
-
[key: string]: unknown;
|
|
1827
|
-
};
|
|
1828
|
-
/**
|
|
1829
|
-
* Default proration configuration. Only valid for SUBSCRIPTION rate_type. Must be
|
|
1830
|
-
* set to true.
|
|
1831
|
-
*/
|
|
1832
|
-
is_prorated?: boolean;
|
|
1833
|
-
/**
|
|
1834
|
-
* Default price. For FLAT rate_type, this must be >=0. For PERCENTAGE rate_type,
|
|
1835
|
-
* this is a decimal fraction, e.g. use 0.1 for 10%; this must be >=0 and <=1.
|
|
1836
|
-
*/
|
|
1837
|
-
price?: number;
|
|
1838
|
-
/**
|
|
1839
|
-
* Default quantity. For SUBSCRIPTION rate_type, this must be >=0.
|
|
1840
|
-
*/
|
|
1841
|
-
quantity?: number;
|
|
1842
|
-
/**
|
|
1843
|
-
* Only set for TIERED rate_type.
|
|
1844
|
-
*/
|
|
1845
|
-
tiers?: Array<Shared.Tier>;
|
|
1846
|
-
}
|
|
1847
|
-
interface Tier {
|
|
1848
|
-
multiplier: number;
|
|
1849
|
-
size?: number;
|
|
1850
|
-
}
|
|
1851
|
-
}
|
|
1852
|
-
interface PrepaidBalanceThresholdConfiguration {
|
|
1853
|
-
commit: PrepaidBalanceThresholdConfiguration.Commit;
|
|
1854
|
-
/**
|
|
1855
|
-
* When set to false, the contract will not be evaluated against the
|
|
1856
|
-
* threshold_amount. Toggling to true will result an immediate evaluation,
|
|
1857
|
-
* regardless of prior state.
|
|
1858
|
-
*/
|
|
1859
|
-
is_enabled: boolean;
|
|
1860
|
-
payment_gate_config: PrepaidBalanceThresholdConfiguration.PaymentGateConfig;
|
|
1861
|
-
/**
|
|
1862
|
-
* Specify the amount the balance should be recharged to.
|
|
1863
|
-
*/
|
|
1864
|
-
recharge_to_amount: number;
|
|
1865
|
-
/**
|
|
1866
|
-
* Specify the threshold amount for the contract. Each time the contract's prepaid
|
|
1867
|
-
* balance lowers to this amount, a threshold charge will be initiated.
|
|
1868
|
-
*/
|
|
1869
|
-
threshold_amount: number;
|
|
1870
|
-
/**
|
|
1871
|
-
* If provided, the threshold, recharge-to amount, and the resulting threshold
|
|
1872
|
-
* commit amount will be in terms of this credit type instead of the fiat currency.
|
|
1873
|
-
*/
|
|
1874
|
-
custom_credit_type_id?: string;
|
|
1875
|
-
}
|
|
1876
|
-
namespace PrepaidBalanceThresholdConfiguration {
|
|
1877
|
-
interface Commit {
|
|
1878
|
-
/**
|
|
1879
|
-
* The commit product that will be used to generate the line item for commit
|
|
1880
|
-
* payment.
|
|
1881
|
-
*/
|
|
1882
|
-
product_id: string;
|
|
1883
|
-
/**
|
|
1884
|
-
* Which products the threshold commit applies to. If applicable_product_ids,
|
|
1885
|
-
* applicable_product_tags or specifiers are not provided, the commit applies to
|
|
1886
|
-
* all products.
|
|
1887
|
-
*/
|
|
1888
|
-
applicable_product_ids?: Array<string>;
|
|
1889
|
-
/**
|
|
1890
|
-
* Which tags the threshold commit applies to. If applicable_product_ids,
|
|
1891
|
-
* applicable_product_tags or specifiers are not provided, the commit applies to
|
|
1892
|
-
* all products.
|
|
1893
|
-
*/
|
|
1894
|
-
applicable_product_tags?: Array<string>;
|
|
1895
|
-
description?: string;
|
|
1896
|
-
/**
|
|
1897
|
-
* Specify the name of the line item for the threshold charge. If left blank, it
|
|
1898
|
-
* will default to the commit product name.
|
|
1899
|
-
*/
|
|
1900
|
-
name?: string;
|
|
1901
|
-
/**
|
|
1902
|
-
* List of filters that determine what kind of customer usage draws down a commit
|
|
1903
|
-
* or credit. A customer's usage needs to meet the condition of at least one of the
|
|
1904
|
-
* specifiers to contribute to a commit's or credit's drawdown. This field cannot
|
|
1905
|
-
* be used together with `applicable_product_ids` or `applicable_product_tags`.
|
|
1906
|
-
*/
|
|
1907
|
-
specifiers?: Array<Commit.Specifier>;
|
|
1908
|
-
}
|
|
1909
|
-
namespace Commit {
|
|
1910
|
-
interface Specifier {
|
|
1911
|
-
presentation_group_values?: {
|
|
1912
|
-
[key: string]: string;
|
|
1913
|
-
};
|
|
1914
|
-
pricing_group_values?: {
|
|
1915
|
-
[key: string]: string;
|
|
1916
|
-
};
|
|
1917
|
-
/**
|
|
1918
|
-
* If provided, the specifier will only apply to the product with the specified ID.
|
|
1919
|
-
*/
|
|
1920
|
-
product_id?: string;
|
|
1921
|
-
/**
|
|
1922
|
-
* If provided, the specifier will only apply to products with all the specified
|
|
1923
|
-
* tags.
|
|
1924
|
-
*/
|
|
1925
|
-
product_tags?: Array<string>;
|
|
1926
|
-
}
|
|
1927
|
-
}
|
|
1928
|
-
interface PaymentGateConfig {
|
|
1929
|
-
/**
|
|
1930
|
-
* Gate access to the commit balance based on successful collection of payment.
|
|
1931
|
-
* Select STRIPE for Metronome to facilitate payment via Stripe. Select EXTERNAL to
|
|
1932
|
-
* facilitate payment using your own payment integration. Select NONE if you do not
|
|
1933
|
-
* wish to payment gate the commit balance.
|
|
1244
|
+
* Can only be used for commit specific overrides. Must be used in conjunction with
|
|
1245
|
+
* one of `product_id`, `product_tags`, `pricing_group_values`, or
|
|
1246
|
+
* `presentation_group_values`. If provided, the override will only apply to
|
|
1247
|
+
* credits created by the specified recurring credit ids.
|
|
1934
1248
|
*/
|
|
1935
|
-
|
|
1249
|
+
recurring_credit_ids?: Array<string>;
|
|
1250
|
+
}
|
|
1251
|
+
/**
|
|
1252
|
+
* Required for OVERWRITE type.
|
|
1253
|
+
*/
|
|
1254
|
+
interface OverwriteRate {
|
|
1255
|
+
rate_type: 'FLAT' | 'PERCENTAGE' | 'SUBSCRIPTION' | 'TIERED' | 'CUSTOM';
|
|
1256
|
+
credit_type_id?: string;
|
|
1936
1257
|
/**
|
|
1937
|
-
* Only
|
|
1258
|
+
* Only set for CUSTOM rate_type. This field is interpreted by custom rate
|
|
1259
|
+
* processors.
|
|
1938
1260
|
*/
|
|
1939
|
-
|
|
1261
|
+
custom_rate?: {
|
|
1262
|
+
[key: string]: unknown;
|
|
1263
|
+
};
|
|
1940
1264
|
/**
|
|
1941
|
-
*
|
|
1265
|
+
* Default proration configuration. Only valid for SUBSCRIPTION rate_type. Must be
|
|
1266
|
+
* set to true.
|
|
1942
1267
|
*/
|
|
1943
|
-
|
|
1268
|
+
is_prorated?: boolean;
|
|
1944
1269
|
/**
|
|
1945
|
-
*
|
|
1946
|
-
*
|
|
1947
|
-
* will default to NONE.
|
|
1270
|
+
* Default price. For FLAT rate_type, this must be >=0. For PERCENTAGE rate_type,
|
|
1271
|
+
* this is a decimal fraction, e.g. use 0.1 for 10%; this must be >=0 and <=1.
|
|
1948
1272
|
*/
|
|
1949
|
-
|
|
1950
|
-
}
|
|
1951
|
-
namespace PaymentGateConfig {
|
|
1273
|
+
price?: number;
|
|
1952
1274
|
/**
|
|
1953
|
-
*
|
|
1275
|
+
* Default quantity. For SUBSCRIPTION rate_type, this must be >=0.
|
|
1954
1276
|
*/
|
|
1955
|
-
|
|
1956
|
-
/**
|
|
1957
|
-
* Amount of tax to be applied. This should be in the same currency and
|
|
1958
|
-
* denomination as the commit's invoice schedule
|
|
1959
|
-
*/
|
|
1960
|
-
tax_amount: number;
|
|
1961
|
-
/**
|
|
1962
|
-
* Name of the tax to be applied. This may be used in an invoice line item
|
|
1963
|
-
* description.
|
|
1964
|
-
*/
|
|
1965
|
-
tax_name?: string;
|
|
1966
|
-
}
|
|
1277
|
+
quantity?: number;
|
|
1967
1278
|
/**
|
|
1968
|
-
* Only
|
|
1279
|
+
* Only set for TIERED rate_type.
|
|
1969
1280
|
*/
|
|
1970
|
-
|
|
1971
|
-
|
|
1972
|
-
|
|
1973
|
-
|
|
1974
|
-
|
|
1975
|
-
/**
|
|
1976
|
-
* Metadata to be added to the Stripe invoice. Only applicable if using INVOICE as
|
|
1977
|
-
* your payment type.
|
|
1978
|
-
*/
|
|
1979
|
-
invoice_metadata?: {
|
|
1980
|
-
[key: string]: string;
|
|
1981
|
-
};
|
|
1982
|
-
}
|
|
1281
|
+
tiers?: Array<Shared.Tier>;
|
|
1282
|
+
}
|
|
1283
|
+
interface Tier {
|
|
1284
|
+
multiplier: number;
|
|
1285
|
+
size?: number;
|
|
1983
1286
|
}
|
|
1984
1287
|
}
|
|
1985
1288
|
interface ProfessionalService {
|
|
@@ -1998,6 +1301,9 @@ export declare namespace ContractCreateParams {
|
|
|
1998
1301
|
* amount and must be specified.
|
|
1999
1302
|
*/
|
|
2000
1303
|
unit_price: number;
|
|
1304
|
+
/**
|
|
1305
|
+
* Custom fields to be added eg. { "key1": "value1", "key2": "value2" }
|
|
1306
|
+
*/
|
|
2001
1307
|
custom_fields?: {
|
|
2002
1308
|
[key: string]: string;
|
|
2003
1309
|
};
|
|
@@ -2046,7 +1352,7 @@ export declare namespace ContractCreateParams {
|
|
|
2046
1352
|
/**
|
|
2047
1353
|
* Optional configuration for recurring commit/credit hierarchy access control
|
|
2048
1354
|
*/
|
|
2049
|
-
hierarchy_configuration?:
|
|
1355
|
+
hierarchy_configuration?: Shared.CommitHierarchyConfiguration;
|
|
2050
1356
|
/**
|
|
2051
1357
|
* The amount the customer should be billed for the commit. Not required.
|
|
2052
1358
|
*/
|
|
@@ -2088,7 +1394,7 @@ export declare namespace ContractCreateParams {
|
|
|
2088
1394
|
* specifiers to contribute to a commit's or credit's drawdown. This field cannot
|
|
2089
1395
|
* be used together with `applicable_product_ids` or `applicable_product_tags`.
|
|
2090
1396
|
*/
|
|
2091
|
-
specifiers?: Array<
|
|
1397
|
+
specifiers?: Array<Shared.CommitSpecifierInput>;
|
|
2092
1398
|
/**
|
|
2093
1399
|
* Attach a subscription to the recurring commit/credit.
|
|
2094
1400
|
*/
|
|
@@ -2121,24 +1427,6 @@ export declare namespace ContractCreateParams {
|
|
|
2121
1427
|
value: number;
|
|
2122
1428
|
unit?: 'PERIODS';
|
|
2123
1429
|
}
|
|
2124
|
-
/**
|
|
2125
|
-
* Optional configuration for recurring commit/credit hierarchy access control
|
|
2126
|
-
*/
|
|
2127
|
-
interface HierarchyConfiguration {
|
|
2128
|
-
child_access: HierarchyConfiguration.CommitHierarchyChildAccessAll | HierarchyConfiguration.CommitHierarchyChildAccessNone | HierarchyConfiguration.CommitHierarchyChildAccessContractIDs;
|
|
2129
|
-
}
|
|
2130
|
-
namespace HierarchyConfiguration {
|
|
2131
|
-
interface CommitHierarchyChildAccessAll {
|
|
2132
|
-
type: 'ALL';
|
|
2133
|
-
}
|
|
2134
|
-
interface CommitHierarchyChildAccessNone {
|
|
2135
|
-
type: 'NONE';
|
|
2136
|
-
}
|
|
2137
|
-
interface CommitHierarchyChildAccessContractIDs {
|
|
2138
|
-
contract_ids: Array<string>;
|
|
2139
|
-
type: 'CONTRACT_IDS';
|
|
2140
|
-
}
|
|
2141
|
-
}
|
|
2142
1430
|
/**
|
|
2143
1431
|
* The amount the customer should be billed for the commit. Not required.
|
|
2144
1432
|
*/
|
|
@@ -2147,23 +1435,6 @@ export declare namespace ContractCreateParams {
|
|
|
2147
1435
|
quantity: number;
|
|
2148
1436
|
unit_price: number;
|
|
2149
1437
|
}
|
|
2150
|
-
interface Specifier {
|
|
2151
|
-
presentation_group_values?: {
|
|
2152
|
-
[key: string]: string;
|
|
2153
|
-
};
|
|
2154
|
-
pricing_group_values?: {
|
|
2155
|
-
[key: string]: string;
|
|
2156
|
-
};
|
|
2157
|
-
/**
|
|
2158
|
-
* If provided, the specifier will only apply to the product with the specified ID.
|
|
2159
|
-
*/
|
|
2160
|
-
product_id?: string;
|
|
2161
|
-
/**
|
|
2162
|
-
* If provided, the specifier will only apply to products with all the specified
|
|
2163
|
-
* tags.
|
|
2164
|
-
*/
|
|
2165
|
-
product_tags?: Array<string>;
|
|
2166
|
-
}
|
|
2167
1438
|
/**
|
|
2168
1439
|
* Attach a subscription to the recurring commit/credit.
|
|
2169
1440
|
*/
|
|
@@ -2176,7 +1447,7 @@ export declare namespace ContractCreateParams {
|
|
|
2176
1447
|
/**
|
|
2177
1448
|
* If set to POOLED, allocation added per seat is pooled across the account.
|
|
2178
1449
|
*/
|
|
2179
|
-
allocation?: 'POOLED';
|
|
1450
|
+
allocation?: 'INDIVIDUAL' | 'POOLED';
|
|
2180
1451
|
}
|
|
2181
1452
|
namespace SubscriptionConfig {
|
|
2182
1453
|
interface ApplySeatIncreaseConfig {
|
|
@@ -2226,7 +1497,7 @@ export declare namespace ContractCreateParams {
|
|
|
2226
1497
|
/**
|
|
2227
1498
|
* Optional configuration for recurring commit/credit hierarchy access control
|
|
2228
1499
|
*/
|
|
2229
|
-
hierarchy_configuration?:
|
|
1500
|
+
hierarchy_configuration?: Shared.CommitHierarchyConfiguration;
|
|
2230
1501
|
/**
|
|
2231
1502
|
* displayed on invoices. will be passed through to the individual commits
|
|
2232
1503
|
*/
|
|
@@ -2264,7 +1535,7 @@ export declare namespace ContractCreateParams {
|
|
|
2264
1535
|
* specifiers to contribute to a commit's or credit's drawdown. This field cannot
|
|
2265
1536
|
* be used together with `applicable_product_ids` or `applicable_product_tags`.
|
|
2266
1537
|
*/
|
|
2267
|
-
specifiers?: Array<
|
|
1538
|
+
specifiers?: Array<Shared.CommitSpecifierInput>;
|
|
2268
1539
|
/**
|
|
2269
1540
|
* Attach a subscription to the recurring commit/credit.
|
|
2270
1541
|
*/
|
|
@@ -2297,41 +1568,6 @@ export declare namespace ContractCreateParams {
|
|
|
2297
1568
|
value: number;
|
|
2298
1569
|
unit?: 'PERIODS';
|
|
2299
1570
|
}
|
|
2300
|
-
/**
|
|
2301
|
-
* Optional configuration for recurring commit/credit hierarchy access control
|
|
2302
|
-
*/
|
|
2303
|
-
interface HierarchyConfiguration {
|
|
2304
|
-
child_access: HierarchyConfiguration.CommitHierarchyChildAccessAll | HierarchyConfiguration.CommitHierarchyChildAccessNone | HierarchyConfiguration.CommitHierarchyChildAccessContractIDs;
|
|
2305
|
-
}
|
|
2306
|
-
namespace HierarchyConfiguration {
|
|
2307
|
-
interface CommitHierarchyChildAccessAll {
|
|
2308
|
-
type: 'ALL';
|
|
2309
|
-
}
|
|
2310
|
-
interface CommitHierarchyChildAccessNone {
|
|
2311
|
-
type: 'NONE';
|
|
2312
|
-
}
|
|
2313
|
-
interface CommitHierarchyChildAccessContractIDs {
|
|
2314
|
-
contract_ids: Array<string>;
|
|
2315
|
-
type: 'CONTRACT_IDS';
|
|
2316
|
-
}
|
|
2317
|
-
}
|
|
2318
|
-
interface Specifier {
|
|
2319
|
-
presentation_group_values?: {
|
|
2320
|
-
[key: string]: string;
|
|
2321
|
-
};
|
|
2322
|
-
pricing_group_values?: {
|
|
2323
|
-
[key: string]: string;
|
|
2324
|
-
};
|
|
2325
|
-
/**
|
|
2326
|
-
* If provided, the specifier will only apply to the product with the specified ID.
|
|
2327
|
-
*/
|
|
2328
|
-
product_id?: string;
|
|
2329
|
-
/**
|
|
2330
|
-
* If provided, the specifier will only apply to products with all the specified
|
|
2331
|
-
* tags.
|
|
2332
|
-
*/
|
|
2333
|
-
product_tags?: Array<string>;
|
|
2334
|
-
}
|
|
2335
1571
|
/**
|
|
2336
1572
|
* Attach a subscription to the recurring commit/credit.
|
|
2337
1573
|
*/
|
|
@@ -2344,7 +1580,7 @@ export declare namespace ContractCreateParams {
|
|
|
2344
1580
|
/**
|
|
2345
1581
|
* If set to POOLED, allocation added per seat is pooled across the account.
|
|
2346
1582
|
*/
|
|
2347
|
-
allocation?: 'POOLED';
|
|
1583
|
+
allocation?: 'INDIVIDUAL' | 'POOLED';
|
|
2348
1584
|
}
|
|
2349
1585
|
namespace SubscriptionConfig {
|
|
2350
1586
|
interface ApplySeatIncreaseConfig {
|
|
@@ -2390,6 +1626,9 @@ export declare namespace ContractCreateParams {
|
|
|
2390
1626
|
* Must provide either schedule_items or recurring_schedule.
|
|
2391
1627
|
*/
|
|
2392
1628
|
schedule: ScheduledCharge.Schedule;
|
|
1629
|
+
/**
|
|
1630
|
+
* Custom fields to be added eg. { "key1": "value1", "key2": "value2" }
|
|
1631
|
+
*/
|
|
2393
1632
|
custom_fields?: {
|
|
2394
1633
|
[key: string]: string;
|
|
2395
1634
|
};
|
|
@@ -2489,100 +1728,13 @@ export declare namespace ContractCreateParams {
|
|
|
2489
1728
|
}
|
|
2490
1729
|
}
|
|
2491
1730
|
}
|
|
2492
|
-
interface SpendThresholdConfiguration {
|
|
2493
|
-
commit: SpendThresholdConfiguration.Commit;
|
|
2494
|
-
/**
|
|
2495
|
-
* When set to false, the contract will not be evaluated against the
|
|
2496
|
-
* threshold_amount. Toggling to true will result an immediate evaluation,
|
|
2497
|
-
* regardless of prior state.
|
|
2498
|
-
*/
|
|
2499
|
-
is_enabled: boolean;
|
|
2500
|
-
payment_gate_config: SpendThresholdConfiguration.PaymentGateConfig;
|
|
2501
|
-
/**
|
|
2502
|
-
* Specify the threshold amount for the contract. Each time the contract's usage
|
|
2503
|
-
* hits this amount, a threshold charge will be initiated.
|
|
2504
|
-
*/
|
|
2505
|
-
threshold_amount: number;
|
|
2506
|
-
}
|
|
2507
|
-
namespace SpendThresholdConfiguration {
|
|
2508
|
-
interface Commit {
|
|
2509
|
-
/**
|
|
2510
|
-
* The commit product that will be used to generate the line item for commit
|
|
2511
|
-
* payment.
|
|
2512
|
-
*/
|
|
2513
|
-
product_id: string;
|
|
2514
|
-
description?: string;
|
|
2515
|
-
/**
|
|
2516
|
-
* Specify the name of the line item for the threshold charge. If left blank, it
|
|
2517
|
-
* will default to the commit product name.
|
|
2518
|
-
*/
|
|
2519
|
-
name?: string;
|
|
2520
|
-
}
|
|
2521
|
-
interface PaymentGateConfig {
|
|
2522
|
-
/**
|
|
2523
|
-
* Gate access to the commit balance based on successful collection of payment.
|
|
2524
|
-
* Select STRIPE for Metronome to facilitate payment via Stripe. Select EXTERNAL to
|
|
2525
|
-
* facilitate payment using your own payment integration. Select NONE if you do not
|
|
2526
|
-
* wish to payment gate the commit balance.
|
|
2527
|
-
*/
|
|
2528
|
-
payment_gate_type: 'NONE' | 'STRIPE' | 'EXTERNAL';
|
|
2529
|
-
/**
|
|
2530
|
-
* Only applicable if using PRECALCULATED as your tax type.
|
|
2531
|
-
*/
|
|
2532
|
-
precalculated_tax_config?: PaymentGateConfig.PrecalculatedTaxConfig;
|
|
2533
|
-
/**
|
|
2534
|
-
* Only applicable if using STRIPE as your payment gate type.
|
|
2535
|
-
*/
|
|
2536
|
-
stripe_config?: PaymentGateConfig.StripeConfig;
|
|
2537
|
-
/**
|
|
2538
|
-
* Stripe tax is only supported for Stripe payment gateway. Select NONE if you do
|
|
2539
|
-
* not wish Metronome to calculate tax on your behalf. Leaving this field blank
|
|
2540
|
-
* will default to NONE.
|
|
2541
|
-
*/
|
|
2542
|
-
tax_type?: 'NONE' | 'STRIPE' | 'ANROK' | 'PRECALCULATED';
|
|
2543
|
-
}
|
|
2544
|
-
namespace PaymentGateConfig {
|
|
2545
|
-
/**
|
|
2546
|
-
* Only applicable if using PRECALCULATED as your tax type.
|
|
2547
|
-
*/
|
|
2548
|
-
interface PrecalculatedTaxConfig {
|
|
2549
|
-
/**
|
|
2550
|
-
* Amount of tax to be applied. This should be in the same currency and
|
|
2551
|
-
* denomination as the commit's invoice schedule
|
|
2552
|
-
*/
|
|
2553
|
-
tax_amount: number;
|
|
2554
|
-
/**
|
|
2555
|
-
* Name of the tax to be applied. This may be used in an invoice line item
|
|
2556
|
-
* description.
|
|
2557
|
-
*/
|
|
2558
|
-
tax_name?: string;
|
|
2559
|
-
}
|
|
2560
|
-
/**
|
|
2561
|
-
* Only applicable if using STRIPE as your payment gate type.
|
|
2562
|
-
*/
|
|
2563
|
-
interface StripeConfig {
|
|
2564
|
-
/**
|
|
2565
|
-
* If left blank, will default to INVOICE
|
|
2566
|
-
*/
|
|
2567
|
-
payment_type: 'INVOICE' | 'PAYMENT_INTENT';
|
|
2568
|
-
/**
|
|
2569
|
-
* Metadata to be added to the Stripe invoice. Only applicable if using INVOICE as
|
|
2570
|
-
* your payment type.
|
|
2571
|
-
*/
|
|
2572
|
-
invoice_metadata?: {
|
|
2573
|
-
[key: string]: string;
|
|
2574
|
-
};
|
|
2575
|
-
}
|
|
2576
|
-
}
|
|
2577
|
-
}
|
|
2578
1731
|
interface Subscription {
|
|
2579
1732
|
collection_schedule: 'ADVANCE' | 'ARREARS';
|
|
2580
|
-
/**
|
|
2581
|
-
* The initial quantity for the subscription. It must be non-negative value.
|
|
2582
|
-
*/
|
|
2583
|
-
initial_quantity: number;
|
|
2584
1733
|
proration: Subscription.Proration;
|
|
2585
1734
|
subscription_rate: Subscription.SubscriptionRate;
|
|
1735
|
+
/**
|
|
1736
|
+
* Custom fields to be added eg. { "key1": "value1", "key2": "value2" }
|
|
1737
|
+
*/
|
|
2586
1738
|
custom_fields?: {
|
|
2587
1739
|
[key: string]: string;
|
|
2588
1740
|
};
|
|
@@ -2592,7 +1744,19 @@ export declare namespace ContractCreateParams {
|
|
|
2592
1744
|
* contract end date.
|
|
2593
1745
|
*/
|
|
2594
1746
|
ending_before?: string;
|
|
1747
|
+
/**
|
|
1748
|
+
* The initial quantity for the subscription. It must be non-negative value.
|
|
1749
|
+
* Required if quantity_management_mode is QUANTITY_ONLY.
|
|
1750
|
+
*/
|
|
1751
|
+
initial_quantity?: number;
|
|
2595
1752
|
name?: string;
|
|
1753
|
+
/**
|
|
1754
|
+
* Determines how the subscription's quantity is controlled. Defaults to
|
|
1755
|
+
* QUANTITY_ONLY. **QUANTITY_ONLY**: The subscription quantity is specified
|
|
1756
|
+
* directly on the subscription. `initial_quantity` must be provided with this
|
|
1757
|
+
* option. Compatible with recurring commits/credits that use POOLED allocation.
|
|
1758
|
+
*/
|
|
1759
|
+
quantity_management_mode?: 'SEAT_BASED' | 'QUANTITY_ONLY';
|
|
2596
1760
|
/**
|
|
2597
1761
|
* Inclusive start time for the subscription. If not provided, defaults to contract
|
|
2598
1762
|
* start date
|
|
@@ -2760,6 +1924,9 @@ export interface ContractAmendParams {
|
|
|
2760
1924
|
starting_at: string;
|
|
2761
1925
|
commits?: Array<ContractAmendParams.Commit>;
|
|
2762
1926
|
credits?: Array<ContractAmendParams.Credit>;
|
|
1927
|
+
/**
|
|
1928
|
+
* Custom fields to be added eg. { "key1": "value1", "key2": "value2" }
|
|
1929
|
+
*/
|
|
2763
1930
|
custom_fields?: {
|
|
2764
1931
|
[key: string]: string;
|
|
2765
1932
|
};
|
|
@@ -2816,6 +1983,9 @@ export declare namespace ContractAmendParams {
|
|
|
2816
1983
|
* all products.
|
|
2817
1984
|
*/
|
|
2818
1985
|
applicable_product_tags?: Array<string>;
|
|
1986
|
+
/**
|
|
1987
|
+
* Custom fields to be added eg. { "key1": "value1", "key2": "value2" }
|
|
1988
|
+
*/
|
|
2819
1989
|
custom_fields?: {
|
|
2820
1990
|
[key: string]: string;
|
|
2821
1991
|
};
|
|
@@ -2826,7 +1996,7 @@ export declare namespace ContractAmendParams {
|
|
|
2826
1996
|
/**
|
|
2827
1997
|
* Optional configuration for commit hierarchy access control
|
|
2828
1998
|
*/
|
|
2829
|
-
hierarchy_configuration?:
|
|
1999
|
+
hierarchy_configuration?: Shared.CommitHierarchyConfiguration;
|
|
2830
2000
|
/**
|
|
2831
2001
|
* Required for "POSTPAID" commits: the true up invoice will be generated at this
|
|
2832
2002
|
* time and only one schedule item is allowed; the total must match access_schedule
|
|
@@ -2862,7 +2032,7 @@ export declare namespace ContractAmendParams {
|
|
|
2862
2032
|
* specifiers to contribute to a commit's or credit's drawdown. This field cannot
|
|
2863
2033
|
* be used together with `applicable_product_ids` or `applicable_product_tags`.
|
|
2864
2034
|
*/
|
|
2865
|
-
specifiers?: Array<
|
|
2035
|
+
specifiers?: Array<Shared.CommitSpecifierInput>;
|
|
2866
2036
|
/**
|
|
2867
2037
|
* A temporary ID for the commit that can be used to reference the commit for
|
|
2868
2038
|
* commit specific overrides.
|
|
@@ -2895,24 +2065,6 @@ export declare namespace ContractAmendParams {
|
|
|
2895
2065
|
starting_at: string;
|
|
2896
2066
|
}
|
|
2897
2067
|
}
|
|
2898
|
-
/**
|
|
2899
|
-
* Optional configuration for commit hierarchy access control
|
|
2900
|
-
*/
|
|
2901
|
-
interface HierarchyConfiguration {
|
|
2902
|
-
child_access: HierarchyConfiguration.CommitHierarchyChildAccessAll | HierarchyConfiguration.CommitHierarchyChildAccessNone | HierarchyConfiguration.CommitHierarchyChildAccessContractIDs;
|
|
2903
|
-
}
|
|
2904
|
-
namespace HierarchyConfiguration {
|
|
2905
|
-
interface CommitHierarchyChildAccessAll {
|
|
2906
|
-
type: 'ALL';
|
|
2907
|
-
}
|
|
2908
|
-
interface CommitHierarchyChildAccessNone {
|
|
2909
|
-
type: 'NONE';
|
|
2910
|
-
}
|
|
2911
|
-
interface CommitHierarchyChildAccessContractIDs {
|
|
2912
|
-
contract_ids: Array<string>;
|
|
2913
|
-
type: 'CONTRACT_IDS';
|
|
2914
|
-
}
|
|
2915
|
-
}
|
|
2916
2068
|
/**
|
|
2917
2069
|
* Required for "POSTPAID" commits: the true up invoice will be generated at this
|
|
2918
2070
|
* time and only one schedule item is allowed; the total must match access_schedule
|
|
@@ -3071,23 +2223,6 @@ export declare namespace ContractAmendParams {
|
|
|
3071
2223
|
on_session_payment?: boolean;
|
|
3072
2224
|
}
|
|
3073
2225
|
}
|
|
3074
|
-
interface Specifier {
|
|
3075
|
-
presentation_group_values?: {
|
|
3076
|
-
[key: string]: string;
|
|
3077
|
-
};
|
|
3078
|
-
pricing_group_values?: {
|
|
3079
|
-
[key: string]: string;
|
|
3080
|
-
};
|
|
3081
|
-
/**
|
|
3082
|
-
* If provided, the specifier will only apply to the product with the specified ID.
|
|
3083
|
-
*/
|
|
3084
|
-
product_id?: string;
|
|
3085
|
-
/**
|
|
3086
|
-
* If provided, the specifier will only apply to products with all the specified
|
|
3087
|
-
* tags.
|
|
3088
|
-
*/
|
|
3089
|
-
product_tags?: Array<string>;
|
|
3090
|
-
}
|
|
3091
2226
|
}
|
|
3092
2227
|
interface Credit {
|
|
3093
2228
|
/**
|
|
@@ -3105,6 +2240,9 @@ export declare namespace ContractAmendParams {
|
|
|
3105
2240
|
* applicable_product_tags are not provided, the credit applies to all products.
|
|
3106
2241
|
*/
|
|
3107
2242
|
applicable_product_tags?: Array<string>;
|
|
2243
|
+
/**
|
|
2244
|
+
* Custom fields to be added eg. { "key1": "value1", "key2": "value2" }
|
|
2245
|
+
*/
|
|
3108
2246
|
custom_fields?: {
|
|
3109
2247
|
[key: string]: string;
|
|
3110
2248
|
};
|
|
@@ -3115,7 +2253,7 @@ export declare namespace ContractAmendParams {
|
|
|
3115
2253
|
/**
|
|
3116
2254
|
* Optional configuration for credit hierarchy access control
|
|
3117
2255
|
*/
|
|
3118
|
-
hierarchy_configuration?:
|
|
2256
|
+
hierarchy_configuration?: Shared.CommitHierarchyConfiguration;
|
|
3119
2257
|
/**
|
|
3120
2258
|
* displayed on invoices
|
|
3121
2259
|
*/
|
|
@@ -3136,7 +2274,7 @@ export declare namespace ContractAmendParams {
|
|
|
3136
2274
|
* specifiers to contribute to a commit's or credit's drawdown. This field cannot
|
|
3137
2275
|
* be used together with `applicable_product_ids` or `applicable_product_tags`.
|
|
3138
2276
|
*/
|
|
3139
|
-
specifiers?: Array<
|
|
2277
|
+
specifiers?: Array<Shared.CommitSpecifierInput>;
|
|
3140
2278
|
}
|
|
3141
2279
|
namespace Credit {
|
|
3142
2280
|
/**
|
|
@@ -3162,41 +2300,6 @@ export declare namespace ContractAmendParams {
|
|
|
3162
2300
|
starting_at: string;
|
|
3163
2301
|
}
|
|
3164
2302
|
}
|
|
3165
|
-
/**
|
|
3166
|
-
* Optional configuration for credit hierarchy access control
|
|
3167
|
-
*/
|
|
3168
|
-
interface HierarchyConfiguration {
|
|
3169
|
-
child_access: HierarchyConfiguration.CommitHierarchyChildAccessAll | HierarchyConfiguration.CommitHierarchyChildAccessNone | HierarchyConfiguration.CommitHierarchyChildAccessContractIDs;
|
|
3170
|
-
}
|
|
3171
|
-
namespace HierarchyConfiguration {
|
|
3172
|
-
interface CommitHierarchyChildAccessAll {
|
|
3173
|
-
type: 'ALL';
|
|
3174
|
-
}
|
|
3175
|
-
interface CommitHierarchyChildAccessNone {
|
|
3176
|
-
type: 'NONE';
|
|
3177
|
-
}
|
|
3178
|
-
interface CommitHierarchyChildAccessContractIDs {
|
|
3179
|
-
contract_ids: Array<string>;
|
|
3180
|
-
type: 'CONTRACT_IDS';
|
|
3181
|
-
}
|
|
3182
|
-
}
|
|
3183
|
-
interface Specifier {
|
|
3184
|
-
presentation_group_values?: {
|
|
3185
|
-
[key: string]: string;
|
|
3186
|
-
};
|
|
3187
|
-
pricing_group_values?: {
|
|
3188
|
-
[key: string]: string;
|
|
3189
|
-
};
|
|
3190
|
-
/**
|
|
3191
|
-
* If provided, the specifier will only apply to the product with the specified ID.
|
|
3192
|
-
*/
|
|
3193
|
-
product_id?: string;
|
|
3194
|
-
/**
|
|
3195
|
-
* If provided, the specifier will only apply to products with all the specified
|
|
3196
|
-
* tags.
|
|
3197
|
-
*/
|
|
3198
|
-
product_tags?: Array<string>;
|
|
3199
|
-
}
|
|
3200
2303
|
}
|
|
3201
2304
|
interface Discount {
|
|
3202
2305
|
product_id: string;
|
|
@@ -3204,6 +2307,9 @@ export declare namespace ContractAmendParams {
|
|
|
3204
2307
|
* Must provide either schedule_items or recurring_schedule.
|
|
3205
2308
|
*/
|
|
3206
2309
|
schedule: Discount.Schedule;
|
|
2310
|
+
/**
|
|
2311
|
+
* Custom fields to be added eg. { "key1": "value1", "key2": "value2" }
|
|
2312
|
+
*/
|
|
3207
2313
|
custom_fields?: {
|
|
3208
2314
|
[key: string]: string;
|
|
3209
2315
|
};
|
|
@@ -3370,8 +2476,8 @@ export declare namespace ContractAmendParams {
|
|
|
3370
2476
|
billing_frequency?: 'MONTHLY' | 'QUARTERLY' | 'ANNUAL' | 'WEEKLY';
|
|
3371
2477
|
/**
|
|
3372
2478
|
* Can only be used for commit specific overrides. Must be used in conjunction with
|
|
3373
|
-
* one of product_id
|
|
3374
|
-
* presentation_group_values
|
|
2479
|
+
* one of `product_id`, `product_tags`, `pricing_group_values`, or
|
|
2480
|
+
* `presentation_group_values`. If provided, the override will only apply to the
|
|
3375
2481
|
* specified commits. If not provided, the override will apply to all commits.
|
|
3376
2482
|
*/
|
|
3377
2483
|
commit_ids?: Array<string>;
|
|
@@ -3400,16 +2506,16 @@ export declare namespace ContractAmendParams {
|
|
|
3400
2506
|
product_tags?: Array<string>;
|
|
3401
2507
|
/**
|
|
3402
2508
|
* Can only be used for commit specific overrides. Must be used in conjunction with
|
|
3403
|
-
* one of product_id
|
|
3404
|
-
* presentation_group_values
|
|
3405
|
-
* created by the specified recurring commit ids.
|
|
2509
|
+
* one of `product_id`, `product_tags`, `pricing_group_values`, or
|
|
2510
|
+
* `presentation_group_values`. If provided, the override will only apply to
|
|
2511
|
+
* commits created by the specified recurring commit ids.
|
|
3406
2512
|
*/
|
|
3407
2513
|
recurring_commit_ids?: Array<string>;
|
|
3408
2514
|
/**
|
|
3409
2515
|
* Can only be used for commit specific overrides. Must be used in conjunction with
|
|
3410
|
-
* one of product_id
|
|
3411
|
-
* presentation_group_values
|
|
3412
|
-
* created by the specified recurring credit ids.
|
|
2516
|
+
* one of `product_id`, `product_tags`, `pricing_group_values`, or
|
|
2517
|
+
* `presentation_group_values`. If provided, the override will only apply to
|
|
2518
|
+
* credits created by the specified recurring credit ids.
|
|
3413
2519
|
*/
|
|
3414
2520
|
recurring_credit_ids?: Array<string>;
|
|
3415
2521
|
}
|
|
@@ -3466,6 +2572,9 @@ export declare namespace ContractAmendParams {
|
|
|
3466
2572
|
* amount and must be specified.
|
|
3467
2573
|
*/
|
|
3468
2574
|
unit_price: number;
|
|
2575
|
+
/**
|
|
2576
|
+
* Custom fields to be added eg. { "key1": "value1", "key2": "value2" }
|
|
2577
|
+
*/
|
|
3469
2578
|
custom_fields?: {
|
|
3470
2579
|
[key: string]: string;
|
|
3471
2580
|
};
|
|
@@ -3513,6 +2622,9 @@ export declare namespace ContractAmendParams {
|
|
|
3513
2622
|
* Must provide either schedule_items or recurring_schedule.
|
|
3514
2623
|
*/
|
|
3515
2624
|
schedule: ScheduledCharge.Schedule;
|
|
2625
|
+
/**
|
|
2626
|
+
* Custom fields to be added eg. { "key1": "value1", "key2": "value2" }
|
|
2627
|
+
*/
|
|
3516
2628
|
custom_fields?: {
|
|
3517
2629
|
[key: string]: string;
|
|
3518
2630
|
};
|
|
@@ -3646,6 +2758,9 @@ export declare namespace ContractCreateHistoricalInvoicesParams {
|
|
|
3646
2758
|
*/
|
|
3647
2759
|
billable_status?: 'billable' | 'unbillable';
|
|
3648
2760
|
breakdown_granularity?: 'HOUR' | 'DAY';
|
|
2761
|
+
/**
|
|
2762
|
+
* Custom fields to be added eg. { "key1": "value1", "key2": "value2" }
|
|
2763
|
+
*/
|
|
3649
2764
|
custom_fields?: {
|
|
3650
2765
|
[key: string]: string;
|
|
3651
2766
|
};
|
|
@@ -3673,7 +2788,7 @@ export declare namespace ContractCreateHistoricalInvoicesParams {
|
|
|
3673
2788
|
}
|
|
3674
2789
|
}
|
|
3675
2790
|
}
|
|
3676
|
-
export interface ContractListBalancesParams {
|
|
2791
|
+
export interface ContractListBalancesParams extends BodyCursorPageParams {
|
|
3677
2792
|
customer_id: string;
|
|
3678
2793
|
id?: string;
|
|
3679
2794
|
/**
|
|
@@ -3702,14 +2817,6 @@ export interface ContractListBalancesParams {
|
|
|
3702
2817
|
* slower.
|
|
3703
2818
|
*/
|
|
3704
2819
|
include_ledgers?: boolean;
|
|
3705
|
-
/**
|
|
3706
|
-
* The maximum number of commits to return. Defaults to 25.
|
|
3707
|
-
*/
|
|
3708
|
-
limit?: number;
|
|
3709
|
-
/**
|
|
3710
|
-
* The next page token from a previous response.
|
|
3711
|
-
*/
|
|
3712
|
-
next_page?: string;
|
|
3713
2820
|
/**
|
|
3714
2821
|
* Include only balances that have any access on or after the provided date
|
|
3715
2822
|
*/
|
|
@@ -3869,9 +2976,9 @@ export interface ContractUpdateEndDateParams {
|
|
|
3869
2976
|
ending_before?: string;
|
|
3870
2977
|
}
|
|
3871
2978
|
export declare namespace Contracts {
|
|
3872
|
-
export { type ContractCreateResponse as ContractCreateResponse, type ContractRetrieveResponse as ContractRetrieveResponse, type ContractListResponse as ContractListResponse, type ContractAmendResponse as ContractAmendResponse, type ContractArchiveResponse as ContractArchiveResponse, type ContractCreateHistoricalInvoicesResponse as ContractCreateHistoricalInvoicesResponse, type ContractListBalancesResponse as ContractListBalancesResponse, type ContractRetrieveRateScheduleResponse as ContractRetrieveRateScheduleResponse, type ContractRetrieveSubscriptionQuantityHistoryResponse as ContractRetrieveSubscriptionQuantityHistoryResponse, type ContractScheduleProServicesInvoiceResponse as ContractScheduleProServicesInvoiceResponse, type ContractUpdateEndDateResponse as ContractUpdateEndDateResponse, type ContractCreateParams as ContractCreateParams, type ContractRetrieveParams as ContractRetrieveParams, type ContractListParams as ContractListParams, type ContractAddManualBalanceEntryParams as ContractAddManualBalanceEntryParams, type ContractAmendParams as ContractAmendParams, type ContractArchiveParams as ContractArchiveParams, type ContractCreateHistoricalInvoicesParams as ContractCreateHistoricalInvoicesParams, type ContractListBalancesParams as ContractListBalancesParams, type ContractRetrieveRateScheduleParams as ContractRetrieveRateScheduleParams, type ContractRetrieveSubscriptionQuantityHistoryParams as ContractRetrieveSubscriptionQuantityHistoryParams, type ContractScheduleProServicesInvoiceParams as ContractScheduleProServicesInvoiceParams, type ContractSetUsageFilterParams as ContractSetUsageFilterParams, type ContractUpdateEndDateParams as ContractUpdateEndDateParams, };
|
|
3873
|
-
export { Products as Products, type ProductListItemState as ProductListItemState, type QuantityConversion as QuantityConversion, type QuantityRounding as QuantityRounding, type ProductCreateResponse as ProductCreateResponse, type ProductRetrieveResponse as ProductRetrieveResponse, type ProductUpdateResponse as ProductUpdateResponse, type ProductListResponse as ProductListResponse, type ProductArchiveResponse as ProductArchiveResponse, ProductListResponsesCursorPage as ProductListResponsesCursorPage, type ProductCreateParams as ProductCreateParams, type ProductRetrieveParams as ProductRetrieveParams, type ProductUpdateParams as ProductUpdateParams, type ProductListParams as ProductListParams, type ProductArchiveParams as ProductArchiveParams, };
|
|
3874
|
-
export { RateCards as RateCards, type RateCardCreateResponse as RateCardCreateResponse, type RateCardRetrieveResponse as RateCardRetrieveResponse, type RateCardUpdateResponse as RateCardUpdateResponse, type RateCardListResponse as RateCardListResponse, type RateCardArchiveResponse as RateCardArchiveResponse, type RateCardRetrieveRateScheduleResponse as RateCardRetrieveRateScheduleResponse, RateCardListResponsesCursorPage as RateCardListResponsesCursorPage, type RateCardCreateParams as RateCardCreateParams, type RateCardRetrieveParams as RateCardRetrieveParams, type RateCardUpdateParams as RateCardUpdateParams, type RateCardListParams as RateCardListParams, type RateCardArchiveParams as RateCardArchiveParams, type RateCardRetrieveRateScheduleParams as RateCardRetrieveRateScheduleParams, };
|
|
2979
|
+
export { type ContractCreateResponse as ContractCreateResponse, type ContractRetrieveResponse as ContractRetrieveResponse, type ContractListResponse as ContractListResponse, type ContractAmendResponse as ContractAmendResponse, type ContractArchiveResponse as ContractArchiveResponse, type ContractCreateHistoricalInvoicesResponse as ContractCreateHistoricalInvoicesResponse, type ContractListBalancesResponse as ContractListBalancesResponse, type ContractRetrieveRateScheduleResponse as ContractRetrieveRateScheduleResponse, type ContractRetrieveSubscriptionQuantityHistoryResponse as ContractRetrieveSubscriptionQuantityHistoryResponse, type ContractScheduleProServicesInvoiceResponse as ContractScheduleProServicesInvoiceResponse, type ContractUpdateEndDateResponse as ContractUpdateEndDateResponse, type ContractListBalancesResponsesBodyCursorPage as ContractListBalancesResponsesBodyCursorPage, type ContractCreateParams as ContractCreateParams, type ContractRetrieveParams as ContractRetrieveParams, type ContractListParams as ContractListParams, type ContractAddManualBalanceEntryParams as ContractAddManualBalanceEntryParams, type ContractAmendParams as ContractAmendParams, type ContractArchiveParams as ContractArchiveParams, type ContractCreateHistoricalInvoicesParams as ContractCreateHistoricalInvoicesParams, type ContractListBalancesParams as ContractListBalancesParams, type ContractRetrieveRateScheduleParams as ContractRetrieveRateScheduleParams, type ContractRetrieveSubscriptionQuantityHistoryParams as ContractRetrieveSubscriptionQuantityHistoryParams, type ContractScheduleProServicesInvoiceParams as ContractScheduleProServicesInvoiceParams, type ContractSetUsageFilterParams as ContractSetUsageFilterParams, type ContractUpdateEndDateParams as ContractUpdateEndDateParams, };
|
|
2980
|
+
export { Products as Products, type ProductListItemState as ProductListItemState, type QuantityConversion as QuantityConversion, type QuantityRounding as QuantityRounding, type ProductCreateResponse as ProductCreateResponse, type ProductRetrieveResponse as ProductRetrieveResponse, type ProductUpdateResponse as ProductUpdateResponse, type ProductListResponse as ProductListResponse, type ProductArchiveResponse as ProductArchiveResponse, type ProductListResponsesCursorPage as ProductListResponsesCursorPage, type ProductCreateParams as ProductCreateParams, type ProductRetrieveParams as ProductRetrieveParams, type ProductUpdateParams as ProductUpdateParams, type ProductListParams as ProductListParams, type ProductArchiveParams as ProductArchiveParams, };
|
|
2981
|
+
export { RateCards as RateCards, type RateCardCreateResponse as RateCardCreateResponse, type RateCardRetrieveResponse as RateCardRetrieveResponse, type RateCardUpdateResponse as RateCardUpdateResponse, type RateCardListResponse as RateCardListResponse, type RateCardArchiveResponse as RateCardArchiveResponse, type RateCardRetrieveRateScheduleResponse as RateCardRetrieveRateScheduleResponse, type RateCardListResponsesCursorPage as RateCardListResponsesCursorPage, type RateCardCreateParams as RateCardCreateParams, type RateCardRetrieveParams as RateCardRetrieveParams, type RateCardUpdateParams as RateCardUpdateParams, type RateCardListParams as RateCardListParams, type RateCardArchiveParams as RateCardArchiveParams, type RateCardRetrieveRateScheduleParams as RateCardRetrieveRateScheduleParams, };
|
|
3875
2982
|
export { NamedSchedules as NamedSchedules, type NamedScheduleRetrieveResponse as NamedScheduleRetrieveResponse, type NamedScheduleRetrieveParams as NamedScheduleRetrieveParams, type NamedScheduleUpdateParams as NamedScheduleUpdateParams, };
|
|
3876
2983
|
}
|
|
3877
2984
|
//# sourceMappingURL=contracts.d.ts.map
|