Streams
Subscribe to chain activity with filters. Replay from a past checkpoint, then continue live with no gap.
Topics and filters
| Topic | Filters |
|---|---|
| transactions | accounts (any of), accountsRequired (all of), coinTypes, eventTypes, packages, objectIds, balanceAddresses, types (transaction type), status |
| events | eventTypes (prefix match), packages, senders |
| checkpoints | none. pending=true adds each checkpoint before it is certified, marked pending: true |
| balances | accounts or balanceAddresses, coinTypes |
| objects | objectIds, types |
Sui filters
These four work on SSE query parameters, on WebSocket subscribe params and on webhooks, with the same names. Entries in one list are OR, different filters are AND. Each list takes up to 100 entries on Free and 1,000 on paid plans. They match live and in replay.
| Filter | Matches |
|---|---|
| objectIds | Any change to these objects: created, mutated, deleted, wrapped or unwrapped. System transactions count, so 0x6 (the Clock) fires every checkpoint. The objects topic delivers one item per change with version and kind; other topics carry matched.objects. |
| eventTypes | Move event types. Give a full type with or without type parameters, a module prefix (0xpackage::module) or a package prefix (0xpackage). Use the package that defines the type, which is its original id. |
| packages | Transactions whose PTB called a function of these packages. Narrow with 0xpackage::module or 0xpackage::module::function. Pass the original package id and every upgraded version matches. Items carry matched.calls. |
| balanceAddresses | A balance change of these addresses, narrowed to the same change when coinTypes is set. Items carry matched.balances with the signed delta in the coin's smallest unit; the balances topic adds a delta field. |
curl -N "https://api.tide.ad/v1/stream?objectIds=0x6&view=raw" -H "x-api-key: YOUR_API_KEY"
curl -N "https://api.tide.ad/v1/stream?packages=0x2c8d603bc51326b8c13cef9dd07031a408a48dddb541963357661df5d3204809::pool" -H "x-api-key: YOUR_API_KEY"Views
| view | You get |
|---|---|
| ids | digest, checkpoint and txIndex only |
| raw | The transaction as the node sees it |
| enhanced | The parsed transaction, the same shape as /v0/transactions. Default for webhooks. |
Replay
Pass fromCheckpoint and the server replays from the index in order, then joins the live tail at a checkpoint boundary, with no gap and no duplicate. Your plan sets how far back you can start: 7 days on Free, 90 days on Developer, since genesis on Business and above. GET /v0/stream/replay-info returns the earliest checkpoint you may use. Replay runs at up to 50,000 checkpoints a minute.
Every message carries a cursor of the form checkpoint:txIndex (events add an event index). To resume after a drop, reconnect with fromCheckpoint, or on SSE send the Last-Event-ID header. Messages are ordered by checkpoint and transaction index and deduplicated by digest.
WebSocket
Connect to wss://api.tide.ad/ with your key. Subscribe with JSON-RPC. Each topic has its own method and an unsubscribe.
| Subscribe | Unsubscribe |
|---|---|
| transactionSubscribe | transactionUnsubscribe |
| eventSubscribe | eventUnsubscribe |
| checkpointSubscribe | checkpointUnsubscribe |
| balanceSubscribe | balanceUnsubscribe |
| objectSubscribe | objectUnsubscribe |
const ws = new WebSocket("wss://api.tide.ad/?api-key=YOUR_API_KEY");
ws.onopen = () =>
ws.send(
JSON.stringify({
jsonrpc: "2.0",
id: 1,
method: "transactionSubscribe",
params: [{ accounts: ["0xYOUR_ADDRESS"] }, { view: "enhanced", fromCheckpoint: 123456789 }],
}),
);
ws.onmessage = (e) => console.log(JSON.parse(e.data));SSE
curl -N "https://api.tide.ad/v1/stream?topic=transactions&accounts=0xYOUR_ADDRESS&view=enhanced&api-key=YOUR_API_KEY"The server sends a heartbeat every 15 seconds so proxies keep the connection open.
Credits
One credit per 10 events delivered. Replayed events count the same. Opening a stream is limited by your plan's concurrent streams. Streams need a key.
| Method | What it does | Credits |
|---|---|---|
| stream.sseGET /v1/stream | Server-sent events for transactions, events, checkpoints, balances or objects, with replay from any checkpoint. | Free |
| stream.wsGET /ws | WebSocket subscriptions (JSON-RPC) for the same topics and filters as /v1/stream. | Free |
| stream.replayInfoGET /v0/stream/replay-info | The earliest checkpoint your plan can replay from, and what the index covers. | Free |