Ad space · Your tool here
PluginStack
Agent Frameworks · by OpenAI

OpenAI Agents SDK

OpenAI Agents SDK official site ↗

Last checked against the official docs:

What it does

OpenAI's lightweight, open-source framework for building agents and multi-agent workflows, in Python (openai-agents) and JavaScript/TypeScript (@openai/agents). It covers agents with tools (functions, MCP servers, hosted tools), handoffs, guardrails, human-in-the-loop, sessions, tracing, sandbox agents and realtime/voice agents. Per the README it is provider-agnostic: it supports the OpenAI Responses and Chat Completions APIs and 100+ other LLMs. MIT licensed.

Agents SDK vs the OpenAI SDK

People often search for "OpenAI SDK" and mean one of two things. The openai package is OpenAI's general API client. The OpenAI Agents SDK is a separate package (openai-agents for Python, @openai/agents for JavaScript/TypeScript) that adds the agent loop, handoffs, guardrails, sessions and tracing on top of model calls.

The Agents SDK docs include a section on when to use the Agents SDK and when to call the Responses API directly. A single model call with no tools or handoffs doesn't need an agent framework.

JavaScript / TypeScript version

There is a separate repository, openai/openai-agents-js. Its README lists Node.js 22 or later, Deno and Bun as supported environments, with Cloudflare Workers (nodejs_compat enabled) as experimental.

bash
npm install @openai/agents zod

Who it's for

Python developers building their own agents who want a small, well-documented framework.

How to set it up

  1. Needs Python 3.10 or newer. Install:

    bash
    python -m venv .venv
    source .venv/bin/activate
    pip install openai-agents
  2. Or with uv:

    bash
    uv init
    uv add openai-agents
  3. Set OPENAI_API_KEY and run a first agent:

    text
    from agents import Agent, Runner
    
    agent = Agent(name="Assistant", instructions="You are a helpful assistant")
    result = Runner.run_sync(agent, "Write a haiku about recursion in programming.")
    print(result.final_output)
  4. JavaScript/TypeScript equivalent of the first agent (after npm install @openai/agents zod):

    text
    import { Agent, run } from '@openai/agents';
    
    const agent = new Agent({
      name: 'Assistant',
      instructions: 'You are a helpful assistant.',
    });
    const result = await run(agent, 'Write a haiku about recursion in programming.');
    console.log(result.finalOutput);
  5. Optional Python extras: pip install 'openai-agents[voice]' for voice pipelines and pip install 'openai-agents[redis]' for Redis-backed sessions. Docs: openai.github.io/openai-agents-python.

Check the official OpenAI Agents SDK docs for the latest steps.

Set it up / Fixes

Step-by-step guides for getting OpenAI Agents SDK running and fixing common errors.

Frequently asked questions

What is the OpenAI Agents SDK?

An open-source framework from OpenAI for building agents and multi-agent workflows. An agent is a model configured with instructions, tools, guardrails and handoffs, and the SDK runs the loop that calls tools and passes work between agents.

How do I install the OpenAI Agents SDK?

For Python 3.10 or newer, run pip install openai-agents (or uv add openai-agents) and set OPENAI_API_KEY. For JavaScript/TypeScript, run npm install @openai/agents zod.

Does it only work with OpenAI models?

No. The README describes it as provider-agnostic: it supports the OpenAI Responses and Chat Completions APIs and 100+ other LLMs. You still need credentials for whichever provider you use.

Can agents use MCP servers?

Yes. The README lists MCP among the tool types, next to function tools and hosted tools.

Is it the same as the openai package?

No. The openai package is the general API client. The Agents SDK is a separate package built for agent workflows.

Is it free?

The SDK is MIT licensed and free to use. Model calls to OpenAI or another provider are billed by that provider.

Example prompts

prompt
Build a triage agent with the OpenAI Agents SDK that hands off to a billing agent or a support agent.
prompt
Add an input guardrail that blocks requests unrelated to our product.
prompt
Connect my agent to a local MCP server and list the tools it can see.

Demo

Official demo by OpenAI on YouTube: “Build Hour: Agents SDK”

Made OpenAI Agents SDK? Add the badge

If you like, show that OpenAI Agents SDK is listed and hand-checked here. It's optional: listings are free and we never ask for a link back.

Hand-checked on PluginStack
Get the Markdown or HTML

Markdown (for a GitHub README)

markdown
[![Hand-checked on PluginStack](https://www.pluginstackai.com/badge/hand-checked.svg)](https://www.pluginstackai.com/plugins/openai-agents-sdk/)

HTML (for a website)

html
<a href="https://www.pluginstackai.com/plugins/openai-agents-sdk/"><img src="https://www.pluginstackai.com/badge/hand-checked.svg" alt="Hand-checked on PluginStack" width="226" height="28"></a>

About the badge

Free: MCP Starter Checklist

After you set this tool up, use the one-page checklist so your next MCP server doesn't fail on first connect.

Markdown download + occasional PluginStack updates. No spam. Privacy policy.

See all Agent Frameworks on PluginStack