Skip to main content

subscribe - live price

Live price / market-cap updates for one pool. The server emits token_update every time the pool's last-trade price changes. Pass one of mint or pool (mint → pool lookup happens server-side).

ChannelSocket.IO event
Authauth.api_key in the handshake
Emitstoken_update

Supported DEXes

Prices stream from trades on every major Solana DEX and launchpad:

PumpFun
PumpFun Mayhem
SWAP
PumpSwap
Meteora
Raydium
Orca
Bonk

Meteora covers DAMM v2 and DBC (dynamic bonding curve); Raydium covers CPMM and AMM v4. The quote field on each update tells you which mint (WSOL or USDC) the price is denominated in.

Example

import { io } from "socket.io-client";

const socket = io("https://api.pumpdata.fun", {
auth: { api_key: "pd_xxxxxxxx…" },
});

socket.on("token_update", (u) => {
console.log(`${u.pool}${u.price} (mcap ${u.mcap})`);
});

socket.emit("subscribe", { mint: "Gc6rNxGnoQt…pump" }, (ack) => {
console.log("subscribed:", ack); // { ok: true, pool: "...", room: "..." }
});

// later, to stop (free): socket.emit("unsubscribe", { pool: "4mBL…" });

Response - token_update

{
"pool": "4mBLRPUyfE7CvxmXiGJx5WA51isanbxpdbdPjFuuBzmY",
"price": 0.000000033,
"mcap": 32.62,
"quote": "So11111111111111111111111111111111111111112",
"priceUSD": 0.0000049,
"mcapUSD": 4893.0,
"time": 1779812627
}
fieldmeaning
priceprice in the quote token per base token
quotethe quote-side mint the price is denominated in — WSOL, USDC, or USD1
mcapmarket cap in the quote token (price × total supply)
priceUSDprice converted to US dollars
mcapUSDmcap converted to US dollars

For USDC- and USD1-quoted pools the USD fields equal price / mcap (those quotes are already dollars). For WSOL-quoted pools they're converted using the live SOL/USD rate (the same rate streamed by subscribe_sol_price). priceUSD / mcapUSD are 0 in the brief window before the first SOL/USD tick is seen.

Errors

If the subscription cannot be created, the ack callback receives an error object instead of { ok: true }:

{ "error": "not_found", "message": "pool not found" }
errorWhen
invalid_requestNeither mint nor pool was provided.
not_foundThe mint has no active pool, or the given pool is not known to the data plane.
unavailableA transient backend error (the server already retried). Safe to retry - it is not a definitive "not found".
limit_exceededThis connection already has the maximum number of subscriptions.

If you do not pass an ack callback, the same payload is emitted as a subscription_error event instead.

Try it

Notes

  • This is the cheapest live stream - use it for "current price" cards or simple tickers.
  • For full trade details (wallet, signature, amounts) use subscribe_trades.
  • For candlesticks use subscribe_ohlcv.