From f3e089e78535d88553bd60681bce6e75f0c29ece Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Fri, 12 Dec 2025 15:17:50 +0000 Subject: [PATCH 1/8] feat(api): remove v1/aggregate_balances and related models --- .stats.yml | 8 +- api.md | 24 --- src/lithic/_client.py | 46 ----- src/lithic/resources/__init__.py | 14 -- src/lithic/resources/aggregate_balances.py | 182 ----------------- src/lithic/resources/cards/__init__.py | 14 -- .../resources/cards/aggregate_balances.py | 190 ------------------ src/lithic/resources/cards/cards.py | 32 --- src/lithic/types/__init__.py | 4 - src/lithic/types/aggregate_balance.py | 54 ----- .../types/aggregate_balance_list_params.py | 12 -- src/lithic/types/cards/__init__.py | 2 - .../cards/aggregate_balance_list_params.py | 15 -- .../cards/aggregate_balance_list_response.py | 50 ----- .../cards/test_aggregate_balances.py | 91 --------- .../api_resources/test_aggregate_balances.py | 89 -------- 16 files changed, 4 insertions(+), 823 deletions(-) delete mode 100644 src/lithic/resources/aggregate_balances.py delete mode 100644 src/lithic/resources/cards/aggregate_balances.py delete mode 100644 src/lithic/types/aggregate_balance.py delete mode 100644 src/lithic/types/aggregate_balance_list_params.py delete mode 100644 src/lithic/types/cards/aggregate_balance_list_params.py delete mode 100644 src/lithic/types/cards/aggregate_balance_list_response.py delete mode 100644 tests/api_resources/cards/test_aggregate_balances.py delete mode 100644 tests/api_resources/test_aggregate_balances.py diff --git a/.stats.yml b/.stats.yml index 0e130cdf..51bc2543 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ -configured_endpoints: 175 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic%2Flithic-abe6a4f82f696099fa8ecb1cc44f08979e17d56578ae7ea68b0e9182e21df508.yml -openapi_spec_hash: d2ce51592a9a234c6f34a1168a31f91f -config_hash: f4b1d2f464e80527f970de61cba0c52f +configured_endpoints: 173 +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic%2Flithic-4fd8048b287f409ad2b91f7d0f0b7fc13cc9bc4ccc7859666f21203bab3d2f01.yml +openapi_spec_hash: a554c54d96a7604a770b6a8b1df46395 +config_hash: df0af4ff639b8a6923a6244d2247910c diff --git a/api.md b/api.md index c07d4f4d..4ca0eeaf 100644 --- a/api.md +++ b/api.md @@ -214,18 +214,6 @@ Methods: - client.cards.get_embed_html(\*args) -> str - client.cards.get_embed_url(\*args) -> URL -## AggregateBalances - -Types: - -```python -from lithic.types.cards import AggregateBalanceListResponse -``` - -Methods: - -- client.cards.aggregate_balances.list(\*\*params) -> SyncSinglePage[AggregateBalanceListResponse] - ## Balances Methods: @@ -266,18 +254,6 @@ Methods: - client.balances.list(\*\*params) -> SyncSinglePage[Balance] -# AggregateBalances - -Types: - -```python -from lithic.types import AggregateBalance -``` - -Methods: - -- client.aggregate_balances.list(\*\*params) -> SyncSinglePage[AggregateBalance] - # Disputes Types: diff --git a/src/lithic/_client.py b/src/lithic/_client.py index 363745a1..d6f1d221 100644 --- a/src/lithic/_client.py +++ b/src/lithic/_client.py @@ -61,7 +61,6 @@ digital_card_art, network_programs, external_payments, - aggregate_balances, financial_accounts, responder_endpoints, management_operations, @@ -93,7 +92,6 @@ from .resources.network_programs import NetworkPrograms, AsyncNetworkPrograms from .resources.external_payments import ExternalPayments, AsyncExternalPayments from .resources.three_ds.three_ds import ThreeDS, AsyncThreeDS - from .resources.aggregate_balances import AggregateBalances, AsyncAggregateBalances from .resources.responder_endpoints import ( ResponderEndpoints, AsyncResponderEndpoints, @@ -284,12 +282,6 @@ def balances(self) -> Balances: return Balances(self) - @cached_property - def aggregate_balances(self) -> AggregateBalances: - from .resources.aggregate_balances import AggregateBalances - - return AggregateBalances(self) - @cached_property def disputes(self) -> Disputes: from .resources.disputes import Disputes @@ -697,12 +689,6 @@ def balances(self) -> AsyncBalances: return AsyncBalances(self) - @cached_property - def aggregate_balances(self) -> AsyncAggregateBalances: - from .resources.aggregate_balances import AsyncAggregateBalances - - return AsyncAggregateBalances(self) - @cached_property def disputes(self) -> AsyncDisputes: from .resources.disputes import AsyncDisputes @@ -1041,12 +1027,6 @@ def balances(self) -> balances.BalancesWithRawResponse: return BalancesWithRawResponse(self._client.balances) - @cached_property - def aggregate_balances(self) -> aggregate_balances.AggregateBalancesWithRawResponse: - from .resources.aggregate_balances import AggregateBalancesWithRawResponse - - return AggregateBalancesWithRawResponse(self._client.aggregate_balances) - @cached_property def disputes(self) -> disputes.DisputesWithRawResponse: from .resources.disputes import DisputesWithRawResponse @@ -1250,14 +1230,6 @@ def balances(self) -> balances.AsyncBalancesWithRawResponse: return AsyncBalancesWithRawResponse(self._client.balances) - @cached_property - def aggregate_balances( - self, - ) -> aggregate_balances.AsyncAggregateBalancesWithRawResponse: - from .resources.aggregate_balances import AsyncAggregateBalancesWithRawResponse - - return AsyncAggregateBalancesWithRawResponse(self._client.aggregate_balances) - @cached_property def disputes(self) -> disputes.AsyncDisputesWithRawResponse: from .resources.disputes import AsyncDisputesWithRawResponse @@ -1471,14 +1443,6 @@ def balances(self) -> balances.BalancesWithStreamingResponse: return BalancesWithStreamingResponse(self._client.balances) - @cached_property - def aggregate_balances( - self, - ) -> aggregate_balances.AggregateBalancesWithStreamingResponse: - from .resources.aggregate_balances import AggregateBalancesWithStreamingResponse - - return AggregateBalancesWithStreamingResponse(self._client.aggregate_balances) - @cached_property def disputes(self) -> disputes.DisputesWithStreamingResponse: from .resources.disputes import DisputesWithStreamingResponse @@ -1696,16 +1660,6 @@ def balances(self) -> balances.AsyncBalancesWithStreamingResponse: return AsyncBalancesWithStreamingResponse(self._client.balances) - @cached_property - def aggregate_balances( - self, - ) -> aggregate_balances.AsyncAggregateBalancesWithStreamingResponse: - from .resources.aggregate_balances import ( - AsyncAggregateBalancesWithStreamingResponse, - ) - - return AsyncAggregateBalancesWithStreamingResponse(self._client.aggregate_balances) - @cached_property def disputes(self) -> disputes.AsyncDisputesWithStreamingResponse: from .resources.disputes import AsyncDisputesWithStreamingResponse diff --git a/src/lithic/resources/__init__.py b/src/lithic/resources/__init__.py index face2018..77245ab4 100644 --- a/src/lithic/resources/__init__.py +++ b/src/lithic/resources/__init__.py @@ -185,14 +185,6 @@ ExternalPaymentsWithStreamingResponse, AsyncExternalPaymentsWithStreamingResponse, ) -from .aggregate_balances import ( - AggregateBalances, - AsyncAggregateBalances, - AggregateBalancesWithRawResponse, - AsyncAggregateBalancesWithRawResponse, - AggregateBalancesWithStreamingResponse, - AsyncAggregateBalancesWithStreamingResponse, -) from .financial_accounts import ( FinancialAccounts, AsyncFinancialAccounts, @@ -297,12 +289,6 @@ "AsyncBalancesWithRawResponse", "BalancesWithStreamingResponse", "AsyncBalancesWithStreamingResponse", - "AggregateBalances", - "AsyncAggregateBalances", - "AggregateBalancesWithRawResponse", - "AsyncAggregateBalancesWithRawResponse", - "AggregateBalancesWithStreamingResponse", - "AsyncAggregateBalancesWithStreamingResponse", "Disputes", "AsyncDisputes", "DisputesWithRawResponse", diff --git a/src/lithic/resources/aggregate_balances.py b/src/lithic/resources/aggregate_balances.py deleted file mode 100644 index 5d35dc36..00000000 --- a/src/lithic/resources/aggregate_balances.py +++ /dev/null @@ -1,182 +0,0 @@ -# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. - -from __future__ import annotations - -from typing_extensions import Literal - -import httpx - -from .. import _legacy_response -from ..types import aggregate_balance_list_params -from .._types import Body, Omit, Query, Headers, NotGiven, omit, not_given -from .._utils import maybe_transform -from .._compat import cached_property -from .._resource import SyncAPIResource, AsyncAPIResource -from .._response import to_streamed_response_wrapper, async_to_streamed_response_wrapper -from ..pagination import SyncSinglePage, AsyncSinglePage -from .._base_client import AsyncPaginator, make_request_options -from ..types.aggregate_balance import AggregateBalance - -__all__ = ["AggregateBalances", "AsyncAggregateBalances"] - - -class AggregateBalances(SyncAPIResource): - @cached_property - def with_raw_response(self) -> AggregateBalancesWithRawResponse: - """ - This property can be used as a prefix for any HTTP method call to return - the raw response object instead of the parsed content. - - For more information, see https://www.github.com/lithic-com/lithic-python#accessing-raw-response-data-eg-headers - """ - return AggregateBalancesWithRawResponse(self) - - @cached_property - def with_streaming_response(self) -> AggregateBalancesWithStreamingResponse: - """ - An alternative to `.with_raw_response` that doesn't eagerly read the response body. - - For more information, see https://www.github.com/lithic-com/lithic-python#with_streaming_response - """ - return AggregateBalancesWithStreamingResponse(self) - - def list( - self, - *, - financial_account_type: Literal["ISSUING", "OPERATING", "RESERVE", "SECURITY"] | Omit = omit, - # 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, - extra_query: Query | None = None, - extra_body: Body | None = None, - timeout: float | httpx.Timeout | None | NotGiven = not_given, - ) -> SyncSinglePage[AggregateBalance]: - """ - Get the aggregated balance across all end-user accounts by financial account - type - - Args: - financial_account_type: Get the aggregate balance for a given Financial Account type. - - extra_headers: Send extra headers - - extra_query: Add additional query parameters to the request - - extra_body: Add additional JSON properties to the request - - timeout: Override the client-level default timeout for this request, in seconds - """ - return self._get_api_list( - "/v1/aggregate_balances", - page=SyncSinglePage[AggregateBalance], - options=make_request_options( - extra_headers=extra_headers, - extra_query=extra_query, - extra_body=extra_body, - timeout=timeout, - query=maybe_transform( - {"financial_account_type": financial_account_type}, - aggregate_balance_list_params.AggregateBalanceListParams, - ), - ), - model=AggregateBalance, - ) - - -class AsyncAggregateBalances(AsyncAPIResource): - @cached_property - def with_raw_response(self) -> AsyncAggregateBalancesWithRawResponse: - """ - This property can be used as a prefix for any HTTP method call to return - the raw response object instead of the parsed content. - - For more information, see https://www.github.com/lithic-com/lithic-python#accessing-raw-response-data-eg-headers - """ - return AsyncAggregateBalancesWithRawResponse(self) - - @cached_property - def with_streaming_response(self) -> AsyncAggregateBalancesWithStreamingResponse: - """ - An alternative to `.with_raw_response` that doesn't eagerly read the response body. - - For more information, see https://www.github.com/lithic-com/lithic-python#with_streaming_response - """ - return AsyncAggregateBalancesWithStreamingResponse(self) - - def list( - self, - *, - financial_account_type: Literal["ISSUING", "OPERATING", "RESERVE", "SECURITY"] | Omit = omit, - # 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, - extra_query: Query | None = None, - extra_body: Body | None = None, - timeout: float | httpx.Timeout | None | NotGiven = not_given, - ) -> AsyncPaginator[AggregateBalance, AsyncSinglePage[AggregateBalance]]: - """ - Get the aggregated balance across all end-user accounts by financial account - type - - Args: - financial_account_type: Get the aggregate balance for a given Financial Account type. - - extra_headers: Send extra headers - - extra_query: Add additional query parameters to the request - - extra_body: Add additional JSON properties to the request - - timeout: Override the client-level default timeout for this request, in seconds - """ - return self._get_api_list( - "/v1/aggregate_balances", - page=AsyncSinglePage[AggregateBalance], - options=make_request_options( - extra_headers=extra_headers, - extra_query=extra_query, - extra_body=extra_body, - timeout=timeout, - query=maybe_transform( - {"financial_account_type": financial_account_type}, - aggregate_balance_list_params.AggregateBalanceListParams, - ), - ), - model=AggregateBalance, - ) - - -class AggregateBalancesWithRawResponse: - def __init__(self, aggregate_balances: AggregateBalances) -> None: - self._aggregate_balances = aggregate_balances - - self.list = _legacy_response.to_raw_response_wrapper( - aggregate_balances.list, - ) - - -class AsyncAggregateBalancesWithRawResponse: - def __init__(self, aggregate_balances: AsyncAggregateBalances) -> None: - self._aggregate_balances = aggregate_balances - - self.list = _legacy_response.async_to_raw_response_wrapper( - aggregate_balances.list, - ) - - -class AggregateBalancesWithStreamingResponse: - def __init__(self, aggregate_balances: AggregateBalances) -> None: - self._aggregate_balances = aggregate_balances - - self.list = to_streamed_response_wrapper( - aggregate_balances.list, - ) - - -class AsyncAggregateBalancesWithStreamingResponse: - def __init__(self, aggregate_balances: AsyncAggregateBalances) -> None: - self._aggregate_balances = aggregate_balances - - self.list = async_to_streamed_response_wrapper( - aggregate_balances.list, - ) diff --git a/src/lithic/resources/cards/__init__.py b/src/lithic/resources/cards/__init__.py index 790baf59..71ca7811 100644 --- a/src/lithic/resources/cards/__init__.py +++ b/src/lithic/resources/cards/__init__.py @@ -16,14 +16,6 @@ BalancesWithStreamingResponse, AsyncBalancesWithStreamingResponse, ) -from .aggregate_balances import ( - AggregateBalances, - AsyncAggregateBalances, - AggregateBalancesWithRawResponse, - AsyncAggregateBalancesWithRawResponse, - AggregateBalancesWithStreamingResponse, - AsyncAggregateBalancesWithStreamingResponse, -) from .financial_transactions import ( FinancialTransactions, AsyncFinancialTransactions, @@ -34,12 +26,6 @@ ) __all__ = [ - "AggregateBalances", - "AsyncAggregateBalances", - "AggregateBalancesWithRawResponse", - "AsyncAggregateBalancesWithRawResponse", - "AggregateBalancesWithStreamingResponse", - "AsyncAggregateBalancesWithStreamingResponse", "Balances", "AsyncBalances", "BalancesWithRawResponse", diff --git a/src/lithic/resources/cards/aggregate_balances.py b/src/lithic/resources/cards/aggregate_balances.py deleted file mode 100644 index 97db711d..00000000 --- a/src/lithic/resources/cards/aggregate_balances.py +++ /dev/null @@ -1,190 +0,0 @@ -# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. - -from __future__ import annotations - -import httpx - -from ... import _legacy_response -from ..._types import Body, Omit, Query, Headers, NotGiven, omit, not_given -from ..._utils import maybe_transform -from ..._compat import cached_property -from ..._resource import SyncAPIResource, AsyncAPIResource -from ..._response import to_streamed_response_wrapper, async_to_streamed_response_wrapper -from ...pagination import SyncSinglePage, AsyncSinglePage -from ...types.cards import aggregate_balance_list_params -from ..._base_client import AsyncPaginator, make_request_options -from ...types.cards.aggregate_balance_list_response import AggregateBalanceListResponse - -__all__ = ["AggregateBalances", "AsyncAggregateBalances"] - - -class AggregateBalances(SyncAPIResource): - @cached_property - def with_raw_response(self) -> AggregateBalancesWithRawResponse: - """ - This property can be used as a prefix for any HTTP method call to return - the raw response object instead of the parsed content. - - For more information, see https://www.github.com/lithic-com/lithic-python#accessing-raw-response-data-eg-headers - """ - return AggregateBalancesWithRawResponse(self) - - @cached_property - def with_streaming_response(self) -> AggregateBalancesWithStreamingResponse: - """ - An alternative to `.with_raw_response` that doesn't eagerly read the response body. - - For more information, see https://www.github.com/lithic-com/lithic-python#with_streaming_response - """ - return AggregateBalancesWithStreamingResponse(self) - - def list( - self, - *, - account_token: str | Omit = omit, - business_account_token: str | Omit = omit, - # 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, - extra_query: Query | None = None, - extra_body: Body | None = None, - timeout: float | httpx.Timeout | None | NotGiven = not_given, - ) -> SyncSinglePage[AggregateBalanceListResponse]: - """ - Get the aggregated card balance across all end-user accounts. - - Args: - account_token: Cardholder to retrieve aggregate balances for. - - business_account_token: Business to retrieve aggregate balances for. - - extra_headers: Send extra headers - - extra_query: Add additional query parameters to the request - - extra_body: Add additional JSON properties to the request - - timeout: Override the client-level default timeout for this request, in seconds - """ - return self._get_api_list( - "/v1/cards/aggregate_balances", - page=SyncSinglePage[AggregateBalanceListResponse], - options=make_request_options( - extra_headers=extra_headers, - extra_query=extra_query, - extra_body=extra_body, - timeout=timeout, - query=maybe_transform( - { - "account_token": account_token, - "business_account_token": business_account_token, - }, - aggregate_balance_list_params.AggregateBalanceListParams, - ), - ), - model=AggregateBalanceListResponse, - ) - - -class AsyncAggregateBalances(AsyncAPIResource): - @cached_property - def with_raw_response(self) -> AsyncAggregateBalancesWithRawResponse: - """ - This property can be used as a prefix for any HTTP method call to return - the raw response object instead of the parsed content. - - For more information, see https://www.github.com/lithic-com/lithic-python#accessing-raw-response-data-eg-headers - """ - return AsyncAggregateBalancesWithRawResponse(self) - - @cached_property - def with_streaming_response(self) -> AsyncAggregateBalancesWithStreamingResponse: - """ - An alternative to `.with_raw_response` that doesn't eagerly read the response body. - - For more information, see https://www.github.com/lithic-com/lithic-python#with_streaming_response - """ - return AsyncAggregateBalancesWithStreamingResponse(self) - - def list( - self, - *, - account_token: str | Omit = omit, - business_account_token: str | Omit = omit, - # 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, - extra_query: Query | None = None, - extra_body: Body | None = None, - timeout: float | httpx.Timeout | None | NotGiven = not_given, - ) -> AsyncPaginator[AggregateBalanceListResponse, AsyncSinglePage[AggregateBalanceListResponse]]: - """ - Get the aggregated card balance across all end-user accounts. - - Args: - account_token: Cardholder to retrieve aggregate balances for. - - business_account_token: Business to retrieve aggregate balances for. - - extra_headers: Send extra headers - - extra_query: Add additional query parameters to the request - - extra_body: Add additional JSON properties to the request - - timeout: Override the client-level default timeout for this request, in seconds - """ - return self._get_api_list( - "/v1/cards/aggregate_balances", - page=AsyncSinglePage[AggregateBalanceListResponse], - options=make_request_options( - extra_headers=extra_headers, - extra_query=extra_query, - extra_body=extra_body, - timeout=timeout, - query=maybe_transform( - { - "account_token": account_token, - "business_account_token": business_account_token, - }, - aggregate_balance_list_params.AggregateBalanceListParams, - ), - ), - model=AggregateBalanceListResponse, - ) - - -class AggregateBalancesWithRawResponse: - def __init__(self, aggregate_balances: AggregateBalances) -> None: - self._aggregate_balances = aggregate_balances - - self.list = _legacy_response.to_raw_response_wrapper( - aggregate_balances.list, - ) - - -class AsyncAggregateBalancesWithRawResponse: - def __init__(self, aggregate_balances: AsyncAggregateBalances) -> None: - self._aggregate_balances = aggregate_balances - - self.list = _legacy_response.async_to_raw_response_wrapper( - aggregate_balances.list, - ) - - -class AggregateBalancesWithStreamingResponse: - def __init__(self, aggregate_balances: AggregateBalances) -> None: - self._aggregate_balances = aggregate_balances - - self.list = to_streamed_response_wrapper( - aggregate_balances.list, - ) - - -class AsyncAggregateBalancesWithStreamingResponse: - def __init__(self, aggregate_balances: AsyncAggregateBalances) -> None: - self._aggregate_balances = aggregate_balances - - self.list = async_to_streamed_response_wrapper( - aggregate_balances.list, - ) diff --git a/src/lithic/resources/cards/cards.py b/src/lithic/resources/cards/cards.py index 5325041a..5a4da996 100644 --- a/src/lithic/resources/cards/cards.py +++ b/src/lithic/resources/cards/cards.py @@ -44,14 +44,6 @@ from ...pagination import SyncCursorPage, AsyncCursorPage from ...types.card import Card from ..._base_client import AsyncPaginator, _merge_mappings, make_request_options -from .aggregate_balances import ( - AggregateBalances, - AsyncAggregateBalances, - AggregateBalancesWithRawResponse, - AsyncAggregateBalancesWithRawResponse, - AggregateBalancesWithStreamingResponse, - AsyncAggregateBalancesWithStreamingResponse, -) from ...types.non_pci_card import NonPCICard from .financial_transactions import ( FinancialTransactions, @@ -72,10 +64,6 @@ class Cards(SyncAPIResource): - @cached_property - def aggregate_balances(self) -> AggregateBalances: - return AggregateBalances(self._client) - @cached_property def balances(self) -> Balances: return Balances(self._client) @@ -1258,10 +1246,6 @@ def web_provision( class AsyncCards(AsyncAPIResource): - @cached_property - def aggregate_balances(self) -> AsyncAggregateBalances: - return AsyncAggregateBalances(self._client) - @cached_property def balances(self) -> AsyncBalances: return AsyncBalances(self._client) @@ -2484,10 +2468,6 @@ def __init__(self, cards: Cards) -> None: cards.web_provision, ) - @cached_property - def aggregate_balances(self) -> AggregateBalancesWithRawResponse: - return AggregateBalancesWithRawResponse(self._cards.aggregate_balances) - @cached_property def balances(self) -> BalancesWithRawResponse: return BalancesWithRawResponse(self._cards.balances) @@ -2538,10 +2518,6 @@ def __init__(self, cards: AsyncCards) -> None: cards.web_provision, ) - @cached_property - def aggregate_balances(self) -> AsyncAggregateBalancesWithRawResponse: - return AsyncAggregateBalancesWithRawResponse(self._cards.aggregate_balances) - @cached_property def balances(self) -> AsyncBalancesWithRawResponse: return AsyncBalancesWithRawResponse(self._cards.balances) @@ -2592,10 +2568,6 @@ def __init__(self, cards: Cards) -> None: cards.web_provision, ) - @cached_property - def aggregate_balances(self) -> AggregateBalancesWithStreamingResponse: - return AggregateBalancesWithStreamingResponse(self._cards.aggregate_balances) - @cached_property def balances(self) -> BalancesWithStreamingResponse: return BalancesWithStreamingResponse(self._cards.balances) @@ -2646,10 +2618,6 @@ def __init__(self, cards: AsyncCards) -> None: cards.web_provision, ) - @cached_property - def aggregate_balances(self) -> AsyncAggregateBalancesWithStreamingResponse: - return AsyncAggregateBalancesWithStreamingResponse(self._cards.aggregate_balances) - @cached_property def balances(self) -> AsyncBalancesWithStreamingResponse: return AsyncBalancesWithStreamingResponse(self._cards.balances) diff --git a/src/lithic/types/__init__.py b/src/lithic/types/__init__.py index 89961e91..a3b9977c 100644 --- a/src/lithic/types/__init__.py +++ b/src/lithic/types/__init__.py @@ -43,7 +43,6 @@ from .external_payment import ExternalPayment as ExternalPayment from .kyc_exempt_param import KYCExemptParam as KYCExemptParam from .statement_totals import StatementTotals as StatementTotals -from .aggregate_balance import AggregateBalance as AggregateBalance from .card_embed_params import CardEmbedParams as CardEmbedParams from .card_renew_params import CardRenewParams as CardRenewParams from .card_spend_limits import CardSpendLimits as CardSpendLimits @@ -174,9 +173,6 @@ from .tokenization_simulate_params import ( TokenizationSimulateParams as TokenizationSimulateParams, ) -from .aggregate_balance_list_params import ( - AggregateBalanceListParams as AggregateBalanceListParams, -) from .balance_updated_webhook_event import ( BalanceUpdatedWebhookEvent as BalanceUpdatedWebhookEvent, ) diff --git a/src/lithic/types/aggregate_balance.py b/src/lithic/types/aggregate_balance.py deleted file mode 100644 index d74f4cee..00000000 --- a/src/lithic/types/aggregate_balance.py +++ /dev/null @@ -1,54 +0,0 @@ -# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. - -from datetime import datetime -from typing_extensions import Literal - -from .._models import BaseModel - -__all__ = ["AggregateBalance"] - - -class AggregateBalance(BaseModel): - """Aggregate Balance across all end-user accounts""" - - available_amount: int - """Funds available for spend in the currency's smallest unit (e.g., cents for USD)""" - - created: datetime - """Date and time for when the balance was first created.""" - - currency: str - """3-character alphabetic ISO 4217 code for the local currency of the balance.""" - - financial_account_type: Literal["ISSUING", "OPERATING", "RESERVE", "SECURITY"] - """Type of financial account""" - - last_financial_account_token: str - """ - Globally unique identifier for the financial account that had its balance - updated most recently - """ - - last_transaction_event_token: str - """ - Globally unique identifier for the last transaction event that impacted this - balance - """ - - last_transaction_token: str - """Globally unique identifier for the last transaction that impacted this balance""" - - pending_amount: int - """Funds not available for spend due to card authorizations or pending ACH release. - - Shown in the currency's smallest unit (e.g., cents for USD) - """ - - total_amount: int - """ - The sum of available and pending balance in the currency's smallest unit (e.g., - cents for USD) - """ - - updated: datetime - """Date and time for when the balance was last updated.""" diff --git a/src/lithic/types/aggregate_balance_list_params.py b/src/lithic/types/aggregate_balance_list_params.py deleted file mode 100644 index 519ad11d..00000000 --- a/src/lithic/types/aggregate_balance_list_params.py +++ /dev/null @@ -1,12 +0,0 @@ -# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. - -from __future__ import annotations - -from typing_extensions import Literal, TypedDict - -__all__ = ["AggregateBalanceListParams"] - - -class AggregateBalanceListParams(TypedDict, total=False): - financial_account_type: Literal["ISSUING", "OPERATING", "RESERVE", "SECURITY"] - """Get the aggregate balance for a given Financial Account type.""" diff --git a/src/lithic/types/cards/__init__.py b/src/lithic/types/cards/__init__.py index 63dfd5cb..3f28d3d0 100644 --- a/src/lithic/types/cards/__init__.py +++ b/src/lithic/types/cards/__init__.py @@ -3,6 +3,4 @@ from __future__ import annotations from .balance_list_params import BalanceListParams as BalanceListParams -from .aggregate_balance_list_params import AggregateBalanceListParams as AggregateBalanceListParams -from .aggregate_balance_list_response import AggregateBalanceListResponse as AggregateBalanceListResponse from .financial_transaction_list_params import FinancialTransactionListParams as FinancialTransactionListParams diff --git a/src/lithic/types/cards/aggregate_balance_list_params.py b/src/lithic/types/cards/aggregate_balance_list_params.py deleted file mode 100644 index 51b927dc..00000000 --- a/src/lithic/types/cards/aggregate_balance_list_params.py +++ /dev/null @@ -1,15 +0,0 @@ -# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. - -from __future__ import annotations - -from typing_extensions import TypedDict - -__all__ = ["AggregateBalanceListParams"] - - -class AggregateBalanceListParams(TypedDict, total=False): - account_token: str - """Cardholder to retrieve aggregate balances for.""" - - business_account_token: str - """Business to retrieve aggregate balances for.""" diff --git a/src/lithic/types/cards/aggregate_balance_list_response.py b/src/lithic/types/cards/aggregate_balance_list_response.py deleted file mode 100644 index 0075a93e..00000000 --- a/src/lithic/types/cards/aggregate_balance_list_response.py +++ /dev/null @@ -1,50 +0,0 @@ -# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. - -from datetime import datetime - -from ..._models import BaseModel - -__all__ = ["AggregateBalanceListResponse"] - - -class AggregateBalanceListResponse(BaseModel): - """Card Aggregate Balance across all end-user accounts""" - - available_amount: int - """Funds available for spend in the currency's smallest unit (e.g., cents for USD)""" - - created: datetime - """Date and time for when the balance was first created.""" - - currency: str - """3-character alphabetic ISO 4217 code for the local currency of the balance.""" - - last_card_token: str - """ - Globally unique identifier for the card that had its balance updated most - recently - """ - - last_transaction_event_token: str - """ - Globally unique identifier for the last transaction event that impacted this - balance - """ - - last_transaction_token: str - """Globally unique identifier for the last transaction that impacted this balance""" - - pending_amount: int - """Funds not available for spend due to card authorizations or pending ACH release. - - Shown in the currency's smallest unit (e.g., cents for USD) - """ - - total_amount: int - """ - The sum of available and pending balance in the currency's smallest unit (e.g., - cents for USD) - """ - - updated: datetime - """Date and time for when the balance was last updated.""" diff --git a/tests/api_resources/cards/test_aggregate_balances.py b/tests/api_resources/cards/test_aggregate_balances.py deleted file mode 100644 index 745e313d..00000000 --- a/tests/api_resources/cards/test_aggregate_balances.py +++ /dev/null @@ -1,91 +0,0 @@ -# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. - -from __future__ import annotations - -import os -from typing import Any, cast - -import pytest - -from lithic import Lithic, AsyncLithic -from tests.utils import assert_matches_type -from lithic.pagination import SyncSinglePage, AsyncSinglePage -from lithic.types.cards import AggregateBalanceListResponse - -base_url = os.environ.get("TEST_API_BASE_URL", "http://127.0.0.1:4010") - - -class TestAggregateBalances: - parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - - @parametrize - def test_method_list(self, client: Lithic) -> None: - aggregate_balance = client.cards.aggregate_balances.list() - assert_matches_type(SyncSinglePage[AggregateBalanceListResponse], aggregate_balance, path=["response"]) - - @parametrize - def test_method_list_with_all_params(self, client: Lithic) -> None: - aggregate_balance = client.cards.aggregate_balances.list( - account_token="account_token", - business_account_token="business_account_token", - ) - assert_matches_type(SyncSinglePage[AggregateBalanceListResponse], aggregate_balance, path=["response"]) - - @parametrize - def test_raw_response_list(self, client: Lithic) -> None: - response = client.cards.aggregate_balances.with_raw_response.list() - - assert response.is_closed is True - assert response.http_request.headers.get("X-Stainless-Lang") == "python" - aggregate_balance = response.parse() - assert_matches_type(SyncSinglePage[AggregateBalanceListResponse], aggregate_balance, path=["response"]) - - @parametrize - def test_streaming_response_list(self, client: Lithic) -> None: - with client.cards.aggregate_balances.with_streaming_response.list() as response: - assert not response.is_closed - assert response.http_request.headers.get("X-Stainless-Lang") == "python" - - aggregate_balance = response.parse() - assert_matches_type(SyncSinglePage[AggregateBalanceListResponse], aggregate_balance, path=["response"]) - - assert cast(Any, response.is_closed) is True - - -class TestAsyncAggregateBalances: - parametrize = pytest.mark.parametrize( - "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] - ) - - @parametrize - async def test_method_list(self, async_client: AsyncLithic) -> None: - aggregate_balance = await async_client.cards.aggregate_balances.list() - assert_matches_type(AsyncSinglePage[AggregateBalanceListResponse], aggregate_balance, path=["response"]) - - @parametrize - async def test_method_list_with_all_params(self, async_client: AsyncLithic) -> None: - aggregate_balance = await async_client.cards.aggregate_balances.list( - account_token="account_token", - business_account_token="business_account_token", - ) - assert_matches_type(AsyncSinglePage[AggregateBalanceListResponse], aggregate_balance, path=["response"]) - - @parametrize - async def test_raw_response_list(self, async_client: AsyncLithic) -> None: - response = await async_client.cards.aggregate_balances.with_raw_response.list() - - assert response.is_closed is True - assert response.http_request.headers.get("X-Stainless-Lang") == "python" - aggregate_balance = response.parse() - assert_matches_type(AsyncSinglePage[AggregateBalanceListResponse], aggregate_balance, path=["response"]) - - @parametrize - async def test_streaming_response_list(self, async_client: AsyncLithic) -> None: - async with async_client.cards.aggregate_balances.with_streaming_response.list() as response: - assert not response.is_closed - assert response.http_request.headers.get("X-Stainless-Lang") == "python" - - aggregate_balance = await response.parse() - assert_matches_type(AsyncSinglePage[AggregateBalanceListResponse], aggregate_balance, path=["response"]) - - assert cast(Any, response.is_closed) is True diff --git a/tests/api_resources/test_aggregate_balances.py b/tests/api_resources/test_aggregate_balances.py deleted file mode 100644 index 485f951f..00000000 --- a/tests/api_resources/test_aggregate_balances.py +++ /dev/null @@ -1,89 +0,0 @@ -# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. - -from __future__ import annotations - -import os -from typing import Any, cast - -import pytest - -from lithic import Lithic, AsyncLithic -from tests.utils import assert_matches_type -from lithic.types import AggregateBalance -from lithic.pagination import SyncSinglePage, AsyncSinglePage - -base_url = os.environ.get("TEST_API_BASE_URL", "http://127.0.0.1:4010") - - -class TestAggregateBalances: - parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - - @parametrize - def test_method_list(self, client: Lithic) -> None: - aggregate_balance = client.aggregate_balances.list() - assert_matches_type(SyncSinglePage[AggregateBalance], aggregate_balance, path=["response"]) - - @parametrize - def test_method_list_with_all_params(self, client: Lithic) -> None: - aggregate_balance = client.aggregate_balances.list( - financial_account_type="ISSUING", - ) - assert_matches_type(SyncSinglePage[AggregateBalance], aggregate_balance, path=["response"]) - - @parametrize - def test_raw_response_list(self, client: Lithic) -> None: - response = client.aggregate_balances.with_raw_response.list() - - assert response.is_closed is True - assert response.http_request.headers.get("X-Stainless-Lang") == "python" - aggregate_balance = response.parse() - assert_matches_type(SyncSinglePage[AggregateBalance], aggregate_balance, path=["response"]) - - @parametrize - def test_streaming_response_list(self, client: Lithic) -> None: - with client.aggregate_balances.with_streaming_response.list() as response: - assert not response.is_closed - assert response.http_request.headers.get("X-Stainless-Lang") == "python" - - aggregate_balance = response.parse() - assert_matches_type(SyncSinglePage[AggregateBalance], aggregate_balance, path=["response"]) - - assert cast(Any, response.is_closed) is True - - -class TestAsyncAggregateBalances: - parametrize = pytest.mark.parametrize( - "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] - ) - - @parametrize - async def test_method_list(self, async_client: AsyncLithic) -> None: - aggregate_balance = await async_client.aggregate_balances.list() - assert_matches_type(AsyncSinglePage[AggregateBalance], aggregate_balance, path=["response"]) - - @parametrize - async def test_method_list_with_all_params(self, async_client: AsyncLithic) -> None: - aggregate_balance = await async_client.aggregate_balances.list( - financial_account_type="ISSUING", - ) - assert_matches_type(AsyncSinglePage[AggregateBalance], aggregate_balance, path=["response"]) - - @parametrize - async def test_raw_response_list(self, async_client: AsyncLithic) -> None: - response = await async_client.aggregate_balances.with_raw_response.list() - - assert response.is_closed is True - assert response.http_request.headers.get("X-Stainless-Lang") == "python" - aggregate_balance = response.parse() - assert_matches_type(AsyncSinglePage[AggregateBalance], aggregate_balance, path=["response"]) - - @parametrize - async def test_streaming_response_list(self, async_client: AsyncLithic) -> None: - async with async_client.aggregate_balances.with_streaming_response.list() as response: - assert not response.is_closed - assert response.http_request.headers.get("X-Stainless-Lang") == "python" - - aggregate_balance = await response.parse() - assert_matches_type(AsyncSinglePage[AggregateBalance], aggregate_balance, path=["response"]) - - assert cast(Any, response.is_closed) is True From 8b4b6eb8ddef5de42cdbe847b4f71902006d47b8 Mon Sep 17 00:00:00 2001 From: Mirek Klimos Date: Mon, 15 Dec 2025 10:29:35 +0100 Subject: [PATCH 2/8] format: revert custom formatting --- src/lithic/_client.py | 290 ++++++++------------------------- src/lithic/types/__init__.py | 308 +++++++++-------------------------- 2 files changed, 147 insertions(+), 451 deletions(-) diff --git a/src/lithic/_client.py b/src/lithic/_client.py index d6f1d221..baca51df 100644 --- a/src/lithic/_client.py +++ b/src/lithic/_client.py @@ -85,43 +85,19 @@ from .resources.reports.reports import Reports, AsyncReports from .resources.account_activity import AccountActivity, AsyncAccountActivity from .resources.card_bulk_orders import CardBulkOrders, AsyncCardBulkOrders - from .resources.digital_card_art import ( - DigitalCardArtResource, - AsyncDigitalCardArtResource, - ) + from .resources.digital_card_art import DigitalCardArtResource, AsyncDigitalCardArtResource from .resources.network_programs import NetworkPrograms, AsyncNetworkPrograms from .resources.external_payments import ExternalPayments, AsyncExternalPayments from .resources.three_ds.three_ds import ThreeDS, AsyncThreeDS - from .resources.responder_endpoints import ( - ResponderEndpoints, - AsyncResponderEndpoints, - ) + from .resources.responder_endpoints import ResponderEndpoints, AsyncResponderEndpoints from .resources.auth_rules.auth_rules import AuthRules, AsyncAuthRules - from .resources.management_operations import ( - ManagementOperations, - AsyncManagementOperations, - ) - from .resources.auth_stream_enrollment import ( - AuthStreamEnrollment, - AsyncAuthStreamEnrollment, - ) - from .resources.tokenization_decisioning import ( - TokenizationDecisioning, - AsyncTokenizationDecisioning, - ) + from .resources.management_operations import ManagementOperations, AsyncManagementOperations + from .resources.auth_stream_enrollment import AuthStreamEnrollment, AsyncAuthStreamEnrollment + from .resources.tokenization_decisioning import TokenizationDecisioning, AsyncTokenizationDecisioning from .resources.transactions.transactions import Transactions, AsyncTransactions - from .resources.credit_products.credit_products import ( - CreditProducts, - AsyncCreditProducts, - ) - from .resources.financial_accounts.financial_accounts import ( - FinancialAccounts, - AsyncFinancialAccounts, - ) - from .resources.external_bank_accounts.external_bank_accounts import ( - ExternalBankAccounts, - AsyncExternalBankAccounts, - ) + from .resources.credit_products.credit_products import CreditProducts, AsyncCreditProducts + from .resources.financial_accounts.financial_accounts import FinancialAccounts, AsyncFinancialAccounts + from .resources.external_bank_accounts.external_bank_accounts import ExternalBankAccounts, AsyncExternalBankAccounts __all__ = [ "ENVIRONMENTS", @@ -506,10 +482,7 @@ def api_status( return self.get( "/v1/status", options=make_request_options( - extra_headers=extra_headers, - extra_query=extra_query, - extra_body=extra_body, - timeout=timeout, + extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout ), cast_to=APIStatus, ) @@ -913,10 +886,7 @@ async def api_status( return await self.get( "/v1/status", options=make_request_options( - extra_headers=extra_headers, - extra_query=extra_query, - extra_body=extra_body, - timeout=timeout, + extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout ), cast_to=APIStatus, ) @@ -984,22 +954,14 @@ def auth_rules(self) -> auth_rules.AuthRulesWithRawResponse: return AuthRulesWithRawResponse(self._client.auth_rules) @cached_property - def auth_stream_enrollment( - self, - ) -> auth_stream_enrollment.AuthStreamEnrollmentWithRawResponse: - from .resources.auth_stream_enrollment import ( - AuthStreamEnrollmentWithRawResponse, - ) + def auth_stream_enrollment(self) -> auth_stream_enrollment.AuthStreamEnrollmentWithRawResponse: + from .resources.auth_stream_enrollment import AuthStreamEnrollmentWithRawResponse return AuthStreamEnrollmentWithRawResponse(self._client.auth_stream_enrollment) @cached_property - def tokenization_decisioning( - self, - ) -> tokenization_decisioning.TokenizationDecisioningWithRawResponse: - from .resources.tokenization_decisioning import ( - TokenizationDecisioningWithRawResponse, - ) + def tokenization_decisioning(self) -> tokenization_decisioning.TokenizationDecisioningWithRawResponse: + from .resources.tokenization_decisioning import TokenizationDecisioningWithRawResponse return TokenizationDecisioningWithRawResponse(self._client.tokenization_decisioning) @@ -1058,20 +1020,14 @@ def transactions(self) -> transactions.TransactionsWithRawResponse: return TransactionsWithRawResponse(self._client.transactions) @cached_property - def responder_endpoints( - self, - ) -> responder_endpoints.ResponderEndpointsWithRawResponse: + def responder_endpoints(self) -> responder_endpoints.ResponderEndpointsWithRawResponse: from .resources.responder_endpoints import ResponderEndpointsWithRawResponse return ResponderEndpointsWithRawResponse(self._client.responder_endpoints) @cached_property - def external_bank_accounts( - self, - ) -> external_bank_accounts.ExternalBankAccountsWithRawResponse: - from .resources.external_bank_accounts import ( - ExternalBankAccountsWithRawResponse, - ) + def external_bank_accounts(self) -> external_bank_accounts.ExternalBankAccountsWithRawResponse: + from .resources.external_bank_accounts import ExternalBankAccountsWithRawResponse return ExternalBankAccountsWithRawResponse(self._client.external_bank_accounts) @@ -1100,9 +1056,7 @@ def card_programs(self) -> card_programs.CardProgramsWithRawResponse: return CardProgramsWithRawResponse(self._client.card_programs) @cached_property - def digital_card_art( - self, - ) -> digital_card_art.DigitalCardArtResourceWithRawResponse: + def digital_card_art(self) -> digital_card_art.DigitalCardArtResourceWithRawResponse: from .resources.digital_card_art import DigitalCardArtResourceWithRawResponse return DigitalCardArtResourceWithRawResponse(self._client.digital_card_art) @@ -1126,9 +1080,7 @@ def external_payments(self) -> external_payments.ExternalPaymentsWithRawResponse return ExternalPaymentsWithRawResponse(self._client.external_payments) @cached_property - def management_operations( - self, - ) -> management_operations.ManagementOperationsWithRawResponse: + def management_operations(self) -> management_operations.ManagementOperationsWithRawResponse: from .resources.management_operations import ManagementOperationsWithRawResponse return ManagementOperationsWithRawResponse(self._client.management_operations) @@ -1187,22 +1139,14 @@ def auth_rules(self) -> auth_rules.AsyncAuthRulesWithRawResponse: return AsyncAuthRulesWithRawResponse(self._client.auth_rules) @cached_property - def auth_stream_enrollment( - self, - ) -> auth_stream_enrollment.AsyncAuthStreamEnrollmentWithRawResponse: - from .resources.auth_stream_enrollment import ( - AsyncAuthStreamEnrollmentWithRawResponse, - ) + def auth_stream_enrollment(self) -> auth_stream_enrollment.AsyncAuthStreamEnrollmentWithRawResponse: + from .resources.auth_stream_enrollment import AsyncAuthStreamEnrollmentWithRawResponse return AsyncAuthStreamEnrollmentWithRawResponse(self._client.auth_stream_enrollment) @cached_property - def tokenization_decisioning( - self, - ) -> tokenization_decisioning.AsyncTokenizationDecisioningWithRawResponse: - from .resources.tokenization_decisioning import ( - AsyncTokenizationDecisioningWithRawResponse, - ) + def tokenization_decisioning(self) -> tokenization_decisioning.AsyncTokenizationDecisioningWithRawResponse: + from .resources.tokenization_decisioning import AsyncTokenizationDecisioningWithRawResponse return AsyncTokenizationDecisioningWithRawResponse(self._client.tokenization_decisioning) @@ -1249,9 +1193,7 @@ def events(self) -> events.AsyncEventsWithRawResponse: return AsyncEventsWithRawResponse(self._client.events) @cached_property - def financial_accounts( - self, - ) -> financial_accounts.AsyncFinancialAccountsWithRawResponse: + def financial_accounts(self) -> financial_accounts.AsyncFinancialAccountsWithRawResponse: from .resources.financial_accounts import AsyncFinancialAccountsWithRawResponse return AsyncFinancialAccountsWithRawResponse(self._client.financial_accounts) @@ -1263,22 +1205,14 @@ def transactions(self) -> transactions.AsyncTransactionsWithRawResponse: return AsyncTransactionsWithRawResponse(self._client.transactions) @cached_property - def responder_endpoints( - self, - ) -> responder_endpoints.AsyncResponderEndpointsWithRawResponse: - from .resources.responder_endpoints import ( - AsyncResponderEndpointsWithRawResponse, - ) + def responder_endpoints(self) -> responder_endpoints.AsyncResponderEndpointsWithRawResponse: + from .resources.responder_endpoints import AsyncResponderEndpointsWithRawResponse return AsyncResponderEndpointsWithRawResponse(self._client.responder_endpoints) @cached_property - def external_bank_accounts( - self, - ) -> external_bank_accounts.AsyncExternalBankAccountsWithRawResponse: - from .resources.external_bank_accounts import ( - AsyncExternalBankAccountsWithRawResponse, - ) + def external_bank_accounts(self) -> external_bank_accounts.AsyncExternalBankAccountsWithRawResponse: + from .resources.external_bank_accounts import AsyncExternalBankAccountsWithRawResponse return AsyncExternalBankAccountsWithRawResponse(self._client.external_bank_accounts) @@ -1307,12 +1241,8 @@ def card_programs(self) -> card_programs.AsyncCardProgramsWithRawResponse: return AsyncCardProgramsWithRawResponse(self._client.card_programs) @cached_property - def digital_card_art( - self, - ) -> digital_card_art.AsyncDigitalCardArtResourceWithRawResponse: - from .resources.digital_card_art import ( - AsyncDigitalCardArtResourceWithRawResponse, - ) + def digital_card_art(self) -> digital_card_art.AsyncDigitalCardArtResourceWithRawResponse: + from .resources.digital_card_art import AsyncDigitalCardArtResourceWithRawResponse return AsyncDigitalCardArtResourceWithRawResponse(self._client.digital_card_art) @@ -1329,20 +1259,14 @@ def credit_products(self) -> credit_products.AsyncCreditProductsWithRawResponse: return AsyncCreditProductsWithRawResponse(self._client.credit_products) @cached_property - def external_payments( - self, - ) -> external_payments.AsyncExternalPaymentsWithRawResponse: + def external_payments(self) -> external_payments.AsyncExternalPaymentsWithRawResponse: from .resources.external_payments import AsyncExternalPaymentsWithRawResponse return AsyncExternalPaymentsWithRawResponse(self._client.external_payments) @cached_property - def management_operations( - self, - ) -> management_operations.AsyncManagementOperationsWithRawResponse: - from .resources.management_operations import ( - AsyncManagementOperationsWithRawResponse, - ) + def management_operations(self) -> management_operations.AsyncManagementOperationsWithRawResponse: + from .resources.management_operations import AsyncManagementOperationsWithRawResponse return AsyncManagementOperationsWithRawResponse(self._client.management_operations) @@ -1400,22 +1324,14 @@ def auth_rules(self) -> auth_rules.AuthRulesWithStreamingResponse: return AuthRulesWithStreamingResponse(self._client.auth_rules) @cached_property - def auth_stream_enrollment( - self, - ) -> auth_stream_enrollment.AuthStreamEnrollmentWithStreamingResponse: - from .resources.auth_stream_enrollment import ( - AuthStreamEnrollmentWithStreamingResponse, - ) + def auth_stream_enrollment(self) -> auth_stream_enrollment.AuthStreamEnrollmentWithStreamingResponse: + from .resources.auth_stream_enrollment import AuthStreamEnrollmentWithStreamingResponse return AuthStreamEnrollmentWithStreamingResponse(self._client.auth_stream_enrollment) @cached_property - def tokenization_decisioning( - self, - ) -> tokenization_decisioning.TokenizationDecisioningWithStreamingResponse: - from .resources.tokenization_decisioning import ( - TokenizationDecisioningWithStreamingResponse, - ) + def tokenization_decisioning(self) -> tokenization_decisioning.TokenizationDecisioningWithStreamingResponse: + from .resources.tokenization_decisioning import TokenizationDecisioningWithStreamingResponse return TokenizationDecisioningWithStreamingResponse(self._client.tokenization_decisioning) @@ -1462,9 +1378,7 @@ def events(self) -> events.EventsWithStreamingResponse: return EventsWithStreamingResponse(self._client.events) @cached_property - def financial_accounts( - self, - ) -> financial_accounts.FinancialAccountsWithStreamingResponse: + def financial_accounts(self) -> financial_accounts.FinancialAccountsWithStreamingResponse: from .resources.financial_accounts import FinancialAccountsWithStreamingResponse return FinancialAccountsWithStreamingResponse(self._client.financial_accounts) @@ -1476,22 +1390,14 @@ def transactions(self) -> transactions.TransactionsWithStreamingResponse: return TransactionsWithStreamingResponse(self._client.transactions) @cached_property - def responder_endpoints( - self, - ) -> responder_endpoints.ResponderEndpointsWithStreamingResponse: - from .resources.responder_endpoints import ( - ResponderEndpointsWithStreamingResponse, - ) + def responder_endpoints(self) -> responder_endpoints.ResponderEndpointsWithStreamingResponse: + from .resources.responder_endpoints import ResponderEndpointsWithStreamingResponse return ResponderEndpointsWithStreamingResponse(self._client.responder_endpoints) @cached_property - def external_bank_accounts( - self, - ) -> external_bank_accounts.ExternalBankAccountsWithStreamingResponse: - from .resources.external_bank_accounts import ( - ExternalBankAccountsWithStreamingResponse, - ) + def external_bank_accounts(self) -> external_bank_accounts.ExternalBankAccountsWithStreamingResponse: + from .resources.external_bank_accounts import ExternalBankAccountsWithStreamingResponse return ExternalBankAccountsWithStreamingResponse(self._client.external_bank_accounts) @@ -1520,12 +1426,8 @@ def card_programs(self) -> card_programs.CardProgramsWithStreamingResponse: return CardProgramsWithStreamingResponse(self._client.card_programs) @cached_property - def digital_card_art( - self, - ) -> digital_card_art.DigitalCardArtResourceWithStreamingResponse: - from .resources.digital_card_art import ( - DigitalCardArtResourceWithStreamingResponse, - ) + def digital_card_art(self) -> digital_card_art.DigitalCardArtResourceWithStreamingResponse: + from .resources.digital_card_art import DigitalCardArtResourceWithStreamingResponse return DigitalCardArtResourceWithStreamingResponse(self._client.digital_card_art) @@ -1542,20 +1444,14 @@ def credit_products(self) -> credit_products.CreditProductsWithStreamingResponse return CreditProductsWithStreamingResponse(self._client.credit_products) @cached_property - def external_payments( - self, - ) -> external_payments.ExternalPaymentsWithStreamingResponse: + def external_payments(self) -> external_payments.ExternalPaymentsWithStreamingResponse: from .resources.external_payments import ExternalPaymentsWithStreamingResponse return ExternalPaymentsWithStreamingResponse(self._client.external_payments) @cached_property - def management_operations( - self, - ) -> management_operations.ManagementOperationsWithStreamingResponse: - from .resources.management_operations import ( - ManagementOperationsWithStreamingResponse, - ) + def management_operations(self) -> management_operations.ManagementOperationsWithStreamingResponse: + from .resources.management_operations import ManagementOperationsWithStreamingResponse return ManagementOperationsWithStreamingResponse(self._client.management_operations) @@ -1601,9 +1497,7 @@ def accounts(self) -> accounts.AsyncAccountsWithStreamingResponse: return AsyncAccountsWithStreamingResponse(self._client.accounts) @cached_property - def account_holders( - self, - ) -> account_holders.AsyncAccountHoldersWithStreamingResponse: + def account_holders(self) -> account_holders.AsyncAccountHoldersWithStreamingResponse: from .resources.account_holders import AsyncAccountHoldersWithStreamingResponse return AsyncAccountHoldersWithStreamingResponse(self._client.account_holders) @@ -1615,22 +1509,14 @@ def auth_rules(self) -> auth_rules.AsyncAuthRulesWithStreamingResponse: return AsyncAuthRulesWithStreamingResponse(self._client.auth_rules) @cached_property - def auth_stream_enrollment( - self, - ) -> auth_stream_enrollment.AsyncAuthStreamEnrollmentWithStreamingResponse: - from .resources.auth_stream_enrollment import ( - AsyncAuthStreamEnrollmentWithStreamingResponse, - ) + def auth_stream_enrollment(self) -> auth_stream_enrollment.AsyncAuthStreamEnrollmentWithStreamingResponse: + from .resources.auth_stream_enrollment import AsyncAuthStreamEnrollmentWithStreamingResponse return AsyncAuthStreamEnrollmentWithStreamingResponse(self._client.auth_stream_enrollment) @cached_property - def tokenization_decisioning( - self, - ) -> tokenization_decisioning.AsyncTokenizationDecisioningWithStreamingResponse: - from .resources.tokenization_decisioning import ( - AsyncTokenizationDecisioningWithStreamingResponse, - ) + def tokenization_decisioning(self) -> tokenization_decisioning.AsyncTokenizationDecisioningWithStreamingResponse: + from .resources.tokenization_decisioning import AsyncTokenizationDecisioningWithStreamingResponse return AsyncTokenizationDecisioningWithStreamingResponse(self._client.tokenization_decisioning) @@ -1647,9 +1533,7 @@ def cards(self) -> cards.AsyncCardsWithStreamingResponse: return AsyncCardsWithStreamingResponse(self._client.cards) @cached_property - def card_bulk_orders( - self, - ) -> card_bulk_orders.AsyncCardBulkOrdersWithStreamingResponse: + def card_bulk_orders(self) -> card_bulk_orders.AsyncCardBulkOrdersWithStreamingResponse: from .resources.card_bulk_orders import AsyncCardBulkOrdersWithStreamingResponse return AsyncCardBulkOrdersWithStreamingResponse(self._client.card_bulk_orders) @@ -1679,12 +1563,8 @@ def events(self) -> events.AsyncEventsWithStreamingResponse: return AsyncEventsWithStreamingResponse(self._client.events) @cached_property - def financial_accounts( - self, - ) -> financial_accounts.AsyncFinancialAccountsWithStreamingResponse: - from .resources.financial_accounts import ( - AsyncFinancialAccountsWithStreamingResponse, - ) + def financial_accounts(self) -> financial_accounts.AsyncFinancialAccountsWithStreamingResponse: + from .resources.financial_accounts import AsyncFinancialAccountsWithStreamingResponse return AsyncFinancialAccountsWithStreamingResponse(self._client.financial_accounts) @@ -1695,22 +1575,14 @@ def transactions(self) -> transactions.AsyncTransactionsWithStreamingResponse: return AsyncTransactionsWithStreamingResponse(self._client.transactions) @cached_property - def responder_endpoints( - self, - ) -> responder_endpoints.AsyncResponderEndpointsWithStreamingResponse: - from .resources.responder_endpoints import ( - AsyncResponderEndpointsWithStreamingResponse, - ) + def responder_endpoints(self) -> responder_endpoints.AsyncResponderEndpointsWithStreamingResponse: + from .resources.responder_endpoints import AsyncResponderEndpointsWithStreamingResponse return AsyncResponderEndpointsWithStreamingResponse(self._client.responder_endpoints) @cached_property - def external_bank_accounts( - self, - ) -> external_bank_accounts.AsyncExternalBankAccountsWithStreamingResponse: - from .resources.external_bank_accounts import ( - AsyncExternalBankAccountsWithStreamingResponse, - ) + def external_bank_accounts(self) -> external_bank_accounts.AsyncExternalBankAccountsWithStreamingResponse: + from .resources.external_bank_accounts import AsyncExternalBankAccountsWithStreamingResponse return AsyncExternalBankAccountsWithStreamingResponse(self._client.external_bank_accounts) @@ -1739,12 +1611,8 @@ def card_programs(self) -> card_programs.AsyncCardProgramsWithStreamingResponse: return AsyncCardProgramsWithStreamingResponse(self._client.card_programs) @cached_property - def digital_card_art( - self, - ) -> digital_card_art.AsyncDigitalCardArtResourceWithStreamingResponse: - from .resources.digital_card_art import ( - AsyncDigitalCardArtResourceWithStreamingResponse, - ) + def digital_card_art(self) -> digital_card_art.AsyncDigitalCardArtResourceWithStreamingResponse: + from .resources.digital_card_art import AsyncDigitalCardArtResourceWithStreamingResponse return AsyncDigitalCardArtResourceWithStreamingResponse(self._client.digital_card_art) @@ -1755,30 +1623,20 @@ def book_transfers(self) -> book_transfers.AsyncBookTransfersWithStreamingRespon return AsyncBookTransfersWithStreamingResponse(self._client.book_transfers) @cached_property - def credit_products( - self, - ) -> credit_products.AsyncCreditProductsWithStreamingResponse: + def credit_products(self) -> credit_products.AsyncCreditProductsWithStreamingResponse: from .resources.credit_products import AsyncCreditProductsWithStreamingResponse return AsyncCreditProductsWithStreamingResponse(self._client.credit_products) @cached_property - def external_payments( - self, - ) -> external_payments.AsyncExternalPaymentsWithStreamingResponse: - from .resources.external_payments import ( - AsyncExternalPaymentsWithStreamingResponse, - ) + def external_payments(self) -> external_payments.AsyncExternalPaymentsWithStreamingResponse: + from .resources.external_payments import AsyncExternalPaymentsWithStreamingResponse return AsyncExternalPaymentsWithStreamingResponse(self._client.external_payments) @cached_property - def management_operations( - self, - ) -> management_operations.AsyncManagementOperationsWithStreamingResponse: - from .resources.management_operations import ( - AsyncManagementOperationsWithStreamingResponse, - ) + def management_operations(self) -> management_operations.AsyncManagementOperationsWithStreamingResponse: + from .resources.management_operations import AsyncManagementOperationsWithStreamingResponse return AsyncManagementOperationsWithStreamingResponse(self._client.management_operations) @@ -1795,22 +1653,14 @@ def fraud(self) -> fraud.AsyncFraudWithStreamingResponse: return AsyncFraudWithStreamingResponse(self._client.fraud) @cached_property - def network_programs( - self, - ) -> network_programs.AsyncNetworkProgramsWithStreamingResponse: - from .resources.network_programs import ( - AsyncNetworkProgramsWithStreamingResponse, - ) + def network_programs(self) -> network_programs.AsyncNetworkProgramsWithStreamingResponse: + from .resources.network_programs import AsyncNetworkProgramsWithStreamingResponse return AsyncNetworkProgramsWithStreamingResponse(self._client.network_programs) @cached_property - def account_activity( - self, - ) -> account_activity.AsyncAccountActivityWithStreamingResponse: - from .resources.account_activity import ( - AsyncAccountActivityWithStreamingResponse, - ) + def account_activity(self) -> account_activity.AsyncAccountActivityWithStreamingResponse: + from .resources.account_activity import AsyncAccountActivityWithStreamingResponse return AsyncAccountActivityWithStreamingResponse(self._client.account_activity) diff --git a/src/lithic/types/__init__.py b/src/lithic/types/__init__.py index a3b9977c..a81a6ba3 100644 --- a/src/lithic/types/__init__.py +++ b/src/lithic/types/__init__.py @@ -99,239 +99,85 @@ from .card_get_embed_url_params import CardGetEmbedURLParams as CardGetEmbedURLParams from .card_search_by_pan_params import CardSearchByPanParams as CardSearchByPanParams from .card_web_provision_params import CardWebProvisionParams as CardWebProvisionParams -from .cardholder_authentication import ( - CardholderAuthentication as CardholderAuthentication, -) -from .financial_account_balance import ( - FinancialAccountBalance as FinancialAccountBalance, -) +from .cardholder_authentication import CardholderAuthentication as CardholderAuthentication +from .financial_account_balance import FinancialAccountBalance as FinancialAccountBalance from .funding_event_list_params import FundingEventListParams as FundingEventListParams -from .responder_endpoint_status import ( - ResponderEndpointStatus as ResponderEndpointStatus, -) -from .account_holder_list_params import ( - AccountHolderListParams as AccountHolderListParams, -) -from .card_created_webhook_event import ( - CardCreatedWebhookEvent as CardCreatedWebhookEvent, -) +from .responder_endpoint_status import ResponderEndpointStatus as ResponderEndpointStatus +from .account_holder_list_params import AccountHolderListParams as AccountHolderListParams +from .card_created_webhook_event import CardCreatedWebhookEvent as CardCreatedWebhookEvent from .card_get_embed_html_params import CardGetEmbedHTMLParams as CardGetEmbedHTMLParams -from .card_renewed_webhook_event import ( - CardRenewedWebhookEvent as CardRenewedWebhookEvent, -) -from .card_shipped_webhook_event import ( - CardShippedWebhookEvent as CardShippedWebhookEvent, -) -from .event_list_attempts_params import ( - EventListAttemptsParams as EventListAttemptsParams, -) -from .settlement_summary_details import ( - SettlementSummaryDetails as SettlementSummaryDetails, -) -from .book_transfer_create_params import ( - BookTransferCreateParams as BookTransferCreateParams, -) -from .card_bulk_order_list_params import ( - CardBulkOrderListParams as CardBulkOrderListParams, -) -from .card_reissued_webhook_event import ( - CardReissuedWebhookEvent as CardReissuedWebhookEvent, -) -from .card_web_provision_response import ( - CardWebProvisionResponse as CardWebProvisionResponse, -) -from .network_program_list_params import ( - NetworkProgramListParams as NetworkProgramListParams, -) -from .tokenization_decline_reason import ( - TokenizationDeclineReason as TokenizationDeclineReason, -) -from .account_activity_list_params import ( - AccountActivityListParams as AccountActivityListParams, -) -from .account_holder_create_params import ( - AccountHolderCreateParams as AccountHolderCreateParams, -) -from .account_holder_update_params import ( - AccountHolderUpdateParams as AccountHolderUpdateParams, -) -from .book_transfer_reverse_params import ( - BookTransferReverseParams as BookTransferReverseParams, -) -from .card_convert_physical_params import ( - CardConvertPhysicalParams as CardConvertPhysicalParams, -) -from .card_converted_webhook_event import ( - CardConvertedWebhookEvent as CardConvertedWebhookEvent, -) -from .digital_card_art_list_params import ( - DigitalCardArtListParams as DigitalCardArtListParams, -) -from .external_payment_list_params import ( - ExternalPaymentListParams as ExternalPaymentListParams, -) -from .tokenization_simulate_params import ( - TokenizationSimulateParams as TokenizationSimulateParams, -) -from .balance_updated_webhook_event import ( - BalanceUpdatedWebhookEvent as BalanceUpdatedWebhookEvent, -) -from .card_bulk_order_create_params import ( - CardBulkOrderCreateParams as CardBulkOrderCreateParams, -) -from .card_bulk_order_update_params import ( - CardBulkOrderUpdateParams as CardBulkOrderUpdateParams, -) -from .digital_wallet_token_metadata import ( - DigitalWalletTokenMetadata as DigitalWalletTokenMetadata, -) -from .dispute_list_evidences_params import ( - DisputeListEvidencesParams as DisputeListEvidencesParams, -) -from .dispute_updated_webhook_event import ( - DisputeUpdatedWebhookEvent as DisputeUpdatedWebhookEvent, -) -from .external_bank_account_address import ( - ExternalBankAccountAddress as ExternalBankAccountAddress, -) -from .financial_account_list_params import ( - FinancialAccountListParams as FinancialAccountListParams, -) -from .account_activity_list_response import ( - AccountActivityListResponse as AccountActivityListResponse, -) -from .account_holder_create_response import ( - AccountHolderCreateResponse as AccountHolderCreateResponse, -) -from .account_holder_update_response import ( - AccountHolderUpdateResponse as AccountHolderUpdateResponse, -) -from .external_payment_cancel_params import ( - ExternalPaymentCancelParams as ExternalPaymentCancelParams, -) -from .external_payment_create_params import ( - ExternalPaymentCreateParams as ExternalPaymentCreateParams, -) -from .external_payment_settle_params import ( - ExternalPaymentSettleParams as ExternalPaymentSettleParams, -) -from .payment_simulate_action_params import ( - PaymentSimulateActionParams as PaymentSimulateActionParams, -) -from .payment_simulate_return_params import ( - PaymentSimulateReturnParams as PaymentSimulateReturnParams, -) -from .external_payment_release_params import ( - ExternalPaymentReleaseParams as ExternalPaymentReleaseParams, -) -from .external_payment_reverse_params import ( - ExternalPaymentReverseParams as ExternalPaymentReverseParams, -) -from .financial_account_create_params import ( - FinancialAccountCreateParams as FinancialAccountCreateParams, -) -from .financial_account_update_params import ( - FinancialAccountUpdateParams as FinancialAccountUpdateParams, -) -from .loan_tape_created_webhook_event import ( - LoanTapeCreatedWebhookEvent as LoanTapeCreatedWebhookEvent, -) -from .loan_tape_updated_webhook_event import ( - LoanTapeUpdatedWebhookEvent as LoanTapeUpdatedWebhookEvent, -) -from .payment_simulate_receipt_params import ( - PaymentSimulateReceiptParams as PaymentSimulateReceiptParams, -) -from .payment_simulate_release_params import ( - PaymentSimulateReleaseParams as PaymentSimulateReleaseParams, -) -from .management_operation_list_params import ( - ManagementOperationListParams as ManagementOperationListParams, -) -from .management_operation_transaction import ( - ManagementOperationTransaction as ManagementOperationTransaction, -) -from .payment_simulate_action_response import ( - PaymentSimulateActionResponse as PaymentSimulateActionResponse, -) -from .payment_simulate_return_response import ( - PaymentSimulateReturnResponse as PaymentSimulateReturnResponse, -) -from .responder_endpoint_create_params import ( - ResponderEndpointCreateParams as ResponderEndpointCreateParams, -) -from .responder_endpoint_delete_params import ( - ResponderEndpointDeleteParams as ResponderEndpointDeleteParams, -) -from .statements_created_webhook_event import ( - StatementsCreatedWebhookEvent as StatementsCreatedWebhookEvent, -) -from .transaction_simulate_void_params import ( - TransactionSimulateVoidParams as TransactionSimulateVoidParams, -) -from .external_bank_account_list_params import ( - ExternalBankAccountListParams as ExternalBankAccountListParams, -) -from .payment_simulate_receipt_response import ( - PaymentSimulateReceiptResponse as PaymentSimulateReceiptResponse, -) -from .payment_simulate_release_response import ( - PaymentSimulateReleaseResponse as PaymentSimulateReleaseResponse, -) -from .tokenization_result_webhook_event import ( - TokenizationResultWebhookEvent as TokenizationResultWebhookEvent, -) -from .management_operation_create_params import ( - ManagementOperationCreateParams as ManagementOperationCreateParams, -) -from .responder_endpoint_create_response import ( - ResponderEndpointCreateResponse as ResponderEndpointCreateResponse, -) -from .tokenization_updated_webhook_event import ( - TokenizationUpdatedWebhookEvent as TokenizationUpdatedWebhookEvent, -) -from .transaction_simulate_return_params import ( - TransactionSimulateReturnParams as TransactionSimulateReturnParams, -) -from .transaction_simulate_void_response import ( - TransactionSimulateVoidResponse as TransactionSimulateVoidResponse, -) -from .external_bank_account_address_param import ( - ExternalBankAccountAddressParam as ExternalBankAccountAddressParam, -) -from .external_bank_account_create_params import ( - ExternalBankAccountCreateParams as ExternalBankAccountCreateParams, -) -from .external_bank_account_list_response import ( - ExternalBankAccountListResponse as ExternalBankAccountListResponse, -) -from .external_bank_account_update_params import ( - ExternalBankAccountUpdateParams as ExternalBankAccountUpdateParams, -) -from .funding_event_created_webhook_event import ( - FundingEventCreatedWebhookEvent as FundingEventCreatedWebhookEvent, -) -from .management_operation_reverse_params import ( - ManagementOperationReverseParams as ManagementOperationReverseParams, -) -from .network_total_created_webhook_event import ( - NetworkTotalCreatedWebhookEvent as NetworkTotalCreatedWebhookEvent, -) -from .network_total_updated_webhook_event import ( - NetworkTotalUpdatedWebhookEvent as NetworkTotalUpdatedWebhookEvent, -) -from .account_holder_created_webhook_event import ( - AccountHolderCreatedWebhookEvent as AccountHolderCreatedWebhookEvent, -) -from .account_holder_updated_webhook_event import ( - AccountHolderUpdatedWebhookEvent as AccountHolderUpdatedWebhookEvent, -) -from .transaction_simulate_clearing_params import ( - TransactionSimulateClearingParams as TransactionSimulateClearingParams, -) -from .transaction_simulate_return_response import ( - TransactionSimulateReturnResponse as TransactionSimulateReturnResponse, -) +from .card_renewed_webhook_event import CardRenewedWebhookEvent as CardRenewedWebhookEvent +from .card_shipped_webhook_event import CardShippedWebhookEvent as CardShippedWebhookEvent +from .event_list_attempts_params import EventListAttemptsParams as EventListAttemptsParams +from .settlement_summary_details import SettlementSummaryDetails as SettlementSummaryDetails +from .book_transfer_create_params import BookTransferCreateParams as BookTransferCreateParams +from .card_bulk_order_list_params import CardBulkOrderListParams as CardBulkOrderListParams +from .card_reissued_webhook_event import CardReissuedWebhookEvent as CardReissuedWebhookEvent +from .card_web_provision_response import CardWebProvisionResponse as CardWebProvisionResponse +from .network_program_list_params import NetworkProgramListParams as NetworkProgramListParams +from .tokenization_decline_reason import TokenizationDeclineReason as TokenizationDeclineReason +from .account_activity_list_params import AccountActivityListParams as AccountActivityListParams +from .account_holder_create_params import AccountHolderCreateParams as AccountHolderCreateParams +from .account_holder_update_params import AccountHolderUpdateParams as AccountHolderUpdateParams +from .book_transfer_reverse_params import BookTransferReverseParams as BookTransferReverseParams +from .card_convert_physical_params import CardConvertPhysicalParams as CardConvertPhysicalParams +from .card_converted_webhook_event import CardConvertedWebhookEvent as CardConvertedWebhookEvent +from .digital_card_art_list_params import DigitalCardArtListParams as DigitalCardArtListParams +from .external_payment_list_params import ExternalPaymentListParams as ExternalPaymentListParams +from .tokenization_simulate_params import TokenizationSimulateParams as TokenizationSimulateParams +from .balance_updated_webhook_event import BalanceUpdatedWebhookEvent as BalanceUpdatedWebhookEvent +from .card_bulk_order_create_params import CardBulkOrderCreateParams as CardBulkOrderCreateParams +from .card_bulk_order_update_params import CardBulkOrderUpdateParams as CardBulkOrderUpdateParams +from .digital_wallet_token_metadata import DigitalWalletTokenMetadata as DigitalWalletTokenMetadata +from .dispute_list_evidences_params import DisputeListEvidencesParams as DisputeListEvidencesParams +from .dispute_updated_webhook_event import DisputeUpdatedWebhookEvent as DisputeUpdatedWebhookEvent +from .external_bank_account_address import ExternalBankAccountAddress as ExternalBankAccountAddress +from .financial_account_list_params import FinancialAccountListParams as FinancialAccountListParams +from .account_activity_list_response import AccountActivityListResponse as AccountActivityListResponse +from .account_holder_create_response import AccountHolderCreateResponse as AccountHolderCreateResponse +from .account_holder_update_response import AccountHolderUpdateResponse as AccountHolderUpdateResponse +from .external_payment_cancel_params import ExternalPaymentCancelParams as ExternalPaymentCancelParams +from .external_payment_create_params import ExternalPaymentCreateParams as ExternalPaymentCreateParams +from .external_payment_settle_params import ExternalPaymentSettleParams as ExternalPaymentSettleParams +from .payment_simulate_action_params import PaymentSimulateActionParams as PaymentSimulateActionParams +from .payment_simulate_return_params import PaymentSimulateReturnParams as PaymentSimulateReturnParams +from .external_payment_release_params import ExternalPaymentReleaseParams as ExternalPaymentReleaseParams +from .external_payment_reverse_params import ExternalPaymentReverseParams as ExternalPaymentReverseParams +from .financial_account_create_params import FinancialAccountCreateParams as FinancialAccountCreateParams +from .financial_account_update_params import FinancialAccountUpdateParams as FinancialAccountUpdateParams +from .loan_tape_created_webhook_event import LoanTapeCreatedWebhookEvent as LoanTapeCreatedWebhookEvent +from .loan_tape_updated_webhook_event import LoanTapeUpdatedWebhookEvent as LoanTapeUpdatedWebhookEvent +from .payment_simulate_receipt_params import PaymentSimulateReceiptParams as PaymentSimulateReceiptParams +from .payment_simulate_release_params import PaymentSimulateReleaseParams as PaymentSimulateReleaseParams +from .management_operation_list_params import ManagementOperationListParams as ManagementOperationListParams +from .management_operation_transaction import ManagementOperationTransaction as ManagementOperationTransaction +from .payment_simulate_action_response import PaymentSimulateActionResponse as PaymentSimulateActionResponse +from .payment_simulate_return_response import PaymentSimulateReturnResponse as PaymentSimulateReturnResponse +from .responder_endpoint_create_params import ResponderEndpointCreateParams as ResponderEndpointCreateParams +from .responder_endpoint_delete_params import ResponderEndpointDeleteParams as ResponderEndpointDeleteParams +from .statements_created_webhook_event import StatementsCreatedWebhookEvent as StatementsCreatedWebhookEvent +from .transaction_simulate_void_params import TransactionSimulateVoidParams as TransactionSimulateVoidParams +from .external_bank_account_list_params import ExternalBankAccountListParams as ExternalBankAccountListParams +from .payment_simulate_receipt_response import PaymentSimulateReceiptResponse as PaymentSimulateReceiptResponse +from .payment_simulate_release_response import PaymentSimulateReleaseResponse as PaymentSimulateReleaseResponse +from .tokenization_result_webhook_event import TokenizationResultWebhookEvent as TokenizationResultWebhookEvent +from .management_operation_create_params import ManagementOperationCreateParams as ManagementOperationCreateParams +from .responder_endpoint_create_response import ResponderEndpointCreateResponse as ResponderEndpointCreateResponse +from .tokenization_updated_webhook_event import TokenizationUpdatedWebhookEvent as TokenizationUpdatedWebhookEvent +from .transaction_simulate_return_params import TransactionSimulateReturnParams as TransactionSimulateReturnParams +from .transaction_simulate_void_response import TransactionSimulateVoidResponse as TransactionSimulateVoidResponse +from .external_bank_account_address_param import ExternalBankAccountAddressParam as ExternalBankAccountAddressParam +from .external_bank_account_create_params import ExternalBankAccountCreateParams as ExternalBankAccountCreateParams +from .external_bank_account_list_response import ExternalBankAccountListResponse as ExternalBankAccountListResponse +from .external_bank_account_update_params import ExternalBankAccountUpdateParams as ExternalBankAccountUpdateParams +from .funding_event_created_webhook_event import FundingEventCreatedWebhookEvent as FundingEventCreatedWebhookEvent +from .management_operation_reverse_params import ManagementOperationReverseParams as ManagementOperationReverseParams +from .network_total_created_webhook_event import NetworkTotalCreatedWebhookEvent as NetworkTotalCreatedWebhookEvent +from .network_total_updated_webhook_event import NetworkTotalUpdatedWebhookEvent as NetworkTotalUpdatedWebhookEvent +from .account_holder_created_webhook_event import AccountHolderCreatedWebhookEvent as AccountHolderCreatedWebhookEvent +from .account_holder_updated_webhook_event import AccountHolderUpdatedWebhookEvent as AccountHolderUpdatedWebhookEvent +from .transaction_simulate_clearing_params import TransactionSimulateClearingParams as TransactionSimulateClearingParams +from .transaction_simulate_return_response import TransactionSimulateReturnResponse as TransactionSimulateReturnResponse from .account_holder_upload_document_params import ( AccountHolderUploadDocumentParams as AccountHolderUploadDocumentParams, ) From 52f441ece2827bf2b57bc2840d226121becbbff4 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Mon, 15 Dec 2025 19:20:41 +0000 Subject: [PATCH 3/8] chore(internal): add missing files argument to base client --- src/lithic/_base_client.py | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/lithic/_base_client.py b/src/lithic/_base_client.py index ddcf4528..ce040646 100644 --- a/src/lithic/_base_client.py +++ b/src/lithic/_base_client.py @@ -1262,9 +1262,12 @@ def patch( *, cast_to: Type[ResponseT], body: Body | None = None, + files: RequestFiles | None = None, options: RequestOptions = {}, ) -> ResponseT: - opts = FinalRequestOptions.construct(method="patch", url=path, json_data=body, **options) + opts = FinalRequestOptions.construct( + method="patch", url=path, json_data=body, files=to_httpx_files(files), **options + ) return self.request(cast_to, opts) def put( @@ -1796,9 +1799,12 @@ async def patch( *, cast_to: Type[ResponseT], body: Body | None = None, + files: RequestFiles | None = None, options: RequestOptions = {}, ) -> ResponseT: - opts = FinalRequestOptions.construct(method="patch", url=path, json_data=body, **options) + opts = FinalRequestOptions.construct( + method="patch", url=path, json_data=body, files=to_httpx_files(files), **options + ) return await self.request(cast_to, opts) async def put( From 783d8ff3f2119f1ff7c89e65864107fa13afe9b4 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Wed, 17 Dec 2025 15:46:28 +0000 Subject: [PATCH 4/8] fix: use async_to_httpx_files in patch method --- src/lithic/_base_client.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lithic/_base_client.py b/src/lithic/_base_client.py index ce040646..e8b7c42d 100644 --- a/src/lithic/_base_client.py +++ b/src/lithic/_base_client.py @@ -1803,7 +1803,7 @@ async def patch( options: RequestOptions = {}, ) -> ResponseT: opts = FinalRequestOptions.construct( - method="patch", url=path, json_data=body, files=to_httpx_files(files), **options + method="patch", url=path, json_data=body, files=await async_to_httpx_files(files), **options ) return await self.request(cast_to, opts) From 8e0a11ca6969fe5956ad244a7222525ff16c11b9 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Thu, 18 Dec 2025 21:51:43 +0000 Subject: [PATCH 5/8] chore(internal): add `--fix` argument to lint script --- scripts/lint | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/scripts/lint b/scripts/lint index c997f8ca..570fee87 100755 --- a/scripts/lint +++ b/scripts/lint @@ -4,8 +4,13 @@ set -e cd "$(dirname "$0")/.." -echo "==> Running lints" -rye run lint +if [ "$1" = "--fix" ]; then + echo "==> Running lints with --fix" + rye run fix:ruff +else + echo "==> Running lints" + rye run lint +fi echo "==> Making sure it imports" rye run python -c 'import lithic' From b87046c51cb5d332ea53959ac3892ce2ba29cec3 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Fri, 19 Dec 2025 10:13:07 +0000 Subject: [PATCH 6/8] feat(api): add external_id to payment_event feat(api): add get /v1/transfer_limits endpoint feat(api): add post /v1/book_transfers/{book_transfer_token}/retry endpoint --- .stats.yml | 8 +- api.md | 13 ++ src/lithic/_client.py | 38 ++++ src/lithic/resources/__init__.py | 14 ++ src/lithic/resources/book_transfers.py | 99 +++++++++- src/lithic/resources/transfer_limits.py | 175 ++++++++++++++++++ src/lithic/types/__init__.py | 3 + .../types/book_transfer_retry_params.py | 12 ++ src/lithic/types/payment.py | 3 + .../types/transfer_limit_list_params.py | 16 ++ src/lithic/types/transfer_limits_response.py | 138 ++++++++++++++ tests/api_resources/test_book_transfers.py | 84 +++++++++ tests/api_resources/test_transfer_limits.py | 90 +++++++++ 13 files changed, 688 insertions(+), 5 deletions(-) create mode 100644 src/lithic/resources/transfer_limits.py create mode 100644 src/lithic/types/book_transfer_retry_params.py create mode 100644 src/lithic/types/transfer_limit_list_params.py create mode 100644 src/lithic/types/transfer_limits_response.py create mode 100644 tests/api_resources/test_transfer_limits.py diff --git a/.stats.yml b/.stats.yml index 51bc2543..3d59bbd3 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ -configured_endpoints: 173 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic%2Flithic-4fd8048b287f409ad2b91f7d0f0b7fc13cc9bc4ccc7859666f21203bab3d2f01.yml -openapi_spec_hash: a554c54d96a7604a770b6a8b1df46395 -config_hash: df0af4ff639b8a6923a6244d2247910c +configured_endpoints: 175 +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic%2Flithic-1916ba0e95ce59f0feeebd6f3d2130990c812be7eabcda6e23c5fa096db912c7.yml +openapi_spec_hash: b465e7cb5c2dee36b5bdc6d540b2a530 +config_hash: a8a802e2c916a5d36a025bf64ab55ee7 diff --git a/api.md b/api.md index 4ca0eeaf..568d0761 100644 --- a/api.md +++ b/api.md @@ -670,6 +670,7 @@ Methods: - client.book_transfers.create(\*\*params) -> BookTransferResponse - client.book_transfers.retrieve(book_transfer_token) -> BookTransferResponse - client.book_transfers.list(\*\*params) -> SyncCursorPage[BookTransferResponse] +- client.book_transfers.retry(book_transfer_token, \*\*params) -> BookTransferResponse - client.book_transfers.reverse(book_transfer_token, \*\*params) -> BookTransferResponse # CreditProducts @@ -799,6 +800,18 @@ Methods: - client.account_activity.list(\*\*params) -> SyncCursorPage[AccountActivityListResponse] - client.account_activity.retrieve_transaction(transaction_token) -> AccountActivityRetrieveTransactionResponse +# TransferLimits + +Types: + +```python +from lithic.types import TransferLimitsResponse +``` + +Methods: + +- client.transfer_limits.list(\*\*params) -> SyncSinglePage[Data] + # Webhooks Types: diff --git a/src/lithic/_client.py b/src/lithic/_client.py index baca51df..ef7bb353 100644 --- a/src/lithic/_client.py +++ b/src/lithic/_client.py @@ -56,6 +56,7 @@ funding_events, account_holders, credit_products, + transfer_limits, account_activity, card_bulk_orders, digital_card_art, @@ -83,6 +84,7 @@ from .resources.funding_events import FundingEvents, AsyncFundingEvents from .resources.account_holders import AccountHolders, AsyncAccountHolders from .resources.reports.reports import Reports, AsyncReports + from .resources.transfer_limits import TransferLimits, AsyncTransferLimits from .resources.account_activity import AccountActivity, AsyncAccountActivity from .resources.card_bulk_orders import CardBulkOrders, AsyncCardBulkOrders from .resources.digital_card_art import DigitalCardArtResource, AsyncDigitalCardArtResource @@ -378,6 +380,12 @@ def account_activity(self) -> AccountActivity: return AccountActivity(self) + @cached_property + def transfer_limits(self) -> TransferLimits: + from .resources.transfer_limits import TransferLimits + + return TransferLimits(self) + @cached_property def webhooks(self) -> Webhooks: from .resources.webhooks import Webhooks @@ -782,6 +790,12 @@ def account_activity(self) -> AsyncAccountActivity: return AsyncAccountActivity(self) + @cached_property + def transfer_limits(self) -> AsyncTransferLimits: + from .resources.transfer_limits import AsyncTransferLimits + + return AsyncTransferLimits(self) + @cached_property def webhooks(self) -> AsyncWebhooks: from .resources.webhooks import AsyncWebhooks @@ -1109,6 +1123,12 @@ def account_activity(self) -> account_activity.AccountActivityWithRawResponse: return AccountActivityWithRawResponse(self._client.account_activity) + @cached_property + def transfer_limits(self) -> transfer_limits.TransferLimitsWithRawResponse: + from .resources.transfer_limits import TransferLimitsWithRawResponse + + return TransferLimitsWithRawResponse(self._client.transfer_limits) + class AsyncLithicWithRawResponse: _client: AsyncLithic @@ -1294,6 +1314,12 @@ def account_activity(self) -> account_activity.AsyncAccountActivityWithRawRespon return AsyncAccountActivityWithRawResponse(self._client.account_activity) + @cached_property + def transfer_limits(self) -> transfer_limits.AsyncTransferLimitsWithRawResponse: + from .resources.transfer_limits import AsyncTransferLimitsWithRawResponse + + return AsyncTransferLimitsWithRawResponse(self._client.transfer_limits) + class LithicWithStreamedResponse: _client: Lithic @@ -1479,6 +1505,12 @@ def account_activity(self) -> account_activity.AccountActivityWithStreamingRespo return AccountActivityWithStreamingResponse(self._client.account_activity) + @cached_property + def transfer_limits(self) -> transfer_limits.TransferLimitsWithStreamingResponse: + from .resources.transfer_limits import TransferLimitsWithStreamingResponse + + return TransferLimitsWithStreamingResponse(self._client.transfer_limits) + class AsyncLithicWithStreamedResponse: _client: AsyncLithic @@ -1664,6 +1696,12 @@ def account_activity(self) -> account_activity.AsyncAccountActivityWithStreaming return AsyncAccountActivityWithStreamingResponse(self._client.account_activity) + @cached_property + def transfer_limits(self) -> transfer_limits.AsyncTransferLimitsWithStreamingResponse: + from .resources.transfer_limits import AsyncTransferLimitsWithStreamingResponse + + return AsyncTransferLimitsWithStreamingResponse(self._client.transfer_limits) + Client = Lithic diff --git a/src/lithic/resources/__init__.py b/src/lithic/resources/__init__.py index 77245ab4..07be719f 100644 --- a/src/lithic/resources/__init__.py +++ b/src/lithic/resources/__init__.py @@ -145,6 +145,14 @@ CreditProductsWithStreamingResponse, AsyncCreditProductsWithStreamingResponse, ) +from .transfer_limits import ( + TransferLimits, + AsyncTransferLimits, + TransferLimitsWithRawResponse, + AsyncTransferLimitsWithRawResponse, + TransferLimitsWithStreamingResponse, + AsyncTransferLimitsWithStreamingResponse, +) from .account_activity import ( AccountActivity, AsyncAccountActivity, @@ -409,6 +417,12 @@ "AsyncAccountActivityWithRawResponse", "AccountActivityWithStreamingResponse", "AsyncAccountActivityWithStreamingResponse", + "TransferLimits", + "AsyncTransferLimits", + "TransferLimitsWithRawResponse", + "AsyncTransferLimitsWithRawResponse", + "TransferLimitsWithStreamingResponse", + "AsyncTransferLimitsWithStreamingResponse", "Webhooks", "AsyncWebhooks", ] diff --git a/src/lithic/resources/book_transfers.py b/src/lithic/resources/book_transfers.py index f2eb20ef..20533bb8 100644 --- a/src/lithic/resources/book_transfers.py +++ b/src/lithic/resources/book_transfers.py @@ -9,7 +9,12 @@ import httpx from .. import _legacy_response -from ..types import book_transfer_list_params, book_transfer_create_params, book_transfer_reverse_params +from ..types import ( + book_transfer_list_params, + book_transfer_retry_params, + book_transfer_create_params, + book_transfer_reverse_params, +) from .._types import Body, Omit, Query, Headers, NotGiven, omit, not_given from .._utils import maybe_transform, async_maybe_transform from .._compat import cached_property @@ -297,6 +302,45 @@ def list( model=BookTransferResponse, ) + def retry( + self, + book_transfer_token: str, + *, + retry_token: str, + # 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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> BookTransferResponse: + """ + Retry a book transfer that has been declined + + Args: + retry_token: Globally unique identifier for the retry. + + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + if not book_transfer_token: + raise ValueError( + f"Expected a non-empty value for `book_transfer_token` but received {book_transfer_token!r}" + ) + return self._post( + f"/v1/book_transfers/{book_transfer_token}/retry", + body=maybe_transform({"retry_token": retry_token}, book_transfer_retry_params.BookTransferRetryParams), + options=make_request_options( + extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout + ), + cast_to=BookTransferResponse, + ) + def reverse( self, book_transfer_token: str, @@ -612,6 +656,47 @@ def list( model=BookTransferResponse, ) + async def retry( + self, + book_transfer_token: str, + *, + retry_token: str, + # 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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> BookTransferResponse: + """ + Retry a book transfer that has been declined + + Args: + retry_token: Globally unique identifier for the retry. + + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + if not book_transfer_token: + raise ValueError( + f"Expected a non-empty value for `book_transfer_token` but received {book_transfer_token!r}" + ) + return await self._post( + f"/v1/book_transfers/{book_transfer_token}/retry", + body=await async_maybe_transform( + {"retry_token": retry_token}, book_transfer_retry_params.BookTransferRetryParams + ), + options=make_request_options( + extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout + ), + cast_to=BookTransferResponse, + ) + async def reverse( self, book_transfer_token: str, @@ -665,6 +750,9 @@ def __init__(self, book_transfers: BookTransfers) -> None: self.list = _legacy_response.to_raw_response_wrapper( book_transfers.list, ) + self.retry = _legacy_response.to_raw_response_wrapper( + book_transfers.retry, + ) self.reverse = _legacy_response.to_raw_response_wrapper( book_transfers.reverse, ) @@ -683,6 +771,9 @@ def __init__(self, book_transfers: AsyncBookTransfers) -> None: self.list = _legacy_response.async_to_raw_response_wrapper( book_transfers.list, ) + self.retry = _legacy_response.async_to_raw_response_wrapper( + book_transfers.retry, + ) self.reverse = _legacy_response.async_to_raw_response_wrapper( book_transfers.reverse, ) @@ -701,6 +792,9 @@ def __init__(self, book_transfers: BookTransfers) -> None: self.list = to_streamed_response_wrapper( book_transfers.list, ) + self.retry = to_streamed_response_wrapper( + book_transfers.retry, + ) self.reverse = to_streamed_response_wrapper( book_transfers.reverse, ) @@ -719,6 +813,9 @@ def __init__(self, book_transfers: AsyncBookTransfers) -> None: self.list = async_to_streamed_response_wrapper( book_transfers.list, ) + self.retry = async_to_streamed_response_wrapper( + book_transfers.retry, + ) self.reverse = async_to_streamed_response_wrapper( book_transfers.reverse, ) diff --git a/src/lithic/resources/transfer_limits.py b/src/lithic/resources/transfer_limits.py new file mode 100644 index 00000000..790e899c --- /dev/null +++ b/src/lithic/resources/transfer_limits.py @@ -0,0 +1,175 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from __future__ import annotations + +from typing import Union +from datetime import date + +import httpx + +from .. import _legacy_response +from ..types import transfer_limit_list_params +from .._types import Body, Omit, Query, Headers, NotGiven, omit, not_given +from .._utils import maybe_transform +from .._compat import cached_property +from .._resource import SyncAPIResource, AsyncAPIResource +from .._response import to_streamed_response_wrapper, async_to_streamed_response_wrapper +from ..pagination import SyncSinglePage, AsyncSinglePage +from .._base_client import AsyncPaginator, make_request_options +from ..types.transfer_limits_response import Data + +__all__ = ["TransferLimits", "AsyncTransferLimits"] + + +class TransferLimits(SyncAPIResource): + @cached_property + def with_raw_response(self) -> TransferLimitsWithRawResponse: + """ + This property can be used as a prefix for any HTTP method call to return + the raw response object instead of the parsed content. + + For more information, see https://www.github.com/lithic-com/lithic-python#accessing-raw-response-data-eg-headers + """ + return TransferLimitsWithRawResponse(self) + + @cached_property + def with_streaming_response(self) -> TransferLimitsWithStreamingResponse: + """ + An alternative to `.with_raw_response` that doesn't eagerly read the response body. + + For more information, see https://www.github.com/lithic-com/lithic-python#with_streaming_response + """ + return TransferLimitsWithStreamingResponse(self) + + def list( + self, + *, + date: Union[str, date] | Omit = omit, + # 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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> SyncSinglePage[Data]: + """ + Get transfer limits for a specified date + + Args: + date: Date for which to retrieve transfer limits (ISO 8601 format) + + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + return self._get_api_list( + "/v1/transfer_limits", + page=SyncSinglePage[Data], + options=make_request_options( + extra_headers=extra_headers, + extra_query=extra_query, + extra_body=extra_body, + timeout=timeout, + query=maybe_transform({"date": date}, transfer_limit_list_params.TransferLimitListParams), + ), + model=Data, + ) + + +class AsyncTransferLimits(AsyncAPIResource): + @cached_property + def with_raw_response(self) -> AsyncTransferLimitsWithRawResponse: + """ + This property can be used as a prefix for any HTTP method call to return + the raw response object instead of the parsed content. + + For more information, see https://www.github.com/lithic-com/lithic-python#accessing-raw-response-data-eg-headers + """ + return AsyncTransferLimitsWithRawResponse(self) + + @cached_property + def with_streaming_response(self) -> AsyncTransferLimitsWithStreamingResponse: + """ + An alternative to `.with_raw_response` that doesn't eagerly read the response body. + + For more information, see https://www.github.com/lithic-com/lithic-python#with_streaming_response + """ + return AsyncTransferLimitsWithStreamingResponse(self) + + def list( + self, + *, + date: Union[str, date] | Omit = omit, + # 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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> AsyncPaginator[Data, AsyncSinglePage[Data]]: + """ + Get transfer limits for a specified date + + Args: + date: Date for which to retrieve transfer limits (ISO 8601 format) + + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + return self._get_api_list( + "/v1/transfer_limits", + page=AsyncSinglePage[Data], + options=make_request_options( + extra_headers=extra_headers, + extra_query=extra_query, + extra_body=extra_body, + timeout=timeout, + query=maybe_transform({"date": date}, transfer_limit_list_params.TransferLimitListParams), + ), + model=Data, + ) + + +class TransferLimitsWithRawResponse: + def __init__(self, transfer_limits: TransferLimits) -> None: + self._transfer_limits = transfer_limits + + self.list = _legacy_response.to_raw_response_wrapper( + transfer_limits.list, + ) + + +class AsyncTransferLimitsWithRawResponse: + def __init__(self, transfer_limits: AsyncTransferLimits) -> None: + self._transfer_limits = transfer_limits + + self.list = _legacy_response.async_to_raw_response_wrapper( + transfer_limits.list, + ) + + +class TransferLimitsWithStreamingResponse: + def __init__(self, transfer_limits: TransferLimits) -> None: + self._transfer_limits = transfer_limits + + self.list = to_streamed_response_wrapper( + transfer_limits.list, + ) + + +class AsyncTransferLimitsWithStreamingResponse: + def __init__(self, transfer_limits: AsyncTransferLimits) -> None: + self._transfer_limits = transfer_limits + + self.list = async_to_streamed_response_wrapper( + transfer_limits.list, + ) diff --git a/src/lithic/types/__init__.py b/src/lithic/types/__init__.py index a81a6ba3..9cb0fdcd 100644 --- a/src/lithic/types/__init__.py +++ b/src/lithic/types/__init__.py @@ -94,6 +94,7 @@ from .card_program_list_params import CardProgramListParams as CardProgramListParams from .tokenization_list_params import TokenizationListParams as TokenizationListParams from .tokenization_rule_result import TokenizationRuleResult as TokenizationRuleResult +from .transfer_limits_response import TransferLimitsResponse as TransferLimitsResponse from .asa_request_webhook_event import AsaRequestWebhookEvent as AsaRequestWebhookEvent from .book_transfer_list_params import BookTransferListParams as BookTransferListParams from .card_get_embed_url_params import CardGetEmbedURLParams as CardGetEmbedURLParams @@ -104,12 +105,14 @@ from .funding_event_list_params import FundingEventListParams as FundingEventListParams from .responder_endpoint_status import ResponderEndpointStatus as ResponderEndpointStatus from .account_holder_list_params import AccountHolderListParams as AccountHolderListParams +from .book_transfer_retry_params import BookTransferRetryParams as BookTransferRetryParams from .card_created_webhook_event import CardCreatedWebhookEvent as CardCreatedWebhookEvent from .card_get_embed_html_params import CardGetEmbedHTMLParams as CardGetEmbedHTMLParams from .card_renewed_webhook_event import CardRenewedWebhookEvent as CardRenewedWebhookEvent from .card_shipped_webhook_event import CardShippedWebhookEvent as CardShippedWebhookEvent from .event_list_attempts_params import EventListAttemptsParams as EventListAttemptsParams from .settlement_summary_details import SettlementSummaryDetails as SettlementSummaryDetails +from .transfer_limit_list_params import TransferLimitListParams as TransferLimitListParams from .book_transfer_create_params import BookTransferCreateParams as BookTransferCreateParams from .card_bulk_order_list_params import CardBulkOrderListParams as CardBulkOrderListParams from .card_reissued_webhook_event import CardReissuedWebhookEvent as CardReissuedWebhookEvent diff --git a/src/lithic/types/book_transfer_retry_params.py b/src/lithic/types/book_transfer_retry_params.py new file mode 100644 index 00000000..d923598c --- /dev/null +++ b/src/lithic/types/book_transfer_retry_params.py @@ -0,0 +1,12 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from __future__ import annotations + +from typing_extensions import Required, TypedDict + +__all__ = ["BookTransferRetryParams"] + + +class BookTransferRetryParams(TypedDict, total=False): + retry_token: Required[str] + """Globally unique identifier for the retry.""" diff --git a/src/lithic/types/payment.py b/src/lithic/types/payment.py index 3b32efaa..f1685c8e 100644 --- a/src/lithic/types/payment.py +++ b/src/lithic/types/payment.py @@ -95,6 +95,9 @@ class Event(BaseModel): ] = None """More detailed reasons for the event""" + external_id: Optional[str] = None + """Payment event external ID, for example, ACH trace number.""" + class MethodAttributesACHMethodAttributes(BaseModel): sec_code: Literal["CCD", "PPD", "WEB", "TEL", "CIE", "CTX"] diff --git a/src/lithic/types/transfer_limit_list_params.py b/src/lithic/types/transfer_limit_list_params.py new file mode 100644 index 00000000..841f0447 --- /dev/null +++ b/src/lithic/types/transfer_limit_list_params.py @@ -0,0 +1,16 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from __future__ import annotations + +import datetime +from typing import Union +from typing_extensions import Annotated, TypedDict + +from .._utils import PropertyInfo + +__all__ = ["TransferLimitListParams"] + + +class TransferLimitListParams(TypedDict, total=False): + date: Annotated[Union[str, datetime.date], PropertyInfo(format="iso8601")] + """Date for which to retrieve transfer limits (ISO 8601 format)""" diff --git a/src/lithic/types/transfer_limits_response.py b/src/lithic/types/transfer_limits_response.py new file mode 100644 index 00000000..6ff5a3e0 --- /dev/null +++ b/src/lithic/types/transfer_limits_response.py @@ -0,0 +1,138 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +import datetime +from typing import List, Optional + +from .._models import BaseModel + +__all__ = [ + "TransferLimitsResponse", + "Data", + "DataDailyLimit", + "DataDailyLimitCredit", + "DataDailyLimitDebit", + "DataMonthlyLimit", + "DataMonthlyLimitCredit", + "DataMonthlyLimitDebit", + "DataProgramLimitPerTransaction", + "DataProgramLimitPerTransactionCredit", + "DataProgramLimitPerTransactionDebit", +] + + +class DataDailyLimitCredit(BaseModel): + """Credit limits""" + + limit: int + """The limit amount""" + + amount_originated: Optional[int] = None + """Amount originated towards limit""" + + +class DataDailyLimitDebit(BaseModel): + """Debit limits""" + + limit: int + """The limit amount""" + + amount_originated: Optional[int] = None + """Amount originated towards limit""" + + +class DataDailyLimit(BaseModel): + """Daily limits with progress""" + + credit: DataDailyLimitCredit + """Credit limits""" + + debit: DataDailyLimitDebit + """Debit limits""" + + +class DataMonthlyLimitCredit(BaseModel): + """Credit limits""" + + limit: int + """The limit amount""" + + amount_originated: Optional[int] = None + """Amount originated towards limit""" + + +class DataMonthlyLimitDebit(BaseModel): + """Debit limits""" + + limit: int + """The limit amount""" + + amount_originated: Optional[int] = None + """Amount originated towards limit""" + + +class DataMonthlyLimit(BaseModel): + """Monthly limits with progress""" + + credit: DataMonthlyLimitCredit + """Credit limits""" + + debit: DataMonthlyLimitDebit + """Debit limits""" + + +class DataProgramLimitPerTransactionCredit(BaseModel): + """Credit limits""" + + limit: int + """The limit amount""" + + amount_originated: Optional[int] = None + """Amount originated towards limit""" + + +class DataProgramLimitPerTransactionDebit(BaseModel): + """Debit limits""" + + limit: int + """The limit amount""" + + amount_originated: Optional[int] = None + """Amount originated towards limit""" + + +class DataProgramLimitPerTransaction(BaseModel): + """Program transaction limits""" + + credit: DataProgramLimitPerTransactionCredit + """Credit limits""" + + debit: DataProgramLimitPerTransactionDebit + """Debit limits""" + + +class Data(BaseModel): + company_id: str + """Company ID""" + + daily_limit: DataDailyLimit + """Daily limits with progress""" + + date: datetime.date + """The date for the limit view (ISO format)""" + + is_fbo: bool + """Whether the company is a FBO; based on the company ID prefix""" + + monthly_limit: DataMonthlyLimit + """Monthly limits with progress""" + + program_limit_per_transaction: DataProgramLimitPerTransaction + """Program transaction limits""" + + +class TransferLimitsResponse(BaseModel): + data: List[Data] + """List of transfer limits""" + + has_more: bool + """Whether there are more transfer limits""" diff --git a/tests/api_resources/test_book_transfers.py b/tests/api_resources/test_book_transfers.py index 38aa6510..690dc830 100644 --- a/tests/api_resources/test_book_transfers.py +++ b/tests/api_resources/test_book_transfers.py @@ -163,6 +163,48 @@ def test_streaming_response_list(self, client: Lithic) -> None: assert cast(Any, response.is_closed) is True + @parametrize + def test_method_retry(self, client: Lithic) -> None: + book_transfer = client.book_transfers.retry( + book_transfer_token="182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", + retry_token="182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", + ) + assert_matches_type(BookTransferResponse, book_transfer, path=["response"]) + + @parametrize + def test_raw_response_retry(self, client: Lithic) -> None: + response = client.book_transfers.with_raw_response.retry( + book_transfer_token="182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", + retry_token="182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", + ) + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + book_transfer = response.parse() + assert_matches_type(BookTransferResponse, book_transfer, path=["response"]) + + @parametrize + def test_streaming_response_retry(self, client: Lithic) -> None: + with client.book_transfers.with_streaming_response.retry( + book_transfer_token="182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", + retry_token="182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", + ) as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + book_transfer = response.parse() + assert_matches_type(BookTransferResponse, book_transfer, path=["response"]) + + assert cast(Any, response.is_closed) is True + + @parametrize + def test_path_params_retry(self, client: Lithic) -> None: + with pytest.raises(ValueError, match=r"Expected a non-empty value for `book_transfer_token` but received ''"): + client.book_transfers.with_raw_response.retry( + book_transfer_token="", + retry_token="182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", + ) + @parametrize def test_method_reverse(self, client: Lithic) -> None: book_transfer = client.book_transfers.reverse( @@ -357,6 +399,48 @@ async def test_streaming_response_list(self, async_client: AsyncLithic) -> None: assert cast(Any, response.is_closed) is True + @parametrize + async def test_method_retry(self, async_client: AsyncLithic) -> None: + book_transfer = await async_client.book_transfers.retry( + book_transfer_token="182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", + retry_token="182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", + ) + assert_matches_type(BookTransferResponse, book_transfer, path=["response"]) + + @parametrize + async def test_raw_response_retry(self, async_client: AsyncLithic) -> None: + response = await async_client.book_transfers.with_raw_response.retry( + book_transfer_token="182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", + retry_token="182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", + ) + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + book_transfer = response.parse() + assert_matches_type(BookTransferResponse, book_transfer, path=["response"]) + + @parametrize + async def test_streaming_response_retry(self, async_client: AsyncLithic) -> None: + async with async_client.book_transfers.with_streaming_response.retry( + book_transfer_token="182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", + retry_token="182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", + ) as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + book_transfer = await response.parse() + assert_matches_type(BookTransferResponse, book_transfer, path=["response"]) + + assert cast(Any, response.is_closed) is True + + @parametrize + async def test_path_params_retry(self, async_client: AsyncLithic) -> None: + with pytest.raises(ValueError, match=r"Expected a non-empty value for `book_transfer_token` but received ''"): + await async_client.book_transfers.with_raw_response.retry( + book_transfer_token="", + retry_token="182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", + ) + @parametrize async def test_method_reverse(self, async_client: AsyncLithic) -> None: book_transfer = await async_client.book_transfers.reverse( diff --git a/tests/api_resources/test_transfer_limits.py b/tests/api_resources/test_transfer_limits.py new file mode 100644 index 00000000..bd9c10c2 --- /dev/null +++ b/tests/api_resources/test_transfer_limits.py @@ -0,0 +1,90 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from __future__ import annotations + +import os +from typing import Any, cast + +import pytest + +from lithic import Lithic, AsyncLithic +from tests.utils import assert_matches_type +from lithic._utils import parse_date +from lithic.pagination import SyncSinglePage, AsyncSinglePage +from lithic.types.transfer_limits_response import Data + +base_url = os.environ.get("TEST_API_BASE_URL", "http://127.0.0.1:4010") + + +class TestTransferLimits: + parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) + + @parametrize + def test_method_list(self, client: Lithic) -> None: + transfer_limit = client.transfer_limits.list() + assert_matches_type(SyncSinglePage[Data], transfer_limit, path=["response"]) + + @parametrize + def test_method_list_with_all_params(self, client: Lithic) -> None: + transfer_limit = client.transfer_limits.list( + date=parse_date("2019-12-27"), + ) + assert_matches_type(SyncSinglePage[Data], transfer_limit, path=["response"]) + + @parametrize + def test_raw_response_list(self, client: Lithic) -> None: + response = client.transfer_limits.with_raw_response.list() + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + transfer_limit = response.parse() + assert_matches_type(SyncSinglePage[Data], transfer_limit, path=["response"]) + + @parametrize + def test_streaming_response_list(self, client: Lithic) -> None: + with client.transfer_limits.with_streaming_response.list() as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + transfer_limit = response.parse() + assert_matches_type(SyncSinglePage[Data], transfer_limit, path=["response"]) + + assert cast(Any, response.is_closed) is True + + +class TestAsyncTransferLimits: + parametrize = pytest.mark.parametrize( + "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] + ) + + @parametrize + async def test_method_list(self, async_client: AsyncLithic) -> None: + transfer_limit = await async_client.transfer_limits.list() + assert_matches_type(AsyncSinglePage[Data], transfer_limit, path=["response"]) + + @parametrize + async def test_method_list_with_all_params(self, async_client: AsyncLithic) -> None: + transfer_limit = await async_client.transfer_limits.list( + date=parse_date("2019-12-27"), + ) + assert_matches_type(AsyncSinglePage[Data], transfer_limit, path=["response"]) + + @parametrize + async def test_raw_response_list(self, async_client: AsyncLithic) -> None: + response = await async_client.transfer_limits.with_raw_response.list() + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + transfer_limit = response.parse() + assert_matches_type(AsyncSinglePage[Data], transfer_limit, path=["response"]) + + @parametrize + async def test_streaming_response_list(self, async_client: AsyncLithic) -> None: + async with async_client.transfer_limits.with_streaming_response.list() as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + transfer_limit = await response.parse() + assert_matches_type(AsyncSinglePage[Data], transfer_limit, path=["response"]) + + assert cast(Any, response.is_closed) is True From 97f012830440e7bd5071bf58d88b47b87b8b2025 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Tue, 23 Dec 2025 09:31:56 +0000 Subject: [PATCH 7/8] feat(api): add WIRE_DRAWDOWN_REQUEST transfer type docs(api): clarify description of token / retry_token when it serves as idempotency key feat(api): remove unnecessary X-Lithic-Pagination header --- .stats.yml | 6 +++--- README.md | 14 -------------- src/lithic/_client.py | 2 -- src/lithic/resources/book_transfers.py | 6 ++++-- src/lithic/resources/external_payments.py | 6 ++++++ src/lithic/resources/management_operations.py | 6 ++++++ src/lithic/types/book_transfer_retry_params.py | 5 ++++- src/lithic/types/external_payment_create_params.py | 4 ++++ .../types/management_operation_create_params.py | 4 ++++ src/lithic/types/payment.py | 1 + 10 files changed, 32 insertions(+), 22 deletions(-) diff --git a/.stats.yml b/.stats.yml index 3d59bbd3..49aee1eb 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 175 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic%2Flithic-1916ba0e95ce59f0feeebd6f3d2130990c812be7eabcda6e23c5fa096db912c7.yml -openapi_spec_hash: b465e7cb5c2dee36b5bdc6d540b2a530 -config_hash: a8a802e2c916a5d36a025bf64ab55ee7 +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic%2Flithic-854de7cc8f79e150ffe98f038ce9f39367010b2bdfffc9992be2738697dc4880.yml +openapi_spec_hash: fd471b20f3eda1e00cdebf028cbfe867 +config_hash: 9dddee5f7af579864599849cb28a0770 diff --git a/README.md b/README.md index f9a17781..0aaa73df 100644 --- a/README.md +++ b/README.md @@ -338,20 +338,6 @@ On timeout, an `APITimeoutError` is thrown. Note that requests that time out are [retried twice by default](#retries). -## Default Headers - -We automatically send the `X-Lithic-Pagination` header set to `cursor`. - -If you need to, you can override it by setting default headers per-request or on the client object. - -```python -from lithic import Lithic - -client = Lithic( - default_headers={"X-Lithic-Pagination": "My-Custom-Value"}, -) -``` - ## Advanced ### Logging diff --git a/src/lithic/_client.py b/src/lithic/_client.py index ef7bb353..3dd30033 100644 --- a/src/lithic/_client.py +++ b/src/lithic/_client.py @@ -417,7 +417,6 @@ def default_headers(self) -> dict[str, str | Omit]: return { **super().default_headers, "X-Stainless-Async": "false", - "X-Lithic-Pagination": "cursor", **self._custom_headers, } @@ -827,7 +826,6 @@ def default_headers(self) -> dict[str, str | Omit]: return { **super().default_headers, "X-Stainless-Async": f"async:{get_async_library()}", - "X-Lithic-Pagination": "cursor", **self._custom_headers, } diff --git a/src/lithic/resources/book_transfers.py b/src/lithic/resources/book_transfers.py index 20533bb8..1fbef4bf 100644 --- a/src/lithic/resources/book_transfers.py +++ b/src/lithic/resources/book_transfers.py @@ -318,7 +318,8 @@ def retry( Retry a book transfer that has been declined Args: - retry_token: Globally unique identifier for the retry. + retry_token: Customer-provided token that will serve as an idempotency token. This token will + become the transaction token. extra_headers: Send extra headers @@ -672,7 +673,8 @@ async def retry( Retry a book transfer that has been declined Args: - retry_token: Globally unique identifier for the retry. + retry_token: Customer-provided token that will serve as an idempotency token. This token will + become the transaction token. extra_headers: Send extra headers diff --git a/src/lithic/resources/external_payments.py b/src/lithic/resources/external_payments.py index 07c51674..fd4cf371 100644 --- a/src/lithic/resources/external_payments.py +++ b/src/lithic/resources/external_payments.py @@ -74,6 +74,9 @@ def create( Create external payment Args: + token: Customer-provided token that will serve as an idempotency token. This token will + become the transaction token. + extra_headers: Send extra headers extra_query: Add additional query parameters to the request @@ -449,6 +452,9 @@ async def create( Create external payment Args: + token: Customer-provided token that will serve as an idempotency token. This token will + become the transaction token. + extra_headers: Send extra headers extra_query: Add additional query parameters to the request diff --git a/src/lithic/resources/management_operations.py b/src/lithic/resources/management_operations.py index 641599fb..ac148f05 100644 --- a/src/lithic/resources/management_operations.py +++ b/src/lithic/resources/management_operations.py @@ -103,6 +103,9 @@ def create( Create management operation Args: + token: Customer-provided token that will serve as an idempotency token. This token will + become the transaction token. + on_closed_account: What to do if the financial account is closed when posting an operation extra_headers: Send extra headers @@ -380,6 +383,9 @@ async def create( Create management operation Args: + token: Customer-provided token that will serve as an idempotency token. This token will + become the transaction token. + on_closed_account: What to do if the financial account is closed when posting an operation extra_headers: Send extra headers diff --git a/src/lithic/types/book_transfer_retry_params.py b/src/lithic/types/book_transfer_retry_params.py index d923598c..305e43a4 100644 --- a/src/lithic/types/book_transfer_retry_params.py +++ b/src/lithic/types/book_transfer_retry_params.py @@ -9,4 +9,7 @@ class BookTransferRetryParams(TypedDict, total=False): retry_token: Required[str] - """Globally unique identifier for the retry.""" + """Customer-provided token that will serve as an idempotency token. + + This token will become the transaction token. + """ diff --git a/src/lithic/types/external_payment_create_params.py b/src/lithic/types/external_payment_create_params.py index 0977186c..294244e9 100644 --- a/src/lithic/types/external_payment_create_params.py +++ b/src/lithic/types/external_payment_create_params.py @@ -27,6 +27,10 @@ class ExternalPaymentCreateParams(TypedDict, total=False): payment_type: Required[Literal["DEPOSIT", "WITHDRAWAL"]] token: str + """Customer-provided token that will serve as an idempotency token. + + This token will become the transaction token. + """ memo: str diff --git a/src/lithic/types/management_operation_create_params.py b/src/lithic/types/management_operation_create_params.py index 47d2dada..2c1cdbc1 100644 --- a/src/lithic/types/management_operation_create_params.py +++ b/src/lithic/types/management_operation_create_params.py @@ -61,6 +61,10 @@ class ManagementOperationCreateParams(TypedDict, total=False): financial_account_token: Required[str] token: str + """Customer-provided token that will serve as an idempotency token. + + This token will become the transaction token. + """ memo: str diff --git a/src/lithic/types/payment.py b/src/lithic/types/payment.py index f1685c8e..0be3425f 100644 --- a/src/lithic/types/payment.py +++ b/src/lithic/types/payment.py @@ -253,6 +253,7 @@ class Payment(BaseModel): "WIRE_INBOUND_ADMIN", "WIRE_OUTBOUND_PAYMENT", "WIRE_OUTBOUND_ADMIN", + "WIRE_DRAWDOWN_REQUEST", ] ] = None From af1e600d253414673745c89d1b89c438c1dddad9 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Tue, 23 Dec 2025 09:32:21 +0000 Subject: [PATCH 8/8] release: 0.113.0 --- .release-please-manifest.json | 2 +- CHANGELOG.md | 29 +++++++++++++++++++++++++++++ pyproject.toml | 2 +- src/lithic/_version.py | 2 +- 4 files changed, 32 insertions(+), 3 deletions(-) diff --git a/.release-please-manifest.json b/.release-please-manifest.json index 820b5c1a..939bb175 100644 --- a/.release-please-manifest.json +++ b/.release-please-manifest.json @@ -1,3 +1,3 @@ { - ".": "0.112.0" + ".": "0.113.0" } \ No newline at end of file diff --git a/CHANGELOG.md b/CHANGELOG.md index 9f8eb077..ccfedc5a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,34 @@ # Changelog +## 0.113.0 (2025-12-23) + +Full Changelog: [v0.112.0...v0.113.0](https://github.com/lithic-com/lithic-python/compare/v0.112.0...v0.113.0) + +### Features + +* **api:** add external_id to payment_event ([b87046c](https://github.com/lithic-com/lithic-python/commit/b87046c51cb5d332ea53959ac3892ce2ba29cec3)) +* **api:** add get /v1/transfer_limits endpoint ([b87046c](https://github.com/lithic-com/lithic-python/commit/b87046c51cb5d332ea53959ac3892ce2ba29cec3)) +* **api:** add post /v1/book_transfers/{book_transfer_token}/retry endpoint ([b87046c](https://github.com/lithic-com/lithic-python/commit/b87046c51cb5d332ea53959ac3892ce2ba29cec3)) +* **api:** add WIRE_DRAWDOWN_REQUEST transfer type ([97f0128](https://github.com/lithic-com/lithic-python/commit/97f012830440e7bd5071bf58d88b47b87b8b2025)) +* **api:** remove unnecessary X-Lithic-Pagination header ([97f0128](https://github.com/lithic-com/lithic-python/commit/97f012830440e7bd5071bf58d88b47b87b8b2025)) +* **api:** remove v1/aggregate_balances and related models ([f3e089e](https://github.com/lithic-com/lithic-python/commit/f3e089e78535d88553bd60681bce6e75f0c29ece)) + + +### Bug Fixes + +* use async_to_httpx_files in patch method ([783d8ff](https://github.com/lithic-com/lithic-python/commit/783d8ff3f2119f1ff7c89e65864107fa13afe9b4)) + + +### Chores + +* **internal:** add `--fix` argument to lint script ([8e0a11c](https://github.com/lithic-com/lithic-python/commit/8e0a11ca6969fe5956ad244a7222525ff16c11b9)) +* **internal:** add missing files argument to base client ([52f441e](https://github.com/lithic-com/lithic-python/commit/52f441ece2827bf2b57bc2840d226121becbbff4)) + + +### Documentation + +* **api:** clarify description of token / retry_token when it serves as idempotency key ([97f0128](https://github.com/lithic-com/lithic-python/commit/97f012830440e7bd5071bf58d88b47b87b8b2025)) + ## 0.112.0 (2025-12-10) Full Changelog: [v0.111.0...v0.112.0](https://github.com/lithic-com/lithic-python/compare/v0.111.0...v0.112.0) diff --git a/pyproject.toml b/pyproject.toml index ba050cec..787f4c8b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "lithic" -version = "0.112.0" +version = "0.113.0" description = "The official Python library for the lithic API" dynamic = ["readme"] license = "Apache-2.0" diff --git a/src/lithic/_version.py b/src/lithic/_version.py index 768e4d15..00d68453 100644 --- a/src/lithic/_version.py +++ b/src/lithic/_version.py @@ -1,4 +1,4 @@ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. __title__ = "lithic" -__version__ = "0.112.0" # x-release-please-version +__version__ = "0.113.0" # x-release-please-version