btcintel

Live updates (server-sent events)

GET /v1/stream
who may call it
Anyone
A User-Agent that claims a search or AI crawler is refused with 403.
what it costs
1 request of the quota
Counted once, when the stream opens; its events are not counted. How many streams a caller holds at once is capped by tier. · tiers and keys
how fresh
Never cached
every answer carries the index's height and the node's
MCP tool
None
On this page

One server-sent event stream of the tip, the mempool, the projection, the fees and the state of up to 16 transactions, from the mempool engine. Each event's data is one JSON object (the Stream* schemas) whose at is when the engine applied the change.

  • The stream opens with retry: 3000 and one snapshot per topic and per transaction whose state is known.
  • Then block, mempool, projected and fees (each only when it changed, at most one per reprojection) and tx.
  • Every event has an id of <boot>-<seq>. There is no replay: Last-Event-ID is ignored and a reconnect gets a fresh snapshot.
  • A comment line goes out every 15 s. The stream closes after six hours, or once the client falls 16 events behind, and the client reconnects.
  • Concurrent streams per caller: t0 2, t1 4, t2 and t3 10, t4 50, under a server-wide cap. Opening a stream counts as one request of the quota; events do not.
  • The stream is for browsers and for agents with a key: a request whose User-Agent claims a search or AI crawler is refused with 403 forbidden; a crawler reads the page.

Parameters

NameWhereTypeRequiredWhat it does
topicsquerystringoptionalComma-separated: block, mempool, projected, fees. A stream needs topics or tx (400 otherwise).
txquerystringoptionalUp to 16 comma-separated txids.

What it answers

200 · text/event-stream

The stream. Events: snapshot (StreamSnapshot), block (StreamBlockEvent), mempool (StreamMempoolEvent), projected (StreamProjectedEvent), fees (StreamFeesEvent), tx (StreamTxEvent).

Headers: Cache-Control, X-Accel-Buffering

schema

array of one of — The stream as a sequence of events; each item is one event's data, named by its event: line.

Absent and empty

The caseIn the answer
A transaction asked for that the engine does not know: never seen, or in a block before the stream opened.No snapshot for it; read GET /v1/tx/{txid}.

Errors

StatusCodeWhen
400invalid_inputMalformed input (invalid_input).
403forbiddenforbidden: the User-Agent claims a search or AI crawler; the stream is for browsers and for agents with a key.
429quota_exceededquota_exceeded: the caller or the server holds as many streams as allowed (Retry-After: 30), or the caller's request quota ran out.
501not_configurednot_configured: the mempool engine is not enabled (BITCOIN_ZMQ_SEQUENCE unset), or the stream is off (STREAM_MAX_CLIENTS=0).
503index_unavailableindex_unavailable: the mempool engine is bootstrapping; retry shortly.

Each comes in the one error envelope, and none is cached: an error carries Cache-Control: no-store.

Example

curl alone: -N prints each event as it arrives. Stop it with Ctrl-C.

curl -sN 'https://api.btcintel.io/v1/stream?topics=block,fees'