Metadata-Version: 2.4
Name: crypto-data-sdk
Version: 0.1.0
Summary: Python SDK for damonstats.com — real-time crypto derivatives data
Author: damonstats
License: MIT
Project-URL: Homepage, https://damonstats.com
Project-URL: Documentation, https://damonstats.com/api
Project-URL: Repository, https://github.com/damonstats/python-sdk
Keywords: crypto,derivatives,funding-rate,open-interest,trading
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: Topic :: Office/Business :: Financial :: Investment
Classifier: Programming Language :: Python :: 3
Requires-Python: >=3.10
Description-Content-Type: text/markdown
Requires-Dist: httpx>=0.27

# damonstats Python SDK

Real-time crypto derivatives data — funding rates, open interest, basis, liquidations across Binance, OKX, Bybit, Hyperliquid, and dYdX.

```bash
pip install crypto-data-sdk
```

## Quick Start

```python
from damonstats import Client

client = Client()  # Uses free tier by default

# Get BTC funding rates across all exchanges
btc = client.get_coin("BTC")
print(btc["exchanges"]["binance"]["funding_rate"])

# Get cross-exchange basis arb opportunities
basis = client.get_basis()
for row in basis["data"][:5]:
    print(f"{row['symbol']}: {row['max_spread']*100:.3f}% spread")

# Get top OI rankings
oi = client.get_open_interest()
for row in oi["data"][:5]:
    print(f"{row['symbol']} ({row['exchange']}): ${row['open_interest']/1e9:.2f}B")

# Get funding rate history
hist = client.get_history("ETH", metric="funding_rate")
print(f"{len(hist['data'])} data points")
```

## API

| Method | Description |
|--------|-------------|
| `get_dashboard()` | Homepage aggregations |
| `get_coin(symbol)` | Single coin + 24h history |
| `get_funding_rates(exchange?, sort?)` | All funding rates |
| `get_liquidations(symbol?, limit?)` | Liquidation data |
| `get_open_interest(exchange?)` | OI rankings |
| `get_basis()` | Cross-exchange basis scanner |
| `get_exchanges()` | Exchange metadata + referral info |
| `get_compare(e1, e2)` | Exchange comparison |
| `get_symbols()` | Available symbols |
| `get_history(symbol, metric?)` | Time-series data |

## Pro Tier

Upgrade at [damonstats.com/api](https://damonstats.com/api):
- Free: 1,000 req/day
- Pro ($29/mo): 100,000 req/day + 90-day history
- Enterprise ($199/mo): Unlimited + full history + WebSocket
