curl 'https://stream.tonbo.dev/ds/demo/hello/bootstrap'
Bootstrap & Snapshots
Bootstrap
Recover full stream state from snapshot plus retained updates in a single request.
GET
/
ds
/
{bucket}
/
{stream}
/
bootstrap
curl 'https://stream.tonbo.dev/ds/demo/hello/bootstrap'
Returns the stream’s latest snapshot (if any) plus all retained updates after the snapshot offset, packed as a
Response headers include:
multipart/mixed response. This is the recommended way to initialize a client that needs the complete current state of a stream.
string
required
Bucket ID.
string
required
Stream ID within the bucket.
Response
| Status | Meaning |
|---|---|
200 | Bootstrap response with snapshot and updates. |
400 | Invalid query parameters. |
404 | Stream not found or expired. |
410 | Requested offset has been trimmed. |
| Header | Description |
|---|---|
Content-Type | multipart/mixed; boundary=... |
Stream-Next-Offset | The offset after the last included update. |
Stream-Snapshot-Offset | The snapshot offset (or none if no snapshot exists). |
Stream-Up-To-Date | true if the response includes all data up to the tail. |
Stream-Closed | Present and true if the stream is closed and fully caught up. |
Response body
The body is amultipart/mixed message:
1
Snapshot part
The first part is the snapshot blob (or an empty part if no snapshot exists).
2
Update parts
Subsequent parts are individual update messages appended after the snapshot offset. For JSON streams, each update is a separate
application/json part.curl 'https://stream.tonbo.dev/ds/demo/hello/bootstrap'
After bootstrapping, switch to SSE reads with
live=sse starting from the Stream-Next-Offset to receive real-time updates.
