eth_newFilter - Boba Network RPC Method
Create event log filter on Boba Network. Essential for monitoring events for AI-powered dApps, Web2 API integration, enterprise blockchain solutions, and offchain computation.
Creates a filter object on Boba Network to notify when state changes (logs).
Use Cases
- Event monitoring - Subscribe to contract events
- Real-time updates - Track events for AI-powered dApps, Web2 API integration, enterprise blockchain solutions, and offchain computation
- Indexing - Build event indexes incrementally
Request Parameters
Starting block
Ending block
Contract address(es)
Topic filters
Response Body
Filter ID
Code Examples
curl -X POST https://api-boba-mainnet.n.dwellir.com/YOUR_API_KEY \
-H "Content-Type: application/json" \
-d '{
"jsonrpc": "2.0",
"method": "eth_newFilter",
"params": [{
"fromBlock": "latest",
"address": "0xDeadDeAddeAddEAddeadDEaDDEAdDeaDDeAD0000"
}],
"id": 1
}'import { JsonRpcProvider } from 'ethers';
const provider = new JsonRpcProvider('https://api-boba-mainnet.n.dwellir.com/YOUR_API_KEY');
// Create filter
const filterId = await provider.send('eth_newFilter', [{
fromBlock: 'latest',
address: '0xDeadDeAddeAddEAddeadDEaDDEAdDeaDDeAD0000',
topics: ['0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef']
}]);
// Poll for changes
const changes = await provider.send('eth_getFilterChanges', [filterId]);
console.log('New events:', changes);
// Cleanup
await provider.send('eth_uninstallFilter', [filterId]);Related Methods
eth_getFilterChanges- Poll filter for changeseth_uninstallFilter- Remove filtereth_getLogs- Direct log query
eth_getLogs
Query event logs on Boba Network. Essential for indexing AI-powered dApps, Web2 API integration, enterprise blockchain solutions, and offchain computation on the Hybrid Compute L2 enabling smart contracts to access AI models and Web2 APIs natively.
eth_getFilterChanges
Poll filter for new events on Boba Network. Essential for event monitoring for AI-powered dApps, Web2 API integration, enterprise blockchain solutions, and offchain computation.