v2
OpenAPI 3.0.02026-08-051996591.2 MBUpdate instruction
Updates an existing instruction's template, metadata, and configuration. Updated templates may include Velocity variables such as $tools or metadata references. Each update creates a new version. Agents continue to use existing versions until you change them explicitly.
:::info Version Management Agents referencing a specific version continue to use it until updated. Agents without a pinned version always use the latest. :::
Disable an instruction
Use this endpoint to disable an instruction without deleting it.
:::warning Disabling an instruction prevents it from being added to new agents, but agents already using it continue to operate normally. :::
Path parameters
The unique identifier for an instruction.
The unique identifier of the instruction to update.
Headers
The platform makes a best effort to complete the request in the specified seconds, or it times out.
The platform makes a best effort to complete the request in the specified milliseconds, or it times out.
Request body
Example request
{
"type": "initial",
"name": "Customer Support Initial Instruction",
"description": "Enhanced initial context and guidelines for customer support interactions",
"template": "You are an expert customer support agent for $agent.name. Available tools: #foreach($tool in $tools)${tool.name}#if($foreach.hasNext), #end#end",
"template_type": "velocity",
"metadata": {
"version": "1.1.0",
"author": "support-team",
"last_reviewed": "2024-01-15"
},
"enabled": true
}Response
The updated instruction.
Example response
{
"id": "ins_customer_support_init",
"type": "initial",
"name": "Customer Support Initial Instruction",
"template_type": "velocity",
"template": "You are an expert customer support agent for $agent.name. Available tools: #foreach($tool in $tools)${tool.name}#if($foreach.hasNext), #end#end",
"version": 1
}