Create AOP

Beta

Create a new AOP (Agent Operating Procedure) asset with the given configuration. The created AOP can then be executed via /aop/execute-async, inspected via /aop/{asset_id}/config, and updated via PUT /aop/{asset_id}/config. Use [[ placeholder ]] syntax in the prompt for user inputs supplied at execution time.

Authentication

X-API-KEYstring
API Key authentication via header
OR
AuthorizationBearer

Bearer authentication of the form Bearer <token>, where token is your auth token.

Request

This endpoint expects an object.
agentIdstring or nullOptional
ID of the agent to use for execution
agent_configmap from strings to any or nullOptional
Full agent configuration override for this AOP
descriptionstring or nullOptional

Human-readable description of what the AOP does

iconstring or nullOptional
Icon identifier for UI display
parent_folder_idstring or nullOptional

ID of the folder to create the AOP in (workspace root if omitted)

promptstring or nullOptional

The main prompt/instructions for the AOP. Use [[ placeholder ]] syntax for user inputs supplied at execution time

sectionstring or nullOptional

Section/category for organization

structured_outputmap from strings to any or nullOptional
JSON schema for structured output
titlestring or nullOptional

Title of the AOP (defaults to ‘Untitled AOP’)

Response

AOP created successfully
asset_idstring
ID of the newly created AOP asset
titlestring
Title of the created AOP
messagestringDefaults to AOP created successfully

Human-readable status message

statusstringDefaults to created
Status of the operation

Errors

400
Bad Request Error
401
Unauthorized Error
422
Unprocessable Entity Error
500
Internal Server Error