debridge-py 0.1.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,218 @@
1
+ # Byte-compiled / optimized / DLL files
2
+ __pycache__/
3
+ *.py[codz]
4
+ *$py.class
5
+
6
+ # C extensions
7
+ *.so
8
+
9
+ # Distribution / packaging
10
+ .Python
11
+ build/
12
+ develop-eggs/
13
+ dist/
14
+ downloads/
15
+ eggs/
16
+ .eggs/
17
+ lib/
18
+ lib64/
19
+ parts/
20
+ sdist/
21
+ var/
22
+ wheels/
23
+ share/python-wheels/
24
+ *.egg-info/
25
+ .installed.cfg
26
+ *.egg
27
+ MANIFEST
28
+
29
+ # PyInstaller
30
+ # Usually these files are written by a python script from a template
31
+ # before PyInstaller builds the exe, so as to inject date/other infos into it.
32
+ *.manifest
33
+ *.spec
34
+
35
+ # Installer logs
36
+ pip-log.txt
37
+ pip-delete-this-directory.txt
38
+
39
+ # Unit test / coverage reports
40
+ htmlcov/
41
+ .tox/
42
+ .nox/
43
+ .coverage
44
+ .coverage.*
45
+ .cache
46
+ nosetests.xml
47
+ coverage.xml
48
+ *.cover
49
+ *.py.cover
50
+ .hypothesis/
51
+ .pytest_cache/
52
+ cover/
53
+
54
+ # Translations
55
+ *.mo
56
+ *.pot
57
+
58
+ # Django stuff:
59
+ *.log
60
+ local_settings.py
61
+ db.sqlite3
62
+ db.sqlite3-journal
63
+
64
+ # Flask stuff:
65
+ instance/
66
+ .webassets-cache
67
+
68
+ # Scrapy stuff:
69
+ .scrapy
70
+
71
+ # Sphinx documentation
72
+ docs/_build/
73
+
74
+ # PyBuilder
75
+ .pybuilder/
76
+ target/
77
+
78
+ # Jupyter Notebook
79
+ .ipynb_checkpoints
80
+
81
+ # IPython
82
+ profile_default/
83
+ ipython_config.py
84
+
85
+ # pyenv
86
+ # For a library or package, you might want to ignore these files since the code is
87
+ # intended to run in multiple environments; otherwise, check them in:
88
+ # .python-version
89
+
90
+ # pipenv
91
+ # According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
92
+ # However, in case of collaboration, if having platform-specific dependencies or dependencies
93
+ # having no cross-platform support, pipenv may install dependencies that don't work, or not
94
+ # install all needed dependencies.
95
+ # Pipfile.lock
96
+
97
+ # UV
98
+ # Similar to Pipfile.lock, it is generally recommended to include uv.lock in version control.
99
+ # This is especially recommended for binary packages to ensure reproducibility, and is more
100
+ # commonly ignored for libraries.
101
+ # uv.lock
102
+
103
+ # poetry
104
+ # Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control.
105
+ # This is especially recommended for binary packages to ensure reproducibility, and is more
106
+ # commonly ignored for libraries.
107
+ # https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control
108
+ # poetry.lock
109
+ # poetry.toml
110
+
111
+ # pdm
112
+ # Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control.
113
+ # pdm recommends including project-wide configuration in pdm.toml, but excluding .pdm-python.
114
+ # https://pdm-project.org/en/latest/usage/project/#working-with-version-control
115
+ # pdm.lock
116
+ # pdm.toml
117
+ .pdm-python
118
+ .pdm-build/
119
+
120
+ # pixi
121
+ # Similar to Pipfile.lock, it is generally recommended to include pixi.lock in version control.
122
+ # pixi.lock
123
+ # Pixi creates a virtual environment in the .pixi directory, just like venv module creates one
124
+ # in the .venv directory. It is recommended not to include this directory in version control.
125
+ .pixi
126
+
127
+ # PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm
128
+ __pypackages__/
129
+
130
+ # Celery stuff
131
+ celerybeat-schedule
132
+ celerybeat.pid
133
+
134
+ # Redis
135
+ *.rdb
136
+ *.aof
137
+ *.pid
138
+
139
+ # RabbitMQ
140
+ mnesia/
141
+ rabbitmq/
142
+ rabbitmq-data/
143
+
144
+ # ActiveMQ
145
+ activemq-data/
146
+
147
+ # SageMath parsed files
148
+ *.sage.py
149
+
150
+ # Environments
151
+ .env
152
+ .envrc
153
+ .venv
154
+ env/
155
+ venv/
156
+ ENV/
157
+ env.bak/
158
+ venv.bak/
159
+
160
+ # Spyder project settings
161
+ .spyderproject
162
+ .spyproject
163
+
164
+ # Rope project settings
165
+ .ropeproject
166
+
167
+ # mkdocs documentation
168
+ /site
169
+
170
+ # mypy
171
+ .mypy_cache/
172
+ .dmypy.json
173
+ dmypy.json
174
+
175
+ # Pyre type checker
176
+ .pyre/
177
+
178
+ # pytype static type analyzer
179
+ .pytype/
180
+
181
+ # Cython debug symbols
182
+ cython_debug/
183
+
184
+ # PyCharm
185
+ # JetBrains specific template is maintained in a separate JetBrains.gitignore that can
186
+ # be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
187
+ # and can be added to the global gitignore or merged into this file. For a more nuclear
188
+ # option (not recommended) you can uncomment the following to ignore the entire idea folder.
189
+ # .idea/
190
+
191
+ # Abstra
192
+ # Abstra is an AI-powered process automation framework.
193
+ # Ignore directories containing user credentials, local state, and settings.
194
+ # Learn more at https://abstra.io/docs
195
+ .abstra/
196
+
197
+ # Visual Studio Code
198
+ # Visual Studio Code specific template is maintained in a separate VisualStudioCode.gitignore
199
+ # that can be found at https://github.com/github/gitignore/blob/main/Global/VisualStudioCode.gitignore
200
+ # and can be added to the global gitignore or merged into this file. However, if you prefer,
201
+ # you could uncomment the following to ignore the entire vscode folder
202
+ # .vscode/
203
+ # Temporary file for partial code execution
204
+ tempCodeRunnerFile.py
205
+
206
+ # Ruff stuff:
207
+ .ruff_cache/
208
+
209
+ # PyPI configuration file
210
+ .pypirc
211
+
212
+ # Marimo
213
+ marimo/_static/
214
+ marimo/_lsp/
215
+ __marimo__/
216
+
217
+ # Streamlit
218
+ .streamlit/secrets.toml
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Robert Ruben
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
@@ -0,0 +1,157 @@
1
+ Metadata-Version: 2.4
2
+ Name: debridge-py
3
+ Version: 0.1.0
4
+ Summary: Typed Python client for the deBridge DLN cross-chain swap/order API (EVM + Solana).
5
+ Project-URL: Homepage, https://github.com/robertruben98/debridge-py
6
+ Project-URL: Repository, https://github.com/robertruben98/debridge-py
7
+ Project-URL: Documentation, https://docs.debridge.com/
8
+ Project-URL: Issues, https://github.com/robertruben98/debridge-py/issues
9
+ Author: Robert Ruben
10
+ License: MIT
11
+ License-File: LICENSE
12
+ Keywords: bridge,cross-chain,debridge,defi,dln,evm,solana,swap
13
+ Classifier: Development Status :: 4 - Beta
14
+ Classifier: Intended Audience :: Developers
15
+ Classifier: License :: OSI Approved :: MIT License
16
+ Classifier: Programming Language :: Python :: 3
17
+ Classifier: Programming Language :: Python :: 3.9
18
+ Classifier: Programming Language :: Python :: 3.10
19
+ Classifier: Programming Language :: Python :: 3.11
20
+ Classifier: Programming Language :: Python :: 3.12
21
+ Classifier: Programming Language :: Python :: 3.13
22
+ Classifier: Typing :: Typed
23
+ Requires-Python: >=3.9
24
+ Requires-Dist: httpx>=0.24
25
+ Requires-Dist: pydantic>=2.0
26
+ Provides-Extra: dev
27
+ Requires-Dist: mypy>=1.8; extra == 'dev'
28
+ Requires-Dist: pytest-asyncio>=0.21; extra == 'dev'
29
+ Requires-Dist: pytest>=7.0; extra == 'dev'
30
+ Requires-Dist: respx>=0.20; extra == 'dev'
31
+ Requires-Dist: ruff>=0.4; extra == 'dev'
32
+ Provides-Extra: exec
33
+ Requires-Dist: solders>=0.18; extra == 'exec'
34
+ Requires-Dist: web3>=6.0; extra == 'exec'
35
+ Description-Content-Type: text/markdown
36
+
37
+ # debridge-py
38
+
39
+ [![CI](https://github.com/robertruben98/debridge-py/actions/workflows/ci.yml/badge.svg)](https://github.com/robertruben98/debridge-py/actions/workflows/ci.yml)
40
+ [![PyPI](https://img.shields.io/pypi/v/debridge-py.svg)](https://pypi.org/project/debridge-py/)
41
+ [![Docs](https://img.shields.io/badge/docs-online-blue)](https://robertruben98.github.io/debridge-py/)
42
+ [![Python versions](https://img.shields.io/pypi/pyversions/debridge-py.svg)](https://pypi.org/project/debridge-py/)
43
+ [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://github.com/robertruben98/debridge-py/blob/main/LICENSE)
44
+
45
+ Typed Python client for the [deBridge DLN](https://docs.debridge.com/) cross-chain
46
+ swap/order API. Works across EVM chains and Solana (19+ chains), sync **and** async,
47
+ with full type hints (`py.typed`), built on `httpx` + `pydantic v2`.
48
+
49
+ The client covers the public, no-auth data endpoints needed to quote and track
50
+ cross-chain orders. Signing and broadcasting the returned transaction is left to
51
+ you (optionally with the `[exec]` extra: `web3.py` for EVM, `solders` for Solana).
52
+
53
+ ## Install
54
+
55
+ ```bash
56
+ pip install debridge-py
57
+ # optional signing helpers:
58
+ pip install "debridge-py[exec]"
59
+ ```
60
+
61
+ ## Quickstart
62
+
63
+ ```python
64
+ from debridge import DebridgeClient
65
+ from debridge.constants import ChainId
66
+
67
+ with DebridgeClient() as client:
68
+ # 1. discover supported chains
69
+ chains = client.get_supported_chains()
70
+
71
+ # 2. quote + build a cross-chain order (10 USDC Base -> USDC Arbitrum)
72
+ order = client.create_order(
73
+ src_chain_id=ChainId.BASE,
74
+ src_chain_token_in="0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913",
75
+ src_chain_token_in_amount="10000000", # 10 USDC (6 decimals)
76
+ dst_chain_id=ChainId.ARBITRUM,
77
+ dst_chain_token_out="0xaf88d065e77c8cC2239327C5EDb3A432268e5831",
78
+ dst_chain_token_out_amount="auto", # API quotes the output
79
+ dst_chain_token_out_recipient="0xYourRecipient",
80
+ sender_address="0xYourSender",
81
+ )
82
+ print(order.estimation.dst_chain_token_out.amount) # estimated output
83
+ print(order.tx.to, order.tx.value, order.tx.data) # tx to sign & send
84
+
85
+ # 3. after broadcasting order.tx, poll until the order settles
86
+ final = client.poll_status(order.order_id, interval=5, timeout=600)
87
+ print(final.status) # e.g. "Fulfilled"
88
+ ```
89
+
90
+ ### Async
91
+
92
+ ```python
93
+ import asyncio
94
+ from debridge import AsyncDebridgeClient
95
+
96
+ async def main():
97
+ async with AsyncDebridgeClient() as client:
98
+ chains = await client.get_supported_chains()
99
+ print(len(chains.chains))
100
+
101
+ asyncio.run(main())
102
+ ```
103
+
104
+ ## EVM and Solana
105
+
106
+ Addresses and amounts are kept as **strings** so the same models represent both
107
+ `0x`-hex (EVM) and base58 (Solana) values and amounts beyond 64-bit range. The
108
+ returned transaction adapts to the **source** chain:
109
+
110
+ - EVM source → `order.tx` has `data`, `to`, `value` (an EVM call).
111
+ - Solana source → `order.tx` has only `data` (the serialized versioned tx as hex).
112
+
113
+ Native-token sentinels are exposed as `constants.EVM_NATIVE_TOKEN` and
114
+ `constants.SOLANA_NATIVE_TOKEN`.
115
+
116
+ ## API surface
117
+
118
+ | Method | Endpoint |
119
+ | --- | --- |
120
+ | `get_supported_chains()` | `GET /supported-chains-info` |
121
+ | `get_token_list(chain_id)` | `GET /token-list` |
122
+ | `create_order(...)` | `GET /dln/order/create-tx` |
123
+ | `get_order_status(order_id)` | `GET /dln/order/{id}/status` |
124
+ | `get_order(order_id)` | `GET /dln/order/{id}` |
125
+ | `poll_status(order_id, interval, timeout)` | polls status to a terminal state |
126
+
127
+ Every method exists on both `DebridgeClient` (sync) and `AsyncDebridgeClient`
128
+ (async, with `await`). Errors raise `DebridgeAPIError` (a `DebridgeError`),
129
+ exposing `.error_id`, `.error_code`, `.message`, `.req_id`, `.status_code` —
130
+ including compliance blocks that the API returns with HTTP 200.
131
+
132
+ ## Configuration
133
+
134
+ ```python
135
+ DebridgeClient(base_url="https://my-proxy.example/v1.0", timeout=30.0)
136
+ ```
137
+
138
+ `base_url` defaults to `https://dln.debridge.finance/v1.0` and can point at any
139
+ compatible endpoint.
140
+
141
+ ## Development
142
+
143
+ ```bash
144
+ uv venv --python 3.9 && source .venv/bin/activate
145
+ uv pip install -e ".[dev]"
146
+ pytest # unit tests (network mocked, integration deselected)
147
+ pytest -m integration # one live test against the real API
148
+ ruff check . && ruff format --check .
149
+ mypy
150
+ ```
151
+
152
+ See [CONTRIBUTING.md](CONTRIBUTING.md) for the full contributor workflow and
153
+ [CHANGELOG.md](CHANGELOG.md) for release history.
154
+
155
+ ## License
156
+
157
+ MIT — see [LICENSE](LICENSE).
@@ -0,0 +1,121 @@
1
+ # debridge-py
2
+
3
+ [![CI](https://github.com/robertruben98/debridge-py/actions/workflows/ci.yml/badge.svg)](https://github.com/robertruben98/debridge-py/actions/workflows/ci.yml)
4
+ [![PyPI](https://img.shields.io/pypi/v/debridge-py.svg)](https://pypi.org/project/debridge-py/)
5
+ [![Docs](https://img.shields.io/badge/docs-online-blue)](https://robertruben98.github.io/debridge-py/)
6
+ [![Python versions](https://img.shields.io/pypi/pyversions/debridge-py.svg)](https://pypi.org/project/debridge-py/)
7
+ [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://github.com/robertruben98/debridge-py/blob/main/LICENSE)
8
+
9
+ Typed Python client for the [deBridge DLN](https://docs.debridge.com/) cross-chain
10
+ swap/order API. Works across EVM chains and Solana (19+ chains), sync **and** async,
11
+ with full type hints (`py.typed`), built on `httpx` + `pydantic v2`.
12
+
13
+ The client covers the public, no-auth data endpoints needed to quote and track
14
+ cross-chain orders. Signing and broadcasting the returned transaction is left to
15
+ you (optionally with the `[exec]` extra: `web3.py` for EVM, `solders` for Solana).
16
+
17
+ ## Install
18
+
19
+ ```bash
20
+ pip install debridge-py
21
+ # optional signing helpers:
22
+ pip install "debridge-py[exec]"
23
+ ```
24
+
25
+ ## Quickstart
26
+
27
+ ```python
28
+ from debridge import DebridgeClient
29
+ from debridge.constants import ChainId
30
+
31
+ with DebridgeClient() as client:
32
+ # 1. discover supported chains
33
+ chains = client.get_supported_chains()
34
+
35
+ # 2. quote + build a cross-chain order (10 USDC Base -> USDC Arbitrum)
36
+ order = client.create_order(
37
+ src_chain_id=ChainId.BASE,
38
+ src_chain_token_in="0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913",
39
+ src_chain_token_in_amount="10000000", # 10 USDC (6 decimals)
40
+ dst_chain_id=ChainId.ARBITRUM,
41
+ dst_chain_token_out="0xaf88d065e77c8cC2239327C5EDb3A432268e5831",
42
+ dst_chain_token_out_amount="auto", # API quotes the output
43
+ dst_chain_token_out_recipient="0xYourRecipient",
44
+ sender_address="0xYourSender",
45
+ )
46
+ print(order.estimation.dst_chain_token_out.amount) # estimated output
47
+ print(order.tx.to, order.tx.value, order.tx.data) # tx to sign & send
48
+
49
+ # 3. after broadcasting order.tx, poll until the order settles
50
+ final = client.poll_status(order.order_id, interval=5, timeout=600)
51
+ print(final.status) # e.g. "Fulfilled"
52
+ ```
53
+
54
+ ### Async
55
+
56
+ ```python
57
+ import asyncio
58
+ from debridge import AsyncDebridgeClient
59
+
60
+ async def main():
61
+ async with AsyncDebridgeClient() as client:
62
+ chains = await client.get_supported_chains()
63
+ print(len(chains.chains))
64
+
65
+ asyncio.run(main())
66
+ ```
67
+
68
+ ## EVM and Solana
69
+
70
+ Addresses and amounts are kept as **strings** so the same models represent both
71
+ `0x`-hex (EVM) and base58 (Solana) values and amounts beyond 64-bit range. The
72
+ returned transaction adapts to the **source** chain:
73
+
74
+ - EVM source → `order.tx` has `data`, `to`, `value` (an EVM call).
75
+ - Solana source → `order.tx` has only `data` (the serialized versioned tx as hex).
76
+
77
+ Native-token sentinels are exposed as `constants.EVM_NATIVE_TOKEN` and
78
+ `constants.SOLANA_NATIVE_TOKEN`.
79
+
80
+ ## API surface
81
+
82
+ | Method | Endpoint |
83
+ | --- | --- |
84
+ | `get_supported_chains()` | `GET /supported-chains-info` |
85
+ | `get_token_list(chain_id)` | `GET /token-list` |
86
+ | `create_order(...)` | `GET /dln/order/create-tx` |
87
+ | `get_order_status(order_id)` | `GET /dln/order/{id}/status` |
88
+ | `get_order(order_id)` | `GET /dln/order/{id}` |
89
+ | `poll_status(order_id, interval, timeout)` | polls status to a terminal state |
90
+
91
+ Every method exists on both `DebridgeClient` (sync) and `AsyncDebridgeClient`
92
+ (async, with `await`). Errors raise `DebridgeAPIError` (a `DebridgeError`),
93
+ exposing `.error_id`, `.error_code`, `.message`, `.req_id`, `.status_code` —
94
+ including compliance blocks that the API returns with HTTP 200.
95
+
96
+ ## Configuration
97
+
98
+ ```python
99
+ DebridgeClient(base_url="https://my-proxy.example/v1.0", timeout=30.0)
100
+ ```
101
+
102
+ `base_url` defaults to `https://dln.debridge.finance/v1.0` and can point at any
103
+ compatible endpoint.
104
+
105
+ ## Development
106
+
107
+ ```bash
108
+ uv venv --python 3.9 && source .venv/bin/activate
109
+ uv pip install -e ".[dev]"
110
+ pytest # unit tests (network mocked, integration deselected)
111
+ pytest -m integration # one live test against the real API
112
+ ruff check . && ruff format --check .
113
+ mypy
114
+ ```
115
+
116
+ See [CONTRIBUTING.md](CONTRIBUTING.md) for the full contributor workflow and
117
+ [CHANGELOG.md](CHANGELOG.md) for release history.
118
+
119
+ ## License
120
+
121
+ MIT — see [LICENSE](LICENSE).
@@ -0,0 +1,85 @@
1
+ [build-system]
2
+ requires = ["hatchling"]
3
+ build-backend = "hatchling.build"
4
+
5
+ [project]
6
+ name = "debridge-py"
7
+ version = "0.1.0"
8
+ description = "Typed Python client for the deBridge DLN cross-chain swap/order API (EVM + Solana)."
9
+ readme = "README.md"
10
+ requires-python = ">=3.9"
11
+ license = { text = "MIT" }
12
+ authors = [{ name = "Robert Ruben" }]
13
+ keywords = ["debridge", "dln", "cross-chain", "bridge", "swap", "defi", "evm", "solana"]
14
+ classifiers = [
15
+ "Development Status :: 4 - Beta",
16
+ "Intended Audience :: Developers",
17
+ "License :: OSI Approved :: MIT License",
18
+ "Programming Language :: Python :: 3",
19
+ "Programming Language :: Python :: 3.9",
20
+ "Programming Language :: Python :: 3.10",
21
+ "Programming Language :: Python :: 3.11",
22
+ "Programming Language :: Python :: 3.12",
23
+ "Programming Language :: Python :: 3.13",
24
+ "Typing :: Typed",
25
+ ]
26
+ dependencies = [
27
+ "httpx>=0.24",
28
+ "pydantic>=2.0",
29
+ ]
30
+
31
+ [project.optional-dependencies]
32
+ exec = [
33
+ "web3>=6.0",
34
+ "solders>=0.18",
35
+ ]
36
+ dev = [
37
+ "pytest>=7.0",
38
+ "pytest-asyncio>=0.21",
39
+ "respx>=0.20",
40
+ "mypy>=1.8",
41
+ "ruff>=0.4",
42
+ ]
43
+
44
+ [project.urls]
45
+ Homepage = "https://github.com/robertruben98/debridge-py"
46
+ Repository = "https://github.com/robertruben98/debridge-py"
47
+ Documentation = "https://docs.debridge.com/"
48
+ Issues = "https://github.com/robertruben98/debridge-py/issues"
49
+
50
+ [tool.hatch.build.targets.wheel]
51
+ packages = ["src/debridge"]
52
+
53
+ [tool.hatch.build.targets.sdist]
54
+ include = ["src/debridge", "README.md", "LICENSE"]
55
+
56
+ [tool.ruff]
57
+ line-length = 100
58
+ target-version = "py39"
59
+ src = ["src", "tests"]
60
+
61
+ [tool.ruff.lint]
62
+ select = ["E", "F", "I", "UP", "B", "W", "C4", "SIM"]
63
+ # UP007/UP045 would push to PEP 604 `X | None`, and UP006 to bare `list`/`dict`,
64
+ # in annotations that pydantic re-evaluates at runtime on Python 3.9. Keep
65
+ # typing.Optional/Union/List/Dict so the models build cleanly on 3.9.
66
+ ignore = ["UP006", "UP007", "UP035", "UP045"]
67
+
68
+ [tool.mypy]
69
+ python_version = "3.10"
70
+ strict = true
71
+ warn_unused_ignores = true
72
+ warn_redundant_casts = true
73
+ files = ["src", "tests"]
74
+
75
+ [[tool.mypy.overrides]]
76
+ module = ["respx.*"]
77
+ ignore_missing_imports = true
78
+
79
+ [tool.pytest.ini_options]
80
+ asyncio_mode = "auto"
81
+ testpaths = ["tests"]
82
+ markers = [
83
+ "integration: live network tests against the real deBridge API (deselected by default)",
84
+ ]
85
+ addopts = "-m 'not integration'"
@@ -0,0 +1,35 @@
1
+ """Typed Python client for the deBridge DLN cross-chain swap/order API."""
2
+
3
+ from debridge import constants
4
+ from debridge._errors import DebridgeAPIError, DebridgeError
5
+ from debridge.client import AsyncDebridgeClient, DebridgeClient
6
+ from debridge.models import (
7
+ CreateOrderResponse,
8
+ Estimation,
9
+ OrderDetails,
10
+ OrderStatus,
11
+ SupportedChain,
12
+ SupportedChainsResponse,
13
+ TokenInfo,
14
+ TokenListResponse,
15
+ Transaction,
16
+ )
17
+
18
+ __all__ = [
19
+ "AsyncDebridgeClient",
20
+ "CreateOrderResponse",
21
+ "DebridgeAPIError",
22
+ "DebridgeClient",
23
+ "DebridgeError",
24
+ "Estimation",
25
+ "OrderDetails",
26
+ "OrderStatus",
27
+ "SupportedChain",
28
+ "SupportedChainsResponse",
29
+ "TokenInfo",
30
+ "TokenListResponse",
31
+ "Transaction",
32
+ "constants",
33
+ ]
34
+
35
+ __version__ = "0.1.0"