v3

latestOpenAPI 3.0.02026-08-081996601.2 MB
Instructions

List instructions

Lists all instructions available to the authenticated user, with optional filtering and pagination. The response includes high-level information about each instruction: the name, status, and version details.

get/v2/instructions

Query parameters

filterstring
Example:support.*

A regular expression against instruction names and descriptions to filter the results.

type'initial'
Example:initial

Filter instructions by type.

enabledboolean
Example:true

Filter instructions by enabled status.

limitinteger

The maximum number of instructions to return in the list.

page_keystring

The opaque cursor returned in metadata.page_key of the previous response. Omit it to fetch the first page.

Headers

Request-Timeoutinteger

The platform makes a best effort to complete the request in the specified seconds, or it times out.

Request-Timeout-Millisinteger

The platform makes a best effort to complete the request in the specified milliseconds, or it times out.

Response

List of available instructions.

Example response

{
  "instructions": [
    {
      "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
    }
  ],
  "metadata": {
    "page_key": "eyJvZmZzZXQiOjF9"
  }
}