v1

latestOpenAPI 3.0.02026-07-26492143.5 KB
Agents

Update agent

Update an existing agent. Only fields included in the request body are changed; omitted fields are left untouched.

This endpoint edits document fields only. To attach or detach skills, use PATCH /agents/{agent_id}/skills; to manage MCP servers, use the agent MCP server endpoints.

patch/agents/{agent_id}

Path parameters

agent_idstring required

ID of the agent to update.

Request body

namestring nullable
model_namestring nullable

ID of the LLM the agent runs on. Use GET /models to discover valid values.

descriptionstring nullable
system_promptstring nullable
toolsobject[] nullable

When provided, replaces the agent's tool list.

resourcesobject[] nullable

When provided, replaces the agent's resource list.

metadataobject nullable
is_activeboolean nullable
team_idstring nullable

When provided, transfers ownership of the agent to this team.

Example request

{
  "model_name": "anthropic/claude-sonnet-4",
  "description": "Researches enterprise accounts and drafts outreach"
}

Response

The updated agent.

Example response

{
  "agent": {
    "id": "abc123DEFghiJKL",
    "name": "Sales research agent",
    "description": "Researches enterprise accounts and drafts outreach",
    "team_id": "team_4f8c92ab",
    "is_active": true,
    "model_name": "anthropic/claude-sonnet-4",
    "folder_id": "folder_91ab",
    "created_at": "2026-05-15T14:32:00Z"
  }
}