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 @@
{
".": "5.16.0"
".": "5.17.0"
}
4 changes: 2 additions & 2 deletions .stats.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
configured_endpoints: 118
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/orb%2Forb-b070c1d97a6e3b400f43d2bce36c22ed89d432345b26374728c55dd0a20f0afa.yml
openapi_spec_hash: dba4ff52c381cda6159fc56d8b77eb32
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/orb%2Forb-15e42bc01739abea4a925894a1a7de447de40b003a3433461952e8e06919588b.yml
openapi_spec_hash: 8a0bc5b6ab417f7256cbf83d70c459a3
config_hash: 1f73a949b649ecfe6ec68ba1bb459dc2
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
# Changelog

## 5.17.0 (2025-10-10)

Full Changelog: [v5.16.0...v5.17.0](https://github.com/orbcorp/orb-node/compare/v5.16.0...v5.17.0)

### Features

* **api:** api update ([e8f7516](https://github.com/orbcorp/orb-node/commit/e8f7516e596c23f8d54b36bdc646e25860ce14c2))

## 5.16.0 (2025-10-07)

Full Changelog: [v5.15.0...v5.16.0](https://github.com/orbcorp/orb-node/compare/v5.15.0...v5.16.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": "5.16.0",
"version": "5.17.0",
"description": "The official TypeScript library for the Orb API",
"author": "Orb <team@withorb.com>",
"types": "dist/index.d.ts",
Expand Down
35 changes: 29 additions & 6 deletions src/resources/invoice-line-items.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,17 @@ export class InvoiceLineItems extends APIResource {
/**
* This creates a one-off fixed fee invoice line item on an Invoice. This can only
* be done for invoices that are in a `draft` status.
*
* The behavior depends on which parameters are provided:
*
* - If `item_id` is provided without `name`: The item is looked up by ID, and the
* item's name is used for the line item.
* - If `name` is provided without `item_id`: An item with the given name is
* searched for in the account. If found, that item is used. If not found, a new
* item is created with that name. The new item's name is used for the line item.
* - If both `item_id` and `name` are provided: The item is looked up by ID for
* association, but the provided `name` is used for the line item (not the item's
* name).
*/
create(
body: InvoiceLineItemCreateParams,
Expand Down Expand Up @@ -168,12 +179,6 @@ export interface InvoiceLineItemCreateParams {
*/
invoice_id: string;

/**
* The item name associated with this line item. If an item with the same name
* exists in Orb, that item will be associated with the line item.
*/
name: string;

/**
* The number of units on the line item
*/
Expand All @@ -183,6 +188,24 @@ export interface InvoiceLineItemCreateParams {
* A date string to specify the line item's start date in the customer's timezone.
*/
start_date: string;

/**
* The id of the item to associate with this line item. If provided without `name`,
* the item's name will be used for the price/line item. If provided with `name`,
* the item will be associated but `name` will be used for the line item. At least
* one of `name` or `item_id` must be provided.
*/
item_id?: string | null;

/**
* The name to use for the line item. If `item_id` is not provided, Orb will search
* for an item with this name. If found, that item will be associated with the line
* item. If not found, a new item will be created with this name. If `item_id` is
* provided, this name will be used for the line item, but the item association
* will be based on `item_id`. At least one of `name` or `item_id` must be
* provided.
*/
name?: string | null;
}

export declare namespace InvoiceLineItems {
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 = '5.16.0'; // x-release-please-version
export const VERSION = '5.17.0'; // x-release-please-version
4 changes: 2 additions & 2 deletions tests/api-resources/invoice-line-items.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ describe('resource invoiceLineItems', () => {
amount: '12.00',
end_date: '2023-09-22',
invoice_id: '4khy3nwzktxv7',
name: 'Item Name',
quantity: 1,
start_date: '2023-09-22',
});
Expand All @@ -32,9 +31,10 @@ describe('resource invoiceLineItems', () => {
amount: '12.00',
end_date: '2023-09-22',
invoice_id: '4khy3nwzktxv7',
name: 'Item Name',
quantity: 1,
start_date: '2023-09-22',
item_id: '4khy3nwzktxv7',
name: 'Item Name',
});
});
});