A Streamlit connector for the CoinMarketCap API.
Project description
CoinMarketCap Connection for Streamlit
A Streamlit connection component to connect Streamlit apps to the CoinMarketCap API for cryptocurrency market data.
🚀 Features
- Easy integration with Streamlit applications.
- Access to real-time and historical cryptocurrency data including prices, market caps, and trading volumes.
- Efficient handling of API rate limits.
- Simple configuration using API key.
🧑🎓 Getting Started
Installation
Install coinmarketcap_connection
via pip:
pip install coinmarketcap_connection
🔩 Configuration
Set your CoinMarketCap API key in the secrets.toml file for Streamlit apps as described in the Streamlit documentation.
🔍 Usage
Import
from coinmarketcap_connection import CoinMarketCapConnection
Initialize
cmc_connection = CoinMarketCapConnection("YOUR_CONNECTION_NAME")
Fetch Data
Use the connection to fetch the latest cryptocurrency data or historical data.
Fetch Latest Cryptocurrency Data
latest_data = cmc_connection.fetch_latest_data(limit=100)
Fetch Historical Cryptocurrency Data
historical_data = cmc_connection.fetch_historical_data(cryptocurrency_id=1, start_date='2023-01-01', end_date='2023-01-31')
📑 Documentation
For detailed documentation, visit CoinMarketCap API documentation.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for coinmarketcap_connection-0.0.0.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | c4bd5c5aad6c8a123d7e78d8c37cc72be60aa77f6618b608c5b80130890e280c |
|
MD5 | 7a15d0873ed11d92cb9d48e025ba3c71 |
|
BLAKE2b-256 | 274273597882c3f48864a87e1d6cc3aec9c9775e16397e9332786dad036d27d4 |
Close
Hashes for coinmarketcap_connection-0.0.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 27c182a0c8438212e73a60c72458834268bdb031ff242f1787803597c5abfa12 |
|
MD5 | 719d01e59c36baadcb96b51548999861 |
|
BLAKE2b-256 | 374a6879e78c30977128707d10ed1e32ec72682191704cc518fc2d4820c26317 |