Skip to main content
A drop-in mapping from the TopLedger Wallets API to Octav. The biggest wins:
  • Solana and EVM. TopLedger is Solana-only. The same Octav GET /v1/portfolio accepts base58 Solana addresses and EVM addresses in the same shape.
  • Loose token holdings included. TopLedger’s holdings endpoint returns empty for most wallets. Octav returns your loose SOL/SPL tokens with per-asset detail (symbol, balance, price, value, contract).
  • Perps marked to market. TopLedger values perps at deposited collateral and returns pnl_usd on the side. Octav folds unrealized PnL into net worth (collateral + PnL).
  • Per-asset detail, not aggregates. TopLedger returns aggregate category values. Octav returns each asset inside every position.
Get your API key at data.octav.fi. Base URL: https://api.octav.fi/v1.

Endpoint mapping

Wallet tokens, DeFi positions, and net worth all come from a single GET /v1/portfolio call. There is no separate analyze and holdings request to merge.

Authentication

TopLedger uses an x-api-key header. Octav uses a standard Authorization: Bearer token.

Wallet token balances

TopLedger’s holdings endpoint returns { holdings: [], holdings_count }, and in practice holdings is empty for most wallets, so loose SOL and SPL tokens go unreported. Octav returns them under the wallet protocol, grouped by chain, with per-asset detail:
Field mapping

Net worth and per-chain breakdown

TopLedger’s total_net_worth_usd maps onto the top-level networth returned by the same portfolio call. Octav also breaks the total down per chain and includes loose token holdings and marked-to-market perps that TopLedger omits.
JavaScript

DeFi positions

TopLedger returns decoded positions as aggregate category values under categories (lending, perpetuals, staking, rewards, and so on). Octav returns the same money under assetByProtocols, keyed by protocol, then chain, then position type (LENDING, MARGIN, STAKED, LIQUIDITYPOOL, FARMING, …), with each underlying asset itemized.
Field mapping
TopLedger reports perps at deposited collateral and hands you pnl_usd separately. Octav folds unrealized PnL into the MARGIN position and into networth, so the collateral + PnL figure is already marked to market.

Transaction history

TopLedger has no wallet transaction endpoint. Octav adds GET /v1/transactions, covering Solana and EVM.
Octav categorizes each transaction (swap, deposit, stake, bridge, …) and prices transfers in USD. See the transaction types reference.

Key differences

  • Chains. TopLedger is Solana-only. Octav covers Solana and EVM from the same endpoint and shape.
  • Loose tokens. TopLedger’s holdings endpoint returns empty for most wallets. Octav returns loose SOL/SPL tokens with per-asset detail in the wallet bucket.
  • Granularity. TopLedger returns aggregate category values (value_usd, token_count). Octav returns each asset (symbol, balance, price, value) inside every position.
  • Perps. TopLedger values perps at deposited collateral and reports pnl_usd separately. Octav marks perps to market (collateral + unrealized PnL) and includes them in networth.
  • Shape. TopLedger groups by categoriesprotocols[]. Octav groups assetByProtocolschainsprotocolPositionsassets[], with a dedicated wallet bucket for loose tokens.
  • Billing. TopLedger charges roughly $0.0004 per call. Octav charges 1 credit per call (see pricing).
  • P&L. Octav adds openPnl, closedPnl, and totalCostBasis at no extra call.

Need help migrating?

Join our Discord

Share your TopLedger response shape and we’ll map it.

Portfolio endpoint

Full reference for the endpoint you’ll be calling.