Skip to main content
GET
https://api.tracelm.ai
/
api
/
v1
/
tasks
/
{id}
Get Task
curl --request GET \
  --url https://api.tracelm.ai/api/v1/tasks/{id}
{
  "id": "<string>",
  "task_name": "<string>",
  "user_id": "<string>",
  "conversation_id": "<string>",
  "status": "<string>",
  "metadata": {},
  "traces": [
    {}
  ],
  "loops": [
    {}
  ],
  "started_at": "<string>",
  "completed_at": "<string>"
}
Returns detailed information about a task including all traces and detected loops.

Path Parameters

id
string
required
The task ID (UUID)

Response

id
string
Unique task identifier
task_name
string
Name of the task
user_id
string
Associated user ID
conversation_id
string
Associated conversation ID
status
string
Task status: active, completed, failed, timeout
metadata
object
Custom metadata attached to the task
traces
array
Array of trace objects in this task
loops
array
Array of detected execution loops
started_at
string
When the task started (ISO 8601)
completed_at
string
When the task completed (ISO 8601)

Example

curl -X GET "https://api.tracelm.ai/api/v1/tasks/550e8400-e29b-41d4-a716-446655440000" \
  -H "X-API-Key: $TRACELM_API_KEY"

Response

{
  "id": "550e8400-e29b-41d4-a716-446655440000",
  "task_name": "booking_flow",
  "user_id": "user_123",
  "conversation_id": "conv_456",
  "status": "completed",
  "metadata": {
    "intent": "book_flight"
  },
  "traces": [
    {
      "id": "trace_1",
      "model": "gpt-4o-mini",
      "latency_ms": 1200,
      "tokens_in": 150,
      "tokens_out": 50,
      "has_tool_calls": true,
      "created_at": "2024-01-15T10:30:00Z"
    }
  ],
  "loops": [],
  "started_at": "2024-01-15T10:30:00Z",
  "completed_at": "2024-01-15T10:31:00Z"
}