A fully typed, validated async client for the MEXC spot and futures APIs.
- Documentation: https://tribulnation.com/typed/mexc
- Source Code: https://github.com/tribulnation/typed/tree/main/packages/mexc
from typed_mexc import MEXC
async with MEXC.new(public=True) as client:
candles = await client.spot.http.market.candles(symbol='BTCUSDT', interval='1m', limit=5)
stream = await client.futures.streams.market.ticker('BTC_USDT')
print(candles[-1][4])
async for ticker in stream:
print(ticker.get('lastPrice'))
break
Why Typed MEXC?
- 🎯 Precise Types: Typed endpoint inputs and responses.
- ✅ Runtime Validation: Validated responses by default.
- ⚡ Async First: HTTP and WebSocket subscriptions.
- 📚 Full API Surface:
client.spot,client.futures, and stream groups for both spot and futures.
Installation
pip install typed-mexc
How To
- API Keys Setup
- Fetch Market Data
- Place & Manage Orders
- Fetch Balances, Positions & History
- Manage Deposits & Withdrawals
- Listen To Streams
Reference
Design Philosophy
Typed MEXC follows the principles outlined in this blog post.
Details matter. Developer experience matters.
License
MIT — see LICENSE.
Release files for typed-mexc 2.2.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| typed_mexc-2.2.0.tar.gz | 87.4 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| typed_mexc-2.2.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 309.3 kB
Release files / typed_mexc-2.2.0.tar.gz
| Download URL | typed_mexc-2.2.0.tar.gz |
|---|---|
| Size | 87.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
ced4b2a42991473ac1db0aa6f54be9de75620b55a08f9cdd73079599535f83dd
|
|
BLAKE2b-256 checksum How to use checksums |
ce73f863642d8e36b2334d287ef19f945ad2a1bf437d0e8f2837c09740d7e189
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Sep 20, 2026.
Transparency logRelease files / typed_mexc-2.2.0-py3-none-any.whl
| Download URL | typed_mexc-2.2.0-py3-none-any.whl |
|---|---|
| Size | 221.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
0ddf035a2910363d88dfbed0834e7b637939b0f000fe436ba6d0327acd1b0a4f
|
|
BLAKE2b-256 checksum How to use checksums |
9854a1ca603bab38d1b321925110689fa05b686f9f103f1541b8290ab90bc221
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Sep 20, 2026.
Transparency log