coinbase-advanced-py
Coinbase Advanced API Python SDK
What it is and what it does
This is the official Coinbase Python SDK for the Advanced API, providing both REST and WebSocket interfaces to trade cryptocurrencies, manage orders, and stream real-time market data. It wraps the Coinbase Advanced Trade API with typed response objects, automatic JWT signing (supporting both Ed25519 and ECDSA key types), and convenience methods for common operations like placing market orders and fetching account balances.
The SDK handles authentication via Coinbase Developer Platform (CDP) API keys, supports environment variable configuration for secrets, and includes built-in rate-limit header tracking. It depends on requests for HTTP, cryptography and PyJWT for signing, websockets for live data streams, and backoff for retry logic. The package targets Python 3.8 and later and is actively maintained by Coinbase.
Use it for:
- Build automated trading bots that place orders and monitor positions via the REST API.
- Stream real-time order book and trade data using the WebSocket client for live market analysis.
- Retrieve account balances, portfolio information, and transaction history programmatically.
- Integrate Coinbase trading into a larger financial application or dashboard.
- Backtest trading strategies by fetching historical market data through API endpoints.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Official Python SDK for the Coinbase Advanced API, providing REST and WebSocket clients to access real-time market data, manage orders, and execute trades programmatically.
Yes. This is the official Coinbase SDK with active maintenance, no known vulnerabilities, low install friction, and permissive licensing. Install it if you need to programmatically trade on Coinbase or consume their Advanced API—it is the canonical choice for Python developers. Ensure you secure your API credentials properly (use a secrets manager, not hardcoded values).
Install
coinbase-advanced-py on PyPI
pip
pip install coinbase-advanced-pyuv
uv add coinbase-advanced-pypoetry
poetry add coinbase-advanced-pyInstalling coinbase-advanced-py
Before you install
Low friction install with five stable runtime dependencies (requests, cryptography, PyJWT, websockets, backoff). Actively maintained with a recent release and no known vulnerabilities.
License in practice
Licensed under Apache 2.0 (permissive), allowing use in commercial and private projects with minimal restrictions.
Quickstart
pip install coinbase-advanced-py
from coinbase.rest import RESTClient
client = RESTClient() # Uses COINBASE_API_KEY and COINBASE_API_SECRET env vars
accounts = client.get_accounts()
print(accounts.to_dict())
Requires Coinbase Developer Platform (CDP) API credentials (Ed25519 or ECDSA key pair); set COINBASE_API_KEY and COINBASE_API_SECRET environment variables or pass them explicitly to RESTClient.
Verify before relying
- Exact scope and completeness of Advanced Trade API endpoint coverage in this SDK version
- WebSocket reconnection and error-handling behavior under network interruptions
- Rate limiting and backoff strategy details beyond what the description states
Package facts
| License | Apache 2.0 (permissive) |
| Python support | supports the current Python release (>=3.8) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 5 — requests, cryptography, PyJWT, websockets, backoff |
| Maintenance | actively maintained — 56 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 242,844/month — #8,835 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: coinbase_advanced_py-1.8.4-py3-none-any.whl
Keywords: Coinbase, Advanced Trade, API, Advanced API
Tags
More Internet packages
Botocore provides low-level, data-driven access…
permissive · top 100 on PyPI
aiobotocoreProvides an async client for AWS services using…
permissive · top 100 on PyPI
pydanticPydantic validates Python data structures…
permissive · top 100 on PyPI
filelockProvides a platform-independent file locking…
permissive · top 100 on PyPI
fastapiFastAPI is a Python web framework for building…
permissive · top 100 on PyPI
googleapis-common-protosProvides common Protocol Buffer message…
permissive · top 100 on PyPI
cdp-sdkPython client library for the Coinbase…
permissive · top 15,000 on PyPI
massiveOfficial Python client for Massive's REST and…
permissive · top 15,000 on PyPI
python-kraken-sdkProvides REST and WebSocket clients for trading…
permissive · top 15,000 on PyPI
python-okxUnofficial Python wrapper for the OKX exchange…
permissive · top 15,000 on PyPI
WooCommerceA Python wrapper for the WooCommerce REST API…
permissive · top 15,000 on PyPI
pybitpybit is the official Python connector for…
permissive · top 15,000 on PyPI
binance-connectorConnects Python applications to Binance's…
permissive · top 15,000 on PyPI
polygon-api-clientProvides REST and WebSocket client libraries…
permissive · top 15,000 on PyPI
smartapi-pythonA Python client library for Angel Broking's…
unclear · top 15,000 on PyPI
paradime-ioPython SDK for interacting with the Paradime…
unclear · top 15,000 on PyPI