@metronome/sdk 2.2.0 → 3.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +188 -0
- package/LICENSE +1 -1
- package/README.md +26 -4
- package/client.d.mts +5 -3
- package/client.d.mts.map +1 -1
- package/client.d.ts +5 -3
- package/client.d.ts.map +1 -1
- package/client.js +26 -10
- package/client.js.map +1 -1
- package/client.mjs +26 -10
- package/client.mjs.map +1 -1
- package/internal/parse.d.mts.map +1 -1
- package/internal/parse.d.ts.map +1 -1
- package/internal/parse.js +5 -0
- package/internal/parse.js.map +1 -1
- package/internal/parse.mjs +5 -0
- package/internal/parse.mjs.map +1 -1
- package/internal/tslib.js +17 -17
- package/internal/utils/query.d.mts +2 -0
- package/internal/utils/query.d.mts.map +1 -0
- package/internal/utils/query.d.ts +2 -0
- package/internal/utils/query.d.ts.map +1 -0
- package/internal/utils/query.js +10 -0
- package/internal/utils/query.js.map +1 -0
- package/internal/utils/query.mjs +6 -0
- package/internal/utils/query.mjs.map +1 -0
- package/internal/utils.d.mts +1 -0
- package/internal/utils.d.ts +1 -0
- package/internal/utils.js +1 -0
- package/internal/utils.js.map +1 -1
- package/internal/utils.mjs +1 -0
- package/package.json +12 -1
- package/resources/shared.d.mts +111 -30
- package/resources/shared.d.mts.map +1 -1
- package/resources/shared.d.ts +111 -30
- package/resources/shared.d.ts.map +1 -1
- package/resources/v1/alerts.d.mts +3 -0
- package/resources/v1/alerts.d.mts.map +1 -1
- package/resources/v1/alerts.d.ts +3 -0
- package/resources/v1/alerts.d.ts.map +1 -1
- package/resources/v1/alerts.js +3 -0
- package/resources/v1/alerts.js.map +1 -1
- package/resources/v1/alerts.mjs +3 -0
- package/resources/v1/alerts.mjs.map +1 -1
- package/resources/v1/audit-logs.d.mts +3 -0
- package/resources/v1/audit-logs.d.mts.map +1 -1
- package/resources/v1/audit-logs.d.ts +3 -0
- package/resources/v1/audit-logs.d.ts.map +1 -1
- package/resources/v1/audit-logs.js +3 -0
- package/resources/v1/audit-logs.js.map +1 -1
- package/resources/v1/audit-logs.mjs +3 -0
- package/resources/v1/audit-logs.mjs.map +1 -1
- package/resources/v1/billable-metrics.d.mts +3 -0
- package/resources/v1/billable-metrics.d.mts.map +1 -1
- package/resources/v1/billable-metrics.d.ts +3 -0
- package/resources/v1/billable-metrics.d.ts.map +1 -1
- package/resources/v1/billable-metrics.js +3 -0
- package/resources/v1/billable-metrics.js.map +1 -1
- package/resources/v1/billable-metrics.mjs +3 -0
- package/resources/v1/billable-metrics.mjs.map +1 -1
- package/resources/v1/contracts/contracts.d.mts +134 -14
- package/resources/v1/contracts/contracts.d.mts.map +1 -1
- package/resources/v1/contracts/contracts.d.ts +134 -14
- package/resources/v1/contracts/contracts.d.ts.map +1 -1
- package/resources/v1/contracts/contracts.js +69 -0
- package/resources/v1/contracts/contracts.js.map +1 -1
- package/resources/v1/contracts/contracts.mjs +69 -0
- package/resources/v1/contracts/contracts.mjs.map +1 -1
- package/resources/v1/contracts/index.d.mts +1 -1
- package/resources/v1/contracts/index.d.mts.map +1 -1
- package/resources/v1/contracts/index.d.ts +1 -1
- package/resources/v1/contracts/index.d.ts.map +1 -1
- package/resources/v1/contracts/index.js.map +1 -1
- package/resources/v1/contracts/index.mjs.map +1 -1
- package/resources/v1/contracts/named-schedules.d.mts +3 -0
- package/resources/v1/contracts/named-schedules.d.mts.map +1 -1
- package/resources/v1/contracts/named-schedules.d.ts +3 -0
- package/resources/v1/contracts/named-schedules.d.ts.map +1 -1
- package/resources/v1/contracts/named-schedules.js +3 -0
- package/resources/v1/contracts/named-schedules.js.map +1 -1
- package/resources/v1/contracts/named-schedules.mjs +3 -0
- package/resources/v1/contracts/named-schedules.mjs.map +1 -1
- package/resources/v1/contracts/products.d.mts +3 -0
- package/resources/v1/contracts/products.d.mts.map +1 -1
- package/resources/v1/contracts/products.d.ts +3 -0
- package/resources/v1/contracts/products.d.ts.map +1 -1
- package/resources/v1/contracts/products.js +3 -0
- package/resources/v1/contracts/products.js.map +1 -1
- package/resources/v1/contracts/products.mjs +3 -0
- package/resources/v1/contracts/products.mjs.map +1 -1
- package/resources/v1/contracts/rate-cards/named-schedules.d.mts +3 -0
- package/resources/v1/contracts/rate-cards/named-schedules.d.mts.map +1 -1
- package/resources/v1/contracts/rate-cards/named-schedules.d.ts +3 -0
- package/resources/v1/contracts/rate-cards/named-schedules.d.ts.map +1 -1
- package/resources/v1/contracts/rate-cards/named-schedules.js +3 -0
- package/resources/v1/contracts/rate-cards/named-schedules.js.map +1 -1
- package/resources/v1/contracts/rate-cards/named-schedules.mjs +3 -0
- package/resources/v1/contracts/rate-cards/named-schedules.mjs.map +1 -1
- package/resources/v1/contracts/rate-cards/product-orders.d.mts +3 -0
- package/resources/v1/contracts/rate-cards/product-orders.d.mts.map +1 -1
- package/resources/v1/contracts/rate-cards/product-orders.d.ts +3 -0
- package/resources/v1/contracts/rate-cards/product-orders.d.ts.map +1 -1
- package/resources/v1/contracts/rate-cards/product-orders.js +3 -0
- package/resources/v1/contracts/rate-cards/product-orders.js.map +1 -1
- package/resources/v1/contracts/rate-cards/product-orders.mjs +3 -0
- package/resources/v1/contracts/rate-cards/product-orders.mjs.map +1 -1
- package/resources/v1/contracts/rate-cards/rate-cards.d.mts +4 -1
- package/resources/v1/contracts/rate-cards/rate-cards.d.mts.map +1 -1
- package/resources/v1/contracts/rate-cards/rate-cards.d.ts +4 -1
- package/resources/v1/contracts/rate-cards/rate-cards.d.ts.map +1 -1
- package/resources/v1/contracts/rate-cards/rate-cards.js +3 -0
- package/resources/v1/contracts/rate-cards/rate-cards.js.map +1 -1
- package/resources/v1/contracts/rate-cards/rate-cards.mjs +3 -0
- package/resources/v1/contracts/rate-cards/rate-cards.mjs.map +1 -1
- package/resources/v1/contracts/rate-cards/rates.d.mts +6 -21
- package/resources/v1/contracts/rate-cards/rates.d.mts.map +1 -1
- package/resources/v1/contracts/rate-cards/rates.d.ts +6 -21
- package/resources/v1/contracts/rate-cards/rates.d.ts.map +1 -1
- package/resources/v1/contracts/rate-cards/rates.js +3 -0
- package/resources/v1/contracts/rate-cards/rates.js.map +1 -1
- package/resources/v1/contracts/rate-cards/rates.mjs +3 -0
- package/resources/v1/contracts/rate-cards/rates.mjs.map +1 -1
- package/resources/v1/credit-grants.d.mts +3 -0
- package/resources/v1/credit-grants.d.mts.map +1 -1
- package/resources/v1/credit-grants.d.ts +3 -0
- package/resources/v1/credit-grants.d.ts.map +1 -1
- package/resources/v1/credit-grants.js +3 -0
- package/resources/v1/credit-grants.js.map +1 -1
- package/resources/v1/credit-grants.mjs +3 -0
- package/resources/v1/credit-grants.mjs.map +1 -1
- package/resources/v1/custom-fields.d.mts +9 -6
- package/resources/v1/custom-fields.d.mts.map +1 -1
- package/resources/v1/custom-fields.d.ts +9 -6
- package/resources/v1/custom-fields.d.ts.map +1 -1
- package/resources/v1/custom-fields.js +3 -0
- package/resources/v1/custom-fields.js.map +1 -1
- package/resources/v1/custom-fields.mjs +3 -0
- package/resources/v1/custom-fields.mjs.map +1 -1
- package/resources/v1/customers/alerts.d.mts +3 -0
- package/resources/v1/customers/alerts.d.mts.map +1 -1
- package/resources/v1/customers/alerts.d.ts +3 -0
- package/resources/v1/customers/alerts.d.ts.map +1 -1
- package/resources/v1/customers/alerts.js +3 -0
- package/resources/v1/customers/alerts.js.map +1 -1
- package/resources/v1/customers/alerts.mjs +3 -0
- package/resources/v1/customers/alerts.mjs.map +1 -1
- package/resources/v1/customers/billing-config.d.mts +8 -5
- package/resources/v1/customers/billing-config.d.mts.map +1 -1
- package/resources/v1/customers/billing-config.d.ts +8 -5
- package/resources/v1/customers/billing-config.d.ts.map +1 -1
- package/resources/v1/customers/billing-config.js +3 -0
- package/resources/v1/customers/billing-config.js.map +1 -1
- package/resources/v1/customers/billing-config.mjs +3 -0
- package/resources/v1/customers/billing-config.mjs.map +1 -1
- package/resources/v1/customers/commits.d.mts +3 -0
- package/resources/v1/customers/commits.d.mts.map +1 -1
- package/resources/v1/customers/commits.d.ts +3 -0
- package/resources/v1/customers/commits.d.ts.map +1 -1
- package/resources/v1/customers/commits.js +3 -0
- package/resources/v1/customers/commits.js.map +1 -1
- package/resources/v1/customers/commits.mjs +3 -0
- package/resources/v1/customers/commits.mjs.map +1 -1
- package/resources/v1/customers/credits.d.mts +3 -0
- package/resources/v1/customers/credits.d.mts.map +1 -1
- package/resources/v1/customers/credits.d.ts +3 -0
- package/resources/v1/customers/credits.d.ts.map +1 -1
- package/resources/v1/customers/credits.js +3 -0
- package/resources/v1/customers/credits.js.map +1 -1
- package/resources/v1/customers/credits.mjs +3 -0
- package/resources/v1/customers/credits.mjs.map +1 -1
- package/resources/v1/customers/customers.d.mts +84 -8
- package/resources/v1/customers/customers.d.mts.map +1 -1
- package/resources/v1/customers/customers.d.ts +84 -8
- package/resources/v1/customers/customers.d.ts.map +1 -1
- package/resources/v1/customers/customers.js +53 -0
- package/resources/v1/customers/customers.js.map +1 -1
- package/resources/v1/customers/customers.mjs +53 -0
- package/resources/v1/customers/customers.mjs.map +1 -1
- package/resources/v1/customers/index.d.mts +1 -1
- package/resources/v1/customers/index.d.mts.map +1 -1
- package/resources/v1/customers/index.d.ts +1 -1
- package/resources/v1/customers/index.d.ts.map +1 -1
- package/resources/v1/customers/index.js.map +1 -1
- package/resources/v1/customers/index.mjs.map +1 -1
- package/resources/v1/customers/invoices.d.mts +38 -19
- package/resources/v1/customers/invoices.d.mts.map +1 -1
- package/resources/v1/customers/invoices.d.ts +38 -19
- package/resources/v1/customers/invoices.d.ts.map +1 -1
- package/resources/v1/customers/invoices.js +3 -0
- package/resources/v1/customers/invoices.js.map +1 -1
- package/resources/v1/customers/invoices.mjs +3 -0
- package/resources/v1/customers/invoices.mjs.map +1 -1
- package/resources/v1/customers/named-schedules.d.mts +3 -0
- package/resources/v1/customers/named-schedules.d.mts.map +1 -1
- package/resources/v1/customers/named-schedules.d.ts +3 -0
- package/resources/v1/customers/named-schedules.d.ts.map +1 -1
- package/resources/v1/customers/named-schedules.js +3 -0
- package/resources/v1/customers/named-schedules.js.map +1 -1
- package/resources/v1/customers/named-schedules.mjs +3 -0
- package/resources/v1/customers/named-schedules.mjs.map +1 -1
- package/resources/v1/customers/plans.d.mts +8 -5
- package/resources/v1/customers/plans.d.mts.map +1 -1
- package/resources/v1/customers/plans.d.ts +8 -5
- package/resources/v1/customers/plans.d.ts.map +1 -1
- package/resources/v1/customers/plans.js +3 -0
- package/resources/v1/customers/plans.js.map +1 -1
- package/resources/v1/customers/plans.mjs +3 -0
- package/resources/v1/customers/plans.mjs.map +1 -1
- package/resources/v1/dashboards.d.mts +3 -0
- package/resources/v1/dashboards.d.mts.map +1 -1
- package/resources/v1/dashboards.d.ts +3 -0
- package/resources/v1/dashboards.d.ts.map +1 -1
- package/resources/v1/dashboards.js +3 -0
- package/resources/v1/dashboards.js.map +1 -1
- package/resources/v1/dashboards.mjs +3 -0
- package/resources/v1/dashboards.mjs.map +1 -1
- package/resources/v1/index.d.mts +3 -2
- package/resources/v1/index.d.mts.map +1 -1
- package/resources/v1/index.d.ts +3 -2
- package/resources/v1/index.d.ts.map +1 -1
- package/resources/v1/index.js +3 -1
- package/resources/v1/index.js.map +1 -1
- package/resources/v1/index.mjs +1 -0
- package/resources/v1/index.mjs.map +1 -1
- package/resources/v1/invoices.d.mts +3 -0
- package/resources/v1/invoices.d.mts.map +1 -1
- package/resources/v1/invoices.d.ts +3 -0
- package/resources/v1/invoices.d.ts.map +1 -1
- package/resources/v1/invoices.js +3 -0
- package/resources/v1/invoices.js.map +1 -1
- package/resources/v1/invoices.mjs +3 -0
- package/resources/v1/invoices.mjs.map +1 -1
- package/resources/v1/packages.d.mts +2352 -0
- package/resources/v1/packages.d.mts.map +1 -0
- package/resources/v1/packages.d.ts +2352 -0
- package/resources/v1/packages.d.ts.map +1 -0
- package/resources/v1/packages.js +160 -0
- package/resources/v1/packages.js.map +1 -0
- package/resources/v1/packages.mjs +156 -0
- package/resources/v1/packages.mjs.map +1 -0
- package/resources/v1/payments.d.mts +10 -0
- package/resources/v1/payments.d.mts.map +1 -1
- package/resources/v1/payments.d.ts +10 -0
- package/resources/v1/payments.d.ts.map +1 -1
- package/resources/v1/plans.d.mts +5 -2
- package/resources/v1/plans.d.mts.map +1 -1
- package/resources/v1/plans.d.ts +5 -2
- package/resources/v1/plans.d.ts.map +1 -1
- package/resources/v1/plans.js +3 -0
- package/resources/v1/plans.js.map +1 -1
- package/resources/v1/plans.mjs +3 -0
- package/resources/v1/plans.mjs.map +1 -1
- package/resources/v1/pricing-units.d.mts +3 -0
- package/resources/v1/pricing-units.d.mts.map +1 -1
- package/resources/v1/pricing-units.d.ts +3 -0
- package/resources/v1/pricing-units.d.ts.map +1 -1
- package/resources/v1/pricing-units.js +3 -0
- package/resources/v1/pricing-units.js.map +1 -1
- package/resources/v1/pricing-units.mjs +3 -0
- package/resources/v1/pricing-units.mjs.map +1 -1
- package/resources/v1/services.d.mts +3 -0
- package/resources/v1/services.d.mts.map +1 -1
- package/resources/v1/services.d.ts +3 -0
- package/resources/v1/services.d.ts.map +1 -1
- package/resources/v1/services.js +3 -0
- package/resources/v1/services.js.map +1 -1
- package/resources/v1/services.mjs +3 -0
- package/resources/v1/services.mjs.map +1 -1
- package/resources/v1/settings/billing-providers.d.mts +3 -0
- package/resources/v1/settings/billing-providers.d.mts.map +1 -1
- package/resources/v1/settings/billing-providers.d.ts +3 -0
- package/resources/v1/settings/billing-providers.d.ts.map +1 -1
- package/resources/v1/settings/billing-providers.js +3 -0
- package/resources/v1/settings/billing-providers.js.map +1 -1
- package/resources/v1/settings/billing-providers.mjs +3 -0
- package/resources/v1/settings/billing-providers.mjs.map +1 -1
- package/resources/v1/settings/settings.d.mts +3 -0
- package/resources/v1/settings/settings.d.mts.map +1 -1
- package/resources/v1/settings/settings.d.ts +3 -0
- package/resources/v1/settings/settings.d.ts.map +1 -1
- package/resources/v1/settings/settings.js +3 -0
- package/resources/v1/settings/settings.js.map +1 -1
- package/resources/v1/settings/settings.mjs +3 -0
- package/resources/v1/settings/settings.mjs.map +1 -1
- package/resources/v1/usage.d.mts +87 -18
- package/resources/v1/usage.d.mts.map +1 -1
- package/resources/v1/usage.d.ts +87 -18
- package/resources/v1/usage.d.ts.map +1 -1
- package/resources/v1/usage.js +37 -11
- package/resources/v1/usage.js.map +1 -1
- package/resources/v1/usage.mjs +37 -11
- package/resources/v1/usage.mjs.map +1 -1
- package/resources/v1/v1.d.mts +8 -4
- package/resources/v1/v1.d.mts.map +1 -1
- package/resources/v1/v1.d.ts +8 -4
- package/resources/v1/v1.d.ts.map +1 -1
- package/resources/v1/v1.js +4 -0
- package/resources/v1/v1.js.map +1 -1
- package/resources/v1/v1.mjs +4 -0
- package/resources/v1/v1.mjs.map +1 -1
- package/resources/v2/contracts.d.mts +45 -7
- package/resources/v2/contracts.d.mts.map +1 -1
- package/resources/v2/contracts.d.ts +45 -7
- package/resources/v2/contracts.d.ts.map +1 -1
- package/resources/v2/contracts.js +1 -4
- package/resources/v2/contracts.js.map +1 -1
- package/resources/v2/contracts.mjs +1 -4
- package/resources/v2/contracts.mjs.map +1 -1
- package/src/client.ts +37 -15
- package/src/internal/parse.ts +6 -0
- package/src/internal/utils/query.ts +7 -0
- package/src/internal/utils.ts +1 -0
- package/src/resources/shared.ts +127 -32
- package/src/resources/v1/alerts.ts +3 -0
- package/src/resources/v1/audit-logs.ts +3 -0
- package/src/resources/v1/billable-metrics.ts +3 -0
- package/src/resources/v1/contracts/contracts.ts +151 -13
- package/src/resources/v1/contracts/index.ts +2 -0
- package/src/resources/v1/contracts/named-schedules.ts +3 -0
- package/src/resources/v1/contracts/products.ts +3 -0
- package/src/resources/v1/contracts/rate-cards/named-schedules.ts +3 -0
- package/src/resources/v1/contracts/rate-cards/product-orders.ts +3 -0
- package/src/resources/v1/contracts/rate-cards/rate-cards.ts +4 -1
- package/src/resources/v1/contracts/rate-cards/rates.ts +6 -24
- package/src/resources/v1/credit-grants.ts +3 -0
- package/src/resources/v1/custom-fields.ts +32 -5
- package/src/resources/v1/customers/alerts.ts +3 -0
- package/src/resources/v1/customers/billing-config.ts +8 -5
- package/src/resources/v1/customers/commits.ts +3 -0
- package/src/resources/v1/customers/credits.ts +3 -0
- package/src/resources/v1/customers/customers.ts +96 -7
- package/src/resources/v1/customers/index.ts +2 -0
- package/src/resources/v1/customers/invoices.ts +45 -19
- package/src/resources/v1/customers/named-schedules.ts +3 -0
- package/src/resources/v1/customers/plans.ts +8 -5
- package/src/resources/v1/dashboards.ts +3 -0
- package/src/resources/v1/index.ts +19 -0
- package/src/resources/v1/invoices.ts +3 -0
- package/src/resources/v1/packages.ts +3057 -0
- package/src/resources/v1/payments.ts +15 -0
- package/src/resources/v1/plans.ts +5 -2
- package/src/resources/v1/pricing-units.ts +3 -0
- package/src/resources/v1/services.ts +3 -0
- package/src/resources/v1/settings/billing-providers.ts +3 -0
- package/src/resources/v1/settings/settings.ts +3 -0
- package/src/resources/v1/usage.ts +86 -18
- package/src/resources/v1/v1.ts +42 -0
- package/src/resources/v2/contracts.ts +55 -7
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
|
@@ -95,6 +95,8 @@ export interface Payment {
|
|
|
95
95
|
|
|
96
96
|
payment_gateway?: Payment.PaymentGateway;
|
|
97
97
|
|
|
98
|
+
revenue_system_payments?: Array<Payment.RevenueSystemPayment>;
|
|
99
|
+
|
|
98
100
|
status?: PaymentStatus;
|
|
99
101
|
|
|
100
102
|
updated_at?: string;
|
|
@@ -126,6 +128,19 @@ export namespace Payment {
|
|
|
126
128
|
}
|
|
127
129
|
}
|
|
128
130
|
}
|
|
131
|
+
|
|
132
|
+
export interface RevenueSystemPayment {
|
|
133
|
+
revenue_system_provider: string;
|
|
134
|
+
|
|
135
|
+
sync_status: string;
|
|
136
|
+
|
|
137
|
+
/**
|
|
138
|
+
* The error message from the revenue system, if available.
|
|
139
|
+
*/
|
|
140
|
+
error_message?: string;
|
|
141
|
+
|
|
142
|
+
revenue_system_external_payment_id?: string;
|
|
143
|
+
}
|
|
129
144
|
}
|
|
130
145
|
|
|
131
146
|
export type PaymentStatus = 'pending' | 'requires_intervention' | 'paid' | 'canceled';
|
|
@@ -8,6 +8,9 @@ import { CursorPage, type CursorPageParams, PagePromise } from '../../core/pagin
|
|
|
8
8
|
import { RequestOptions } from '../../internal/request-options';
|
|
9
9
|
import { path } from '../../internal/utils/path';
|
|
10
10
|
|
|
11
|
+
/**
|
|
12
|
+
* [Plans](https://docs.metronome.com/pricing-and-packaging/create-plans/) determine the base pricing for a customer. Use these endpoints to add a plan to a customer, end a customer plan, retrieve plans, and retrieve plan details. Create plans in the [Metronome app](https://app.metronome.com/plans).
|
|
13
|
+
*/
|
|
11
14
|
export class Plans extends APIResource {
|
|
12
15
|
/**
|
|
13
16
|
* List all available plans. This is a Plans (deprecated) endpoint. New clients
|
|
@@ -306,14 +309,14 @@ export interface PlanGetDetailsParams {
|
|
|
306
309
|
|
|
307
310
|
export interface PlanListChargesParams extends CursorPageParams {
|
|
308
311
|
/**
|
|
309
|
-
* Path param
|
|
312
|
+
* Path param
|
|
310
313
|
*/
|
|
311
314
|
plan_id: string;
|
|
312
315
|
}
|
|
313
316
|
|
|
314
317
|
export interface PlanListCustomersParams extends CursorPageParams {
|
|
315
318
|
/**
|
|
316
|
-
* Path param
|
|
319
|
+
* Path param
|
|
317
320
|
*/
|
|
318
321
|
plan_id: string;
|
|
319
322
|
|
|
@@ -4,6 +4,9 @@ import { APIResource } from '../../core/resource';
|
|
|
4
4
|
import { CursorPage, type CursorPageParams, PagePromise } from '../../core/pagination';
|
|
5
5
|
import { RequestOptions } from '../../internal/request-options';
|
|
6
6
|
|
|
7
|
+
/**
|
|
8
|
+
* Use these endpoints to configure a billing API key, a webhook secret, or invoice finalization behavior.
|
|
9
|
+
*/
|
|
7
10
|
export class PricingUnits extends APIResource {
|
|
8
11
|
/**
|
|
9
12
|
* List all pricing units. All fiat currency types (for example, USD or GBP) will
|
|
@@ -4,6 +4,9 @@ import { APIResource } from '../../core/resource';
|
|
|
4
4
|
import { APIPromise } from '../../core/api-promise';
|
|
5
5
|
import { RequestOptions } from '../../internal/request-options';
|
|
6
6
|
|
|
7
|
+
/**
|
|
8
|
+
* [Security](https://docs.metronome.com/developer-resources/security/) endpoints allow you to retrieve security-related data.
|
|
9
|
+
*/
|
|
7
10
|
export class Services extends APIResource {
|
|
8
11
|
/**
|
|
9
12
|
* Gets Metronome's service registry with associated IP addresses for security
|
|
@@ -4,6 +4,9 @@ import { APIResource } from '../../../core/resource';
|
|
|
4
4
|
import { APIPromise } from '../../../core/api-promise';
|
|
5
5
|
import { RequestOptions } from '../../../internal/request-options';
|
|
6
6
|
|
|
7
|
+
/**
|
|
8
|
+
* Use these endpoints to configure a billing API key, a webhook secret, or invoice finalization behavior.
|
|
9
|
+
*/
|
|
7
10
|
export class BillingProviders extends APIResource {
|
|
8
11
|
/**
|
|
9
12
|
* Set up account-level configuration for a billing provider. Once configured,
|
|
@@ -12,6 +12,9 @@ import {
|
|
|
12
12
|
import { APIPromise } from '../../../core/api-promise';
|
|
13
13
|
import { RequestOptions } from '../../../internal/request-options';
|
|
14
14
|
|
|
15
|
+
/**
|
|
16
|
+
* Use these endpoints to configure a billing API key, a webhook secret, or invoice finalization behavior.
|
|
17
|
+
*/
|
|
15
18
|
export class Settings extends APIResource {
|
|
16
19
|
billingProviders: BillingProvidersAPI.BillingProviders = new BillingProvidersAPI.BillingProviders(
|
|
17
20
|
this._client,
|
|
@@ -13,6 +13,9 @@ import {
|
|
|
13
13
|
import { buildHeaders } from '../../internal/headers';
|
|
14
14
|
import { RequestOptions } from '../../internal/request-options';
|
|
15
15
|
|
|
16
|
+
/**
|
|
17
|
+
* [Usage events](https://docs.metronome.com/connecting-metronome/send-usage-data/) are the basis for billable metrics. Use these endpoints to send usage events to Metronome and retrieve aggregated event data.
|
|
18
|
+
*/
|
|
16
19
|
export class Usage extends APIResource {
|
|
17
20
|
/**
|
|
18
21
|
* Retrieve aggregated usage data across multiple customers and billable metrics in
|
|
@@ -192,13 +195,37 @@ export class Usage extends APIResource {
|
|
|
192
195
|
* - Build detailed usage dashboards with dimensional filtering
|
|
193
196
|
* - Identify high-usage segments for optimization opportunities
|
|
194
197
|
*
|
|
198
|
+
* ### Request parameters
|
|
199
|
+
*
|
|
200
|
+
* Use [`group_key`](#body-group-key) and [`group_filters`](#body-group-filters) to
|
|
201
|
+
* group by one or more dimensions. This is required for compound group keys and
|
|
202
|
+
* recommended for all new integrations:
|
|
203
|
+
*
|
|
204
|
+
* ```json
|
|
205
|
+
* {
|
|
206
|
+
* "group_key": ["region", "team"],
|
|
207
|
+
* "group_filters": {
|
|
208
|
+
* "region": ["US-East", "US-West"]
|
|
209
|
+
* }
|
|
210
|
+
* }
|
|
211
|
+
* ```
|
|
212
|
+
*
|
|
213
|
+
* Important: For compound group keys, you must pass the complete set of keys that
|
|
214
|
+
* make up the compound key. Partial key combinations are not supported. For
|
|
215
|
+
* example, if your billable metric has a compound group key [region, team,
|
|
216
|
+
* environment], you must pass all three keys in group_key—you cannot pass just
|
|
217
|
+
* `[region]` or `[region, team]`.
|
|
218
|
+
*
|
|
195
219
|
* ### Key response fields:
|
|
196
220
|
*
|
|
197
221
|
* An array of `PagedUsageAggregate` objects containing:
|
|
198
222
|
*
|
|
199
223
|
* - `starting_on` and `ending_before`: Time window boundaries
|
|
200
|
-
* - `
|
|
201
|
-
*
|
|
224
|
+
* - `group`: Object mapping group keys to their values
|
|
225
|
+
* - For simple groups, this will be a map with a single key-value pair (e.g.,
|
|
226
|
+
* `{"region": "US-East"}`)
|
|
227
|
+
* - For compound groups, this will be a map with multiple key-value pairs (e.g.,
|
|
228
|
+
* `{"region": "US-East", "team": "engineering"}`)
|
|
202
229
|
* - `value`: Aggregated usage for this group and time window
|
|
203
230
|
* - `next_page`: Pagination cursor for large datasets
|
|
204
231
|
*
|
|
@@ -208,12 +235,13 @@ export class Usage extends APIResource {
|
|
|
208
235
|
* `window_size`
|
|
209
236
|
* - Time windows: Set `window_size` to hour, day, or none for different
|
|
210
237
|
* granularities
|
|
211
|
-
* - Group filtering: Use `
|
|
212
|
-
*
|
|
213
|
-
*
|
|
214
|
-
*
|
|
238
|
+
* - Group filtering: Use `group_key` and `group_filters` to specify groups and
|
|
239
|
+
* group filters
|
|
240
|
+
* - Limits: When using compound group keys (2+ keys in `group_key`), the default
|
|
241
|
+
* and max limit is 100
|
|
215
242
|
* - Pagination: Use limit and `next_page` for large result sets
|
|
216
|
-
* - Null handling:
|
|
243
|
+
* - Null handling: Group values may be null for events missing the group key
|
|
244
|
+
* property
|
|
217
245
|
*
|
|
218
246
|
* @example
|
|
219
247
|
* ```ts
|
|
@@ -225,10 +253,8 @@ export class Usage extends APIResource {
|
|
|
225
253
|
* customer_id: '04ca7e72-4229-4a6e-ab11-9f7376fccbcb',
|
|
226
254
|
* window_size: 'day',
|
|
227
255
|
* ending_before: '2021-01-03T00:00:00Z',
|
|
228
|
-
*
|
|
229
|
-
*
|
|
230
|
-
* values: ['US-East', 'US-West', 'EU-Central'],
|
|
231
|
-
* },
|
|
256
|
+
* group_filters: { region: ['us-east1', 'us-west1'] },
|
|
257
|
+
* group_key: ['region'],
|
|
232
258
|
* starting_on: '2021-01-01T00:00:00Z',
|
|
233
259
|
* },
|
|
234
260
|
* )) {
|
|
@@ -324,13 +350,27 @@ export interface UsageListResponse {
|
|
|
324
350
|
export interface UsageListWithGroupsResponse {
|
|
325
351
|
ending_before: string;
|
|
326
352
|
|
|
353
|
+
/**
|
|
354
|
+
* @deprecated Use `group` instead. The group key for single-key grouping.
|
|
355
|
+
*/
|
|
327
356
|
group_key: string | null;
|
|
328
357
|
|
|
358
|
+
/**
|
|
359
|
+
* @deprecated Use `group` instead. The group value for single-key grouping.
|
|
360
|
+
*/
|
|
329
361
|
group_value: string | null;
|
|
330
362
|
|
|
331
363
|
starting_on: string;
|
|
332
364
|
|
|
333
365
|
value: number | null;
|
|
366
|
+
|
|
367
|
+
/**
|
|
368
|
+
* Map of group key to their value for this usage aggregate. For simple group keys,
|
|
369
|
+
* this should be a single key e.g. `{"region": "US-East"}` For compound group
|
|
370
|
+
* keys, this should contain the values of each group key that forms the compound
|
|
371
|
+
* e.g. `{"region": "US-East", "team": "engineering"}`
|
|
372
|
+
*/
|
|
373
|
+
group?: { [key: string]: string };
|
|
334
374
|
}
|
|
335
375
|
|
|
336
376
|
export type UsageSearchResponse = Array<UsageSearchResponse.UsageSearchResponseItem>;
|
|
@@ -451,12 +491,12 @@ export namespace UsageSearchResponse {
|
|
|
451
491
|
|
|
452
492
|
export interface UsageListParams extends CursorPageWithoutLimitParams {
|
|
453
493
|
/**
|
|
454
|
-
* Body param
|
|
494
|
+
* Body param
|
|
455
495
|
*/
|
|
456
496
|
ending_before: string;
|
|
457
497
|
|
|
458
498
|
/**
|
|
459
|
-
* Body param
|
|
499
|
+
* Body param
|
|
460
500
|
*/
|
|
461
501
|
starting_on: string;
|
|
462
502
|
|
|
@@ -527,12 +567,12 @@ export namespace UsageIngestParams {
|
|
|
527
567
|
|
|
528
568
|
export interface UsageListWithGroupsParams extends CursorPageParams {
|
|
529
569
|
/**
|
|
530
|
-
* Body param
|
|
570
|
+
* Body param
|
|
531
571
|
*/
|
|
532
572
|
billable_metric_id: string;
|
|
533
573
|
|
|
534
574
|
/**
|
|
535
|
-
* Body param
|
|
575
|
+
* Body param
|
|
536
576
|
*/
|
|
537
577
|
customer_id: string;
|
|
538
578
|
|
|
@@ -552,22 +592,50 @@ export interface UsageListWithGroupsParams extends CursorPageParams {
|
|
|
552
592
|
current_period?: boolean;
|
|
553
593
|
|
|
554
594
|
/**
|
|
555
|
-
* Body param
|
|
595
|
+
* Body param
|
|
556
596
|
*/
|
|
557
597
|
ending_before?: string;
|
|
558
598
|
|
|
559
599
|
/**
|
|
560
|
-
* Body param:
|
|
600
|
+
* @deprecated Body param: Use group_key and group_filters instead. Use a single
|
|
601
|
+
* group key to group by. Compound group keys are not supported.
|
|
561
602
|
*/
|
|
562
603
|
group_by?: UsageListWithGroupsParams.GroupBy;
|
|
563
604
|
|
|
564
605
|
/**
|
|
565
|
-
* Body param:
|
|
606
|
+
* Body param: Object mapping group keys to arrays of values to filter on. Only
|
|
607
|
+
* usage matching these filter values will be returned. Keys must be present in
|
|
608
|
+
* group_key. Omit a key or use an empty array to include all values for that
|
|
609
|
+
* dimension.
|
|
610
|
+
*/
|
|
611
|
+
group_filters?: { [key: string]: Array<string> };
|
|
612
|
+
|
|
613
|
+
/**
|
|
614
|
+
* Body param: Group key to group usage by. Supports both simple (single key) and
|
|
615
|
+
* compound (multiple keys) group keys.
|
|
616
|
+
*
|
|
617
|
+
* For simple group keys, provide a single key e.g. `["region"]`. For compound
|
|
618
|
+
* group keys, provide multiple keys e.g. `["region", "team"]`.
|
|
619
|
+
*
|
|
620
|
+
* For streaming metrics, the keys must be defined as a simple or compound group
|
|
621
|
+
* key on the billable metric. For compound group keys, all keys must match an
|
|
622
|
+
* exact compound group key definition — partial matches are not allowed.
|
|
623
|
+
*
|
|
624
|
+
* Cannot be used together with `group_by`.
|
|
625
|
+
*/
|
|
626
|
+
group_key?: Array<string>;
|
|
627
|
+
|
|
628
|
+
/**
|
|
629
|
+
* Body param
|
|
566
630
|
*/
|
|
567
631
|
starting_on?: string;
|
|
568
632
|
}
|
|
569
633
|
|
|
570
634
|
export namespace UsageListWithGroupsParams {
|
|
635
|
+
/**
|
|
636
|
+
* @deprecated Use group_key and group_filters instead. Use a single group key to
|
|
637
|
+
* group by. Compound group keys are not supported.
|
|
638
|
+
*/
|
|
571
639
|
export interface GroupBy {
|
|
572
640
|
/**
|
|
573
641
|
* The name of the group_by key to use
|
package/src/resources/v1/v1.ts
CHANGED
|
@@ -69,6 +69,22 @@ import {
|
|
|
69
69
|
InvoiceVoidResponse,
|
|
70
70
|
Invoices,
|
|
71
71
|
} from './invoices';
|
|
72
|
+
import * as PackagesAPI from './packages';
|
|
73
|
+
import {
|
|
74
|
+
PackageArchiveParams,
|
|
75
|
+
PackageArchiveResponse,
|
|
76
|
+
PackageCreateParams,
|
|
77
|
+
PackageCreateResponse,
|
|
78
|
+
PackageListContractsOnPackageParams,
|
|
79
|
+
PackageListContractsOnPackageResponse,
|
|
80
|
+
PackageListContractsOnPackageResponsesCursorPage,
|
|
81
|
+
PackageListParams,
|
|
82
|
+
PackageListResponse,
|
|
83
|
+
PackageListResponsesCursorPage,
|
|
84
|
+
PackageRetrieveParams,
|
|
85
|
+
PackageRetrieveResponse,
|
|
86
|
+
Packages,
|
|
87
|
+
} from './packages';
|
|
72
88
|
import * as PaymentsAPI from './payments';
|
|
73
89
|
import {
|
|
74
90
|
Payment,
|
|
@@ -130,6 +146,8 @@ import {
|
|
|
130
146
|
ContractCreateHistoricalInvoicesResponse,
|
|
131
147
|
ContractCreateParams,
|
|
132
148
|
ContractCreateResponse,
|
|
149
|
+
ContractGetNetBalanceParams,
|
|
150
|
+
ContractGetNetBalanceResponse,
|
|
133
151
|
ContractListBalancesParams,
|
|
134
152
|
ContractListBalancesResponse,
|
|
135
153
|
ContractListBalancesResponsesBodyCursorPage,
|
|
@@ -151,6 +169,8 @@ import {
|
|
|
151
169
|
import * as CustomersAPI from './customers/customers';
|
|
152
170
|
import {
|
|
153
171
|
Customer,
|
|
172
|
+
CustomerArchiveBillingConfigurationsParams,
|
|
173
|
+
CustomerArchiveBillingConfigurationsResponse,
|
|
154
174
|
CustomerArchiveParams,
|
|
155
175
|
CustomerArchiveResponse,
|
|
156
176
|
CustomerCreateParams,
|
|
@@ -199,6 +219,7 @@ export class V1 extends APIResource {
|
|
|
199
219
|
services: ServicesAPI.Services = new ServicesAPI.Services(this._client);
|
|
200
220
|
invoices: InvoicesAPI.Invoices = new InvoicesAPI.Invoices(this._client);
|
|
201
221
|
contracts: ContractsAPI.Contracts = new ContractsAPI.Contracts(this._client);
|
|
222
|
+
packages: PackagesAPI.Packages = new PackagesAPI.Packages(this._client);
|
|
202
223
|
payments: PaymentsAPI.Payments = new PaymentsAPI.Payments(this._client);
|
|
203
224
|
settings: SettingsAPI.Settings = new SettingsAPI.Settings(this._client);
|
|
204
225
|
}
|
|
@@ -216,6 +237,7 @@ V1.BillableMetrics = BillableMetrics;
|
|
|
216
237
|
V1.Services = Services;
|
|
217
238
|
V1.Invoices = Invoices;
|
|
218
239
|
V1.Contracts = Contracts;
|
|
240
|
+
V1.Packages = Packages;
|
|
219
241
|
V1.Payments = Payments;
|
|
220
242
|
V1.Settings = Settings;
|
|
221
243
|
|
|
@@ -277,6 +299,7 @@ export declare namespace V1 {
|
|
|
277
299
|
type CustomerCreateResponse as CustomerCreateResponse,
|
|
278
300
|
type CustomerRetrieveResponse as CustomerRetrieveResponse,
|
|
279
301
|
type CustomerArchiveResponse as CustomerArchiveResponse,
|
|
302
|
+
type CustomerArchiveBillingConfigurationsResponse as CustomerArchiveBillingConfigurationsResponse,
|
|
280
303
|
type CustomerListBillableMetricsResponse as CustomerListBillableMetricsResponse,
|
|
281
304
|
type CustomerListCostsResponse as CustomerListCostsResponse,
|
|
282
305
|
type CustomerPreviewEventsResponse as CustomerPreviewEventsResponse,
|
|
@@ -290,6 +313,7 @@ export declare namespace V1 {
|
|
|
290
313
|
type CustomerRetrieveParams as CustomerRetrieveParams,
|
|
291
314
|
type CustomerListParams as CustomerListParams,
|
|
292
315
|
type CustomerArchiveParams as CustomerArchiveParams,
|
|
316
|
+
type CustomerArchiveBillingConfigurationsParams as CustomerArchiveBillingConfigurationsParams,
|
|
293
317
|
type CustomerListBillableMetricsParams as CustomerListBillableMetricsParams,
|
|
294
318
|
type CustomerListCostsParams as CustomerListCostsParams,
|
|
295
319
|
type CustomerPreviewEventsParams as CustomerPreviewEventsParams,
|
|
@@ -368,6 +392,7 @@ export declare namespace V1 {
|
|
|
368
392
|
type ContractAmendResponse as ContractAmendResponse,
|
|
369
393
|
type ContractArchiveResponse as ContractArchiveResponse,
|
|
370
394
|
type ContractCreateHistoricalInvoicesResponse as ContractCreateHistoricalInvoicesResponse,
|
|
395
|
+
type ContractGetNetBalanceResponse as ContractGetNetBalanceResponse,
|
|
371
396
|
type ContractListBalancesResponse as ContractListBalancesResponse,
|
|
372
397
|
type ContractRetrieveRateScheduleResponse as ContractRetrieveRateScheduleResponse,
|
|
373
398
|
type ContractRetrieveSubscriptionQuantityHistoryResponse as ContractRetrieveSubscriptionQuantityHistoryResponse,
|
|
@@ -381,6 +406,7 @@ export declare namespace V1 {
|
|
|
381
406
|
type ContractAmendParams as ContractAmendParams,
|
|
382
407
|
type ContractArchiveParams as ContractArchiveParams,
|
|
383
408
|
type ContractCreateHistoricalInvoicesParams as ContractCreateHistoricalInvoicesParams,
|
|
409
|
+
type ContractGetNetBalanceParams as ContractGetNetBalanceParams,
|
|
384
410
|
type ContractListBalancesParams as ContractListBalancesParams,
|
|
385
411
|
type ContractRetrieveRateScheduleParams as ContractRetrieveRateScheduleParams,
|
|
386
412
|
type ContractRetrieveSubscriptionQuantityHistoryParams as ContractRetrieveSubscriptionQuantityHistoryParams,
|
|
@@ -389,6 +415,22 @@ export declare namespace V1 {
|
|
|
389
415
|
type ContractUpdateEndDateParams as ContractUpdateEndDateParams,
|
|
390
416
|
};
|
|
391
417
|
|
|
418
|
+
export {
|
|
419
|
+
Packages as Packages,
|
|
420
|
+
type PackageCreateResponse as PackageCreateResponse,
|
|
421
|
+
type PackageRetrieveResponse as PackageRetrieveResponse,
|
|
422
|
+
type PackageListResponse as PackageListResponse,
|
|
423
|
+
type PackageArchiveResponse as PackageArchiveResponse,
|
|
424
|
+
type PackageListContractsOnPackageResponse as PackageListContractsOnPackageResponse,
|
|
425
|
+
type PackageListResponsesCursorPage as PackageListResponsesCursorPage,
|
|
426
|
+
type PackageListContractsOnPackageResponsesCursorPage as PackageListContractsOnPackageResponsesCursorPage,
|
|
427
|
+
type PackageCreateParams as PackageCreateParams,
|
|
428
|
+
type PackageRetrieveParams as PackageRetrieveParams,
|
|
429
|
+
type PackageListParams as PackageListParams,
|
|
430
|
+
type PackageArchiveParams as PackageArchiveParams,
|
|
431
|
+
type PackageListContractsOnPackageParams as PackageListContractsOnPackageParams,
|
|
432
|
+
};
|
|
433
|
+
|
|
392
434
|
export {
|
|
393
435
|
Payments as Payments,
|
|
394
436
|
type Payment as Payment,
|
|
@@ -76,10 +76,7 @@ export class Contracts extends APIResource {
|
|
|
76
76
|
*
|
|
77
77
|
* ### Key response fields:
|
|
78
78
|
*
|
|
79
|
-
* - The `id` of the
|
|
80
|
-
* - Complete edit details. For example, if you edited the contract to add new
|
|
81
|
-
* overrides and credits, you will receive the IDs of those overrides and credits
|
|
82
|
-
* in the response.
|
|
79
|
+
* - The `id` of the contract that was edited
|
|
83
80
|
*
|
|
84
81
|
* ### Usage guidelines:
|
|
85
82
|
*
|
|
@@ -556,7 +553,7 @@ export namespace ContractGetEditHistoryResponse {
|
|
|
556
553
|
}
|
|
557
554
|
|
|
558
555
|
export interface OverwriteRate {
|
|
559
|
-
rate_type: 'FLAT' | 'PERCENTAGE' | 'SUBSCRIPTION' | 'TIERED' | 'CUSTOM';
|
|
556
|
+
rate_type: 'FLAT' | 'PERCENTAGE' | 'SUBSCRIPTION' | 'TIERED' | 'TIERED_PERCENTAGE' | 'CUSTOM';
|
|
560
557
|
|
|
561
558
|
credit_type?: Shared.CreditTypeData;
|
|
562
559
|
|
|
@@ -1677,6 +1674,13 @@ export interface ContractEditParams {
|
|
|
1677
1674
|
|
|
1678
1675
|
add_reseller_royalties?: Array<ContractEditParams.AddResellerRoyalty>;
|
|
1679
1676
|
|
|
1677
|
+
/**
|
|
1678
|
+
* Update the revenue system configuration on the contract. Currently only supports
|
|
1679
|
+
* adding a revenue system configuration to a contract that does not already have
|
|
1680
|
+
* one.
|
|
1681
|
+
*/
|
|
1682
|
+
add_revenue_system_configuration_update?: ContractEditParams.AddRevenueSystemConfigurationUpdate;
|
|
1683
|
+
|
|
1680
1684
|
add_scheduled_charges?: Array<ContractEditParams.AddScheduledCharge>;
|
|
1681
1685
|
|
|
1682
1686
|
add_spend_threshold_configuration?: Shared.SpendThresholdConfigurationV2;
|
|
@@ -1736,6 +1740,12 @@ export interface ContractEditParams {
|
|
|
1736
1740
|
|
|
1737
1741
|
update_credits?: Array<ContractEditParams.UpdateCredit>;
|
|
1738
1742
|
|
|
1743
|
+
/**
|
|
1744
|
+
* Number of days after issuance of invoice after which the invoice is due (e.g.
|
|
1745
|
+
* Net 30).
|
|
1746
|
+
*/
|
|
1747
|
+
update_net_payment_terms_days?: number | null;
|
|
1748
|
+
|
|
1739
1749
|
update_prepaid_balance_threshold_configuration?: ContractEditParams.UpdatePrepaidBalanceThresholdConfiguration;
|
|
1740
1750
|
|
|
1741
1751
|
/**
|
|
@@ -2065,7 +2075,7 @@ export namespace ContractEditParams {
|
|
|
2065
2075
|
* not wish Metronome to calculate tax on your behalf. Leaving this field blank
|
|
2066
2076
|
* will default to NONE.
|
|
2067
2077
|
*/
|
|
2068
|
-
tax_type?: 'NONE' | 'STRIPE' | 'ANROK' | '
|
|
2078
|
+
tax_type?: 'NONE' | 'STRIPE' | 'ANROK' | 'PRECALCULATED';
|
|
2069
2079
|
}
|
|
2070
2080
|
|
|
2071
2081
|
export namespace PaymentGateConfig {
|
|
@@ -2169,6 +2179,11 @@ export namespace ContractEditParams {
|
|
|
2169
2179
|
|
|
2170
2180
|
rate_type?: 'COMMIT_RATE' | 'LIST_RATE';
|
|
2171
2181
|
|
|
2182
|
+
/**
|
|
2183
|
+
* Fraction of unused segments that will be rolled over. Must be between 0 and 1.
|
|
2184
|
+
*/
|
|
2185
|
+
rollover_fraction?: number;
|
|
2186
|
+
|
|
2172
2187
|
/**
|
|
2173
2188
|
* List of filters that determine what kind of customer usage draws down a commit
|
|
2174
2189
|
* or credit. A customer's usage needs to meet the condition of at least one of the
|
|
@@ -2461,7 +2476,7 @@ export namespace ContractEditParams {
|
|
|
2461
2476
|
* Required for OVERWRITE type.
|
|
2462
2477
|
*/
|
|
2463
2478
|
export interface OverwriteRate {
|
|
2464
|
-
rate_type: 'FLAT' | 'PERCENTAGE' | 'SUBSCRIPTION' | 'TIERED' | 'CUSTOM';
|
|
2479
|
+
rate_type: 'FLAT' | 'PERCENTAGE' | 'SUBSCRIPTION' | 'TIERED' | 'TIERED_PERCENTAGE' | 'CUSTOM';
|
|
2465
2480
|
|
|
2466
2481
|
credit_type_id?: string;
|
|
2467
2482
|
|
|
@@ -2925,6 +2940,37 @@ export namespace ContractEditParams {
|
|
|
2925
2940
|
}
|
|
2926
2941
|
}
|
|
2927
2942
|
|
|
2943
|
+
/**
|
|
2944
|
+
* Update the revenue system configuration on the contract. Currently only supports
|
|
2945
|
+
* adding a revenue system configuration to a contract that does not already have
|
|
2946
|
+
* one.
|
|
2947
|
+
*/
|
|
2948
|
+
export interface AddRevenueSystemConfigurationUpdate {
|
|
2949
|
+
revenue_system_configuration: AddRevenueSystemConfigurationUpdate.RevenueSystemConfiguration;
|
|
2950
|
+
|
|
2951
|
+
schedule: AddRevenueSystemConfigurationUpdate.Schedule;
|
|
2952
|
+
}
|
|
2953
|
+
|
|
2954
|
+
export namespace AddRevenueSystemConfigurationUpdate {
|
|
2955
|
+
export interface RevenueSystemConfiguration {
|
|
2956
|
+
delivery_method?: 'direct_to_billing_provider' | 'aws_sqs' | 'tackle' | 'aws_sns';
|
|
2957
|
+
|
|
2958
|
+
/**
|
|
2959
|
+
* The revenue system provider type.
|
|
2960
|
+
*/
|
|
2961
|
+
provider?: 'netsuite';
|
|
2962
|
+
|
|
2963
|
+
revenue_system_configuration_id?: string;
|
|
2964
|
+
}
|
|
2965
|
+
|
|
2966
|
+
export interface Schedule {
|
|
2967
|
+
/**
|
|
2968
|
+
* When the revenue system configuration update will take effect.
|
|
2969
|
+
*/
|
|
2970
|
+
effective_at: 'START_OF_CURRENT_PERIOD';
|
|
2971
|
+
}
|
|
2972
|
+
}
|
|
2973
|
+
|
|
2928
2974
|
export interface AddScheduledCharge {
|
|
2929
2975
|
product_id: string;
|
|
2930
2976
|
|
|
@@ -3332,6 +3378,8 @@ export namespace ContractEditParams {
|
|
|
3332
3378
|
* regenerated to reflect the rate type change.
|
|
3333
3379
|
*/
|
|
3334
3380
|
rate_type?: 'LIST_RATE' | 'COMMIT_RATE';
|
|
3381
|
+
|
|
3382
|
+
rollover_fraction?: number | null;
|
|
3335
3383
|
}
|
|
3336
3384
|
|
|
3337
3385
|
export namespace UpdateCredit {
|
package/src/version.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export const VERSION = '
|
|
1
|
+
export const VERSION = '3.4.1'; // x-release-please-version
|
package/version.d.mts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const VERSION = "
|
|
1
|
+
export declare const VERSION = "3.4.1";
|
|
2
2
|
//# sourceMappingURL=version.d.mts.map
|
package/version.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const VERSION = "
|
|
1
|
+
export declare const VERSION = "3.4.1";
|
|
2
2
|
//# sourceMappingURL=version.d.ts.map
|
package/version.js
CHANGED
package/version.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export const VERSION = '
|
|
1
|
+
export const VERSION = '3.4.1'; // x-release-please-version
|
|
2
2
|
//# sourceMappingURL=version.mjs.map
|