Design notes for AI-led TypeScript systems

One container. One schema. Many agent-facing surfaces.

A short-form publication for the ideas behind AgentBack: dependency injection, Zod-first contracts, REST, MCP, errors agents can act on, and the architectural choices that keep it all coherent.

Latest posts

Notes from the framework boundary

These posts are repo-local, dependency-free HTML. They are meant to be easy to review in diffs and easy to publish from any static host.

A console for one container

A read-only dev console that renders the same DI container and Zod schemas your servers run on — bindings, five kinds of wiring edge, routes, tools, and the schema graph. It reads what runs, so it can't drift.

Read post

Building with an agent inside the framework

How the agentback-demo weather MCP server was built with Claude Code, commit by commit — and what the framework's constraints changed about the experience.

Read post

Introducing AgentBack

A TypeScript framework for agent-facing services: one Zod contract across REST, MCP, docs, typed clients, policy, and usage rails.

Read post

Charge agents per call

One @price decorator meters a route or MCP tool and gates it behind a payment rail — x402 today, Stripe metered billing from the same usage log.

Read post

Errors an agent can fix, operations an agent can't break

Stable codes, field-level issues, the violated schema, and a retry hint in every failure — plus confirmation tokens and idempotency keys for the calls that must not run twice.

Read post

Tools are not endpoints

Every tool definition is paid for in context-window tokens on every connection. Why @tool is opt-in, and how toolCostReport makes the bill visible.

Read post

Your API's first reader is an agent

/llms.txt and /llms-full.txt served from the same registry as /openapi.json, and an agent-context manual you can commit — derived contracts can't drift.

Read post

Boundary coherence is the product

Why AgentBack treats a Zod schema as the same artifact across runtime validation, TypeScript, OpenAPI, MCP, and docs.

Read post

One container, two surfaces

The practical shape of a hybrid REST + MCP app, and why discovery by tag keeps feature work local.

Read post

Contract-first clients without codegen

How shared schemas let TypeScript clients stay typed and runtime-validated without importing a running server.

Read post