Skip to content
For the complete documentation index, see llms.txt. Markdown versions of documentation pages are available by appending .md to the page URL.
Primary navigation
Theme

Delete an agent

DELETE
/agents/{agent_id}

Deletes a reusable agent. See agent configuration.

Delete an agent

curl https://api.openai.com/v1/agents/$AGENT_ID \
    -X DELETE \
    -H 'OpenAI-Beta: agents=v1' \
    -H "Authorization: Bearer $OPENAI_API_KEY"
200 — Example
{
  "id": "id",
  "deleted": true,
  "object": "agent.deleted"
}
Path Parameters
agent_id: string

The ID of the reusable agent.

minLength0
maxLength1048576
Returns
AgentDeleted object { id, deleted, object }

A deleted reusable agent.

id: string

The ID of the deleted agent.

minLength0
deleted: boolean

Whether the agent was deleted. Always true.

object: "agent.deleted" (default: "agent.deleted")

The object type. Always agent.deleted.

Returns Examples
200 — Example
{
  "id": "id",
  "deleted": true,
  "object": "agent.deleted"
}