bdnBlocks
Available on Gateway and Cloud API
Name: bdnBlocks
bdnBlocks is a stream of all new blocks as they are propagated in the BDN. The blocks published in the bdnBlocks stream may include blocks that will not be accepted on chain. This stream offers significant performance speed over the newBlocks stream (from the Gateway or the node).
Important update (as of October 10, 2025): The default value for parsedTxs has changed to false.
If you rely on parsed transaction fields, you will need to explicitly set parsedTxs: true.
Options
Key
Description
Values
include
Fields to include in the block stream.
hash,header,transactions,uncles,future_validator_info,withdrawals
[Default: all] future_validator_info contains validator addresses for future blocks and indicates whether the validators are connected to the BDN (currently only supported in BSC) withdrawals
contains withdrawals for ETH block
parsedTxs
Controls whether transactions in each block are returned as fully parsed JSON objects (true) or as raw, unparsed RLP payloads (false). Disabling parsing reduces server work and improves delivery latency.
Type: boolean
[Default: false]
Examples (Websocket)
Cloud-API
## ETH Example
wscat -c wss://virginia.eth.blxrbdn.com/ws --header "Authorization: <YOUR-AUTHORIZATION-HEADER>"
> {"jsonrpc": "2.0", "id": 1, "method": "subscribe", "params": ["bdnBlocks", {"include": ["hash"], "parsedTxs": true}]}
< ......
## BSC Example
wscat -c wss://virginia.bsc.blxrbdn.com/ws --header "Authorization: <YOUR-AUTHORIZATION-HEADER>"
> {"jsonrpc": "2.0", "id": 1, "method": "subscribe", "params": ["bdnBlocks", {"include": ["hash"], "blockchain_network": "BSC-Mainnet", "parsedTxs": true}]}
< ......
var fs = require('fs');
const WebSocket = require('ws');
// Enterprise users can follow line 5-16
const ws = new WebSocket(
'wss://virginia.eth.blxrbdn.com/ws', // for ETH
// use 'wss://virginia.bsc.blxrbdn.com/ws', //for BSC
{
headers: {
"Authorization" : <YOUR-AUTHORIZATION-HEADER>
},
// Add the following line if you work with IP instead of DNS
// rejectUnauthorized: false,
}
);
// Non Enterprise users should follow line 19-27
// const ws = new WebSocket(
// "wss://api.blxrbdn.com/ws",
// {
// headers: {
// "Authorization" : <YOUR-AUTHORIZATION-HEADER>
// },
// rejectUnauthorized: false,
// }
// );
function proceed() {
// ETH Example
ws.send(`{"jsonrpc": "2.0", "id": 1, "method": "subscribe", "params": ["bdnBlocks", {"include": ["tx_hash"]}]}`);
// BSC Example (only available at endpoint wss://<region>.bsc.blxrbdn.com/ws)
// ws.send(`{"jsonrpc": "2.0", "id": 1, "method": "subscribe", "params": ["bdnBlocks", {"include": ["hash"], "blockchain_network": "BSC-Mainnet"}]}`);
}
function handle(nextNotification) {
console.log(nextNotification.toString()); // or process it generally
}
ws.on('open', proceed);
ws.on('message', handle);Gateway
Response (Block Event)
Examples - gRPC
Response (Block Event)
Last updated