API Reference
The reference is generated from the public TypeScript entry points on every documentation build. Choose a package below, or jump directly to one of the most commonly used APIs.
Packages
| Package | Reference | Purpose |
|---|---|---|
@lsync/definitions | Browse definitions | Shared collection schemas, keys, child collections, and API contracts. |
@lsync/server | Browse server APIs | Durable Object storage, synchronization, access control, and Worker handlers. |
@lsync/server/client | Browse shared client types | Shared contracts for custom clients and server integrations. |
@lsync/client | Browse client APIs | TanStack DB collection adapters, subscriptions, and typed API methods. |
@lsync/transport | Browse transport APIs | Wire contracts, message schemas, and serializable read expressions. |
Common Entry Points
| API | Package | Use |
|---|---|---|
defineCollections() | @lsync/definitions | Define a shared collection and API contract. |
CollectionShardDurableObject | @lsync/server | Host collection storage, history, subscriptions, and APIs. |
createWorkerHandler() | @lsync/server | Route Worker requests to the correct Durable Object. |
collectionTypesFrom() | @lsync/client | Create typed TanStack DB collection managers from the shared definition. |
eq() | @lsync/server | Build serializable read and access expressions. |
apiCallSchema | @lsync/transport | Validate API-call messages at the transport boundary. |
The generated reference has its own package navigation and symbol search. Return to this page when you want the public package overview.