List runs by task
curl --request GET \
--url https://melso.ai/api/tasks/{id}/runs \
--header 'Authorization: Bearer <token>'import requests
url = "https://melso.ai/api/tasks/{id}/runs"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://melso.ai/api/tasks/{id}/runs', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://melso.ai/api/tasks/{id}/runs",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://melso.ai/api/tasks/{id}/runs"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://melso.ai/api/tasks/{id}/runs")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://melso.ai/api/tasks/{id}/runs")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body[
{
"id": "<string>",
"execution_owner_id": "<string>",
"worker_id": "<string>",
"task_id": "<string>",
"workspace_id": "<string>",
"status": "queued",
"dispatched_at": "<string>",
"started_at": "<string>",
"completed_at": "<string>",
"result": "<unknown>",
"error": "<string>",
"attempt": 123,
"max_attempts": 123,
"created_at": "<string>",
"delivered_message_ids": [
"<string>"
],
"kind": "<string>",
"access": {
"method": "<string>",
"reason": "<string>",
"account_id": "<string>",
"provider": "<string>",
"label": "<string>",
"email": "<string>"
},
"model": "<string>",
"thinking_level": "<string>",
"service_tier": "<string>",
"execution_receipt": {
"harness": "<string>",
"model": "<string>",
"thinking_level": "<string>",
"service_tier": "<string>",
"worker_id": "<string>"
},
"failure_reason": "<string>",
"parent_run_id": "<string>",
"work_dir": "<string>",
"relative_work_dir": "<string>",
"branch_name": "<string>",
"trigger_message_id": "<string>",
"coalesced_message_ids": [
"<string>"
],
"trigger_summary": "<string>",
"automation_invocation_id": "<string>",
"interaction_continuation": {
"type": "<string>",
"request_id": "<string>",
"kind": "<string>",
"status": "<string>",
"source_run_id": "<string>",
"title": "<string>",
"message": "<string>",
"payload": "<unknown>",
"response": "<unknown>",
"audit_text": "<string>",
"response_actor_type": "<string>",
"response_actor_id": "<string>",
"resolved_at": "<string>",
"resume_provider": "<string>",
"resume_session_id": "<string>",
"tool_call_id": "<string>",
"tool_name": "<string>",
"tool_result": "<unknown>"
},
"attribution": {
"source": "<string>",
"precise": true,
"initiator": {
"id": "<string>",
"name": "<string>",
"email": "<string>",
"avatar_url": "<string>"
},
"originator": {
"id": "<string>",
"name": "<string>",
"email": "<string>",
"avatar_url": "<string>"
},
"evidence": {
"kind": "<string>",
"ref_id": "<string>"
},
"automation_version_id": "<string>",
"delegated_from_run_id": "<string>",
"retry_of_run_id": "<string>",
"rerun_of_run_id": "<string>"
},
"usage": [
{
"model": "<string>",
"input_tokens": 123,
"output_tokens": 123,
"cache_read_tokens": 123,
"cache_write_tokens": 123,
"provider": "<string>",
"cost_usd_ticks": 123
}
],
"billed": {
"model_usd_ticks": "<string>",
"estimated": true
}
}
]{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}Tasks
List runs by task
Workspace member with access to this resource.
Request: Path: Task ID. No body.
Response: RunResponse array, newest first.
Status: 200. Authentication and resource-access errors follow Overview.
GET
/
api
/
tasks
/
{id}
/
runs
List runs by task
curl --request GET \
--url https://melso.ai/api/tasks/{id}/runs \
--header 'Authorization: Bearer <token>'import requests
url = "https://melso.ai/api/tasks/{id}/runs"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://melso.ai/api/tasks/{id}/runs', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://melso.ai/api/tasks/{id}/runs",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://melso.ai/api/tasks/{id}/runs"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://melso.ai/api/tasks/{id}/runs")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://melso.ai/api/tasks/{id}/runs")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body[
{
"id": "<string>",
"execution_owner_id": "<string>",
"worker_id": "<string>",
"task_id": "<string>",
"workspace_id": "<string>",
"status": "queued",
"dispatched_at": "<string>",
"started_at": "<string>",
"completed_at": "<string>",
"result": "<unknown>",
"error": "<string>",
"attempt": 123,
"max_attempts": 123,
"created_at": "<string>",
"delivered_message_ids": [
"<string>"
],
"kind": "<string>",
"access": {
"method": "<string>",
"reason": "<string>",
"account_id": "<string>",
"provider": "<string>",
"label": "<string>",
"email": "<string>"
},
"model": "<string>",
"thinking_level": "<string>",
"service_tier": "<string>",
"execution_receipt": {
"harness": "<string>",
"model": "<string>",
"thinking_level": "<string>",
"service_tier": "<string>",
"worker_id": "<string>"
},
"failure_reason": "<string>",
"parent_run_id": "<string>",
"work_dir": "<string>",
"relative_work_dir": "<string>",
"branch_name": "<string>",
"trigger_message_id": "<string>",
"coalesced_message_ids": [
"<string>"
],
"trigger_summary": "<string>",
"automation_invocation_id": "<string>",
"interaction_continuation": {
"type": "<string>",
"request_id": "<string>",
"kind": "<string>",
"status": "<string>",
"source_run_id": "<string>",
"title": "<string>",
"message": "<string>",
"payload": "<unknown>",
"response": "<unknown>",
"audit_text": "<string>",
"response_actor_type": "<string>",
"response_actor_id": "<string>",
"resolved_at": "<string>",
"resume_provider": "<string>",
"resume_session_id": "<string>",
"tool_call_id": "<string>",
"tool_name": "<string>",
"tool_result": "<unknown>"
},
"attribution": {
"source": "<string>",
"precise": true,
"initiator": {
"id": "<string>",
"name": "<string>",
"email": "<string>",
"avatar_url": "<string>"
},
"originator": {
"id": "<string>",
"name": "<string>",
"email": "<string>",
"avatar_url": "<string>"
},
"evidence": {
"kind": "<string>",
"ref_id": "<string>"
},
"automation_version_id": "<string>",
"delegated_from_run_id": "<string>",
"retry_of_run_id": "<string>",
"rerun_of_run_id": "<string>"
},
"usage": [
{
"model": "<string>",
"input_tokens": 123,
"output_tokens": 123,
"cache_read_tokens": 123,
"cache_write_tokens": 123,
"provider": "<string>",
"cost_usd_ticks": 123
}
],
"billed": {
"model_usd_ticks": "<string>",
"estimated": true
}
}
]{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}Authorizations
Company API key (mwk_) or personal access token (mel_). A PAT requires X-Workspace-ID on company-scoped routes. An API key implies its own company.
Headers
Company UUID for a personal token on company-scoped operations. A company API key already binds its company.
Path Parameters
id from the corresponding authorized response.
Response
RunResponse array, newest first.
Available options:
queued, deferred, dispatched, running, paused, completed, failed, cancelled Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes