Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
".": "4.56.0"
".": "4.57.0"
}
2 changes: 1 addition & 1 deletion .stats.yml
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
configured_endpoints: 103
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/orb%2Forb-2824cb456b8e3a7ce1ea34aa37a2c8e63d5b70425a5863502ffe1e1b1ef7efaf.yml
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/orb%2Forb-4dede72b827939939b5386cda07c3bc1fa2eea79901819792c1820e8531718d6.yml
14 changes: 14 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,19 @@
# Changelog

## 4.57.0 (2025-02-15)

Full Changelog: [v4.56.0...v4.57.0](https://github.com/orbcorp/orb-node/compare/v4.56.0...v4.57.0)

### Features

* **api:** api update ([#506](https://github.com/orbcorp/orb-node/issues/506)) ([a8ca5ec](https://github.com/orbcorp/orb-node/commit/a8ca5ec2ac40fc2394b66040c747e53079518ddb))
* **api:** api update ([#508](https://github.com/orbcorp/orb-node/issues/508)) ([e491b0e](https://github.com/orbcorp/orb-node/commit/e491b0ef6a2ac3138847b5dcdda888f5f90a9218))


### Bug Fixes

* **client:** fix export map for index exports ([#509](https://github.com/orbcorp/orb-node/issues/509)) ([c994913](https://github.com/orbcorp/orb-node/commit/c9949137fca48db8aed4d430cff6dd934a99a220))

## 4.56.0 (2025-02-11)

Full Changelog: [v4.55.0...v4.56.0](https://github.com/orbcorp/orb-node/compare/v4.55.0...v4.56.0)
Expand Down
37 changes: 29 additions & 8 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "orb-billing",
"version": "4.56.0",
"version": "4.57.0",
"description": "The official TypeScript library for the Orb API",
"author": "Orb <[email protected]>",
"types": "dist/index.d.ts",
Expand Down Expand Up @@ -107,17 +107,38 @@
"default": "./dist/index.mjs"
},
"./*.mjs": {
"types": "./dist/*.d.ts",
"default": "./dist/*.mjs"
"types": [
"./dist/*.d.ts",
"./dist/*/index.d.ts"
],
"default": [
"./dist/*.mjs",
"./dist/*/index.mjs"
]
},
"./*.js": {
"types": "./dist/*.d.ts",
"default": "./dist/*.js"
"types": [
"./dist/*.d.ts",
"./dist/*/index.d.ts"
],
"default": [
"./dist/*.js",
"./dist/*/index.js"
]
},
"./*": {
"types": "./dist/*.d.ts",
"require": "./dist/*.js",
"default": "./dist/*.mjs"
"types": [
"./dist/*.d.ts",
"./dist/*/index.d.ts"
],
"require": [
"./dist/*.js",
"./dist/*/index.js"
],
"default": [
"./dist/*.mjs",
"./dist/*/index.mjs"
]
}
}
}
32 changes: 12 additions & 20 deletions src/resources/customers/costs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -311,19 +311,15 @@ export namespace CostListResponse {
export namespace Data {
export interface PerPriceCost {
/**
* The Price resource represents a price that can be billed on a subscription,
* resulting in a charge on an invoice in the form of an invoice line item. Prices
* take a quantity and determine an amount to bill.
*
* Orb supports a few different pricing models out of the box. Each of these models
* is serialized differently in a given Price object. The model_type field
* determines the key for the configuration object that is present.
*
* For more on the types of prices, see
* [the core concepts documentation](/core-concepts#plan-and-price)
* The price object
*/
price: PricesAPI.Price;

/**
* The price the cost is associated with
*/
price_id: string;

/**
* Price's contributions for the timeframe, excluding any minimums and discounts.
*/
Expand Down Expand Up @@ -368,19 +364,15 @@ export namespace CostListByExternalIDResponse {
export namespace Data {
export interface PerPriceCost {
/**
* The Price resource represents a price that can be billed on a subscription,
* resulting in a charge on an invoice in the form of an invoice line item. Prices
* take a quantity and determine an amount to bill.
*
* Orb supports a few different pricing models out of the box. Each of these models
* is serialized differently in a given Price object. The model_type field
* determines the key for the configuration object that is present.
*
* For more on the types of prices, see
* [the core concepts documentation](/core-concepts#plan-and-price)
* The price object
*/
price: PricesAPI.Price;

/**
* The price the cost is associated with
*/
price_id: string;

/**
* Price's contributions for the timeframe, excluding any minimums and discounts.
*/
Expand Down
114 changes: 114 additions & 0 deletions src/resources/plans/plans.ts
Original file line number Diff line number Diff line change
Expand Up @@ -500,6 +500,7 @@ export interface PlanCreateParams {
| PlanCreateParams.NewPlanMaxGroupTieredPackagePrice
| PlanCreateParams.NewPlanScalableMatrixWithUnitPricingPrice
| PlanCreateParams.NewPlanScalableMatrixWithTieredPricingPrice
| PlanCreateParams.NewPlanCumulativeGroupedBulkPrice
>;

/**
Expand Down Expand Up @@ -3413,6 +3414,119 @@ export namespace PlanCreateParams {
duration_unit: 'day' | 'month';
}
}

export interface NewPlanCumulativeGroupedBulkPrice {
/**
* The cadence to bill for this price on.
*/
cadence: 'annual' | 'semi_annual' | 'monthly' | 'quarterly' | 'one_time' | 'custom';

cumulative_grouped_bulk_config: Record<string, unknown>;

/**
* The id of the item the plan will be associated with.
*/
item_id: string;

model_type: 'cumulative_grouped_bulk';

/**
* The name of the price.
*/
name: string;

/**
* The id of the billable metric for the price. Only needed if the price is
* usage-based.
*/
billable_metric_id?: string | null;

/**
* If the Price represents a fixed cost, the price will be billed in-advance if
* this is true, and in-arrears if this is false.
*/
billed_in_advance?: boolean | null;

/**
* For custom cadence: specifies the duration of the billing period in days or
* months.
*/
billing_cycle_configuration?: NewPlanCumulativeGroupedBulkPrice.BillingCycleConfiguration | null;

/**
* The per unit conversion rate of the price currency to the invoicing currency.
*/
conversion_rate?: number | null;

/**
* An ISO 4217 currency string, or custom pricing unit identifier, in which this
* price is billed.
*/
currency?: string | null;

/**
* An alias for the price.
*/
external_price_id?: string | null;

/**
* If the Price represents a fixed cost, this represents the quantity of units
* applied.
*/
fixed_price_quantity?: number | null;

/**
* The property used to group this price on an invoice
*/
invoice_grouping_key?: string | null;

/**
* Within each billing cycle, specifies the cadence at which invoices are produced.
* If unspecified, a single invoice is produced per billing cycle.
*/
invoicing_cycle_configuration?: NewPlanCumulativeGroupedBulkPrice.InvoicingCycleConfiguration | null;

/**
* User-specified key/value pairs for the resource. Individual keys can be removed
* by setting the value to `null`, and the entire metadata mapping can be cleared
* by setting `metadata` to `null`.
*/
metadata?: Record<string, string | null> | null;
}

export namespace NewPlanCumulativeGroupedBulkPrice {
/**
* For custom cadence: specifies the duration of the billing period in days or
* months.
*/
export interface BillingCycleConfiguration {
/**
* The duration of the billing period.
*/
duration: number;

/**
* The unit of billing period duration.
*/
duration_unit: 'day' | 'month';
}

/**
* Within each billing cycle, specifies the cadence at which invoices are produced.
* If unspecified, a single invoice is produced per billing cycle.
*/
export interface InvoicingCycleConfiguration {
/**
* The duration of the billing period.
*/
duration: number;

/**
* The unit of billing period duration.
*/
duration_unit: 'day' | 'month';
}
}
}

export interface PlanUpdateParams {
Expand Down
Loading