Data API
The SDK includes a REST client for querying off-chain analytics - position history, pool statistics, leaderboards, oracle prices, and more. This is separate from the on-chain RPC interface.
Setup
Full API reference is available at datapi.adrena.trade/docs.
import { AdrenaApi } from 'adrena-sdk/adrena-api';
const api = new AdrenaApi(); // defaults to datapi.adrena.tradeTo point to a custom endpoint:
const api = new AdrenaApi('https://your-custom-endpoint.com');Positions
Fetch the position history for a wallet address.
const positions = await api.getPositions({
userWallet: '8xMT...abc',
});Pool Analytics
Query pool-level statistics at various time resolutions.
Custody Analytics
Per-asset statistics (open interest, utilisation, fees collected).
Trader Data
Mutagen (Points)
See Mutagen (Points System) for details on how points are earned.
Prices
Available Methods
getPositions(params)
Position history for a wallet
getPoolInfo(params?)
Latest pool statistics
getHourlyPoolInfo(params?)
Hourly pool statistics
getDailyPoolInfo(params?)
Daily pool statistics
getCustodyInfo(params?)
Per-asset custody statistics
getHourlyCustodyInfo(params?)
Hourly custody statistics
getDailyCustodyInfo(params?)
Daily custody statistics
getMutagen(userWallet)
Mutagen points for a wallet
getMutagenLeaderboard(params?)
Full mutagen leaderboard
getTraderInfo(userPubkey)
Performance metrics for a trader
getTraderProfiles(params?)
Trader leaderboard
getTraderVolume(params?)
Volume history for a trader
getPrice()
Current ADX and ALP token prices
getLastTradingPrices()
Latest oracle prices for all traded assets
Advanced: Building Instructions Manually
Every core function is a thin wrapper around an instructions builder that then submits via Jito. Use the builders directly when you need to compose custom transactions.
All liquidity and staking instruction builders follow the same pattern - see src/instructions/ in the SDK repository for the full set.
Last updated
Was this helpful?
