Skip to content

What is Lenso?

Build TypeScript applications from ordinary async services, explicit plugin instances and adapters you choose.

Lenso is a Bun-first TypeScript application framework. A plugin declares how a service starts, which exact other instances it needs, and how its owned resources stop. Business methods remain ordinary async functions. The same service can serve application code, an explicit CLI operation, a Fetch entry or an authorized agent tool.

Start with one service

Quickstart installs the published Core package and runs an application without a server or database. It introduces three objects: a plugin declaration, an application assembly and a running application.

Your taskRead next
Connect services and release resourcesComposition, lifecycle
Configure a particular instanceConfiguration
Inspect or invoke declared operationsCLI
Add a browser/API entryWeb, native Fetch, React
Protect business objectsAuth
Expose selected management operationsManage
Persist Notes or produce reportsExisting examples
Select a hostDeployment

Keep three boundaries clear

Runtime. Core validates dependencies, initializes services and owns cleanup. The exact plugin object is the dependency key; a matching ID does not make another instance equivalent. Business policy belongs to the service.

Build-time Engine. Engine discovers trusted application declarations and extends generation, build and supervised development. Its conventions are replaceable through public extension interfaces. It has a separate lifetime from application setup.

Adapters. Web, Auth, DB, Storage, Tasks, Manage, MCP, logging and telemetry are optional. Installing one does not make every service remotely callable. Operations and identity remain explicit. Applications may use the underlying Fetch, Drizzle, Pino or OpenTelemetry APIs directly.

Know the documentation baseline

These guides use verified npm artifacts, audited against TypeScript source 549b987. Core, Engine and the principal adapters are 0.2.0; CLI is 0.19.0; DB and Storage are 0.1.1. Quickstart has been run with the actual @lenso/core@0.2.0 artifact. Configuration, Bun listener, Manage and Log/OTel entries are now published in this matrix.

Installation records exact versions and host boundaries. oRPC v2 still uses prerelease 2.0.0-beta.42; client and server must match. A source commit and an npm release are separate facts: both were checked for this baseline.

What the application owns

The application chooses its listener, deployment, secret authority, schemas, migrations, authentication provider and object/tenant policy. Cleanup releases resources; it does not reverse a committed write. An operation's effect metadata does not authorize execution. Optional Manage now selects existing instance-bound operations for explicit CLI, agent or oRPC entries. It borrows an existing running graph and requires trusted per-call binding and service authorization. A configuration center and built-in Observe query service are not provided.

The previous Rust/Host/Capability generation is archived. Its commands and contracts are not TypeScript APIs. Console and Relay are separate products.