Beta sign in

Live streams

Updated 2026-11-14.

Status: on (beta). Live sources in work on every plan within its caps. Live streams out are part of Builder and Pro; Stripe Checkout is not open yet during the invite beta, so until it opens, streams out are enabled per workspace on request. If an operator turns the ASIPIPES_STREAMING flag off, the /v1/streams endpoints answer 404 not_found and the stream MCP tools are not listed.

Streaming has two halves:

Live sources in

Add a stream section to the pipe file and make the first step stream_items:

pipes: 0
name: release-stream
version: 0.1.0
permissions:
  network:
    - https://events.example.com
stream:
  source: sse                 # sse | websocket | poll
  url: https://events.example.com/feed
  events: [release]           # SSE only: event names to keep (default: all)
  batch_max_items: 25         # run the pipe when this many items are waiting...
  batch_max_ms: 2000          # ...or when the oldest has waited this long
  buffer_max: 200             # items held while a batch runs
  overflow: drop_oldest       # drop_oldest | drop_newest | sample
steps:
  - id: items
    block: stream_items
  - id: new
    block: diff_since_last
    in: ${steps.items}
    with:
      key: [id]
  - id: hook
    block: emit_webhook
    in: ${steps.new}
    with:
      url: https://hooks.example.com/new
      skip_if_empty: true
output: ${steps.new}

Then start it with POST /v1/streams ({"pipe": "release-stream"}) or the MCP tool start_stream. GET /v1/streams and list_streams show each stream's status, counters (items in and out, batches, dropped, reconnects), and your caps. DELETE /v1/streams/{pipe} or stop_stream stops it. Deleting the pipe stops its stream.

Sources:

Other options: event_time_path (a dotted path to the item's own event time, used for metrics; by default meta.dt, timestamp, published, dt, time, created_at, or updated is used when present), headers (up to 20; use ${env.NAME} for secrets listed under permissions.env), item_path (a dotted path to the record inside each message), max_item_bytes (default 16384, up to 262144), and idle_timeout_s (reconnect when the source goes quiet; default 300).

What a batch is

Items are micro-batched by count and time, and each batch is one ordinary pipe run with mode stream:

Limits and overload

Current caps (beta; GET /v1/billing → streaming.plans always has the live values):

Plan Concurrent streams Items per minute, per stream Workspace total per minute Subscribers (streams out)
Free 1 60 60 0
Builder 3 300 900 3
Pro 10 1,200 12,000 10

An operator can grant a workspace different stream caps; caps then reports the granted values.

Live streams out (paid)

GET /v1/streams/{pipe} with Authorization: Bearer pk_live_… and Accept: text/event-stream opens an SSE stream of the pipe's new output items:

retry: 3000

event: ready
data: {"access":"plan:builder","docs":"https://asipipes.com/docs/streaming","heartbeat_ms":15000,"max_seconds":3600,"pipe":"release-stream","resumed_from":null}

id: 1763139600123456
event: item
data: {"at":"2026-11-14T17:00:00Z","dropped":0,"id":"1763139600123456","item":{"_change":"added","id":42,"title":"v2.1.0"},"mode":"stream","pipe":"release-stream","receipt":"b3:…","run_id":"run_…"}

: ping

Who can subscribe: workspaces on Builder or Pro. Each plan has a cap on concurrent subscribers per workspace. A Free workspace gets HTTP 402 with JSON {"error":"payment_required","status":402,"message":"Live streams out are a paid feature. Upgrade to Builder or Pro …","docs":"https://asipipes.com/docs/streaming","billing":"https://asipipes.com/v1/billing"}, on both GET /v1/streams/{pipe} and /events. Over the subscriber cap the answer is 429 quota_exceeded with Retry-After. When x402 is on (Base Sepolia testnet only), the 402 also carries a PAYMENT-REQUIRED header, and a retry with PAYMENT-SIGNATURE buys one stream session; see /docs/x402.

Over MCP

/mcp stays JSON for every client. A paid caller that sends Accept: application/json, text/event-stream gets an SSE response for two calls:

Without that Accept header, or for an unpaid workspace, the same calls return JSON exactly as before. watch_stream over JSON returns the buffered items since last_event_id.

Stream tools: start_stream, list_streams, stop_stream, watch_stream, stream_metrics.

Keys and errors

Every /v1/streams call and /mcp needs Authorization: Bearer pk_live_…. A missing or unknown key is 401 unauthorized. If the server briefly can't read the key store, the answer is 503 {"error":"unavailable","message":"…your key was not rejected."} with Retry-After: 2; retry, the key is fine. While streaming is off on the server, /v1/streams* answers 404 not_found. A key may make 60 API requests a minute (429 past that).

Metrics

GET /v1/streams/{pipe}/metrics?hours=24 (1 to 168, default 24) and the MCP tool stream_metrics return hours, one object per hour for your stream (the current hour live, earlier hours from storage; kept for 7 days by default):

Percentiles are nearest-rank over a uniform sample of at most 512 values per hour. SSE and webhook latencies start at the earliest item of the batch, so they are an upper bound for the rest of that batch. A resumed backlog is not counted as SSE latency.

Numbers

Measured on the Asipipes test suite (Erlang/OTP 27): an idle SSE source costs about 6 KB for its process plus a 16 KB socket buffer. These are engineering measurements, not a service guarantee, and plan caps are listed in GET /v1/streams and GET /v1/billing. The 92% fewer tokens, 99.4% fewer when nothing is new, and exact replayable output figures are the measured checks on /benchmarks. This page does not invent other stats.