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.55.0"
".": "4.56.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-43a4d1d907fd25faa99fef58ba7afb3dd39fae36f955b29bfe27b4bfdaa0ee54.yml
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/orb%2Forb-2824cb456b8e3a7ce1ea34aa37a2c8e63d5b70425a5863502ffe1e1b1ef7efaf.yml
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
# Changelog

## 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)

### Features

* **api:** api update ([#503](https://github.com/orbcorp/orb-node/issues/503)) ([adb02a1](https://github.com/orbcorp/orb-node/commit/adb02a1782cfd36dfbe3ea308df59a4ce3c93482))

## 4.55.0 (2025-02-07)

Full Changelog: [v4.54.0...v4.55.0](https://github.com/orbcorp/orb-node/compare/v4.54.0...v4.55.0)
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "orb-billing",
"version": "4.55.0",
"version": "4.56.0",
"description": "The official TypeScript library for the Orb API",
"author": "Orb <team@withorb.com>",
"types": "dist/index.d.ts",
Expand Down
6 changes: 4 additions & 2 deletions src/resources/customers/balance-transactions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,8 @@ export interface BalanceTransactionCreateResponse {
| 'return_from_voiding'
| 'credit_note_applied'
| 'credit_note_voided'
| 'overpayment_refund';
| 'overpayment_refund'
| 'external_payment';

/**
* The value of the amount changed in the transaction.
Expand Down Expand Up @@ -155,7 +156,8 @@ export interface BalanceTransactionListResponse {
| 'return_from_voiding'
| 'credit_note_applied'
| 'credit_note_voided'
| 'overpayment_refund';
| 'overpayment_refund'
| 'external_payment';

/**
* The value of the amount changed in the transaction.
Expand Down
6 changes: 4 additions & 2 deletions src/resources/invoices.ts
Original file line number Diff line number Diff line change
Expand Up @@ -524,7 +524,8 @@ export namespace Invoice {
| 'return_from_voiding'
| 'credit_note_applied'
| 'credit_note_voided'
| 'overpayment_refund';
| 'overpayment_refund'
| 'external_payment';

/**
* The value of the amount changed in the transaction.
Expand Down Expand Up @@ -1734,7 +1735,8 @@ export namespace InvoiceFetchUpcomingResponse {
| 'return_from_voiding'
| 'credit_note_applied'
| 'credit_note_voided'
| 'overpayment_refund';
| 'overpayment_refund'
| 'external_payment';

/**
* The value of the amount changed in the transaction.
Expand Down
128 changes: 128 additions & 0 deletions src/resources/subscriptions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8156,6 +8156,11 @@ export namespace SubscriptionCreateParams {
}

export interface AddPrice {
/**
* The definition of a new allocation price to create and add to the subscription.
*/
allocation_price?: AddPrice.AllocationPrice | null;

/**
* @deprecated [DEPRECATED] Use add_adjustments instead. The subscription's
* discounts for this price.
Expand Down Expand Up @@ -8229,6 +8234,33 @@ export namespace SubscriptionCreateParams {
}

export namespace AddPrice {
/**
* The definition of a new allocation price to create and add to the subscription.
*/
export interface AllocationPrice {
/**
* An amount of the currency to allocate to the customer at the specified cadence.
*/
amount: string;

/**
* The cadence at which to allocate the amount to the customer.
*/
cadence: 'one_time' | 'monthly' | 'quarterly' | 'semi_annual' | 'annual' | 'custom';

/**
* An ISO 4217 currency string or a custom pricing unit identifier in which to bill
* this price.
*/
currency: string;

/**
* Whether the allocated amount should expire at the end of the cadence or roll
* over to the next period.
*/
expires_at_end_of_cadence: boolean;
}

export interface Discount {
discount_type: 'percentage' | 'usage' | 'amount';

Expand Down Expand Up @@ -10721,6 +10753,11 @@ export namespace SubscriptionCreateParams {
*/
replaces_price_id: string;

/**
* The definition of a new allocation price to create and add to the subscription.
*/
allocation_price?: ReplacePrice.AllocationPrice | null;

/**
* @deprecated [DEPRECATED] Use add_adjustments instead. The subscription's
* discounts for the replacement price.
Expand Down Expand Up @@ -10780,6 +10817,33 @@ export namespace SubscriptionCreateParams {
}

export namespace ReplacePrice {
/**
* The definition of a new allocation price to create and add to the subscription.
*/
export interface AllocationPrice {
/**
* An amount of the currency to allocate to the customer at the specified cadence.
*/
amount: string;

/**
* The cadence at which to allocate the amount to the customer.
*/
cadence: 'one_time' | 'monthly' | 'quarterly' | 'semi_annual' | 'annual' | 'custom';

/**
* An ISO 4217 currency string or a custom pricing unit identifier in which to bill
* this price.
*/
currency: string;

/**
* Whether the allocated amount should expire at the end of the cadence or roll
* over to the next period.
*/
expires_at_end_of_cadence: boolean;
}

export interface Discount {
discount_type: 'percentage' | 'usage' | 'amount';

Expand Down Expand Up @@ -17127,6 +17191,11 @@ export namespace SubscriptionSchedulePlanChangeParams {
}

export interface AddPrice {
/**
* The definition of a new allocation price to create and add to the subscription.
*/
allocation_price?: AddPrice.AllocationPrice | null;

/**
* @deprecated [DEPRECATED] Use add_adjustments instead. The subscription's
* discounts for this price.
Expand Down Expand Up @@ -17200,6 +17269,33 @@ export namespace SubscriptionSchedulePlanChangeParams {
}

export namespace AddPrice {
/**
* The definition of a new allocation price to create and add to the subscription.
*/
export interface AllocationPrice {
/**
* An amount of the currency to allocate to the customer at the specified cadence.
*/
amount: string;

/**
* The cadence at which to allocate the amount to the customer.
*/
cadence: 'one_time' | 'monthly' | 'quarterly' | 'semi_annual' | 'annual' | 'custom';

/**
* An ISO 4217 currency string or a custom pricing unit identifier in which to bill
* this price.
*/
currency: string;

/**
* Whether the allocated amount should expire at the end of the cadence or roll
* over to the next period.
*/
expires_at_end_of_cadence: boolean;
}

export interface Discount {
discount_type: 'percentage' | 'usage' | 'amount';

Expand Down Expand Up @@ -19692,6 +19788,11 @@ export namespace SubscriptionSchedulePlanChangeParams {
*/
replaces_price_id: string;

/**
* The definition of a new allocation price to create and add to the subscription.
*/
allocation_price?: ReplacePrice.AllocationPrice | null;

/**
* @deprecated [DEPRECATED] Use add_adjustments instead. The subscription's
* discounts for the replacement price.
Expand Down Expand Up @@ -19751,6 +19852,33 @@ export namespace SubscriptionSchedulePlanChangeParams {
}

export namespace ReplacePrice {
/**
* The definition of a new allocation price to create and add to the subscription.
*/
export interface AllocationPrice {
/**
* An amount of the currency to allocate to the customer at the specified cadence.
*/
amount: string;

/**
* The cadence at which to allocate the amount to the customer.
*/
cadence: 'one_time' | 'monthly' | 'quarterly' | 'semi_annual' | 'annual' | 'custom';

/**
* An ISO 4217 currency string or a custom pricing unit identifier in which to bill
* this price.
*/
currency: string;

/**
* Whether the allocated amount should expire at the end of the cadence or roll
* over to the next period.
*/
expires_at_end_of_cadence: boolean;
}

export interface Discount {
discount_type: 'percentage' | 'usage' | 'amount';

Expand Down
2 changes: 1 addition & 1 deletion src/version.ts
Original file line number Diff line number Diff line change
@@ -1 +1 @@
export const VERSION = '4.55.0'; // x-release-please-version
export const VERSION = '4.56.0'; // x-release-please-version
12 changes: 12 additions & 0 deletions tests/api-resources/subscriptions.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -263,6 +263,12 @@ describe('resource subscriptions', () => {
],
add_prices: [
{
allocation_price: {
amount: '10.00',
cadence: 'one_time',
currency: 'USD',
expires_at_end_of_cadence: true,
},
discounts: [
{
discount_type: 'percentage',
Expand Down Expand Up @@ -331,6 +337,12 @@ describe('resource subscriptions', () => {
replace_prices: [
{
replaces_price_id: 'replaces_price_id',
allocation_price: {
amount: '10.00',
cadence: 'one_time',
currency: 'USD',
expires_at_end_of_cadence: true,
},
discounts: [
{
discount_type: 'percentage',
Expand Down