Coincappy
Simple Python wrapper around CoinMarketCap free endpoints.
Installing
Install from PyPI using pip:
pip install coincappy
Install directly from repository:
pip install git+https://github.com/kiwioverseas/coincappy.git
Usage
Response data is in JSON format.
from coincappy import CoinMarketCap
cmc = CoinMarketCap(API_KEY)
response = cmc.crypto_quotes(symbol='BTC')
print(response['BTC'][0]['quote']['USD']['price'])
Endpoints
CoinMarketCap API documentation is available at https://coinmarketcap.com/api/documentation/v1/
Endpoints available using the basic/free plan are supported:
crypto_metadata()
cryptocurrency/info
Static metadata for one or more cryptocurrencies.
Requires id, slug or symbol. Optional parameters are described in API documentation.
response = cmc.crypto_metadata(id=1)
crypto_cmc_map()
/cryptocurrency/map
Mapping of cryptocurrencies to CoinMarketCap ids.
Optional parameters are described in API documentation.
response = cmc.crypto_cmc_map()
response = cmc.crypto_cmc_map(symbol='BTC')
crypto_listings()
/cryptocurrency/listings/latest
Latest cryptocurrency market data.
Optional parameters are described in API documentation.
response = cmc.crypto_listings()
response = cmc.crypto_listings(market_cap_min=10000000000)
crypto_quotes()
/cryptocurrency/quotes/latest
Latest cryptocurrency market quotes.
Requires id, slug or symbol. Optional parameters are described in API documentation.
response = cmc.crypto_quotes(id=1)
response = cmc.crypto_quotes(id=1, convert='NZD')
market_metrics()
/global-metrics/quotes/latest
Latest global cryptocurrency market metrics.
Optional parameters are described in API documentation.
response = cmc.market_metrics()
convert_currency()
/tools/price-conversion
Coverts one cryptocurrency or fiat currency into another.
Requires amount and id or slug. Optional parameters are described in API documentation.
response = cmc.convert_currency(amount=100, id=1)
fiat_cmc_map()
/fiat/map
Mapping of fiat currencies to unique CoinMarketCap ids.
Optional parameters are described in API documentation.
response = cmc.fiat_cmc_map()
account_info()
/key/info
API key details and usage stats.
response = cmc.account_info()
Metadata
Release files for coincappy 0.1.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 | |
|---|---|---|---|
| coincappy-0.1.0.tar.gz | 3.7 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| coincappy-0.1.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 8.5 kB
Release files / coincappy-0.1.0.tar.gz
| Download URL | coincappy-0.1.0.tar.gz |
|---|---|
| Size | 3.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
9bb48c21ebce0c1dbe89257a56c0b6af87ac42021fdb4533aa0b10059f74657f
|
|
BLAKE2b-256 checksum How to use checksums |
6321e82fe213d9ba65bd3dca86bf0c84de089598beb78028858100fc7e45b680
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/53.0.0 requests-toolbelt/0.9.1 tqdm/4.59.0 CPython/3.9.2
|
Release files / coincappy-0.1.0-py3-none-any.whl
| Download URL | coincappy-0.1.0-py3-none-any.whl |
|---|---|
| Size | 4.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
9a185ac8715865d16ad3e89ecc29de51d865df246f3181e1c7f5d7922988f552
|
|
BLAKE2b-256 checksum How to use checksums |
959091dd906c5bad7bc1993b709af5c725e78f8a01d79b916664f40fbe8451dc
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/53.0.0 requests-toolbelt/0.9.1 tqdm/4.59.0 CPython/3.9.2
|