Test instruction
POST/v2/instructions/:instruction_id/test
Supported API Key Type:
Personal
Test an instruction template using supplied context and available tools. This endpoint evaluates Velocity expressions such as $tools, ${session.metadata.field}, or ${agent.metadata.field}, and returns the fully rendered template output. Use this operation to validate formatting, logic, or metadata-dependent behavior before deploying instructions to agents.
Request
Responses
- 200
- 400
- 403
- 404
- 422
The instruction has been tested successfully and the rendered result is returned.
Test request was malformed.
Permissions do not allow testing this instruction.
Instruction not found.
Template compilation failed due to invalid instruction template.