Real-Time Trades
Learn more about getting a token trades data stream from our WebSocket.
Get Started
Get real-time trades from the Solana blockchain across major DEXs such as Orca, Raydium, Meteora, Phoenix, Pump.fun, and more to power your trading applications and market analysis. Continuous support for additional DEXs will be added.
Follow our guided recipe to learn how you can quickly start streaming trades from Solana.
Supported DEXs & AMMs:
Name | Program ID |
---|---|
Orca Whirlpool | whirLbMiicVdio4qvUfM5KAg6Ct8VwpYzGff3uctyCc |
Phoenix DEX | PhoeNiXZ8ByJGLkxNfZRnkUfjvmuYqLR89jjFHGqdXY |
Raydium V4 | 675kPX9MHTjS2zt1qfr1NYHuzeLXfQM9H24wFSUt1Mp8 |
Raydium CLMM | CAMMCzo5YL8w4VFF8KVHrK22GGUsp5VTaW7grrKgrWqK |
Meteora DLMM | LBUZKhRxPF3XUpBCjp4YzTKgLccjZhTSDM9YuVaPwxo |
Meteora Pools | Eo7WjKq67rjJQSZxS6z3YkapzY3eMj6Xy8X5EQVn5UaB |
Lifinity Swap V2 | 2wT8Yq49kHgDzXuPxZSaeLaH1qbmGXtEyPy64bL7aD3c |
Lifinity Swap V1 | EewxydAPCCVuNEyrVN68PuSYdQ7wKn27V9Gjeoi8dy3S |
OpenBook V2 | opnb2LAfJYbRMAHHvqjCwQxanZn7ReEHp1k81EohpZb |
Pump.fun | 6EF8rrecthR5Dkzon8Nwu78hRvfCKubJ14M5uBEwF6P |
Filters
Things to keep in mind:
- If you use this connection without a filter you will receive data for ALL trade events. This can result in excessive credit usage
- Filters can be used in any combination to make a precise request for the data you need.
- programId: At the moment, you can filter by one program address per request. Multi-program filtering will be available soon.
- tokenMintAddress: At the moment, you can filter by one mint address per request. Multi-token filtering will be available soon.
- To get trades for native Solana you must use
11111111111111111111111111111111
as the token mint.
Name | Description |
---|---|
authorityAddress | The public key of the entity that authorized the trade, often used for retrieving trades associated with a specific trading account. |
feePayer | The public key of the entity responsible for paying the transaction fees associated with a trade. This address is typically the originator of the transaction. |
marketId | The public key identifying the specific market pair involved in the trade, such as SOL/USDC. |
programId | The public key of the decentralized exchange (DEX) Solana program executing the trade. Refer to documentation for a list of available program IDs. |
baseMintAddress | The public key of the base token’s mint in a trading pair. |
quoteMintAddress | The public key of the quote token’s mint in a trading pair. |
tokenMintAddress | The public key for the mint of the token involved in the trade, identifying the specific token type being transacted. |
Market ID vs Base/Quote Mint vs Token Mint Filters
To effectively utilize the token mint, base/quote, and market ID filters, it is important to understand their distinct functionalities, as only one of these filters can be used at a time. The token mint filter allows users to retrieve all trading pairs associated with a specific token. For example, by entering "SOL," users can access trades such as SOL/USDC, SOL/BONK, SOL/BTC, and more. This filter is particularly useful for exploring all possible trading pairs for a given token, as it overrides any specific base/quote inputs.
In contrast, the base/quote filter is used to specify particular trading pairs by defining the base and quote currencies, such as SOL/USDC. This is ideal for users interested in specific currency pair trades. Lastly, the market ID filter targets a specific market pair. Users must select one filter based on their trading query needs, ensuring a customized approach to data retrieval.
Response
Overview of the response from a trades data stream:
Name | Description |
---|---|
authorityAddress | The public key of the signer who authorized the trade. |
baseMintAddress | The mint address of the base token involved in the trade. |
baseSize | The quantity of the base token involved in the trade. |
blockTime | The Unix timestamp at which the trade occurred on the blockchain. |
fee | The amount of fees paid for the trade. |
feePayer | The public key of the account responsible for paying the transaction fees. |
ixOrdinal | The location of the trade ix inside the transaction. |
iixOrdinal | The location of the trade inner ix inside the transaction. 255 is returned if not applicable. |
interIxOrdinal | The location of the trade inside an ix (in 2 hop swaps). 255 is returned if not applicable. |
marketId | The identifier for the market pair, e.g., SOL/USDC, where the trade took place. |
price | The price of one unit of the base token, expressed in terms of the quote token. |
programId | The public key of the AMM or DEX program that facilitated the trade. |
quoteMintAddress | The mint address of the quote token used in the trade. |
quoteSize | The amount of the quote token exchanged in the trade. |
signature | The unique identifier of the transaction signature on the blockchain. |
txIndex | The transaction index of the trade. |
Updated 3 months ago