Subscribe Collections
Subscribe to blockchain events
Last updated
Was this helpful?
Subscribe to blockchain events
Last updated
Was this helpful?
You can create a websocket subscription for any event in the blockchain.
Read filter syntax and collections documentation .
In this example, we start a subscription and get a result whenever a new block is generated.
The filter
and result
parameters are the same as in the query
method. The filter
parameter narrows the action down to a subset of monitored items. In this case, the filter is empty: all items are included into monitoring.