import { Crevio } from "@crevio/sdk";
const crevio = new Crevio({
apiKey: process.env["CREVIO_API_KEY"] ?? "",
});
async function run() {
const result = await crevio.taskRuns.list({});
console.log(result);
}
run();{
"object": "list",
"data": [
{
"id": "<string>",
"object": "<string>",
"task_id": "<string>",
"status": "pending",
"summary": "<string>",
"error_message": "<string>",
"input_tokens": 123,
"output_tokens": 123,
"credits_consumed": 123,
"tool_calls_count": 123,
"duration_ms": 123,
"started_at": "2023-11-07T05:31:56Z",
"completed_at": "2023-11-07T05:31:56Z",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}
],
"has_more": true,
"url": "<string>"
}Returns a list of task run records for the current account, ordered by most recent first. Supports filtering by status and ai_task_id.
import { Crevio } from "@crevio/sdk";
const crevio = new Crevio({
apiKey: process.env["CREVIO_API_KEY"] ?? "",
});
async function run() {
const result = await crevio.taskRuns.list({});
console.log(result);
}
run();{
"object": "list",
"data": [
{
"id": "<string>",
"object": "<string>",
"task_id": "<string>",
"status": "pending",
"summary": "<string>",
"error_message": "<string>",
"input_tokens": 123,
"output_tokens": 123,
"credits_consumed": 123,
"tool_calls_count": 123,
"duration_ms": 123,
"started_at": "2023-11-07T05:31:56Z",
"completed_at": "2023-11-07T05:31:56Z",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}
],
"has_more": true,
"url": "<string>"
}API key in the format: Bearer {api_token}
Filter by run status
pending, running, completed, failed, needs_input Filter by the parent task's prefixed ID
Cursor for pagination — the ID of the last item in the previous page
Items per page
1 <= x <= 100Was this page helpful?