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
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
.prism.log
.vscode
_dev

__pycache__
Expand Down
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.8.1"
".": "4.9.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: 116
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/orb%2Forb-a44cccd16bb58080f7cc0669999403f6ed3f77287fad901caa6fd2523f2fbafd.yml
openapi_spec_hash: af6444648d0b2a70b7f7ad234bd37541
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/orb%2Forb-1aabbd8715a871e993abf67f0bf9c1d6793b4f197c4b2f11fc7a76453590cd6c.yml
openapi_spec_hash: 3e5878f87e74881d882a69e1ccdc25a3
config_hash: 1f535c1fa222aacf28b636eed21bec72
3 changes: 3 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"python.analysis.importFormat": "relative",
}
13 changes: 13 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,18 @@
# Changelog

## 4.9.0 (2025-07-24)

Full Changelog: [v4.8.1...v4.9.0](https://github.com/orbcorp/orb-python/compare/v4.8.1...v4.9.0)

### Features

* **api:** api update ([8eb1072](https://github.com/orbcorp/orb-python/commit/8eb107295f3e00437f5143d790884a35252639c0))


### Chores

* **project:** add settings file for vscode ([b95d016](https://github.com/orbcorp/orb-python/commit/b95d01634114df214eb92cdade208dcd3333b905))

## 4.8.1 (2025-07-22)

Full Changelog: [v4.8.0...v4.8.1](https://github.com/orbcorp/orb-python/compare/v4.8.0...v4.8.1)
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "orb-billing"
version = "4.8.1"
version = "4.9.0"
description = "The official Python library for the orb API"
dynamic = ["readme"]
license = "Apache-2.0"
Expand Down
2 changes: 1 addition & 1 deletion src/orb/_version.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.

__title__ = "orb"
__version__ = "4.8.1" # x-release-please-version
__version__ = "4.9.0" # x-release-please-version
8 changes: 4 additions & 4 deletions src/orb/resources/customers/costs.py
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ def list(
`grouping_value` and `secondary_grouping_value` available.

Args:
currency: The currency to use.
currency: The currency or custom pricing unit to use.

timeframe_end: Costs returned are exclusive of `timeframe_end`.

Expand Down Expand Up @@ -353,7 +353,7 @@ def list_by_external_id(
`grouping_value` and `secondary_grouping_value` available.

Args:
currency: The currency to use.
currency: The currency or custom pricing unit to use.

timeframe_end: Costs returned are exclusive of `timeframe_end`.

Expand Down Expand Up @@ -552,7 +552,7 @@ async def list(
`grouping_value` and `secondary_grouping_value` available.

Args:
currency: The currency to use.
currency: The currency or custom pricing unit to use.

timeframe_end: Costs returned are exclusive of `timeframe_end`.

Expand Down Expand Up @@ -728,7 +728,7 @@ async def list_by_external_id(
`grouping_value` and `secondary_grouping_value` available.

Args:
currency: The currency to use.
currency: The currency or custom pricing unit to use.

timeframe_end: Costs returned are exclusive of `timeframe_end`.

Expand Down
28 changes: 20 additions & 8 deletions src/orb/resources/customers/customers.py
Original file line number Diff line number Diff line change
Expand Up @@ -371,8 +371,11 @@ def update(

email: A valid customer email, to be used for invoicing and notifications.

external_customer_id: The external customer ID. This can only be set if empty and the customer has no
past or current subscriptions.
external_customer_id: The external customer ID. This can only be set if the customer has no existing
external customer ID. Since this action may change usage quantities for all
existing subscriptions, it is disallowed if the customer has issued invoices
with usage line items and subject to the same restrictions as backdated
subscription creation.

hierarchy: The hierarchical relationships for this customer.

Expand Down Expand Up @@ -880,8 +883,11 @@ def update_by_external_id(

email: A valid customer email, to be used for invoicing and notifications.

external_customer_id: The external customer ID. This can only be set if empty and the customer has no
past or current subscriptions.
external_customer_id: The external customer ID. This can only be set if the customer has no existing
external customer ID. Since this action may change usage quantities for all
existing subscriptions, it is disallowed if the customer has issued invoices
with usage line items and subject to the same restrictions as backdated
subscription creation.

hierarchy: The hierarchical relationships for this customer.

Expand Down Expand Up @@ -1370,8 +1376,11 @@ async def update(

email: A valid customer email, to be used for invoicing and notifications.

external_customer_id: The external customer ID. This can only be set if empty and the customer has no
past or current subscriptions.
external_customer_id: The external customer ID. This can only be set if the customer has no existing
external customer ID. Since this action may change usage quantities for all
existing subscriptions, it is disallowed if the customer has issued invoices
with usage line items and subject to the same restrictions as backdated
subscription creation.

hierarchy: The hierarchical relationships for this customer.

Expand Down Expand Up @@ -1879,8 +1888,11 @@ async def update_by_external_id(

email: A valid customer email, to be used for invoicing and notifications.

external_customer_id: The external customer ID. This can only be set if empty and the customer has no
past or current subscriptions.
external_customer_id: The external customer ID. This can only be set if the customer has no existing
external customer ID. Since this action may change usage quantities for all
existing subscriptions, it is disallowed if the customer has issued invoices
with usage line items and subject to the same restrictions as backdated
subscription creation.

hierarchy: The hierarchical relationships for this customer.

Expand Down
24 changes: 12 additions & 12 deletions src/orb/resources/invoices.py
Original file line number Diff line number Diff line change
Expand Up @@ -155,13 +155,13 @@ def update(
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
idempotency_key: str | None = None,
) -> Invoice:
"""This endpoint allows you to update the `metadata` property on an invoice.

If you
pass null for the metadata value, it will clear any existing metadata for that
invoice.
"""
This endpoint allows you to update the `metadata`, `net_terms`, and `due_date`
properties on an invoice. If you pass null for the metadata value, it will clear
any existing metadata for that invoice.

`metadata` can be modified regardless of invoice state.
`metadata` can be modified regardless of invoice state. `net_terms` and
`due_date` can only be modified if the invoice is in a `draft` state.

Args:
metadata: User-specified key/value pairs for the resource. Individual keys can be removed
Expand Down Expand Up @@ -695,13 +695,13 @@ async def update(
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
idempotency_key: str | None = None,
) -> Invoice:
"""This endpoint allows you to update the `metadata` property on an invoice.

If you
pass null for the metadata value, it will clear any existing metadata for that
invoice.
"""
This endpoint allows you to update the `metadata`, `net_terms`, and `due_date`
properties on an invoice. If you pass null for the metadata value, it will clear
any existing metadata for that invoice.

`metadata` can be modified regardless of invoice state.
`metadata` can be modified regardless of invoice state. `net_terms` and
`due_date` can only be modified if the invoice is in a `draft` state.

Args:
metadata: User-specified key/value pairs for the resource. Individual keys can be removed
Expand Down
4 changes: 2 additions & 2 deletions src/orb/resources/subscriptions.py
Original file line number Diff line number Diff line change
Expand Up @@ -833,7 +833,7 @@ def fetch_costs(
same day).

Args:
currency: The currency to use.
currency: The currency or custom pricing unit to use.

timeframe_end: Costs returned are exclusive of `timeframe_end`.

Expand Down Expand Up @@ -2919,7 +2919,7 @@ async def fetch_costs(
same day).

Args:
currency: The currency to use.
currency: The currency or custom pricing unit to use.

timeframe_end: Costs returned are exclusive of `timeframe_end`.

Expand Down
6 changes: 4 additions & 2 deletions src/orb/types/customer_update_by_external_id_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,10 @@ class CustomerUpdateByExternalIDParams(TypedDict, total=False):
external_customer_id: Optional[str]
"""The external customer ID.

This can only be set if empty and the customer has no past or current
subscriptions.
This can only be set if the customer has no existing external customer ID. Since
this action may change usage quantities for all existing subscriptions, it is
disallowed if the customer has issued invoices with usage line items and subject
to the same restrictions as backdated subscription creation.
"""

hierarchy: Optional[CustomerHierarchyConfigParam]
Expand Down
6 changes: 4 additions & 2 deletions src/orb/types/customer_update_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,10 @@ class CustomerUpdateParams(TypedDict, total=False):
external_customer_id: Optional[str]
"""The external customer ID.

This can only be set if empty and the customer has no past or current
subscriptions.
This can only be set if the customer has no existing external customer ID. Since
this action may change usage quantities for all existing subscriptions, it is
disallowed if the customer has issued invoices with usage line items and subject
to the same restrictions as backdated subscription creation.
"""

hierarchy: Optional[CustomerHierarchyConfigParam]
Expand Down
2 changes: 1 addition & 1 deletion src/orb/types/customers/cost_list_by_external_id_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@

class CostListByExternalIDParams(TypedDict, total=False):
currency: Optional[str]
"""The currency to use."""
"""The currency or custom pricing unit to use."""

timeframe_end: Annotated[Union[str, datetime, None], PropertyInfo(format="iso8601")]
"""Costs returned are exclusive of `timeframe_end`."""
Expand Down
2 changes: 1 addition & 1 deletion src/orb/types/customers/cost_list_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@

class CostListParams(TypedDict, total=False):
currency: Optional[str]
"""The currency to use."""
"""The currency or custom pricing unit to use."""

timeframe_end: Annotated[Union[str, datetime, None], PropertyInfo(format="iso8601")]
"""Costs returned are exclusive of `timeframe_end`."""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ class AddIncrementCreditLedgerEntryRequestParamsInvoiceSettings(TypedDict, total
saved payment method.
"""

net_terms: Required[int]
net_terms: Required[Optional[int]]
"""
The net terms determines the difference between the invoice date and the issue
date for the invoice. If you intend the invoice to be due on issue, set this
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ class AddIncrementCreditLedgerEntryRequestParamsInvoiceSettings(TypedDict, total
saved payment method.
"""

net_terms: Required[int]
net_terms: Required[Optional[int]]
"""
The net terms determines the difference between the invoice date and the issue
date for the invoice. If you intend the invoice to be due on issue, set this
Expand Down
2 changes: 1 addition & 1 deletion src/orb/types/subscription_fetch_costs_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@

class SubscriptionFetchCostsParams(TypedDict, total=False):
currency: Optional[str]
"""The currency to use."""
"""The currency or custom pricing unit to use."""

timeframe_end: Annotated[Union[str, datetime, None], PropertyInfo(format="iso8601")]
"""Costs returned are exclusive of `timeframe_end`."""
Expand Down