finds.dev← search

// the find

sammchardy/python-binance

★ 7,169 · Python · MIT · updated Jun 2026

Binance Exchange API python implementation for automated trading

Unofficial Python client for the Binance REST and WebSocket APIs, covering spot, futures, margin, and portfolio margin trading. It wraps all 797+ Binance endpoints with both sync and async clients, plus threaded and async WebSocket managers with automatic reconnection. The target audience is algo traders and quants building on top of Binance specifically.

The async client is a first-class citizen, not an afterthought — `AsyncClient.create()` is a proper coroutine and the depth cache manager works as an async context manager. WebSocket reconnection is built-in at the `ReconnectingWebsocket` level so your strategy code doesn't have to handle connection drops. The depth cache implementation keeps a locally synced order book and handles the initial snapshot + incremental update sequencing correctly, which is easy to get wrong. Test coverage is broad and split by product area (spot/futures/margin/options), which makes regressions easy to localize.

This is Binance-only — if you ever need to run the same strategy on another exchange you are rewriting from scratch; CCXT (which this project is now powered by) is the right call if multi-exchange matters. The README buries the fact that this is now a CCXT-backed wrapper, not an independent implementation, which changes your dependency story and issue escalation path in ways that aren't obvious. RSA/EDDSA key support is mentioned as a feature but the docs are thin on how to configure it — discovering the right `private_key` parameter format is trial and error. There is no rate-limit tracking built in on the client side; you have to read Binance's response headers or manage your own bucket, and in a fast WebSocket environment it's easy to ban your IP before you notice.

View on GitHub → Homepage ↗

// want more like this?

We dig through GitHub every week and send a few repos picked for what you actually care about — each with an honest take like this one.

Get finds in your inbox → Search again →