PATCH /v1/agents/{agent_id} - Update agent
PATCH /v1/agents/{agent_id}
Parameters
Section titled “ Parameters ”Path Parameters
Section titled “Path Parameters ”Agent ID (prefixed, e.g., agt_…)
Request Body required
Section titled “Request Body required ”Request to update an agent. Only provided fields will be updated.
object
Capabilities to enable for this agent with per-agent configuration.
Replaces existing capabilities. Each has a ref (capability ID) and optional config.
Per-agent capability configuration
Associates a capability with an agent, including optional per-agent configuration. The config field allows the same capability to behave differently per-agent.
object
Per-agent configuration for this capability (capability-specific)
Reference to the capability ID
Example
[ { "config": {}, "ref": "current_time" }, { "config": {}, "ref": "web_fetch" }]The ID of the default LLM model to use for this agent.
Example
model_01933b5a00007000800000000000001A human-readable description of what the agent does.
Example
Updated description for the agentThe name of the agent. Used for display purposes.
Example
Updated Support AgentThe system prompt that defines the agent’s behavior and capabilities.
Example
You are an updated helpful assistant.Tags for organizing and filtering agents.
Example
[ "updated-tag"]Responses
Section titled “ Responses ”Agent updated successfully
Agent configuration for agentic loop. An agent defines the behavior and capabilities of an AI assistant.
object
Capabilities enabled for this agent with per-agent configuration. Capabilities add tools and system prompt modifications.
Per-agent capability configuration
Associates a capability with an agent, including optional per-agent configuration. The config field allows the same capability to behave differently per-agent.
object
Per-agent configuration for this capability (capability-specific)
Reference to the capability ID
Timestamp when the agent was created.
Default LLM model ID for this agent. Can be overridden at the session level.
Example
model_01933b5a00007000800000000000001Human-readable description of what the agent does.
External identifier (agent_<32-hex>). Shown as “id” in API. Client-supplied or auto-generated.
Example
agent_01933b5a000070008000000000000001Display name of the agent.
Current lifecycle status of the agent.
System prompt that defines the agent’s behavior. Sent as the first message in every conversation.
Tags for organizing and filtering agents.
Timestamp when the agent was last updated.
Cumulative token usage across all sessions for this agent.
object
Number of tokens written to cache (Anthropic-specific)
Number of tokens read from cache (reduces cost)
Number of input/prompt tokens
Number of output/completion tokens
Invalid agent ID or input exceeds allowed limits
Standard error response for API endpoints.
object
Error message describing what went wrong.
Agent not found
Standard error response for API endpoints.
object
Error message describing what went wrong.
Internal server error
Standard error response for API endpoints.
object
Error message describing what went wrong.