PubSub JSON-RPC API
Methods to subscribe/unsubscribe to events and receive notifications on Validium Network.
Clients can subscribe to specific events and receive notifications, thus avoiding the need to poll. Validium Network is fully compatible with Geth's pubsub API, except for the syncing
subscription.
The WebSocket URL is wss://devnet.l2.rpc.validium.network/ws
eth_subscribe
eth_subscribe
Creates a new subscription for events.
Parameters
String - Name of the subscription. Valid names include "newHeads" for new block headers, "logs" for new log entries, and others depending on the client's capabilities.
Object - (Optional) Filter conditions for the subscription, applicable for subscriptions like "logs" where specific event criteria can be set.
Returns
DATA - A subscription ID used to identify and manage the subscription.
Example Request
Example Response
eth_unsubscribe
eth_unsubscribe
Cancels an existing subscription.
Parameters
DATA - The ID of the subscription to cancel, as returned by
eth_subscribe
.
Returns
Boolean - true
if the subscription was successfully cancelled, false
otherwise.
Example Request
Example Response
Last updated