L0vdL0vd

net_listening

Returns true if the node is listening for peer connections.

curl https://eth.l0vdinfra.com/YOUR_KEY \
  -X POST \
  -H "Content-Type: application/json" \
  --data '{"jsonrpc":"2.0","id":1,"method":"net_listening","params":[]}'

Example response

{
  "jsonrpc": "2.0",
  "id": 1,
  "result": true
}
Params and your endpoint

Parameters

This method takes no parameters.

Returns

boolean Listening state.

When to use it

Check that the node accepts peer connections; a basic liveness signal.

How to read the result

true or false.

Tips

  • For application health checks eth_blockNumber is more useful: it also shows the node is moving.

Related methods