@dawn-ai/sdk
v0.8.26
Published
Author-facing TypeScript SDK for defining Dawn agents, tools, middleware, memory, and routes.
Maintainers
Readme
@dawn-ai/sdk
Author-facing TypeScript declarations for Dawn agents, tools, middleware, memory, routes, and typed runtime contracts.
Use this when: You are authoring routes, tools, middleware, memory declarations, or typed runtime contracts.
Install
Requires Node.js 24 or later.
pnpm add @dawn-ai/sdkAdd zod when declaring typed long-term memory:
pnpm add zodExample
Define a minimal agent route:
// src/app/support/index.ts
import { agent } from "@dawn-ai/sdk"
export default agent({
model: "gpt-5-mini",
systemPrompt: "Answer support questions clearly and concisely.",
})The same package provides adjacent memory and middleware declarations:
// src/app/support/memory.ts
import { defineMemory } from "@dawn-ai/sdk"
import { z } from "zod"
export default defineMemory({
kind: "semantic",
scope: ["workspace", "route"],
schema: z.object({
subject: z.string(),
predicate: z.string(),
value: z.string(),
}),
})// src/middleware.ts
import { defineMiddleware } from "@dawn-ai/sdk"
export default defineMiddleware(() => ({ action: "continue" }))Runtime and stability
@dawn-ai/sdkis the supported, edge-safe application surface.@dawn-ai/sdk/pureis a supported, dependency-free edge-safe integration surface.@dawn-ai/sdk/testingis a supported Node-only scenario-authoring surface. It is separate from@dawn-ai/testing.
Related
@dawn-ai/clidevelops, tests, builds, and serves routes declared with the SDK.@dawn-ai/testingprovides programmatic harnesses for Dawn applications.- SDK API reference
- Agents
- Tools
- Middleware
- Memory
- Scenario testing
Maturity and support
Dawn is pre-1.0, and its public surface can change. All publishable Dawn packages release together as a fixed group; review the @dawn-ai/sdk changelog and upgrading guide before upgrading. For support, use GitHub Discussions; report defects in GitHub Issues.
License
MIT. See the repository license.
