orb-billing 4.32.0 → 4.47.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 +184 -0
- package/LICENSE +1 -1
- package/README.md +12 -3
- package/core.d.ts +4 -5
- package/core.d.ts.map +1 -1
- package/core.js +16 -11
- package/core.js.map +1 -1
- package/core.mjs +16 -11
- package/core.mjs.map +1 -1
- package/error.d.ts +30 -36
- package/error.d.ts.map +1 -1
- package/error.js +24 -43
- package/error.js.map +1 -1
- package/error.mjs +24 -43
- package/error.mjs.map +1 -1
- package/index.d.mts +43 -109
- package/index.d.ts +43 -109
- package/index.d.ts.map +1 -1
- package/index.js +71 -33
- package/index.js.map +1 -1
- package/index.mjs +43 -32
- package/index.mjs.map +1 -1
- package/package.json +2 -2
- package/resources/alerts.d.ts +58 -19
- package/resources/alerts.d.ts.map +1 -1
- package/resources/alerts.js +19 -37
- package/resources/alerts.js.map +1 -1
- package/resources/alerts.mjs +19 -14
- package/resources/alerts.mjs.map +1 -1
- package/resources/coupons/coupons.d.ts +3 -7
- package/resources/coupons/coupons.d.ts.map +1 -1
- package/resources/coupons/coupons.js +3 -5
- package/resources/coupons/coupons.js.map +1 -1
- package/resources/coupons/coupons.mjs +3 -5
- package/resources/coupons/coupons.mjs.map +1 -1
- package/resources/coupons/index.d.ts +2 -2
- package/resources/coupons/index.d.ts.map +1 -1
- package/resources/coupons/index.js.map +1 -1
- package/resources/coupons/index.mjs.map +1 -1
- package/resources/coupons/subscriptions.d.ts +1 -2
- package/resources/coupons/subscriptions.d.ts.map +1 -1
- package/resources/coupons/subscriptions.js +0 -2
- package/resources/coupons/subscriptions.js.map +1 -1
- package/resources/coupons/subscriptions.mjs +0 -2
- package/resources/coupons/subscriptions.mjs.map +1 -1
- package/resources/credit-notes.d.ts +29 -4
- package/resources/credit-notes.d.ts.map +1 -1
- package/resources/credit-notes.js +8 -27
- package/resources/credit-notes.js.map +1 -1
- package/resources/credit-notes.mjs +8 -4
- package/resources/credit-notes.mjs.map +1 -1
- package/resources/customers/balance-transactions.d.ts +1 -6
- package/resources/customers/balance-transactions.d.ts.map +1 -1
- package/resources/customers/balance-transactions.js +1 -27
- package/resources/customers/balance-transactions.js.map +1 -1
- package/resources/customers/balance-transactions.mjs +1 -4
- package/resources/customers/balance-transactions.mjs.map +1 -1
- package/resources/customers/costs.d.ts +1 -5
- package/resources/customers/costs.d.ts.map +1 -1
- package/resources/customers/costs.js +0 -2
- package/resources/customers/costs.js.map +1 -1
- package/resources/customers/costs.mjs +0 -2
- package/resources/customers/costs.mjs.map +1 -1
- package/resources/customers/credits/credits.d.ts +15 -31
- package/resources/customers/credits/credits.d.ts.map +1 -1
- package/resources/customers/credits/credits.js +10 -11
- package/resources/customers/credits/credits.js.map +1 -1
- package/resources/customers/credits/credits.mjs +10 -11
- package/resources/customers/credits/credits.mjs.map +1 -1
- package/resources/customers/credits/index.d.ts +3 -3
- package/resources/customers/credits/index.d.ts.map +1 -1
- package/resources/customers/credits/index.js.map +1 -1
- package/resources/customers/credits/index.mjs.map +1 -1
- package/resources/customers/credits/ledger.d.ts +15 -23
- package/resources/customers/credits/ledger.d.ts.map +1 -1
- package/resources/customers/credits/ledger.js +12 -36
- package/resources/customers/credits/ledger.js.map +1 -1
- package/resources/customers/credits/ledger.mjs +12 -13
- package/resources/customers/credits/ledger.mjs.map +1 -1
- package/resources/customers/credits/top-ups.d.ts +1 -11
- package/resources/customers/credits/top-ups.d.ts.map +1 -1
- package/resources/customers/credits/top-ups.js +2 -28
- package/resources/customers/credits/top-ups.js.map +1 -1
- package/resources/customers/credits/top-ups.mjs +2 -5
- package/resources/customers/credits/top-ups.mjs.map +1 -1
- package/resources/customers/customers.d.ts +9 -29
- package/resources/customers/customers.d.ts.map +1 -1
- package/resources/customers/customers.js +25 -18
- package/resources/customers/customers.js.map +1 -1
- package/resources/customers/customers.mjs +25 -18
- package/resources/customers/customers.mjs.map +1 -1
- package/resources/customers/index.d.ts +4 -4
- package/resources/customers/index.d.ts.map +1 -1
- package/resources/customers/index.js.map +1 -1
- package/resources/customers/index.mjs.map +1 -1
- package/resources/dimensional-price-groups/dimensional-price-groups.d.ts +90 -0
- package/resources/dimensional-price-groups/dimensional-price-groups.d.ts.map +1 -0
- package/resources/dimensional-price-groups/dimensional-price-groups.js +73 -0
- package/resources/dimensional-price-groups/dimensional-price-groups.js.map +1 -0
- package/resources/dimensional-price-groups/dimensional-price-groups.mjs +45 -0
- package/resources/dimensional-price-groups/dimensional-price-groups.mjs.map +1 -0
- package/resources/dimensional-price-groups/external-dimensional-price-group-id.d.ts +10 -0
- package/resources/dimensional-price-groups/external-dimensional-price-group-id.d.ts.map +1 -0
- package/resources/dimensional-price-groups/external-dimensional-price-group-id.js +15 -0
- package/resources/dimensional-price-groups/external-dimensional-price-group-id.js.map +1 -0
- package/resources/dimensional-price-groups/external-dimensional-price-group-id.mjs +11 -0
- package/resources/dimensional-price-groups/external-dimensional-price-group-id.mjs.map +1 -0
- package/resources/dimensional-price-groups/index.d.ts +3 -0
- package/resources/dimensional-price-groups/index.d.ts.map +1 -0
- package/resources/dimensional-price-groups/index.js +9 -0
- package/resources/dimensional-price-groups/index.js.map +1 -0
- package/resources/dimensional-price-groups/index.mjs +4 -0
- package/resources/dimensional-price-groups/index.mjs.map +1 -0
- package/resources/events/backfills.d.ts +5 -11
- package/resources/events/backfills.d.ts.map +1 -1
- package/resources/events/backfills.js +5 -29
- package/resources/events/backfills.js.map +1 -1
- package/resources/events/backfills.mjs +5 -6
- package/resources/events/backfills.mjs.map +1 -1
- package/resources/events/events.d.ts +7 -22
- package/resources/events/events.d.ts.map +1 -1
- package/resources/events/events.js +7 -7
- package/resources/events/events.js.map +1 -1
- package/resources/events/events.mjs +7 -7
- package/resources/events/events.mjs.map +1 -1
- package/resources/events/index.d.ts +3 -3
- package/resources/events/index.d.ts.map +1 -1
- package/resources/events/index.js.map +1 -1
- package/resources/events/index.mjs.map +1 -1
- package/resources/events/volume.d.ts +9 -12
- package/resources/events/volume.d.ts.map +1 -1
- package/resources/events/volume.js +16 -7
- package/resources/events/volume.js.map +1 -1
- package/resources/events/volume.mjs +16 -7
- package/resources/events/volume.mjs.map +1 -1
- package/resources/index.d.ts +14 -13
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js +10 -7
- package/resources/index.js.map +1 -1
- package/resources/index.mjs +8 -7
- package/resources/index.mjs.map +1 -1
- package/resources/invoice-line-items.d.ts +1 -3
- package/resources/invoice-line-items.d.ts.map +1 -1
- package/resources/invoice-line-items.js +0 -2
- package/resources/invoice-line-items.js.map +1 -1
- package/resources/invoice-line-items.mjs +0 -2
- package/resources/invoice-line-items.mjs.map +1 -1
- package/resources/invoices.d.ts +81 -18
- package/resources/invoices.d.ts.map +1 -1
- package/resources/invoices.js +22 -35
- package/resources/invoices.js.map +1 -1
- package/resources/invoices.mjs +22 -12
- package/resources/invoices.mjs.map +1 -1
- package/resources/items.d.ts +2 -8
- package/resources/items.d.ts.map +1 -1
- package/resources/items.js +5 -31
- package/resources/items.js.map +1 -1
- package/resources/items.mjs +5 -8
- package/resources/items.mjs.map +1 -1
- package/resources/metrics.d.ts +2 -8
- package/resources/metrics.d.ts.map +1 -1
- package/resources/metrics.js +7 -31
- package/resources/metrics.js.map +1 -1
- package/resources/metrics.mjs +7 -8
- package/resources/metrics.mjs.map +1 -1
- package/resources/plans/external-plan-id.d.ts +2 -4
- package/resources/plans/external-plan-id.d.ts.map +1 -1
- package/resources/plans/external-plan-id.js +7 -7
- package/resources/plans/external-plan-id.js.map +1 -1
- package/resources/plans/external-plan-id.mjs +7 -7
- package/resources/plans/external-plan-id.mjs.map +1 -1
- package/resources/plans/index.d.ts +2 -2
- package/resources/plans/index.d.ts.map +1 -1
- package/resources/plans/index.js.map +1 -1
- package/resources/plans/index.mjs +1 -1
- package/resources/plans/index.mjs.map +1 -1
- package/resources/plans/plans.d.ts +332 -11
- package/resources/plans/plans.d.ts.map +1 -1
- package/resources/plans/plans.js +10 -9
- package/resources/plans/plans.js.map +1 -1
- package/resources/plans/plans.mjs +10 -9
- package/resources/plans/plans.mjs.map +1 -1
- package/resources/prices/external-price-id.d.ts +2 -4
- package/resources/prices/external-price-id.d.ts.map +1 -1
- package/resources/prices/external-price-id.js +6 -7
- package/resources/prices/external-price-id.js.map +1 -1
- package/resources/prices/external-price-id.mjs +6 -7
- package/resources/prices/external-price-id.mjs.map +1 -1
- package/resources/prices/index.d.ts +2 -2
- package/resources/prices/index.d.ts.map +1 -1
- package/resources/prices/index.js +3 -3
- package/resources/prices/index.js.map +1 -1
- package/resources/prices/index.mjs +1 -1
- package/resources/prices/index.mjs.map +1 -1
- package/resources/prices/prices.d.ts +340 -15
- package/resources/prices/prices.d.ts.map +1 -1
- package/resources/prices/prices.js +9 -9
- package/resources/prices/prices.js.map +1 -1
- package/resources/prices/prices.mjs +9 -9
- package/resources/prices/prices.mjs.map +1 -1
- package/resources/subscriptions.d.ts +7636 -200
- package/resources/subscriptions.d.ts.map +1 -1
- package/resources/subscriptions.js +348 -47
- package/resources/subscriptions.js.map +1 -1
- package/resources/subscriptions.mjs +348 -24
- package/resources/subscriptions.mjs.map +1 -1
- package/resources/top-level.d.ts +1 -2
- package/resources/top-level.d.ts.map +1 -1
- package/resources/top-level.js +0 -2
- package/resources/top-level.js.map +1 -1
- package/resources/top-level.mjs +0 -2
- package/resources/top-level.mjs.map +1 -1
- package/src/core.ts +23 -19
- package/src/error.ts +82 -125
- package/src/index.ts +334 -130
- package/src/resources/alerts.ts +117 -24
- package/src/resources/coupons/coupons.ts +13 -8
- package/src/resources/coupons/index.ts +2 -2
- package/src/resources/coupons/subscriptions.ts +2 -3
- package/src/resources/credit-notes.ts +45 -5
- package/src/resources/customers/balance-transactions.ts +10 -7
- package/src/resources/customers/costs.ts +7 -6
- package/src/resources/customers/credits/credits.ts +82 -32
- package/src/resources/customers/credits/index.ts +20 -20
- package/src/resources/customers/credits/ledger.ts +30 -24
- package/src/resources/customers/credits/top-ups.ts +16 -12
- package/src/resources/customers/customers.ts +70 -46
- package/src/resources/customers/index.ts +17 -17
- package/src/resources/dimensional-price-groups/dimensional-price-groups.ts +146 -0
- package/src/resources/dimensional-price-groups/external-dimensional-price-group-id.ts +20 -0
- package/src/resources/dimensional-price-groups/index.ts +10 -0
- package/src/resources/events/backfills.ts +17 -12
- package/src/resources/events/events.ts +42 -23
- package/src/resources/events/index.ts +15 -15
- package/src/resources/events/volume.ts +11 -22
- package/src/resources/index.ts +113 -67
- package/src/resources/invoice-line-items.ts +5 -4
- package/src/resources/invoices.ts +111 -34
- package/src/resources/items.ts +11 -17
- package/src/resources/metrics.ts +11 -17
- package/src/resources/plans/external-plan-id.ts +3 -14
- package/src/resources/plans/index.ts +9 -2
- package/src/resources/plans/plans.ts +425 -19
- package/src/resources/prices/external-price-id.ts +3 -14
- package/src/resources/prices/index.ts +8 -8
- package/src/resources/prices/prices.ts +471 -24
- package/src/resources/subscriptions.ts +9238 -440
- package/src/resources/top-level.ts +2 -3
- package/src/version.ts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
package/resources/metrics.d.ts
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { APIResource } from "../resource.js";
|
|
2
2
|
import * as Core from "../core.js";
|
|
3
|
-
import * as MetricsAPI from "./metrics.js";
|
|
4
3
|
import * as ItemsAPI from "./items.js";
|
|
5
4
|
import { Page, type PageParams } from "../pagination.js";
|
|
6
5
|
export declare class Metrics extends APIResource {
|
|
@@ -16,8 +15,7 @@ export declare class Metrics extends APIResource {
|
|
|
16
15
|
* pass `null` for the metadata value, it will clear any existing metadata for that
|
|
17
16
|
* invoice.
|
|
18
17
|
*/
|
|
19
|
-
update(metricId: string, body
|
|
20
|
-
update(metricId: string, options?: Core.RequestOptions): Core.APIPromise<BillableMetric>;
|
|
18
|
+
update(metricId: string, body: MetricUpdateParams, options?: Core.RequestOptions): Core.APIPromise<BillableMetric>;
|
|
21
19
|
/**
|
|
22
20
|
* This endpoint is used to fetch [metric](../guides/concepts#metric) details given
|
|
23
21
|
* a metric identifier. It returns information about the metrics including its
|
|
@@ -96,10 +94,6 @@ export interface MetricListParams extends PageParams {
|
|
|
96
94
|
'created_at[lte]'?: string | null;
|
|
97
95
|
}
|
|
98
96
|
export declare namespace Metrics {
|
|
99
|
-
export
|
|
100
|
-
export import BillableMetricsPage = MetricsAPI.BillableMetricsPage;
|
|
101
|
-
export import MetricCreateParams = MetricsAPI.MetricCreateParams;
|
|
102
|
-
export import MetricUpdateParams = MetricsAPI.MetricUpdateParams;
|
|
103
|
-
export import MetricListParams = MetricsAPI.MetricListParams;
|
|
97
|
+
export { type BillableMetric as BillableMetric, BillableMetricsPage as BillableMetricsPage, type MetricCreateParams as MetricCreateParams, type MetricUpdateParams as MetricUpdateParams, type MetricListParams as MetricListParams, };
|
|
104
98
|
}
|
|
105
99
|
//# sourceMappingURL=metrics.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"metrics.d.ts","sourceRoot":"","sources":["../src/resources/metrics.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAE1C,OAAO,KAAK,IAAI,MAAM,SAAS,CAAC;AAChC,OAAO,KAAK,
|
|
1
|
+
{"version":3,"file":"metrics.d.ts","sourceRoot":"","sources":["../src/resources/metrics.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAE1C,OAAO,KAAK,IAAI,MAAM,SAAS,CAAC;AAChC,OAAO,KAAK,QAAQ,MAAM,SAAS,CAAC;AACpC,OAAO,EAAE,IAAI,EAAE,KAAK,UAAU,EAAE,MAAM,eAAe,CAAC;AAEtD,qBAAa,OAAQ,SAAQ,WAAW;IACtC;;;;;OAKG;IACH,MAAM,CAAC,IAAI,EAAE,kBAAkB,EAAE,OAAO,CAAC,EAAE,IAAI,CAAC,cAAc,GAAG,IAAI,CAAC,UAAU,CAAC,cAAc,CAAC;IAIhG;;;;OAIG;IACH,MAAM,CACJ,QAAQ,EAAE,MAAM,EAChB,IAAI,EAAE,kBAAkB,EACxB,OAAO,CAAC,EAAE,IAAI,CAAC,cAAc,GAC5B,IAAI,CAAC,UAAU,CAAC,cAAc,CAAC;IAIlC;;;;OAIG;IACH,IAAI,CACF,KAAK,CAAC,EAAE,gBAAgB,EACxB,OAAO,CAAC,EAAE,IAAI,CAAC,cAAc,GAC5B,IAAI,CAAC,WAAW,CAAC,mBAAmB,EAAE,cAAc,CAAC;IACxD,IAAI,CAAC,OAAO,CAAC,EAAE,IAAI,CAAC,cAAc,GAAG,IAAI,CAAC,WAAW,CAAC,mBAAmB,EAAE,cAAc,CAAC;IAW1F;;;OAGG;IACH,KAAK,CAAC,QAAQ,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,IAAI,CAAC,cAAc,GAAG,IAAI,CAAC,UAAU,CAAC,cAAc,CAAC;CAGxF;AAED,qBAAa,mBAAoB,SAAQ,IAAI,CAAC,cAAc,CAAC;CAAG;AAEhE;;;;GAIG;AACH,MAAM,WAAW,cAAc;IAC7B,EAAE,EAAE,MAAM,CAAC;IAEX,WAAW,EAAE,MAAM,GAAG,IAAI,CAAC;IAE3B;;;;OAIG;IACH,IAAI,EAAE,QAAQ,CAAC,IAAI,CAAC;IAEpB;;;;;OAKG;IACH,QAAQ,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAEjC,IAAI,EAAE,MAAM,CAAC;IAEb,MAAM,EAAE,QAAQ,GAAG,OAAO,GAAG,UAAU,CAAC;CACzC;AAED,MAAM,WAAW,kBAAkB;IACjC;;OAEG;IACH,WAAW,EAAE,MAAM,GAAG,IAAI,CAAC;IAE3B;;OAEG;IACH,OAAO,EAAE,MAAM,CAAC;IAEhB;;OAEG;IACH,IAAI,EAAE,MAAM,CAAC;IAEb;;OAEG;IACH,GAAG,EAAE,MAAM,CAAC;IAEZ;;;;OAIG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,IAAI,CAAC,GAAG,IAAI,CAAC;CACjD;AAED,MAAM,WAAW,kBAAkB;IACjC;;;;OAIG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,IAAI,CAAC,GAAG,IAAI,CAAC;CACjD;AAED,MAAM,WAAW,gBAAiB,SAAQ,UAAU;IAClD,gBAAgB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAEjC,iBAAiB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAElC,gBAAgB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAEjC,iBAAiB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;CACnC;AAID,MAAM,CAAC,OAAO,WAAW,OAAO,CAAC;IAC/B,OAAO,EACL,KAAK,cAAc,IAAI,cAAc,EACrC,mBAAmB,IAAI,mBAAmB,EAC1C,KAAK,kBAAkB,IAAI,kBAAkB,EAC7C,KAAK,kBAAkB,IAAI,kBAAkB,EAC7C,KAAK,gBAAgB,IAAI,gBAAgB,GAC1C,CAAC;CACH"}
|
package/resources/metrics.js
CHANGED
|
@@ -1,33 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
3
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
4
|
-
if (k2 === undefined) k2 = k;
|
|
5
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
6
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
7
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
8
|
-
}
|
|
9
|
-
Object.defineProperty(o, k2, desc);
|
|
10
|
-
}) : (function(o, m, k, k2) {
|
|
11
|
-
if (k2 === undefined) k2 = k;
|
|
12
|
-
o[k2] = m[k];
|
|
13
|
-
}));
|
|
14
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
15
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
16
|
-
}) : function(o, v) {
|
|
17
|
-
o["default"] = v;
|
|
18
|
-
});
|
|
19
|
-
var __importStar = (this && this.__importStar) || function (mod) {
|
|
20
|
-
if (mod && mod.__esModule) return mod;
|
|
21
|
-
var result = {};
|
|
22
|
-
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
23
|
-
__setModuleDefault(result, mod);
|
|
24
|
-
return result;
|
|
25
|
-
};
|
|
26
3
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
27
4
|
exports.BillableMetricsPage = exports.Metrics = void 0;
|
|
28
5
|
const resource_1 = require("../resource.js");
|
|
29
6
|
const core_1 = require("../core.js");
|
|
30
|
-
const MetricsAPI = __importStar(require("./metrics.js"));
|
|
31
7
|
const pagination_1 = require("../pagination.js");
|
|
32
8
|
class Metrics extends resource_1.APIResource {
|
|
33
9
|
/**
|
|
@@ -39,10 +15,12 @@ class Metrics extends resource_1.APIResource {
|
|
|
39
15
|
create(body, options) {
|
|
40
16
|
return this._client.post('/metrics', { body, ...options });
|
|
41
17
|
}
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
18
|
+
/**
|
|
19
|
+
* This endpoint allows you to update the `metadata` property on a metric. If you
|
|
20
|
+
* pass `null` for the metadata value, it will clear any existing metadata for that
|
|
21
|
+
* invoice.
|
|
22
|
+
*/
|
|
23
|
+
update(metricId, body, options) {
|
|
46
24
|
return this._client.put(`/metrics/${metricId}`, { body, ...options });
|
|
47
25
|
}
|
|
48
26
|
list(query = {}, options) {
|
|
@@ -63,7 +41,5 @@ exports.Metrics = Metrics;
|
|
|
63
41
|
class BillableMetricsPage extends pagination_1.Page {
|
|
64
42
|
}
|
|
65
43
|
exports.BillableMetricsPage = BillableMetricsPage;
|
|
66
|
-
|
|
67
|
-
Metrics.BillableMetricsPage = MetricsAPI.BillableMetricsPage;
|
|
68
|
-
})(Metrics = exports.Metrics || (exports.Metrics = {}));
|
|
44
|
+
Metrics.BillableMetricsPage = BillableMetricsPage;
|
|
69
45
|
//# sourceMappingURL=metrics.js.map
|
package/resources/metrics.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"metrics.js","sourceRoot":"","sources":["../src/resources/metrics.ts"],"names":[],"mappings":";AAAA,sFAAsF
|
|
1
|
+
{"version":3,"file":"metrics.js","sourceRoot":"","sources":["../src/resources/metrics.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,6CAA0C;AAC1C,qCAA2C;AAG3C,iDAAsD;AAEtD,MAAa,OAAQ,SAAQ,sBAAW;IACtC;;;;;OAKG;IACH,MAAM,CAAC,IAAwB,EAAE,OAA6B;QAC5D,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,UAAU,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IAC7D,CAAC;IAED;;;;OAIG;IACH,MAAM,CACJ,QAAgB,EAChB,IAAwB,EACxB,OAA6B;QAE7B,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,YAAY,QAAQ,EAAE,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACxE,CAAC;IAYD,IAAI,CACF,QAAgD,EAAE,EAClD,OAA6B;QAE7B,IAAI,IAAA,uBAAgB,EAAC,KAAK,CAAC,EAAE;YAC3B,OAAO,IAAI,CAAC,IAAI,CAAC,EAAE,EAAE,KAAK,CAAC,CAAC;SAC7B;QACD,OAAO,IAAI,CAAC,OAAO,CAAC,UAAU,CAAC,UAAU,EAAE,mBAAmB,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACzF,CAAC;IAED;;;OAGG;IACH,KAAK,CAAC,QAAgB,EAAE,OAA6B;QACnD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,YAAY,QAAQ,EAAE,EAAE,OAAO,CAAC,CAAC;IAC3D,CAAC;CACF;AAnDD,0BAmDC;AAED,MAAa,mBAAoB,SAAQ,iBAAoB;CAAG;AAAhE,kDAAgE;AAgFhE,OAAO,CAAC,mBAAmB,GAAG,mBAAmB,CAAC"}
|
package/resources/metrics.mjs
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
import { APIResource } from "../resource.mjs";
|
|
3
3
|
import { isRequestOptions } from "../core.mjs";
|
|
4
|
-
import * as MetricsAPI from "./metrics.mjs";
|
|
5
4
|
import { Page } from "../pagination.mjs";
|
|
6
5
|
export class Metrics extends APIResource {
|
|
7
6
|
/**
|
|
@@ -13,10 +12,12 @@ export class Metrics extends APIResource {
|
|
|
13
12
|
create(body, options) {
|
|
14
13
|
return this._client.post('/metrics', { body, ...options });
|
|
15
14
|
}
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
15
|
+
/**
|
|
16
|
+
* This endpoint allows you to update the `metadata` property on a metric. If you
|
|
17
|
+
* pass `null` for the metadata value, it will clear any existing metadata for that
|
|
18
|
+
* invoice.
|
|
19
|
+
*/
|
|
20
|
+
update(metricId, body, options) {
|
|
20
21
|
return this._client.put(`/metrics/${metricId}`, { body, ...options });
|
|
21
22
|
}
|
|
22
23
|
list(query = {}, options) {
|
|
@@ -35,7 +36,5 @@ export class Metrics extends APIResource {
|
|
|
35
36
|
}
|
|
36
37
|
export class BillableMetricsPage extends Page {
|
|
37
38
|
}
|
|
38
|
-
|
|
39
|
-
Metrics.BillableMetricsPage = MetricsAPI.BillableMetricsPage;
|
|
40
|
-
})(Metrics || (Metrics = {}));
|
|
39
|
+
Metrics.BillableMetricsPage = BillableMetricsPage;
|
|
41
40
|
//# sourceMappingURL=metrics.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"metrics.mjs","sourceRoot":"","sources":["../src/resources/metrics.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;OACf,EAAE,gBAAgB,EAAE;
|
|
1
|
+
{"version":3,"file":"metrics.mjs","sourceRoot":"","sources":["../src/resources/metrics.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;OACf,EAAE,gBAAgB,EAAE;OAGpB,EAAE,IAAI,EAAmB;AAEhC,MAAM,OAAO,OAAQ,SAAQ,WAAW;IACtC;;;;;OAKG;IACH,MAAM,CAAC,IAAwB,EAAE,OAA6B;QAC5D,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,UAAU,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IAC7D,CAAC;IAED;;;;OAIG;IACH,MAAM,CACJ,QAAgB,EAChB,IAAwB,EACxB,OAA6B;QAE7B,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,YAAY,QAAQ,EAAE,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACxE,CAAC;IAYD,IAAI,CACF,QAAgD,EAAE,EAClD,OAA6B;QAE7B,IAAI,gBAAgB,CAAC,KAAK,CAAC,EAAE;YAC3B,OAAO,IAAI,CAAC,IAAI,CAAC,EAAE,EAAE,KAAK,CAAC,CAAC;SAC7B;QACD,OAAO,IAAI,CAAC,OAAO,CAAC,UAAU,CAAC,UAAU,EAAE,mBAAmB,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACzF,CAAC;IAED;;;OAGG;IACH,KAAK,CAAC,QAAgB,EAAE,OAA6B;QACnD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,YAAY,QAAQ,EAAE,EAAE,OAAO,CAAC,CAAC;IAC3D,CAAC;CACF;AAED,MAAM,OAAO,mBAAoB,SAAQ,IAAoB;CAAG;AAgFhE,OAAO,CAAC,mBAAmB,GAAG,mBAAmB,CAAC"}
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { APIResource } from "../../resource.js";
|
|
2
2
|
import * as Core from "../../core.js";
|
|
3
|
-
import * as ExternalPlanIDAPI from "./external-plan-id.js";
|
|
4
3
|
import * as PlansAPI from "./plans.js";
|
|
5
4
|
export declare class ExternalPlanID extends APIResource {
|
|
6
5
|
/**
|
|
@@ -9,8 +8,7 @@ export declare class ExternalPlanID extends APIResource {
|
|
|
9
8
|
*
|
|
10
9
|
* Other fields on a customer are currently immutable.
|
|
11
10
|
*/
|
|
12
|
-
update(otherExternalPlanId: string, body
|
|
13
|
-
update(otherExternalPlanId: string, options?: Core.RequestOptions): Core.APIPromise<PlansAPI.Plan>;
|
|
11
|
+
update(otherExternalPlanId: string, body: ExternalPlanIDUpdateParams, options?: Core.RequestOptions): Core.APIPromise<PlansAPI.Plan>;
|
|
14
12
|
/**
|
|
15
13
|
* This endpoint is used to fetch [plan](../guides/concepts##plan-and-price)
|
|
16
14
|
* details given an external_plan_id identifier. It returns information about the
|
|
@@ -46,6 +44,6 @@ export interface ExternalPlanIDUpdateParams {
|
|
|
46
44
|
metadata?: Record<string, string | null> | null;
|
|
47
45
|
}
|
|
48
46
|
export declare namespace ExternalPlanID {
|
|
49
|
-
export
|
|
47
|
+
export { type ExternalPlanIDUpdateParams as ExternalPlanIDUpdateParams };
|
|
50
48
|
}
|
|
51
49
|
//# sourceMappingURL=external-plan-id.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"external-plan-id.d.ts","sourceRoot":"","sources":["../../src/resources/plans/external-plan-id.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;
|
|
1
|
+
{"version":3,"file":"external-plan-id.d.ts","sourceRoot":"","sources":["../../src/resources/plans/external-plan-id.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAC7C,OAAO,KAAK,IAAI,MAAM,YAAY,CAAC;AACnC,OAAO,KAAK,QAAQ,MAAM,SAAS,CAAC;AAEpC,qBAAa,cAAe,SAAQ,WAAW;IAC7C;;;;;OAKG;IACH,MAAM,CACJ,mBAAmB,EAAE,MAAM,EAC3B,IAAI,EAAE,0BAA0B,EAChC,OAAO,CAAC,EAAE,IAAI,CAAC,cAAc,GAC5B,IAAI,CAAC,UAAU,CAAC,QAAQ,CAAC,IAAI,CAAC;IAIjC;;;;;;;;;;;;;;;;;OAiBG;IACH,KAAK,CAAC,cAAc,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,IAAI,CAAC,cAAc,GAAG,IAAI,CAAC,UAAU,CAAC,QAAQ,CAAC,IAAI,CAAC;CAG7F;AAED,MAAM,WAAW,0BAA0B;IACzC;;;;OAIG;IACH,gBAAgB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAEjC;;;;OAIG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,IAAI,CAAC,GAAG,IAAI,CAAC;CACjD;AAED,MAAM,CAAC,OAAO,WAAW,cAAc,CAAC;IACtC,OAAO,EAAE,KAAK,0BAA0B,IAAI,0BAA0B,EAAE,CAAC;CAC1E"}
|
|
@@ -3,12 +3,14 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
4
|
exports.ExternalPlanID = void 0;
|
|
5
5
|
const resource_1 = require("../../resource.js");
|
|
6
|
-
const core_1 = require("../../core.js");
|
|
7
6
|
class ExternalPlanID extends resource_1.APIResource {
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
7
|
+
/**
|
|
8
|
+
* This endpoint can be used to update the `external_plan_id`, and `metadata` of an
|
|
9
|
+
* existing plan.
|
|
10
|
+
*
|
|
11
|
+
* Other fields on a customer are currently immutable.
|
|
12
|
+
*/
|
|
13
|
+
update(otherExternalPlanId, body, options) {
|
|
12
14
|
return this._client.put(`/plans/external_plan_id/${otherExternalPlanId}`, { body, ...options });
|
|
13
15
|
}
|
|
14
16
|
/**
|
|
@@ -34,6 +36,4 @@ class ExternalPlanID extends resource_1.APIResource {
|
|
|
34
36
|
}
|
|
35
37
|
}
|
|
36
38
|
exports.ExternalPlanID = ExternalPlanID;
|
|
37
|
-
(function (ExternalPlanID) {
|
|
38
|
-
})(ExternalPlanID = exports.ExternalPlanID || (exports.ExternalPlanID = {}));
|
|
39
39
|
//# sourceMappingURL=external-plan-id.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"external-plan-id.js","sourceRoot":"","sources":["../../src/resources/plans/external-plan-id.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,gDAA6C;
|
|
1
|
+
{"version":3,"file":"external-plan-id.js","sourceRoot":"","sources":["../../src/resources/plans/external-plan-id.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,gDAA6C;AAI7C,MAAa,cAAe,SAAQ,sBAAW;IAC7C;;;;;OAKG;IACH,MAAM,CACJ,mBAA2B,EAC3B,IAAgC,EAChC,OAA6B;QAE7B,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,2BAA2B,mBAAmB,EAAE,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IAClG,CAAC;IAED;;;;;;;;;;;;;;;;;OAiBG;IACH,KAAK,CAAC,cAAsB,EAAE,OAA6B;QACzD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,2BAA2B,cAAc,EAAE,EAAE,OAAO,CAAC,CAAC;IAChF,CAAC;CACF;AApCD,wCAoCC"}
|
|
@@ -1,11 +1,13 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
import { APIResource } from "../../resource.mjs";
|
|
3
|
-
import { isRequestOptions } from "../../core.mjs";
|
|
4
3
|
export class ExternalPlanID extends APIResource {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
4
|
+
/**
|
|
5
|
+
* This endpoint can be used to update the `external_plan_id`, and `metadata` of an
|
|
6
|
+
* existing plan.
|
|
7
|
+
*
|
|
8
|
+
* Other fields on a customer are currently immutable.
|
|
9
|
+
*/
|
|
10
|
+
update(otherExternalPlanId, body, options) {
|
|
9
11
|
return this._client.put(`/plans/external_plan_id/${otherExternalPlanId}`, { body, ...options });
|
|
10
12
|
}
|
|
11
13
|
/**
|
|
@@ -30,6 +32,4 @@ export class ExternalPlanID extends APIResource {
|
|
|
30
32
|
return this._client.get(`/plans/external_plan_id/${externalPlanId}`, options);
|
|
31
33
|
}
|
|
32
34
|
}
|
|
33
|
-
(function (ExternalPlanID) {
|
|
34
|
-
})(ExternalPlanID || (ExternalPlanID = {}));
|
|
35
35
|
//# sourceMappingURL=external-plan-id.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"external-plan-id.mjs","sourceRoot":"","sources":["../../src/resources/plans/external-plan-id.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;
|
|
1
|
+
{"version":3,"file":"external-plan-id.mjs","sourceRoot":"","sources":["../../src/resources/plans/external-plan-id.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;AAItB,MAAM,OAAO,cAAe,SAAQ,WAAW;IAC7C;;;;;OAKG;IACH,MAAM,CACJ,mBAA2B,EAC3B,IAAgC,EAChC,OAA6B;QAE7B,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,2BAA2B,mBAAmB,EAAE,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IAClG,CAAC;IAED;;;;;;;;;;;;;;;;;OAiBG;IACH,KAAK,CAAC,cAAsB,EAAE,OAA6B;QACzD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,2BAA2B,cAAc,EAAE,EAAE,OAAO,CAAC,CAAC;IAChF,CAAC;CACF"}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export {
|
|
2
|
-
export { Plan, PlanCreateParams, PlanUpdateParams, PlanListParams,
|
|
1
|
+
export { ExternalPlanID, type ExternalPlanIDUpdateParams } from "./external-plan-id.js";
|
|
2
|
+
export { PlansPage, Plans, type Plan, type PlanCreateParams, type PlanUpdateParams, type PlanListParams, } from "./plans.js";
|
|
3
3
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/resources/plans/index.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/resources/plans/index.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,cAAc,EAAE,KAAK,0BAA0B,EAAE,MAAM,oBAAoB,CAAC;AACrF,OAAO,EACL,SAAS,EACT,KAAK,EACL,KAAK,IAAI,EACT,KAAK,gBAAgB,EACrB,KAAK,gBAAgB,EACrB,KAAK,cAAc,GACpB,MAAM,SAAS,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/resources/plans/index.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/resources/plans/index.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,0DAAqF;AAA5E,kHAAA,cAAc,OAAA;AACvB,oCAOiB;AANf,kGAAA,SAAS,OAAA;AACT,8FAAA,KAAK,OAAA"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
export { ExternalPlanID } from "./external-plan-id.mjs";
|
|
3
|
-
export { PlansPage, Plans } from "./plans.mjs";
|
|
3
|
+
export { PlansPage, Plans, } from "./plans.mjs";
|
|
4
4
|
//# sourceMappingURL=index.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","sourceRoot":"","sources":["../../src/resources/plans/index.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,
|
|
1
|
+
{"version":3,"file":"index.mjs","sourceRoot":"","sources":["../../src/resources/plans/index.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,cAAc,EAAmC;OACnD,EACL,SAAS,EACT,KAAK,GAKN"}
|