S2
S2 is a serverless API for durable, real-time data streams with SDKs, a CLI, and a self-hostable open-source server.
At a Glance
About S2
S2 is a serverless datastore for real-time, streaming data, built by Bandar Systems Inc. Applications append records to named streams and read or tail them over a REST API, a CLI, or SDKs in TypeScript, Python, Go and Rust. An open-source, self-hostable server called s2-lite implements the same API.
What It Is
S2 treats streams as a cloud storage primitive. The homepage describes it as to moving data what object storage is to static data. Each stream is addressed by a URL: a POST appends records and a GET reads from a sequence number, then tails new records over server-sent events. Records are defined by the user, so the same primitive can carry telemetry, agent messages, events, or state changes.
Use Cases
The site lists telemetry, agent I/O, event history, agent write-ahead logs, and app sync as production uses. These cover live and historical access to workload telemetry, messages that survive sleeps and dropped connections, replay of captured events, crash recovery by replaying logged state, and keeping clients and services applying the same sequence of changes.
Self-Hosting with s2-lite
s2-lite is embedded in the CLI as the s2 lite subcommand. It is a single-node binary that uses SlateDB and object storage such as AWS S3 or Tigris for durability. It can also run in-memory as an emulator for integration tests, or persist to a local directory. It can be deployed with Docker or a Helm chart for Kubernetes, and exposes /health and Prometheus-format /metrics. The access-tokens endpoint is not yet supported in s2-lite.
Performance Tooling
The s2 bench command measures acknowledgement and end-to-end latency and throughput against a basin. The homepage states same-region end-to-end p99 latency under 50 ms, up to 100 MiBps write throughput per stream, and unlimited streams with bottomless storage per stream.
Community Discussions
Be the first to start a conversation about S2
Share your experience with S2, ask questions, or help others learn from your insights.
Pricing
s2-lite (self-hosted, MIT)
Open source, self-hostable server implementation of the S2 API, licensed under MIT.
- Self-hostable single-node binary
- Runs in-memory, on local disk, or on S3-compatible object storage
- Does not support /access-tokens and /metrics endpoints
- MIT License
Usage-based
Metered pricing for the S2 cloud service across storage, transfers and operations; includes 99.99% availability SLO and support.
- Storage: $0.05 per GiB retained / mo
- Basin: $0.01 / mo
- 1000 streams: $0.01 / mo
- 1000 access tokens: $0.01 / mo
- Metered hourly and pro-rated assuming 730 hours in a month
- Writes Standard: $0.050 / GiB
- Writes Express: $0.075 / GiB
- Reads Private: $0.050 / GiB
- Reads Internet: $0.100 / GiB
- Stream ops (append, read, check-tail): $0.001 / 1000 ops
- Basin ops: $0.010 / 1000 ops
- Account ops: $0.100 / 1000 ops
- 99.99% availability SLO
- SOC 2 report, GDPR DPA, and HIPAA BAA available
Capabilities
Key Features
- Append and tail streams over REST with POST and GET
- Server-sent events for following new records
- SDKs for TypeScript, Python, Go and Rust
- Command-line interface with built-in benchmarking (s2 bench)
- Self-hostable s2-lite server backed by SlateDB and object storage
- In-memory mode for use as an S2 emulator in tests
- Helm chart for Kubernetes deployment
- Health and Prometheus metrics endpoints in s2-lite
- OpenAPI and Protobuf specifications
- Web playground and dashboard
