Trigger manual task execution
POST
/api/v1/agents/{role}/execute
const url = 'https://api.ultimateteam.ai/api/v1/agents/example/execute';const options = { method: 'POST', headers: {'X-API-Key': '<X-API-Key>', 'Content-Type': 'application/json'}, body: '{"input":{},"request_id":"2489E9AD-2EE2-8E00-8EC9-32D5F69181C0","task_type":"example"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://api.ultimateteam.ai/api/v1/agents/example/execute \ --header 'Content-Type: application/json' \ --header 'X-API-Key: <X-API-Key>' \ --data '{ "input": {}, "request_id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "task_type": "example" }'Manually enqueue a task for the specified agent.
Authorizations
Section titled “Authorizations”Parameters
Section titled “ Parameters ”Path Parameters
Section titled “Path Parameters”role
required
Role
The agent role to execute a task
string
The agent role to execute a task
Request Bodyrequired
Section titled “Request Bodyrequired”Media typeapplication/json
ExecuteRequest
Request body for POST /agents/{role}/execute.
Attributes: task_type: The type of task to execute. input: Whitelisted business arguments; caller authority is server-derived.
object
input
Input
object
key
additional properties
any
request_id
required
Request Id
string format: uuid
task_type
required
Task Type
string
Examplegenerated
{ "input": {}, "request_id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "task_type": "example"}Responses
Section titled “ Responses ”Successful Response
Media typeapplication/json
ExecuteResponse
Wrapper response for POST /agents/{role}/execute.
Attributes: data: The execute result payload.
object
data
required
ExecuteData
Payload returned by POST /agents/{role}/execute.
Attributes: task_id: The ID of the created task. agent_role: The agent role executing the task. status: Persisted task status; retries return the original task.
object
agent_role
required
Agent Role
string
status
required
Status
string
task_id
required
Task Id
string format: uuid
Examplegenerated
{ "data": { "agent_role": "example", "status": "example", "task_id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0" }}Validation Error
Media typeapplication/json
HTTPValidationError
object
detail
Detail
Array<object>
ValidationErrorobject
ctx
Context
object
input
Input
loc
required
Location
Array
msg
required
Message
string
type
required
Error Type
string
Examplegenerated
{ "detail": [ { "ctx": {}, "input": "example", "loc": [ "example" ], "msg": "example", "type": "example" } ]}