Major release of the OnDB TypeScript SDK and backend platform, delivering a complete data infrastructure for building agentic applications.New features
-
Model API — A typed, declarative interface for structured reads and writes. Use
db.model<T>(collection) to get findMany, findFirst, findUnique, create, createMany, updateDocument, deleteDocument, count, and aggregate methods with full TypeScript support. Learn more
-
Server-side JOINs — Execute
joinOne and joinMany operations on the backend in a single request. Supports nested JOINs and parent-field references with $data.fieldname. Learn more
-
SQL interface — Query and insert data using SQL syntax via
db.sql() and db.sqlInsert(). Learn more
-
Predefined queries — Create named, parameterized queries that execute publicly without authentication. Ideal for building custom API endpoints. Learn more
-
Materialized views — Define views over collections using JSON queries or SQL. Supports
live (auto-refresh on write) and lazy (manual refresh) modes. Learn more
-
Collection sharding — Partition large collections across shards using discrete, time-range, or hash-distributed strategies. Shard-aware query routing prunes irrelevant shards automatically. Learn more
-
Agent Keys — Keys with
Pay permission can pay other apps inline using USDC via EIP-3009. Configure spend limits, expiration, and target app whitelists. Learn more
-
Multi-chain payments — Pay for reads and writes across Celestia (TIA), EVM chains (Base, Ethereum, Polygon, Avalanche via USDC), and Solana using the x402 protocol. Learn more
-
MCP server — Built-in Model Context Protocol server exposes your predefined queries as discoverable AI tools, with HTTP and stdio transports. Learn more
-
Data retention policies — Configure per-collection retention with the first 30 days free. Monitor costs across all collections. Learn more
-
Blob storage — Upload and retrieve binary files on-chain with metadata and task tracking. Learn more
Updates
-
Rebrand to OnDB — All SDK classes renamed from
OnChainDB* to OnDB* (e.g., OnDBClient, OnDBConfig, OnDBError).
-
Currency-agnostic pricing —
X402Quote.totalCostTia renamed to totalCost to reflect multi-currency support (USDC, TIA, ETH, SOL).
-
Flexible payment routing — The SDK now matches the payment network returned by your callback instead of defaulting to the first option. You can choose any payment option the backend offers.
-
Batch operations — Store multiple records in a single request with retry strategies for partial failures. Learn more
-
Price index — Collections can define price fields with per-KB, per-record, or field-value pricing models with configurable revenue splits. Learn more
-
Query builder operators — Full set of field operators including string matching, IP classification, GeoIP, CIDR range, regex, and keyword search. Learn more
-
Server-side aggregations —
count, sum, avg, min, max, distinctBy, and groupBy execute on the backend. Learn more