Skip to content

Get a task's status and result

GET
/api/v1/agents/{role}/tasks/{task_id}
curl --request GET \
--url https://api.ultimateteam.ai/api/v1/agents/example/tasks/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0 \
--header 'X-API-Key: <X-API-Key>'

Fetch a single AgentTask by ID, tenant-scoped.

role
required
Role

The agent role the task belongs to

string

The agent role the task belongs to

task_id
required
Task Id

The task ID to fetch

string format: uuid

The task ID to fetch

Successful Response

Media typeapplication/json
AgentTaskResponse

Wrapper response for GET /agents/{role}/tasks/{task_id}.

Attributes: data: The task payload.

object
data
required
AgentTaskData

Payload returned by GET /agents/{role}/tasks/{task_id}.

Attributes: task_id: The task’s ID. agent_role: The agent role the task belongs to. task_type: The type of task. status: Current task status (e.g. pending/completed/failed). input: The task’s input payload. output: The task’s output payload, populated once completed. error: Error message, populated if the task failed.

object
agent_role
required
Agent Role
string
error
Any of:
string
input
required
Input
object
key
additional properties
any
output
Any of:
object
key
additional properties
any
status
required
Status
string
task_id
required
Task Id
string format: uuid
task_type
required
Task Type
string
Examplegenerated
{
"data": {
"agent_role": "example",
"error": "example",
"input": {},
"output": {},
"status": "example",
"task_id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0",
"task_type": "example"
}
}

Validation Error

Media typeapplication/json
HTTPValidationError
object
detail
Detail
Array<object>
ValidationError
object
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"
}
]
}