Skip to main content

Requirements

  • Node.js 18 or higher
  • Agent Diff backend running (locally or remote)

Installation

Configuration

Self-Hosted (Local)

Agent Diff Cloud (Hosted)

For the hosted version at api.agentdiff.dev:
Sign up at agentdiff.dev to get your API key for the hosted version.

Custom Self-Hosted URL

With API Key (Self-Hosted)

Environment Variables

You can also configure via environment variables:

Configuration Priority

The SDK resolves configuration in this order:
  1. Explicit parameters passed to new AgentDiff()
  2. Environment variables (AGENT_DIFF_BASE_URL, AGENT_DIFF_API_KEY)
  3. Defaults (http://localhost:8000, no API key)

Verify Installation

TypeScript Types

The SDK exports all types:

Next Steps

Basic Usage

Learn the core SDK operations

Vercel AI SDK

Integrate with Vercel AI SDK