eth_uninstallFilter
Uninstalls a filter with given ID. This method should always be called when watching is no longer needed. Additionally, filters time out when they aren't requested with eth_getFilterChanges
for a period of time.
Parameters
filter ID
: A string denoting the ID of the filter to be uninstalled.
Returns
uninstalled flag
: (boolean) true
if the filter was successfully uninstalled, otherwise false
.
Example
Replace YOUR-API-KEY
with an API key from your Infura dashboard.
Request
- cURL
- WSS
curl https://mainnet.infura.io/v3/YOUR-API-KEY \
-X POST \
-H "Content-Type: application/json" \
-d '{"jsonrpc":"2.0","method":"eth_uninstallFilter","params":["0x10ff0bfba9472c87932c56632eef8f5cc70910e8e71d"],"id":1}'
wscat -c wss://mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc":"2.0","method":"eth_uninstallFilter","params":["0x10ff0bfba9472c87932c56632eef8f5cc70910e8e71d"],"id":1}'
Response
- JSON
{
"jsonrpc": "2.0",
"id": 1,
"result": true
}