Subscribing to Real-Time Token Transaction Updates (SUBSCRIBE_TXS)
The “SUBSCRIBE_TXS” event allows you to receive real-time updates about token transactions. You can subscribe to transactions for individual tokens, token pairs, or a combination of both. This subscription is useful for tracking trading activities and other relevant transactions on the Birdeye platform. You can use this Websocket to get real time transaction updates of following objects:- Transactions of a token
- Transactions of a pair/market
- Transactions of multiple Tokens/Pairs
Code Example
Checkout this Github file for an example:https://github.com/birdeye-so/tradingview-example-js-api/blob/main/websocket_example.js
1 - Subscribe Token Transactions
To receive real-time updates about transactions for a specific token, you can use the following subscription message format:Input
txsType: “all”, “add_remove_liquidity”, “add_liquidity”, “remove_liquidity”, “swap” to filter transaction types.
If txsType is not provided, the result will default to returning all transaction types, the same as when using “all”.
Output Example
2 - Subscribe Pair Transactions
To receive real-time updates about transactions for a specific token pair, you can use the following subscription message format:Input
txsType: “all”, “add_remove_liquidity”, “add_liquidity”, “remove_liquidity”, “swap” to filter transaction types.
If txsType is not provided, the result will default to returning all transaction types, the same as when using “all”.
Output Example
3 - Subscribe to Multiple Addresses (Limit 100)
You can also subscribe to transactions for multiple addresses by using the “complex” query type. You can get updates for maximum 100 addresses at once.Subscribing to TXS for Multiple Tokens SUBSCRIBE_TXS replaces the existing txs subscription for that connection and message type. If you want to add more tokens to your txs subscription, you must send a new SUBSCRIBE_TXS message whose payload includes the full list of token addresses you want to receive txs updates for— including both tokens you were already subscribed to and the new ones. Example You first send: SUBSCRIBE_TXS for So11111111111111111111111111111111111111112 You will begin receiving: TXS events for So11111111111111111111111111111111111111112 Later, you want to subscribe to tx updates for an additional token: JUPyiwrYJFskUPiHa7hkeR8VUtAeFoSYbKedZNsDvCN To do this, you must send SUBSCRIBE_TXS again with a payload containing both addresses: SUBSCRIBE_TXS with addresses: [So11111111111111111111111111111111111111112, JUPyiwrYJFskUPiHa7hkeR8VUtAeFoSYbKedZNsDvCN] Result You continue receiving txs events for So11111111111111111111111111111111111111112 You start receiving txs events for JUPyiwrYJFskUPiHa7hkeR8VUtAeFoSYbKedZNsDvCN The previous SUBSCRIBE_TXS subscription is overwritten by the new one (now containing both tokens) The following example demonstrates how to subscribe to transactions for either a specific token address or a specific token pair address:
Input
txsType: “all”, “add_remove_liquidity”, “add_liquidity”, “remove_liquidity”, “swap” to filter transaction types.
If txsType is not provided, the result will default to returning all transaction types, the same as when using “all”.
Output
Request Type Difference
First WebSocket Request (COMPLEX Query)- Logical OR statement, tracking multiple addresses.
- Returns all transactions involving these addresses, including swap, add liquidity and remove liquidity.
- Tracks only this specific address.
- Optimized for this token address being a main asset in the transaction.
Response Structural Differences
Contextual Interpretation
COMPLEX query is more general and is probably used for monitoring addresses (wallets or token contracts) regardless of their transaction role. It yields raw swap data and doesn’t include enriched metadata like tokenAddress, pricePair, or network.Example:

