SDKs & tools
Python SDK
The official Python SDK wraps the CoinMarketCap Pro API with typed request/response models, automatic retries, and a namespace API grouped by endpoint category.
- PyPI:
coinmarketcap-sdk - GitHub: OpenCMC/coinmarketcap-api-python
- Import name:
coinmarketcap(package on PyPI iscoinmarketcap-sdk) - Requires: Python 3.10+
Get started
-
Install the package
CodeOr with
uv/ Poetry:Code -
Create a client
Set your API key from the Developer Portal. For keyless endpoints, use
environment="public".Code -
Call an endpoint
Endpoints are grouped by category on the client instance:
CodeAsync variants use the
async_prefix:Code -
Handle errors
The SDK raises typed exceptions for common HTTP failures:
Code
Public (keyless) mode
Code
See the Keyless Public API for available endpoints without a key.
Next steps
- Get Started with an API Key if you have not set up authentication yet
- Choose an endpoint to find the right API family
- Full README and examples on GitHub