Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
17 commits
Select commit Hold shift + click to select a range
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
18 changes: 10 additions & 8 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -1,17 +1,18 @@
name: CI
on:
push:
branches:
- main
pull_request:
branches:
- main
- next
branches-ignore:
- 'generated'
- 'codegen/**'
- 'integrated/**'
- 'stl-preview-head/**'
- 'stl-preview-base/**'

jobs:
lint:
timeout-minutes: 10
name: lint
runs-on: ubuntu-latest
runs-on: ${{ github.repository == 'stainless-sdks/modern-treasury-python' && 'depot-ubuntu-24.04' || 'ubuntu-latest' }}
steps:
- uses: actions/checkout@v4

Expand All @@ -30,8 +31,9 @@ jobs:
run: ./scripts/lint

test:
timeout-minutes: 10
name: test
runs-on: ubuntu-latest
runs-on: ${{ github.repository == 'stainless-sdks/modern-treasury-python' && 'depot-ubuntu-24.04' || 'ubuntu-latest' }}
steps:
- uses: actions/checkout@v4

Expand Down
2 changes: 1 addition & 1 deletion .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
".": "1.47.1"
".": "1.48.0"
}
35 changes: 35 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,40 @@
# Changelog

## 1.48.0 (2025-05-09)

Full Changelog: [v1.47.1...v1.48.0](https://github.com/Modern-Treasury/modern-treasury-python/compare/v1.47.1...v1.48.0)

### Features

* **api:** only send idempotency headers on PUT / POST requets ([c73433d](https://github.com/Modern-Treasury/modern-treasury-python/commit/c73433dc820ddc7d93f249c18c78eeedd2fafe93))


### Bug Fixes

* **internal:** fix dangling merge conflict ([2b1a146](https://github.com/Modern-Treasury/modern-treasury-python/commit/2b1a146d4ff20b8d6930240d2d2906287ed150f1))
* **package:** support direct resource imports ([ff8114d](https://github.com/Modern-Treasury/modern-treasury-python/commit/ff8114d2b4a97ab153c98887cb0a85ad87140ce2))
* **pydantic v1:** more robust ModelField.annotation check ([e83f527](https://github.com/Modern-Treasury/modern-treasury-python/commit/e83f527f6a7e5e432cfa8fbd2b9dab79b8d2b040))


### Chores

* broadly detect json family of content-type headers ([56eeec0](https://github.com/Modern-Treasury/modern-treasury-python/commit/56eeec01457220e8eccb1a0975bdcd7e2e93b0e8))
* **ci:** add timeout thresholds for CI jobs ([42ee73a](https://github.com/Modern-Treasury/modern-treasury-python/commit/42ee73a2f7f7a57bd4d8cb47a4921dfc920c3305))
* **ci:** only use depot for staging repos ([1ff5cac](https://github.com/Modern-Treasury/modern-treasury-python/commit/1ff5cac1a02ada40685f0196059d9c0b6a72a91e))
* **ci:** run on more branches and use depot runners ([9d4dd29](https://github.com/Modern-Treasury/modern-treasury-python/commit/9d4dd2963ef889e3fbbd17177a2dfff4767da0d9))
* **internal:** avoid errors for isinstance checks on proxies ([ddb2ce2](https://github.com/Modern-Treasury/modern-treasury-python/commit/ddb2ce2b7fc8a0aa15f6aee4429d3e0ada03c8f0))
* **internal:** fix list file params ([7653eb8](https://github.com/Modern-Treasury/modern-treasury-python/commit/7653eb8967cfa8ba6c66904edc31ec8f37ea004f))
* **internal:** import reformatting ([e96d2e1](https://github.com/Modern-Treasury/modern-treasury-python/commit/e96d2e11a6d3a2ba61b4c0c847a3a76cdc6c6a4f))
* **internal:** minor formatting changes ([34ea0e3](https://github.com/Modern-Treasury/modern-treasury-python/commit/34ea0e3b26eb74e401772fb90c601c48a49e2f7c))
* **internal:** refactor retries to not use recursion ([1f46e05](https://github.com/Modern-Treasury/modern-treasury-python/commit/1f46e0513e040e91ab7eaa9191c036b3b4fe99fa))
* **internal:** update models test ([62c7763](https://github.com/Modern-Treasury/modern-treasury-python/commit/62c7763b1be1d7064fe52331e6e4075ef9cf4f44))
* use lazy imports for resources ([75d7317](https://github.com/Modern-Treasury/modern-treasury-python/commit/75d731734c12c833401fd1a5cde3f8381bd06076))


### Documentation

* remove or fix invalid readme examples ([ee8a05f](https://github.com/Modern-Treasury/modern-treasury-python/commit/ee8a05f71b219e9f5b0f483dcc093e3372fcb001))

## 1.47.1 (2025-04-16)

Full Changelog: [v1.47.0...v1.47.1](https://github.com/Modern-Treasury/modern-treasury-python/compare/v1.47.0...v1.47.1)
Expand Down
15 changes: 0 additions & 15 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -146,21 +146,6 @@ for counterparty in first_page.items:
# Remove `await` for non-async usage.
```

## Nested params

Nested parameters are dictionaries, typed using `TypedDict`, for example:

```python
from modern_treasury import ModernTreasury

client = ModernTreasury()

external_account = client.external_accounts.create(
counterparty_id="182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
)
print(external_account.id)
```

## File uploads

Request parameters that correspond to file uploads can be passed as `bytes`, or a [`PathLike`](https://docs.python.org/3/library/os.html#os.PathLike) instance or a tuple of `(filename, contents, media type)`.
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 = "modern-treasury"
version = "1.47.1"
version = "1.48.0"
description = "The official Python library for the Modern Treasury API"
dynamic = ["readme"]
license = "MIT"
Expand Down
5 changes: 5 additions & 0 deletions src/modern_treasury/__init__.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.

import typing as _t

from . import types
from ._types import NOT_GIVEN, Omit, NoneType, NotGiven, Transport, ProxiesTypes
from ._utils import file_from_path
Expand Down Expand Up @@ -78,6 +80,9 @@
"DefaultAsyncHttpxClient",
]

if not _t.TYPE_CHECKING:
from ._utils._resources_proxy import resources as resources

_setup_logging()

# Update the __module__ attribute for exported symbols so that
Expand Down
Loading