From 2e77ad270e3eebe335d631e69c5e156e64af859c Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Thu, 27 Feb 2025 21:56:21 +0000 Subject: [PATCH 1/4] docs: update URLs from stainlessapi.com to stainless.com (#987) More details at https://www.stainless.com/changelog/stainless-com --- SECURITY.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/SECURITY.md b/SECURITY.md index c0967acc5..0f599b6d3 100644 --- a/SECURITY.md +++ b/SECURITY.md @@ -2,9 +2,9 @@ ## Reporting Security Issues -This SDK is generated by [Stainless Software Inc](http://stainlessapi.com). Stainless takes security seriously, and encourages you to report any security vulnerability promptly so that appropriate action can be taken. +This SDK is generated by [Stainless Software Inc](http://stainless.com). Stainless takes security seriously, and encourages you to report any security vulnerability promptly so that appropriate action can be taken. -To report a security issue, please contact the Stainless team at security@stainlessapi.com. +To report a security issue, please contact the Stainless team at security@stainless.com. ## Responsible Disclosure From 4cdb97608cb2b0ea3a803e3d387fa0c67bf73594 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Thu, 27 Feb 2025 22:48:26 +0000 Subject: [PATCH 2/4] chore(docs): update client docstring (#989) --- src/increase/_client.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/increase/_client.py b/src/increase/_client.py index da2e8a779..492fe8abd 100644 --- a/src/increase/_client.py +++ b/src/increase/_client.py @@ -202,7 +202,7 @@ def __init__( # part of our public interface in the future. _strict_response_validation: bool = False, ) -> None: - """Construct a new synchronous increase client instance. + """Construct a new synchronous Increase client instance. This automatically infers the following arguments from their corresponding environment variables if they are not provided: - `api_key` from `INCREASE_API_KEY` @@ -575,7 +575,7 @@ def __init__( # part of our public interface in the future. _strict_response_validation: bool = False, ) -> None: - """Construct a new async increase client instance. + """Construct a new async AsyncIncrease client instance. This automatically infers the following arguments from their corresponding environment variables if they are not provided: - `api_key` from `INCREASE_API_KEY` From e93825436cdcaebc3df000dc932dbe7a6e3f2221 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Fri, 28 Feb 2025 23:27:22 +0000 Subject: [PATCH 3/4] feat(api): api update (#990) --- .stats.yml | 2 +- src/increase/resources/accounts.py | 15 ++------------ src/increase/types/account_list_params.py | 24 +++++++++++++++-------- tests/api_resources/test_accounts.py | 4 ++-- 4 files changed, 21 insertions(+), 24 deletions(-) diff --git a/.stats.yml b/.stats.yml index 43048b318..abd340a25 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,2 +1,2 @@ configured_endpoints: 201 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/increase%2Fincrease-d4eedf5add319b076d462be8b764246f0c3251ff60708906a90494e05ed8e93c.yml +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/increase%2Fincrease-a39e9d1d0001ea729c1ee2e06ac456278e4fc9064790da323630e54ab02bf056.yml diff --git a/src/increase/resources/accounts.py b/src/increase/resources/accounts.py index b6d327d74..338659050 100644 --- a/src/increase/resources/accounts.py +++ b/src/increase/resources/accounts.py @@ -4,7 +4,6 @@ from typing import Union from datetime import datetime -from typing_extensions import Literal import httpx @@ -206,7 +205,7 @@ def list( informational_entity_id: str | NotGiven = NOT_GIVEN, limit: int | NotGiven = NOT_GIVEN, program_id: str | NotGiven = NOT_GIVEN, - status: Literal["closed", "open"] | NotGiven = NOT_GIVEN, + status: account_list_params.Status | 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. extra_headers: Headers | None = None, @@ -234,11 +233,6 @@ def list( program_id: Filter Accounts for those in a specific Program. - status: Filter Accounts for those with the specified status. - - - `closed` - Closed Accounts on which no new activity can occur. - - `open` - Open Accounts that are ready to use. - extra_headers: Send extra headers extra_query: Add additional query parameters to the request @@ -530,7 +524,7 @@ def list( informational_entity_id: str | NotGiven = NOT_GIVEN, limit: int | NotGiven = NOT_GIVEN, program_id: str | NotGiven = NOT_GIVEN, - status: Literal["closed", "open"] | NotGiven = NOT_GIVEN, + status: account_list_params.Status | 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. extra_headers: Headers | None = None, @@ -558,11 +552,6 @@ def list( program_id: Filter Accounts for those in a specific Program. - status: Filter Accounts for those with the specified status. - - - `closed` - Closed Accounts on which no new activity can occur. - - `open` - Open Accounts that are ready to use. - extra_headers: Send extra headers extra_query: Add additional query parameters to the request diff --git a/src/increase/types/account_list_params.py b/src/increase/types/account_list_params.py index 6b5044ba0..1888d6908 100644 --- a/src/increase/types/account_list_params.py +++ b/src/increase/types/account_list_params.py @@ -2,13 +2,13 @@ from __future__ import annotations -from typing import Union +from typing import List, Union from datetime import datetime from typing_extensions import Literal, Annotated, TypedDict from .._utils import PropertyInfo -__all__ = ["AccountListParams", "CreatedAt"] +__all__ = ["AccountListParams", "CreatedAt", "Status"] class AccountListParams(TypedDict, total=False): @@ -40,12 +40,7 @@ class AccountListParams(TypedDict, total=False): program_id: str """Filter Accounts for those in a specific Program.""" - status: Literal["closed", "open"] - """Filter Accounts for those with the specified status. - - - `closed` - Closed Accounts on which no new activity can occur. - - `open` - Open Accounts that are ready to use. - """ + status: Status class CreatedAt(TypedDict, total=False): @@ -72,3 +67,16 @@ class CreatedAt(TypedDict, total=False): Return results on or before this [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) timestamp. """ + + +_StatusReservedKeywords = TypedDict( + "_StatusReservedKeywords", + { + "in": List[Literal["closed", "open"]], + }, + total=False, +) + + +class Status(_StatusReservedKeywords, total=False): + pass diff --git a/tests/api_resources/test_accounts.py b/tests/api_resources/test_accounts.py index b8cfbb9bb..2a06214e3 100644 --- a/tests/api_resources/test_accounts.py +++ b/tests/api_resources/test_accounts.py @@ -167,7 +167,7 @@ def test_method_list_with_all_params(self, client: Increase) -> None: informational_entity_id="informational_entity_id", limit=1, program_id="program_id", - status="closed", + status={"in": ["closed"]}, ) assert_matches_type(SyncPage[Account], account, path=["response"]) @@ -424,7 +424,7 @@ async def test_method_list_with_all_params(self, async_client: AsyncIncrease) -> informational_entity_id="informational_entity_id", limit=1, program_id="program_id", - status="closed", + status={"in": ["closed"]}, ) assert_matches_type(AsyncPage[Account], account, path=["response"]) From 73edfd6f6c74e46dd62721eec494fe9485cbe48a Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Fri, 28 Feb 2025 23:27:47 +0000 Subject: [PATCH 4/4] release: 0.197.0 --- .release-please-manifest.json | 2 +- CHANGELOG.md | 18 ++++++++++++++++++ pyproject.toml | 2 +- src/increase/_version.py | 2 +- 4 files changed, 21 insertions(+), 3 deletions(-) diff --git a/.release-please-manifest.json b/.release-please-manifest.json index ba48addfa..ceb465254 100644 --- a/.release-please-manifest.json +++ b/.release-please-manifest.json @@ -1,3 +1,3 @@ { - ".": "0.196.0" + ".": "0.197.0" } \ No newline at end of file diff --git a/CHANGELOG.md b/CHANGELOG.md index b27cf236d..769e76be3 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,23 @@ # Changelog +## 0.197.0 (2025-02-28) + +Full Changelog: [v0.196.0...v0.197.0](https://github.com/Increase/increase-python/compare/v0.196.0...v0.197.0) + +### Features + +* **api:** api update ([#990](https://github.com/Increase/increase-python/issues/990)) ([e938254](https://github.com/Increase/increase-python/commit/e93825436cdcaebc3df000dc932dbe7a6e3f2221)) + + +### Chores + +* **docs:** update client docstring ([#989](https://github.com/Increase/increase-python/issues/989)) ([4cdb976](https://github.com/Increase/increase-python/commit/4cdb97608cb2b0ea3a803e3d387fa0c67bf73594)) + + +### Documentation + +* update URLs from stainlessapi.com to stainless.com ([#987](https://github.com/Increase/increase-python/issues/987)) ([2e77ad2](https://github.com/Increase/increase-python/commit/2e77ad270e3eebe335d631e69c5e156e64af859c)) + ## 0.196.0 (2025-02-26) Full Changelog: [v0.195.0...v0.196.0](https://github.com/Increase/increase-python/compare/v0.195.0...v0.196.0) diff --git a/pyproject.toml b/pyproject.toml index 82d6a30ef..f2e402c36 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "increase" -version = "0.196.0" +version = "0.197.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 7c542a20e..e04185b01 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.196.0" # x-release-please-version +__version__ = "0.197.0" # x-release-please-version