Skip to main content
GET
https://api.tracelm.ai
/
api
/
v1
/
tasks
List Tasks
curl --request GET \
  --url https://api.tracelm.ai/api/v1/tasks
{
  "tasks": [
    {}
  ],
  "total": 123,
  "page": 123,
  "page_size": 123
}
Returns a paginated list of tasks with optional filtering.

Query Parameters

project_id
string
Filter by project ID
conversation_id
string
Filter by conversation ID
user_id
string
Filter by user ID
status
string
Filter by status: active, completed, failed, timeout
loop_detected
boolean
Filter by whether loops were detected
has_issues
boolean
Filter tasks that have any issues (loops OR failures)
start_date
string
Filter tasks started after this date (ISO 8601)
end_date
string
Filter tasks started before this date (ISO 8601)
page
integer
default:"1"
Page number for pagination
page_size
integer
default:"50"
Number of tasks per page (max 100)
sort_by
string
default:"started_at"
Field to sort by: started_at, completed_at, trace_count
sort_order
string
default:"desc"
Sort order: asc or desc

Response

tasks
array
Array of task objects with summary information
total
integer
Total number of tasks matching the filters
page
integer
Current page number
page_size
integer
Number of tasks per page

Example

curl -X GET "https://api.tracelm.ai/api/v1/tasks?has_issues=true&status=completed&page=1" \
  -H "X-API-Key: $TRACELM_API_KEY"

Response

{
  "tasks": [
    {
      "id": "550e8400-e29b-41d4-a716-446655440000",
      "task_name": "booking_flow",
      "user_id": "user_123",
      "conversation_id": "conv_456",
      "status": "completed",
      "trace_count": 5,
      "tool_call_count": 3,
      "tool_failure_count": 1,
      "loop_detected": false,
      "context_failure_count": 0,
      "started_at": "2024-01-15T10:30:00Z",
      "completed_at": "2024-01-15T10:31:00Z"
    }
  ],
  "total": 42,
  "page": 1,
  "page_size": 50
}