BSC Mempool Stream - Real-Time Transaction Monitoring
Monitor BSC (BNB Smart Chain) mempool transactions in real-time before they are confirmed on-chain. Track pending DEX trades, token creations, transfers, and detect opportunities early with Bitquery's Mempool APIs and Streams.
Any Bitquery GraphQL stream can be converted to a mempool monitoring stream by setting mempool: true
.
We also provide low-latency Kafka streams to monitor broadcasted data, which are much faster than GraphQL mempool streams. Read more about Kafka streams here.
To query or stream data via GraphQL outside the Bitquery IDE, you need to generate an API access token.
Follow the steps here to create one: How to generate Bitquery API token ➤
Table of Contents​
1. How Mempool Simulation Works​
2. Mempool Streaming Examples​
- Stream Four Meme Trades in Mempool ➤
- Stream Four Meme Token Creation in Mempool ➤
- Stream All Transactions in Mempool ➤
- Stream DEX Trades in Mempool ➤
How do we simulate txs for Bitquery Mempool APIs & Streams?​
When a transaction is received by the node but not yet included in a block, Bitquery uses the following context to send mempool data:
-
The transaction is executed in the EVM (using the current pending block context).
-
The system captures the simulated receipt and trace.
For each batch of simulated transactions, Bitquery records the block header used as the execution context.
message BroadcastedTransactionsMessage {
Chain Chain = 1;
BlockHeader Header = 2;
repeated Transaction Transactions = 3;
}
Mempool Streaming Examples​
Stream Four Meme Trades in Mempool - Detect Them Early​
Monitor Four Meme DEX trades in real-time as they appear in the mempool, before they are confirmed on-chain. This allows you to detect trading opportunities early and front-run or back-run trades.
Click to expand GraphQL query
subscription {
EVM(network: bsc, mempool: true) {
DEXTrades(where: {Trade: {Dex: {ProtocolName: {is: "fourmeme_v1"}}}}) {
Trade {
Buy {
Buyer
Currency {
Name
Symbol
SmartContract
}
Amount
}
Sell {
Seller
Currency {
Name
Symbol
SmartContract
}
Amount
}
}
Transaction {
Hash
}
}
}
}
Stream Four Meme Token Creation in Mempool - Detect Them First​
Track new Four Meme token creations in the mempool instantly. Be the first to know when a new token is being created, before it's confirmed on-chain.
Click to expand GraphQL query
subscription {
EVM(network: bsc, mempool: true) {
Events(
where: {Transaction: {To: {is: "0x5c952063c7fc8610ffdb798152d69f0b9550762b"}}, Log: {Signature: {Name: {is: "TokenCreate"}}}}
) {
Log {
Signature {
Name
Signature
}
}
Arguments {
Value {
... on EVM_ABI_Integer_Value_Arg {
integer
}
... on EVM_ABI_Boolean_Value_Arg {
bool
}
... on EVM_ABI_Bytes_Value_Arg {
hex
}
... on EVM_ABI_BigInt_Value_Arg {
bigInteger
}
... on EVM_ABI_Address_Value_Arg {
address
}
... on EVM_ABI_String_Value_Arg {
string
}
}
Name
Type
}
Transaction {
Hash
To
From
}
}
}
}
Streaming Transactions in Mempool on BSC​
Monitor all pending transactions and transfers on BSC in real-time. Track transaction details including sender, receiver, gas, amounts, and token information before blocks are mined.
Click to expand GraphQL query
subscription {
EVM(mempool: true, network: bsc) {
Transfers {
Log {
Index
}
Transaction {
Time
Type
To
Gas
From
Cost
Hash
}
Transfer {
Amount
Currency {
Name
}
Type
}
TransactionStatus {
Success
FaultError
EndError
}
Block {
Time
}
Call {
Signature {
Name
}
}
}
}
}
Streaming Trades in Mempool on BSC​
Stream all DEX trades happening in the BSC mempool in real-time. Monitor buy/sell activity, prices, volumes, and trading pairs across all DEXs before transactions are confirmed.
Click to expand GraphQL query
subscription {
EVM(mempool: true, network: bsc) {
DEXTradeByTokens {
Block {
Number
}
Transaction {
Hash
}
Trade {
Price
PriceInUSD
Currency {
Name
}
Amount
Buyer
Dex {
ProtocolName
}
Side {
Seller
Buyer
AmountInUSD
Amount
Currency {
Name
Symbol
}
}
}
}
}
}
Related Resources​
You may also be interested in:
- Four Meme API Documentation ➤
- BSC DEX Trades API ➤
- Kafka Protobuf Streams for EVM ➤
- WebSocket Subscriptions ➤
Need Help?​
If you have any questions or need assistance with BSC mempool streams, reach out to our Telegram support.