Real-world asset · Stock perp
| Venue | Atlas ID | Price | 24h | Open interest | Funding | Basis, bps | Spread, bps | Top depth | Buy/sell |
|---|---|---|---|---|---|---|---|---|---|
| Binance | perpetual-AAOI-USDT:USDT | 37.200 | -12.02% | $10.0M | 0.0000% | -7.35 | 2.56 | $1.1K | 1.02 |
| OKX | perpetual-AAOI-USDT:USDT | 37.210 | -11.95% | $2.7M | 0.0000% | 0.00 | 2.60 | $1.4K | 0.98 |
| Hyperliquid | perpetual-XYZ:AAOI-USDC:USDC | 37.226 | -11.95% | $1.6M | +0.0030% | +5.92 | 7.89 | $5.2K | 0.90 |
| Hyperliquid | perpetual-PARA:AAOI-USDC:USDC | 37.514 | -12.33% | $62.0K | +0.0024% | +0.27 | 38.7 | $17.5K | 1.15 |
pip install "aperiodic[polars]"from datetime import date
from aperiodic import get_metrics
# Applied Optoelectronics (AAOI), `basis`, hourly, on 3 venues
for exchange, symbol in [
("binance-futures", "perpetual-AAOI-USDT:USDT"),
("okx-perps", "perpetual-AAOI-USDT:USDT"),
("hyperliquid-perps", "perpetual-XYZ:AAOI-USDC:USDC"),
]:
df = get_metrics(
api_key="YOUR_API_KEY",
metric="basis",
exchange=exchange,
symbol=symbol,
interval="1h",
timestamp="exchange",
start_date=date(2026, 10, 21),
end_date=date(2026, 11, 20),
)
print(exchange, df.head())Read https://aperiodic.io/start.md and follow it. Then, for the Applied Optoelectronics (AAOI) perps on Binance, OKX and Hyperliquid over the last 30 days: how does the premium over the stock (`basis`, `funding`) behave overnight and at weekends, while its market is shut?