Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
".": "0.307.0"
".": "0.308.0"
}
4 changes: 2 additions & 2 deletions .stats.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
configured_endpoints: 216
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/increase%2Fincrease-5ecfd5d7d11e1ed73e093008b8ec107f9c1d0d455f660badf74e0a12d98805ed.yml
openapi_spec_hash: ec6f6ea0766c1c56085f9032da2a9e24
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/increase%2Fincrease-a6d99e6e3e405acf3e592e273aa1c5d519ed4f1157d0f87f1dcf21e7710f59b5.yml
openapi_spec_hash: f1f21c7331c905f2e5549978454059dc
config_hash: 632b628b59d8f0b717153b3d8133f6cb
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
# Changelog

## 0.308.0 (2025-08-28)

Full Changelog: [v0.307.0...v0.308.0](https://github.com/Increase/increase-python/compare/v0.307.0...v0.308.0)

### Features

* **api:** api update ([4f571ed](https://github.com/Increase/increase-python/commit/4f571ed9567f8c7226b5f6fd5cc1d7b4ad38f404))

## 0.307.0 (2025-08-28)

Full Changelog: [v0.306.0...v0.307.0](https://github.com/Increase/increase-python/compare/v0.306.0...v0.307.0)
Expand Down
2 changes: 1 addition & 1 deletion api.md
Original file line number Diff line number Diff line change
Expand Up @@ -877,7 +877,7 @@ Methods:
- <code title="post /simulations/ach_transfers/{ach_transfer_id}/acknowledge">client.simulations.ach_transfers.<a href="./src/increase/resources/simulations/ach_transfers.py">acknowledge</a>(ach_transfer_id) -> <a href="./src/increase/types/ach_transfer.py">ACHTransfer</a></code>
- <code title="post /simulations/ach_transfers/{ach_transfer_id}/create_notification_of_change">client.simulations.ach_transfers.<a href="./src/increase/resources/simulations/ach_transfers.py">create_notification_of_change</a>(ach_transfer_id, \*\*<a href="src/increase/types/simulations/ach_transfer_create_notification_of_change_params.py">params</a>) -> <a href="./src/increase/types/ach_transfer.py">ACHTransfer</a></code>
- <code title="post /simulations/ach_transfers/{ach_transfer_id}/return">client.simulations.ach*transfers.<a href="./src/increase/resources/simulations/ach_transfers.py">return*</a>(ach_transfer_id, \*\*<a href="src/increase/types/simulations/ach_transfer_return_params.py">params</a>) -> <a href="./src/increase/types/ach_transfer.py">ACHTransfer</a></code>
- <code title="post /simulations/ach_transfers/{ach_transfer_id}/settle">client.simulations.ach_transfers.<a href="./src/increase/resources/simulations/ach_transfers.py">settle</a>(ach_transfer_id) -> <a href="./src/increase/types/ach_transfer.py">ACHTransfer</a></code>
- <code title="post /simulations/ach_transfers/{ach_transfer_id}/settle">client.simulations.ach_transfers.<a href="./src/increase/resources/simulations/ach_transfers.py">settle</a>(ach_transfer_id, \*\*<a href="src/increase/types/simulations/ach_transfer_settle_params.py">params</a>) -> <a href="./src/increase/types/ach_transfer.py">ACHTransfer</a></code>
- <code title="post /simulations/ach_transfers/{ach_transfer_id}/submit">client.simulations.ach_transfers.<a href="./src/increase/resources/simulations/ach_transfers.py">submit</a>(ach_transfer_id) -> <a href="./src/increase/types/ach_transfer.py">ACHTransfer</a></code>

## InboundACHTransfers
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "increase"
version = "0.307.0"
version = "0.308.0"
description = "The official Python library for the increase API"
dynamic = ["readme"]
license = "Apache-2.0"
Expand Down
2 changes: 1 addition & 1 deletion src/increase/_version.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.

__title__ = "increase"
__version__ = "0.307.0" # x-release-please-version
__version__ = "0.308.0" # x-release-please-version
44 changes: 41 additions & 3 deletions src/increase/resources/simulations/ach_transfers.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,11 @@
async_to_streamed_response_wrapper,
)
from ..._base_client import make_request_options
from ...types.simulations import ach_transfer_return_params, ach_transfer_create_notification_of_change_params
from ...types.simulations import (
ach_transfer_return_params,
ach_transfer_settle_params,
ach_transfer_create_notification_of_change_params,
)
from ...types.ach_transfer import ACHTransfer

__all__ = ["ACHTransfersResource", "AsyncACHTransfersResource"]
Expand Down Expand Up @@ -475,6 +479,8 @@ def settle(
self,
ach_transfer_id: str,
*,
inbound_funds_hold_behavior: Literal["release_immediately", "release_on_default_schedule"]
| NotGiven = NOT_GIVEN,
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
# The extra values given here take precedence over values defined on the client or passed to this method.
extra_headers: Headers | None = None,
Expand All @@ -489,11 +495,22 @@ def settle(
`submitted`. For convenience, if the transfer is in `status`:
`pending_submission`, the simulation will also submit the transfer. Without this
simulation the transfer will eventually settle on its own following the same
Federal Reserve timeline as in production.
Federal Reserve timeline as in production. Additionally, you can specify the
behavior of the inbound funds hold that is created when the ACH Transfer is
settled. If no behavior is specified, the inbound funds hold will be released
immediately in order for the funds to be available for use.

Args:
ach_transfer_id: The identifier of the ACH Transfer you wish to become settled.

inbound_funds_hold_behavior: The behavior of the inbound funds hold that is created when the ACH Transfer is
settled. If no behavior is specified, the inbound funds hold will be released
immediately in order for the funds to be available for use.

- `release_immediately` - Release the inbound funds hold immediately.
- `release_on_default_schedule` - Release the inbound funds hold on the default
schedule.

extra_headers: Send extra headers

extra_query: Add additional query parameters to the request
Expand All @@ -508,6 +525,10 @@ def settle(
raise ValueError(f"Expected a non-empty value for `ach_transfer_id` but received {ach_transfer_id!r}")
return self._post(
f"/simulations/ach_transfers/{ach_transfer_id}/settle",
body=maybe_transform(
{"inbound_funds_hold_behavior": inbound_funds_hold_behavior},
ach_transfer_settle_params.ACHTransferSettleParams,
),
options=make_request_options(
extra_headers=extra_headers,
extra_query=extra_query,
Expand Down Expand Up @@ -1018,6 +1039,8 @@ async def settle(
self,
ach_transfer_id: str,
*,
inbound_funds_hold_behavior: Literal["release_immediately", "release_on_default_schedule"]
| NotGiven = NOT_GIVEN,
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
# The extra values given here take precedence over values defined on the client or passed to this method.
extra_headers: Headers | None = None,
Expand All @@ -1032,11 +1055,22 @@ async def settle(
`submitted`. For convenience, if the transfer is in `status`:
`pending_submission`, the simulation will also submit the transfer. Without this
simulation the transfer will eventually settle on its own following the same
Federal Reserve timeline as in production.
Federal Reserve timeline as in production. Additionally, you can specify the
behavior of the inbound funds hold that is created when the ACH Transfer is
settled. If no behavior is specified, the inbound funds hold will be released
immediately in order for the funds to be available for use.

Args:
ach_transfer_id: The identifier of the ACH Transfer you wish to become settled.

inbound_funds_hold_behavior: The behavior of the inbound funds hold that is created when the ACH Transfer is
settled. If no behavior is specified, the inbound funds hold will be released
immediately in order for the funds to be available for use.

- `release_immediately` - Release the inbound funds hold immediately.
- `release_on_default_schedule` - Release the inbound funds hold on the default
schedule.

extra_headers: Send extra headers

extra_query: Add additional query parameters to the request
Expand All @@ -1051,6 +1085,10 @@ async def settle(
raise ValueError(f"Expected a non-empty value for `ach_transfer_id` but received {ach_transfer_id!r}")
return await self._post(
f"/simulations/ach_transfers/{ach_transfer_id}/settle",
body=await async_maybe_transform(
{"inbound_funds_hold_behavior": inbound_funds_hold_behavior},
ach_transfer_settle_params.ACHTransferSettleParams,
),
options=make_request_options(
extra_headers=extra_headers,
extra_query=extra_query,
Expand Down
1 change: 1 addition & 0 deletions src/increase/types/simulations/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
from .card_token_create_params import CardTokenCreateParams as CardTokenCreateParams
from .card_refund_create_params import CardRefundCreateParams as CardRefundCreateParams
from .ach_transfer_return_params import ACHTransferReturnParams as ACHTransferReturnParams
from .ach_transfer_settle_params import ACHTransferSettleParams as ACHTransferSettleParams
from .card_dispute_action_params import CardDisputeActionParams as CardDisputeActionParams
from .card_reversal_create_params import CardReversalCreateParams as CardReversalCreateParams
from .card_increment_create_params import CardIncrementCreateParams as CardIncrementCreateParams
Expand Down
20 changes: 20 additions & 0 deletions src/increase/types/simulations/ach_transfer_settle_params.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.

from __future__ import annotations

from typing_extensions import Literal, TypedDict

__all__ = ["ACHTransferSettleParams"]


class ACHTransferSettleParams(TypedDict, total=False):
inbound_funds_hold_behavior: Literal["release_immediately", "release_on_default_schedule"]
"""
The behavior of the inbound funds hold that is created when the ACH Transfer is
settled. If no behavior is specified, the inbound funds hold will be released
immediately in order for the funds to be available for use.

- `release_immediately` - Release the inbound funds hold immediately.
- `release_on_default_schedule` - Release the inbound funds hold on the default
schedule.
"""
32 changes: 24 additions & 8 deletions tests/api_resources/simulations/test_ach_transfers.py
Original file line number Diff line number Diff line change
Expand Up @@ -150,14 +150,22 @@ def test_path_params_return(self, client: Increase) -> None:
@parametrize
def test_method_settle(self, client: Increase) -> None:
ach_transfer = client.simulations.ach_transfers.settle(
"ach_transfer_id",
ach_transfer_id="ach_transfer_uoxatyh3lt5evrsdvo7q",
)
assert_matches_type(ACHTransfer, ach_transfer, path=["response"])

@parametrize
def test_method_settle_with_all_params(self, client: Increase) -> None:
ach_transfer = client.simulations.ach_transfers.settle(
ach_transfer_id="ach_transfer_uoxatyh3lt5evrsdvo7q",
inbound_funds_hold_behavior="release_immediately",
)
assert_matches_type(ACHTransfer, ach_transfer, path=["response"])

@parametrize
def test_raw_response_settle(self, client: Increase) -> None:
response = client.simulations.ach_transfers.with_raw_response.settle(
"ach_transfer_id",
ach_transfer_id="ach_transfer_uoxatyh3lt5evrsdvo7q",
)

assert response.is_closed is True
Expand All @@ -168,7 +176,7 @@ def test_raw_response_settle(self, client: Increase) -> None:
@parametrize
def test_streaming_response_settle(self, client: Increase) -> None:
with client.simulations.ach_transfers.with_streaming_response.settle(
"ach_transfer_id",
ach_transfer_id="ach_transfer_uoxatyh3lt5evrsdvo7q",
) as response:
assert not response.is_closed
assert response.http_request.headers.get("X-Stainless-Lang") == "python"
Expand All @@ -182,7 +190,7 @@ def test_streaming_response_settle(self, client: Increase) -> None:
def test_path_params_settle(self, client: Increase) -> None:
with pytest.raises(ValueError, match=r"Expected a non-empty value for `ach_transfer_id` but received ''"):
client.simulations.ach_transfers.with_raw_response.settle(
"",
ach_transfer_id="",
)

@parametrize
Expand Down Expand Up @@ -362,14 +370,22 @@ async def test_path_params_return(self, async_client: AsyncIncrease) -> None:
@parametrize
async def test_method_settle(self, async_client: AsyncIncrease) -> None:
ach_transfer = await async_client.simulations.ach_transfers.settle(
"ach_transfer_id",
ach_transfer_id="ach_transfer_uoxatyh3lt5evrsdvo7q",
)
assert_matches_type(ACHTransfer, ach_transfer, path=["response"])

@parametrize
async def test_method_settle_with_all_params(self, async_client: AsyncIncrease) -> None:
ach_transfer = await async_client.simulations.ach_transfers.settle(
ach_transfer_id="ach_transfer_uoxatyh3lt5evrsdvo7q",
inbound_funds_hold_behavior="release_immediately",
)
assert_matches_type(ACHTransfer, ach_transfer, path=["response"])

@parametrize
async def test_raw_response_settle(self, async_client: AsyncIncrease) -> None:
response = await async_client.simulations.ach_transfers.with_raw_response.settle(
"ach_transfer_id",
ach_transfer_id="ach_transfer_uoxatyh3lt5evrsdvo7q",
)

assert response.is_closed is True
Expand All @@ -380,7 +396,7 @@ async def test_raw_response_settle(self, async_client: AsyncIncrease) -> None:
@parametrize
async def test_streaming_response_settle(self, async_client: AsyncIncrease) -> None:
async with async_client.simulations.ach_transfers.with_streaming_response.settle(
"ach_transfer_id",
ach_transfer_id="ach_transfer_uoxatyh3lt5evrsdvo7q",
) as response:
assert not response.is_closed
assert response.http_request.headers.get("X-Stainless-Lang") == "python"
Expand All @@ -394,7 +410,7 @@ async def test_streaming_response_settle(self, async_client: AsyncIncrease) -> N
async def test_path_params_settle(self, async_client: AsyncIncrease) -> None:
with pytest.raises(ValueError, match=r"Expected a non-empty value for `ach_transfer_id` but received ''"):
await async_client.simulations.ach_transfers.with_raw_response.settle(
"",
ach_transfer_id="",
)

@parametrize
Expand Down