Features
Everything you need. Nothing you don't.
Silkweave is small on purpose, but the things you actually need to ship a real server are built in - validation, auth, context, streaming, and docs - and they work the same across every transport because they live in the action layer, not the adapter.
Schemas and types, from one declaration
Inputs and outputs are Zod schemas, so a single declaration gives you runtime validation, static type inference, and generated documentation. There is no second source of truth to keep in sync.
- Zod-powered schemas
Validation, type inference, and docs from one input/output declaration per action.
Actions → - Typed context, no globals
A fluent
Context →.set()API hands each action a typed bag - logger, auth, request - with no module singletons. - Build-time type generation
Emit
Typegen →.d.tsinterfaces from your Zod schemas at build time. Zero runtime cost.
Authentication, built in
@silkweave/auth ships a full OAuth 2.1 proxy - PKCE, refresh tokens,
dynamic client registration, and protected resource metadata (RFC 9728) - plus simple bearer-token
validation when that is all you need. It is the same auth layer across MCP HTTP, REST, and tRPC.
Auth lives in the action/context layer, so a guard you write once applies the same way whether a request arrives over REST, tRPC, or an MCP tool call. See authentication.
Streaming and AI
- Streaming actions
Yield chunks from an async generator; each adapter delivers them as MCP progress, SSE, NDJSON, or tRPC subscriptions.
Streaming → - Vercel AI SDK native
AI SDK →useChatwired straight to a streaming action over tRPC - typedUIMessageChunks, no Data Stream Protocol.
Deploy anywhere
- CLI with prompts
The same actions as a command-line tool with interactive Clack prompts.
CLI → - Serverless & edge
Stateless MCP on Web Standard APIs - Vercel, Cloudflare Workers, or Bun.
Edge adapter → - Auto-generated Swagger
The Fastify adapter emits OpenAPI specs and an interactive Swagger UI for free.
REST adapter →