Ogmios Websocket API
Last updated
Was this helpful?
The Ogmios WebSocket interface carries the same JSON-RPC 2.0 protocol as the HTTP interface, over a persistent connection. It is required for the stateful Ouroboros mini-protocols, which hold session state across messages: chain synchronization, ledger-state acquisition, and mempool monitoring. The stateless queries documented under the JSON-RPC API also work over this connection.
wss://go.getblock.io/<ACCESS-TOKEN>/Replace <ACCESS-TOKEN> with the access token from the GetBlock dashboard. Open a WebSocket to this URL and exchange JSON-RPC 2.0 messages.
Find a starting point on the node's chain, then stream forward blocks and backward rollbacks.
findIntersection
Find a chain intersection point
nextBlock
Stream the next block or a rollback
Pin a fixed ledger point so a batch of state queries is answered consistently.
acquireLedgerState
Acquire a fixed ledger state
releaseLedgerState
Release the acquired ledger state
Acquire a mempool snapshot, then list and inspect pending transactions.
acquireMempool
Acquire a mempool snapshot
nextTransaction
Read the next mempool transaction
hasTransaction
Check if a transaction is in the mempool
sizeOfMempool
Read mempool size and capacity
releaseMempool
Release the mempool snapshot
For technical support and questions:
Support: support@getblock.io
Last updated
Was this helpful?
Was this helpful?