Skip to content

OpenAI Agents SDK (TypeScript)

Production-ready TypeScript SDK with the same minimal primitives as the Python version, plus first-class browser support, HITL approval flows, and Express streaming.

Install

Terminal window
npm install @openai/agents

Version

v0.8.5 · April 2026 · Node 18+

Best for

Full-stack agents, HITL-approved workflows, browser-side tools.

  • HITL approval flows for tool calls in browser clients.
  • Browser support improvements with tree-shaken bundles.
  • Zod v4 support across all structured-output helpers.
import { Agent, run } from '@openai/agents';
const agent = new Agent({
name: 'Assistant',
instructions: 'You are a helpful assistant.',
});
const result = await run(agent, 'What is 2 + 2?');
console.log(result.finalOutput);

Ready? Start Zero → Hero Step 1 →


DateVersionChanges
2026-04-210.8.5Banner bumped to installed version 0.8.5.
April 9, 20260.8.3HITL approval flows; browser bundle improvements; Zod v4.
November 20250.3.2Initial TypeScript guide; Swarm migration; MCP.

Note: Python implementation lives at OpenAI Agents SDK (Python).