Skip to content

Wallet PnL API

What a wallet spent and got back on one coin: realised profit, open position, in SOL and USD.

GET/v1/memecoin/wallet/:wallet/pnl

You send

  • wallet The wallet's address
  • mint The coin's mint address

+ 1 optional: chain

You get back

JSON with these fields, inside data:

wallet, trades, bought_sol, sold_sol, realized_pnl_sol, realized_pnl_usd, …

Example and every field explained ↓

It costs

$0.003 / call

The first 100 priced calls a day are free on every key.

Freshness
up to 30 s old
Auth
Bearer key
Chains
4 chains
curl "https://api.crypto2api.com/v1/memecoin/wallet/AEjQP2gxyVrrtJqUw5dCoNLgfjXhoTreJY8sTKar6dPv/pnl?mint=8o9YbJHdhhpJgyPoWDRZBqvJkKCiKZYuVkW6Qpccpump&chain=solana" \
  -H "Authorization: Bearer c2a_your_key"

Swap in your key for c2a_your_key. No key yet? curl -X POST https://api.crypto2api.com/v1/keys makes one, free, no sign-up, or just press Run below.

Used forTrack a wallet

Works on 4 chains. Pass chain=; it defaults to solana. Pick one in the playground and the cURL, JavaScript, Python and MCP snippets all follow it.

  • solana
  • ethereum
  • avalanche
  • mantle

Parameters

Required first. Each example is a value that works.

Response

Every answer is { data, cost_usd, balance_usd, cached, request_id }. Below is a real data from this endpoint, read when the page was built.

Example data

"wallet": "AEjQP2gxyVrrtJqUw5dCoNLgfjXhoTreJY8sTKar6dPv",
"mint": "8o9YbJHdhhpJgyPoWDRZBqvJkKCiKZYuVkW6Qpccpump",
"trades": 2,
"bought_sol": 0.6153,
"sold_sol": 1.3703,
"realized_pnl_sol": 0.755,
"realized_pnl_usd": 53.17,
"tokens_held_by_trades": 0,
"open_cost_sol": 0,
"open_value_sol": 0,
"unrealized_pnl_sol": 0,
"transactions_read": 2,
"fully_read": true,
"method": "Average cost: each sale is matched against the average price paid for the tokens held at that moment. Transfers in or out are not trades and are ignored.",
"source": "The wallet's own token account for this coin, read on chain; price from Jupiter."
}

Key fields

walletstring
The wallet address asked about.
tradesnumber
The list of trades, newest first.
bought_solnumber
Bought, in SOL.
sold_solnumber
Sold, in SOL.
realized_pnl_solnumber
Realized pnl, in SOL.
realized_pnl_usdnumber
Realized pnl, in US dollars.
tokens_held_by_tradesnumber
Tokens held by trades.
open_cost_solnumber
Open cost, in SOL.
open_value_solnumber
Open value, in SOL.
unrealized_pnl_solnumber
Unrealized pnl, in SOL.
5 more fields
transactions_readnumber
How many transactions were read to answer.
fully_readboolean
true when every transaction needed was read.
methodstring
Method.
mintstring
The coin's mint address (its contract address on Solana).
sourcestring
Where the numbers were read from.
The wrapper every answer comes in
data
The answer itself: the example above.
cost_usd
What this one call was charged — 0 while you are inside the free 100 a day.
balance_usd
What is left on the key after it.
cached
true means another caller asked first, so the answer may be up to 30 s old.
request_id
Quote this if you report something; it is on your Activity page too.

A fact the API could not read is left out or named, never estimated. When an upstream is down you get a 503 with a stable code you can branch on, not a half-filled answer.

Try it

A real call against the live API. The first 100 priced calls a day are free.

Response

"wallet": "AEjQP2gxyVrrtJqUw5dCoNLgfjXhoTreJY8sTKar6dPv",
"mint": "8o9YbJHdhhpJgyPoWDRZBqvJkKCiKZYuVkW6Qpccpump",
"trades": 2,
"bought_sol": 0.6153,
"sold_sol": 1.3703,
"realized_pnl_sol": 0.755,
"realized_pnl_usd": 53.17,
"tokens_held_by_trades": 0,
"open_cost_sol": 0,
"open_value_sol": 0,
"unrealized_pnl_sol": 0,
"transactions_read": 2,
"fully_read": true,
"method": "Average cost: each sale is matched against the average price paid for the tokens held at that moment. Transfers in or out are not trades and are ignored.",
"source": "The wallet's own token account for this coin, read on chain; price from Jupiter."
}

What this example answered when the page was built, shortened. Run it for a live answer.

Copy it

Runs as-is, with your key in place of c2a_your_key. It follows the boxes above, on Solana.

curl "https://api.crypto2api.com/v1/memecoin/wallet/AEjQP2gxyVrrtJqUw5dCoNLgfjXhoTreJY8sTKar6dPv/pnl?mint=8o9YbJHdhhpJgyPoWDRZBqvJkKCiKZYuVkW6Qpccpump&chain=solana" \
  -H "Authorization: Bearer c2a_your_key"

Related

More in Wallet

All endpoints →