Installation
Get started by installing the SDK.
Installation & Setup
Weave is published as a zero-dependency TypeScript package compatible with Node.js 18+, Deno, and Bun.
Package Installation
Install Weave alongside zod using your package manager of choice:
pnpm add Weave zodnpm install Weave zodyarn add Weave zodbun add Weave zodEnvironment Credentials
Configure your API secret keys in your backend environment:
# OpenAI Provider Key
OPENAI_API_KEY="sk-proj-..."
# Anthropic Claude Provider Key
ANTHROPIC_API_KEY="sk-ant-..."
# Google Gemini Provider Key
GEMINI_API_KEY="AIzaSy..."TypeScript Configuration
Ensure your tsconfig.json targets ES2022 or higher with strict type checks enabled:
{
"compilerOptions": {
"target": "ES2022",
"module": "NodeNext",
"moduleResolution": "NodeNext",
"strict": true,
"esModuleInterop": true,
"skipLibCheck": true
}
}