Description
The Pool Fee Terms stream delivers notifications whenever a pool’s fee configuration is updated on-chain. This includes changes to the total swap fee or the split between recipients (LPs, protocol, etc.).
Subscription Parameters
Filter updates to specific BlockDB pool identifiers.
Filter updates by exchange identifiers.
Message Fields
Total fee fraction (e.g., 0.003 = 0.30%).
Fee fraction allocated to LPs/users.
Fee fraction allocated to the protocol.
Block height where the update occurred.
Row-level lineage hash for correlation.
Subscription Example
# Use wscat to connect and subscribe
wscat -c wss://stream.blockdb.io/v1/evm/ \
-H "Authorization: Bearer $BLOCKDB_API_KEY" \
-x '{"action": "subscribe", "dataset_id": "0204", "chain_id": 1, "params": {"pool_uids": ["88e6a0c2ddd26feeb64f039a2c41296fcb3f5640000000000000000000000000"]}}'
Response Example
{
"chain_id": 1,
"dataset_id": "0204",
"is_reorg": false,
"data": {
"pool_uid": "88e6a0c2ddd26feeb64f039a2c41296fcb3f5640000000000000000000000000",
"block_number": 19001234,
"block_time": "2025-12-20T12:34:56Z",
"total_fee": "0.003000000000000000",
"user_fee": "0.003000000000000000",
"protocol_fee": "0.000000000000000000",
"extra_fee": "0.000000000000000000",
"_tracing_id": "0204c0ffee0000000000000000000000000000000000000000000000000001",
"_created_at": "2025-12-20T12:35:01Z"
}
}