// Fetch market data for a single asset
const marketData = await client.fetchMarketData({
asset: 'bitcoin',
});
// Fetch multiple assets
const multiData = await client.fetchMarketMultiData({
assets: ['bitcoin', 'ethereum', 'solana'],
});
// Fetch market history
const history = await client.fetchMarketHistory({
asset: 'bitcoin',
interval: '1d',
from: Math.floor(Date.now() / 1000) - 86400 * 30,
to: Math.floor(Date.now() / 1000),
});
// Fetch OHLCV data
const ohlcv = await client.fetchMarketOHLCVHistory({
asset: 'bitcoin',
blockchain: 'ethereum',
pair: 'WETH/USDC',
interval: '1h',
from: Math.floor(Date.now() / 1000) - 86400,
to: Math.floor(Date.now() / 1000),
});