From a83de7ed9822100c5391c7af937accbba3bfdb23 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Mon, 14 Jul 2025 17:30:26 +0000 Subject: [PATCH 1/4] feat: clean up environment call outs --- README.md | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/README.md b/README.md index 16abab576..0bac60aee 100644 --- a/README.md +++ b/README.md @@ -89,7 +89,6 @@ pip install increase[aiohttp] Then you can enable it by instantiating the client with `http_client=DefaultAioHttpClient()`: ```python -import os import asyncio from increase import DefaultAioHttpClient from increase import AsyncIncrease @@ -97,7 +96,7 @@ from increase import AsyncIncrease async def main() -> None: async with AsyncIncrease( - api_key=os.environ.get("INCREASE_API_KEY"), # This is the default and can be omitted + api_key="My API Key", http_client=DefaultAioHttpClient(), ) as client: account = await client.accounts.create( From 54cae4e241e105cc7a18363345dd2683dc892767 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Thu, 17 Jul 2025 19:31:26 +0000 Subject: [PATCH 2/4] codegen metadata --- .stats.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.stats.yml b/.stats.yml index 076aae75a..e5f614ec2 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 202 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/increase%2Fincrease-c9d527ceb849bd9a01edc968016381f25fcc375a1409eb113d7e876ae0f2f529.yml -openapi_spec_hash: c7820089282fc6db267d08eaa465075f +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/increase%2Fincrease-c3c84498ed204ebe6297ac77700cd63bf1353915e4577508baabf8ed1e4201ae.yml +openapi_spec_hash: e6cfa093a4bba7d0d1961515b0aed651 config_hash: a185e9a72778cc4658ea73fb3a7f1354 From 57fbc268c42bf896250f2e3222392c420eb4f91d Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Fri, 18 Jul 2025 17:10:23 +0000 Subject: [PATCH 3/4] feat(api): api update --- .stats.yml | 4 ++-- src/increase/resources/accounts.py | 24 +++++++++++++++++++-- src/increase/types/account_update_params.py | 6 ++++++ tests/api_resources/test_accounts.py | 2 ++ 4 files changed, 32 insertions(+), 4 deletions(-) diff --git a/.stats.yml b/.stats.yml index e5f614ec2..b26d90908 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 202 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/increase%2Fincrease-c3c84498ed204ebe6297ac77700cd63bf1353915e4577508baabf8ed1e4201ae.yml -openapi_spec_hash: e6cfa093a4bba7d0d1961515b0aed651 +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/increase%2Fincrease-7f26440e2137fb4f39521c361e76d56bad7c56d81cd06d0677d7735e73f7c160.yml +openapi_spec_hash: aa475d425f493e41eb8485ae17a3d0f9 config_hash: a185e9a72778cc4658ea73fb3a7f1354 diff --git a/src/increase/resources/accounts.py b/src/increase/resources/accounts.py index c524fd217..b3a417e50 100644 --- a/src/increase/resources/accounts.py +++ b/src/increase/resources/accounts.py @@ -145,6 +145,7 @@ def update( self, account_id: str, *, + credit_limit: int | NotGiven = NOT_GIVEN, name: str | NotGiven = NOT_GIVEN, # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs. # The extra values given here take precedence over values defined on the client or passed to this method. @@ -160,6 +161,9 @@ def update( Args: account_id: The identifier of the Account to update. + credit_limit: The new credit limit of the Account, if and only if the Account is a loan + account. + name: The new name of the Account. extra_headers: Send extra headers @@ -176,7 +180,13 @@ def update( raise ValueError(f"Expected a non-empty value for `account_id` but received {account_id!r}") return self._patch( f"/accounts/{account_id}", - body=maybe_transform({"name": name}, account_update_params.AccountUpdateParams), + body=maybe_transform( + { + "credit_limit": credit_limit, + "name": name, + }, + account_update_params.AccountUpdateParams, + ), options=make_request_options( extra_headers=extra_headers, extra_query=extra_query, @@ -464,6 +474,7 @@ async def update( self, account_id: str, *, + credit_limit: int | NotGiven = NOT_GIVEN, name: str | NotGiven = NOT_GIVEN, # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs. # The extra values given here take precedence over values defined on the client or passed to this method. @@ -479,6 +490,9 @@ async def update( Args: account_id: The identifier of the Account to update. + credit_limit: The new credit limit of the Account, if and only if the Account is a loan + account. + name: The new name of the Account. extra_headers: Send extra headers @@ -495,7 +509,13 @@ async def update( raise ValueError(f"Expected a non-empty value for `account_id` but received {account_id!r}") return await self._patch( f"/accounts/{account_id}", - body=await async_maybe_transform({"name": name}, account_update_params.AccountUpdateParams), + body=await async_maybe_transform( + { + "credit_limit": credit_limit, + "name": name, + }, + account_update_params.AccountUpdateParams, + ), options=make_request_options( extra_headers=extra_headers, extra_query=extra_query, diff --git a/src/increase/types/account_update_params.py b/src/increase/types/account_update_params.py index 86ec914d0..32eaaba0f 100644 --- a/src/increase/types/account_update_params.py +++ b/src/increase/types/account_update_params.py @@ -8,5 +8,11 @@ class AccountUpdateParams(TypedDict, total=False): + credit_limit: int + """ + The new credit limit of the Account, if and only if the Account is a loan + account. + """ + name: str """The new name of the Account.""" diff --git a/tests/api_resources/test_accounts.py b/tests/api_resources/test_accounts.py index f87c593ed..d445753d8 100644 --- a/tests/api_resources/test_accounts.py +++ b/tests/api_resources/test_accounts.py @@ -112,6 +112,7 @@ def test_method_update(self, client: Increase) -> None: def test_method_update_with_all_params(self, client: Increase) -> None: account = client.accounts.update( account_id="account_in71c4amph0vgo2qllky", + credit_limit=0, name="My renamed account", ) assert_matches_type(Account, account, path=["response"]) @@ -371,6 +372,7 @@ async def test_method_update(self, async_client: AsyncIncrease) -> None: async def test_method_update_with_all_params(self, async_client: AsyncIncrease) -> None: account = await async_client.accounts.update( account_id="account_in71c4amph0vgo2qllky", + credit_limit=0, name="My renamed account", ) assert_matches_type(Account, account, path=["response"]) From 2bb7e25ba6236119054c835118cc2878944b18f8 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Fri, 18 Jul 2025 17:10:46 +0000 Subject: [PATCH 4/4] release: 0.266.0 --- .release-please-manifest.json | 2 +- CHANGELOG.md | 9 +++++++++ pyproject.toml | 2 +- src/increase/_version.py | 2 +- 4 files changed, 12 insertions(+), 3 deletions(-) diff --git a/.release-please-manifest.json b/.release-please-manifest.json index c8ed07941..a587f67dd 100644 --- a/.release-please-manifest.json +++ b/.release-please-manifest.json @@ -1,3 +1,3 @@ { - ".": "0.265.0" + ".": "0.266.0" } \ No newline at end of file diff --git a/CHANGELOG.md b/CHANGELOG.md index 7c5604f00..4f2c486af 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,14 @@ # Changelog +## 0.266.0 (2025-07-18) + +Full Changelog: [v0.265.0...v0.266.0](https://github.com/Increase/increase-python/compare/v0.265.0...v0.266.0) + +### Features + +* **api:** api update ([57fbc26](https://github.com/Increase/increase-python/commit/57fbc268c42bf896250f2e3222392c420eb4f91d)) +* clean up environment call outs ([a83de7e](https://github.com/Increase/increase-python/commit/a83de7ed9822100c5391c7af937accbba3bfdb23)) + ## 0.265.0 (2025-07-11) Full Changelog: [v0.264.0...v0.265.0](https://github.com/Increase/increase-python/compare/v0.264.0...v0.265.0) diff --git a/pyproject.toml b/pyproject.toml index 3df61dac1..60ab96bed 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "increase" -version = "0.265.0" +version = "0.266.0" description = "The official Python library for the increase API" dynamic = ["readme"] license = "Apache-2.0" diff --git a/src/increase/_version.py b/src/increase/_version.py index 478d15b2e..243a8bbe0 100644 --- a/src/increase/_version.py +++ b/src/increase/_version.py @@ -1,4 +1,4 @@ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. __title__ = "increase" -__version__ = "0.265.0" # x-release-please-version +__version__ = "0.266.0" # x-release-please-version