From 5859f81b67cbdedc0911548f06121b5171bb924f Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Mon, 3 Nov 2025 22:31:28 +0000 Subject: [PATCH 1/2] feat(api): api update --- .stats.yml | 4 +-- src/orb/resources/beta/beta.py | 26 +++++-------------- src/orb/resources/beta/external_plan_id.py | 26 +++++-------------- ...dger_create_entry_by_external_id_params.py | 20 +++++++------- .../credits/ledger_create_entry_params.py | 20 +++++++------- .../customers/credits/test_ledger.py | 8 +++--- 6 files changed, 38 insertions(+), 66 deletions(-) diff --git a/.stats.yml b/.stats.yml index 62604532..5f8609e8 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 118 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/orb%2Forb-d1abf71a1a70a43bdcc4da7104dabcbd67aa7e2d3e6cf21e33f50904b6997bb2.yml -openapi_spec_hash: 28b0b31a997588cf3692458889321e1b +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/orb%2Forb-d74790c0b5540235e8387ccad7b806c11bcbb968fbdf99ea7dfbfc004bceb9dc.yml +openapi_spec_hash: eae212fa0114d8c3b4293c35f6ed7f7f config_hash: dd4343ce95871032ef6e0735a4ca038c diff --git a/src/orb/resources/beta/beta.py b/src/orb/resources/beta/beta.py index cdb2393e..eb85e15f 100644 --- a/src/orb/resources/beta/beta.py +++ b/src/orb/resources/beta/beta.py @@ -141,12 +141,9 @@ def fetch_plan_version( extra_body: Body | None = None, timeout: float | httpx.Timeout | None | NotGiven = not_given, ) -> PlanVersion: - """This API endpoint is in beta and its interface may change. + """This endpoint is used to fetch a plan version. - It is recommended for - use only in test mode. - - This endpoint is used to fetch a plan version. It returns the phases, prices, + It returns the phases, prices, and adjustments present on this version of the plan. Args: @@ -183,11 +180,7 @@ def set_default_plan_version( timeout: float | httpx.Timeout | None | NotGiven = not_given, idempotency_key: str | None = None, ) -> Plan: - """This API endpoint is in beta and its interface may change. - - It is recommended for - use only in test mode. - + """ This endpoint allows setting the default version of a plan. Args: @@ -334,12 +327,9 @@ async def fetch_plan_version( extra_body: Body | None = None, timeout: float | httpx.Timeout | None | NotGiven = not_given, ) -> PlanVersion: - """This API endpoint is in beta and its interface may change. + """This endpoint is used to fetch a plan version. - It is recommended for - use only in test mode. - - This endpoint is used to fetch a plan version. It returns the phases, prices, + It returns the phases, prices, and adjustments present on this version of the plan. Args: @@ -376,11 +366,7 @@ async def set_default_plan_version( timeout: float | httpx.Timeout | None | NotGiven = not_given, idempotency_key: str | None = None, ) -> Plan: - """This API endpoint is in beta and its interface may change. - - It is recommended for - use only in test mode. - + """ This endpoint allows setting the default version of a plan. Args: diff --git a/src/orb/resources/beta/external_plan_id.py b/src/orb/resources/beta/external_plan_id.py index 47f78c21..d76ecb35 100644 --- a/src/orb/resources/beta/external_plan_id.py +++ b/src/orb/resources/beta/external_plan_id.py @@ -131,12 +131,9 @@ def fetch_plan_version( extra_body: Body | None = None, timeout: float | httpx.Timeout | None | NotGiven = not_given, ) -> PlanVersion: - """This API endpoint is in beta and its interface may change. + """This endpoint is used to fetch a plan version. - It is recommended for - use only in test mode. - - This endpoint is used to fetch a plan version. It returns the phases, prices, + It returns the phases, prices, and adjustments present on this version of the plan. Args: @@ -173,11 +170,7 @@ def set_default_plan_version( timeout: float | httpx.Timeout | None | NotGiven = not_given, idempotency_key: str | None = None, ) -> Plan: - """This API endpoint is in beta and its interface may change. - - It is recommended for - use only in test mode. - + """ This endpoint allows setting the default version of a plan. Args: @@ -323,12 +316,9 @@ async def fetch_plan_version( extra_body: Body | None = None, timeout: float | httpx.Timeout | None | NotGiven = not_given, ) -> PlanVersion: - """This API endpoint is in beta and its interface may change. + """This endpoint is used to fetch a plan version. - It is recommended for - use only in test mode. - - This endpoint is used to fetch a plan version. It returns the phases, prices, + It returns the phases, prices, and adjustments present on this version of the plan. Args: @@ -365,11 +355,7 @@ async def set_default_plan_version( timeout: float | httpx.Timeout | None | NotGiven = not_given, idempotency_key: str | None = None, ) -> Plan: - """This API endpoint is in beta and its interface may change. - - It is recommended for - use only in test mode. - + """ This endpoint allows setting the default version of a plan. Args: diff --git a/src/orb/types/customers/credits/ledger_create_entry_by_external_id_params.py b/src/orb/types/customers/credits/ledger_create_entry_by_external_id_params.py index 7352286f..05d8b6ea 100644 --- a/src/orb/types/customers/credits/ledger_create_entry_by_external_id_params.py +++ b/src/orb/types/customers/credits/ledger_create_entry_by_external_id_params.py @@ -100,16 +100,6 @@ class AddIncrementCreditLedgerEntryRequestParamsInvoiceSettings(TypedDict, total saved payment method. """ - net_terms: Required[Optional[int]] - """The net terms determines the due date of the invoice. - - Due date is calculated based on the invoice or issuance date, depending on the - account's configured due date calculation method. A value of '0' here represents - that the invoice is due on issue, whereas a value of '30' represents that the - customer has 30 days to pay the invoice. Do not set this field if you want to - set a custom due date. - """ - custom_due_date: Annotated[Union[Union[str, date], Union[str, datetime], None], PropertyInfo(format="iso8601")] """An optional custom due date for the invoice. @@ -132,6 +122,16 @@ class AddIncrementCreditLedgerEntryRequestParamsInvoiceSettings(TypedDict, total memo: Optional[str] """An optional memo to display on the invoice.""" + net_terms: Optional[int] + """The net terms determines the due date of the invoice. + + Due date is calculated based on the invoice or issuance date, depending on the + account's configured due date calculation method. A value of '0' here represents + that the invoice is due on issue, whereas a value of '30' represents that the + customer has 30 days to pay the invoice. Do not set this field if you want to + set a custom due date. + """ + require_successful_payment: bool """ If true, the new credit block will require that the corresponding invoice is diff --git a/src/orb/types/customers/credits/ledger_create_entry_params.py b/src/orb/types/customers/credits/ledger_create_entry_params.py index 6aacb4df..55843f66 100644 --- a/src/orb/types/customers/credits/ledger_create_entry_params.py +++ b/src/orb/types/customers/credits/ledger_create_entry_params.py @@ -100,16 +100,6 @@ class AddIncrementCreditLedgerEntryRequestParamsInvoiceSettings(TypedDict, total saved payment method. """ - net_terms: Required[Optional[int]] - """The net terms determines the due date of the invoice. - - Due date is calculated based on the invoice or issuance date, depending on the - account's configured due date calculation method. A value of '0' here represents - that the invoice is due on issue, whereas a value of '30' represents that the - customer has 30 days to pay the invoice. Do not set this field if you want to - set a custom due date. - """ - custom_due_date: Annotated[Union[Union[str, date], Union[str, datetime], None], PropertyInfo(format="iso8601")] """An optional custom due date for the invoice. @@ -132,6 +122,16 @@ class AddIncrementCreditLedgerEntryRequestParamsInvoiceSettings(TypedDict, total memo: Optional[str] """An optional memo to display on the invoice.""" + net_terms: Optional[int] + """The net terms determines the due date of the invoice. + + Due date is calculated based on the invoice or issuance date, depending on the + account's configured due date calculation method. A value of '0' here represents + that the invoice is due on issue, whereas a value of '30' represents that the + customer has 30 days to pay the invoice. Do not set this field if you want to + set a custom due date. + """ + require_successful_payment: bool """ If true, the new credit block will require that the corresponding invoice is diff --git a/tests/api_resources/customers/credits/test_ledger.py b/tests/api_resources/customers/credits/test_ledger.py index c5f0af21..f3cf3ee6 100644 --- a/tests/api_resources/customers/credits/test_ledger.py +++ b/tests/api_resources/customers/credits/test_ledger.py @@ -107,11 +107,11 @@ def test_method_create_entry_with_all_params_overload_1(self, client: Orb) -> No ], invoice_settings={ "auto_collection": True, - "net_terms": 0, "custom_due_date": parse_date("2019-12-27"), "invoice_date": parse_date("2019-12-27"), "item_id": "item_id", "memo": "memo", + "net_terms": 0, "require_successful_payment": True, }, metadata={"foo": "string"}, @@ -430,11 +430,11 @@ def test_method_create_entry_by_external_id_with_all_params_overload_1(self, cli ], invoice_settings={ "auto_collection": True, - "net_terms": 0, "custom_due_date": parse_date("2019-12-27"), "invoice_date": parse_date("2019-12-27"), "item_id": "item_id", "memo": "memo", + "net_terms": 0, "require_successful_payment": True, }, metadata={"foo": "string"}, @@ -869,11 +869,11 @@ async def test_method_create_entry_with_all_params_overload_1(self, async_client ], invoice_settings={ "auto_collection": True, - "net_terms": 0, "custom_due_date": parse_date("2019-12-27"), "invoice_date": parse_date("2019-12-27"), "item_id": "item_id", "memo": "memo", + "net_terms": 0, "require_successful_payment": True, }, metadata={"foo": "string"}, @@ -1192,11 +1192,11 @@ async def test_method_create_entry_by_external_id_with_all_params_overload_1(sel ], invoice_settings={ "auto_collection": True, - "net_terms": 0, "custom_due_date": parse_date("2019-12-27"), "invoice_date": parse_date("2019-12-27"), "item_id": "item_id", "memo": "memo", + "net_terms": 0, "require_successful_payment": True, }, metadata={"foo": "string"}, From 14ede688e191d57ecdd4aacb0ffe3b921bb6a23b Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Mon, 3 Nov 2025 22:31:48 +0000 Subject: [PATCH 2/2] release: 4.34.0 --- .release-please-manifest.json | 2 +- CHANGELOG.md | 8 ++++++++ pyproject.toml | 2 +- src/orb/_version.py | 2 +- 4 files changed, 11 insertions(+), 3 deletions(-) diff --git a/.release-please-manifest.json b/.release-please-manifest.json index 14292ece..7dc692e1 100644 --- a/.release-please-manifest.json +++ b/.release-please-manifest.json @@ -1,3 +1,3 @@ { - ".": "4.33.1" + ".": "4.34.0" } \ No newline at end of file diff --git a/CHANGELOG.md b/CHANGELOG.md index e35449cb..8b2df4aa 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,13 @@ # Changelog +## 4.34.0 (2025-11-03) + +Full Changelog: [v4.33.1...v4.34.0](https://github.com/orbcorp/orb-python/compare/v4.33.1...v4.34.0) + +### Features + +* **api:** api update ([5859f81](https://github.com/orbcorp/orb-python/commit/5859f81b67cbdedc0911548f06121b5171bb924f)) + ## 4.33.1 (2025-11-03) Full Changelog: [v4.33.0...v4.33.1](https://github.com/orbcorp/orb-python/compare/v4.33.0...v4.33.1) diff --git a/pyproject.toml b/pyproject.toml index 12e9633a..c565c0ae 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "orb-billing" -version = "4.33.1" +version = "4.34.0" description = "The official Python library for the orb API" dynamic = ["readme"] license = "Apache-2.0" diff --git a/src/orb/_version.py b/src/orb/_version.py index 40d267da..17996266 100644 --- a/src/orb/_version.py +++ b/src/orb/_version.py @@ -1,4 +1,4 @@ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. __title__ = "orb" -__version__ = "4.33.1" # x-release-please-version +__version__ = "4.34.0" # x-release-please-version