Skip to main content
POST
Wallet - PnL Details

Detailed wallet PnL breakdown.

  • Maximum number of tokens per request body is 100.
  • Body parameters include wallet, optional token_addresses, duration, position_scope, pnl_method, sort_by, sort_type, offset, and limit.
  • limit supports 1 to 100, and offset supports up to 10,000.
  • Use this endpoint when you need wallet-level summary plus token-level breakdown in one request.
  • This endpoint consumes 30 CU per request.
  • Drill from wallet-level PnL into token-level contributors in one call.
  • Sort and page through the assets that drove gains or losses.
  • Support research views that need both summary and breakdown without multiple round trips.
  • Set the supported PnL chain in x-chain.
  • Send the wallet address in the POST body.
  • Optionally restrict the breakdown with token_addresses.
  • Set pnl_method=netcash or pnl_method=wac when you need to lock the accounting method used in the result.
  • Use offset, limit, sort_by, and sort_type to control the returned token rows.
  • Start with the summary endpoint when you need only headline metrics, then switch to details when the wallet warrants investigation.
  • Restrict token_addresses for focused investigations instead of always requesting a full breakdown.
  • Keep sort order stable across pagination so result slices are reproducible.

Authorizations

X-API-KEY
string
header
required

API key for authentication

Headers

x-chain
enum<string>
default:solana

The chain support PNL data.

Available options:
solana,
ethereum,
arbitrum,
avalanche,
bsc,
optimism,
polygon,
base,
zksync,
monad,
hyperevm,
mantle,
megaeth,
robinhood

Body

application/json
wallet
string
required
Example:

"5Q544fKrFoe6tsEbD7S8EmxGTJYAKtTVhAW5Q5pge4j1"

token_addresses
string[]
Example:
duration
enum<string>
default:all
Available options:
all,
90d,
30d,
7d,
24h
position_scope
enum<string>
default:duration_only

Calculation mode for PnL. duration_only calculates PnL only for each selected time bucket. cumulative calculates realized_pnl cumulatively from the start time, while unrealized_pnl is based on the all-time open position. Defaults to duration_only.

Available options:
duration_only,
cumulative
pnl_method
string

PNL calculation method. wac (Weighted Average Cost): calculates PNL for each sell against the average cost of the position held at the time of the sell. Buys only re-average the cost of the remaining inventory, and previously realized sell PNL is not affected by later trades. netcash (Net Cash): calculates PNL across the full trade history using the spread between cumulative average sell price and cumulative average buy price. The buy average includes all buys and is not reduced by sells, so later buys can change the reported PNL.

sort_type
enum<string>
default:desc
Available options:
asc,
desc
sort_by
enum<string>
default:last_trade
Available options:
last_trade
limit
integer
default:10
Required range: 1 <= x <= 100
offset
integer
default:0
Required range: 0 <= x <= 10000

Response

JSON object containing a wallet

data
object
required
success
boolean

Whether the request succeeded.