TL;DR
- Read a token’s normal trading stats so the threshold is not a guess
- Pull only the trades that clear that threshold
- Classify each print as a buy or a sell
- Poll for new prints on a short loop so alerts fire near the moment a whale trade lands
https://public-api.birdeye.so, authenticate with the X-API-KEY header, and select the network with x-chain: solana.
The four stage pipeline
1
Size a threshold from the token's own baseline
A whale is relative. A 50,000 of daily volume and barely noticeable on one with $50 million, so the first call is not detection, it is context.Endpoint:
GET /defi/v3/token/trade-data/single2
Pull only the trades above that threshold
Most tokens generate thousands of small trades for every one that matters. Filtering for size up front means the tracker only ever looks at prints worth caring about.Endpoint:
GET /defi/v3/token/txs-by-volume3
Classify each print as a buy or a sell
A whale buying and a whale selling look identical on a line chart but mean opposite things for where price goes next.This is the same endpoint as Step 2, used two ways. Either read each print’s
side field from a combined pull, or issue two calls with tx_type=buy and tx_type=sell to get each direction pre split.The convention is relative to the token you query: a print labeled
buy sits in the to leg with a positive ui_change_amount, and a sell sits in from with a negative amount. Query the specific token you are monitoring, not a quote token like SOL, or the labels stop reading correctly, since the trades returned would span every pair that token touches.4
Poll for new prints on a short loop
A whale tracker that only answers when asked is a research tool, not an alert system. This stage turns the same endpoint into a live feed.
Watch your credit budget
A whale tracker polling on a tight loop across several tokens can consume credits faster than a one off script. Endpoint:GET /utils/v1/credits
Before you ship
- Every threshold is sized from the
_usdfields, never the raw token quantity fields. volume_type=usdis always set explicitly, since a missing value returns a 400 error.- The specific token being monitored is queried, not a quote token like SOL, so buy and sell labels read correctly.
volume_usdis summed per direction to get net pressure instead of counting trades.- Dedupe runs on the composite key, not
tx_hashalone, so multi leg transactions are not collapsed.
FAQ
What counts as a whale trade?
What counts as a whale trade?
There is no universal dollar figure, since a large trade on one token is routine on another. Set the threshold relative to the token’s own baseline, using
volume_1h_usd or volume_24h_usd, rather than a single number applied across every token you watch.How do you tell a buy from a sell?
How do you tell a buy from a sell?
Read the print relative to the token you queried. The monitored token sitting in the
to leg with a positive ui_change_amount is a buy, and the same token sitting in from with a negative amount is a sell. Query the specific token you care about rather than a quote token, or the labels stop reading correctly.Can you look back at whale activity that already happened?
Can you look back at whale activity that already happened?
Yes, the same endpoint that powers live polling also answers a historical question. Set
before_time and after_time to bound a past window instead of polling forward. This is useful for reviewing what drove a price move after the fact, or for backtesting a threshold before committing to it live.Should one whale tracker watch several tokens at once?
Should one whale tracker watch several tokens at once?
Yes, by running the same four stages per token rather than building anything new. Keep each token’s threshold tied to its own baseline instead of reusing one number across very different tokens, since a single fixed floor floods you with noise on a quiet token and misses everything on an active one.

