curl --request GET \
--url https://melso.ai/api/tasks/{id}/messages/page \
--header 'Authorization: Bearer <token>'import requests
url = "https://melso.ai/api/tasks/{id}/messages/page"
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}/messages/page', 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}/messages/page",
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}/messages/page"
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}/messages/page")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://melso.ai/api/tasks/{id}/messages/page")
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{
"messages": [
{
"id": "<string>",
"task_id": "<string>",
"author_type": "<string>",
"author_id": "<string>",
"content": "<string>",
"role": "<string>",
"kind": "<string>",
"created_at": "<string>",
"updated_at": "<string>",
"reactions": [
{
"id": "<string>",
"message_id": "<string>",
"actor_type": "<string>",
"actor_id": "<string>",
"emoji": "<string>",
"created_at": "<string>"
}
],
"attachments": [
{
"id": "<string>",
"workspace_id": "<string>",
"task_id": "<string>",
"message_id": "<string>",
"run_id": "<string>",
"uploader_type": "<string>",
"uploader_id": "<string>",
"filename": "<string>",
"url": "<string>",
"download_url": "<string>",
"markdown_url": "<string>",
"content_type": "<string>",
"size_bytes": 123,
"created_at": "<string>",
"attachment_download_url": "<string>"
}
],
"run_id": "<string>",
"failure_reason": "<string>",
"elapsed_ms": 123,
"final": true
}
],
"limit": 123,
"has_more": true,
"next_cursor": {
"created_at": "<string>",
"id": "<string>"
}
}{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}List task message page
Workspace member with access to this resource.
Request: Path: Task UUID. Query: limit?:integer, before_created_at?:RFC3339Nano, before_id?:UUID (cursor pair).
Response: TaskMessagesPageResponse; default limit 50, valid range 1–100, chronological order within each page. The first page, without a cursor, holds the newest messages. For older ones, pass next_cursor.created_at and next_cursor.id as before_created_at and before_id while has_more is true. Queued follow-ups that are not yet next in line are omitted.
Status: 200; 400 invalid limit or cursor. Authentication and resource-access errors follow Overview.
curl --request GET \
--url https://melso.ai/api/tasks/{id}/messages/page \
--header 'Authorization: Bearer <token>'import requests
url = "https://melso.ai/api/tasks/{id}/messages/page"
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}/messages/page', 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}/messages/page",
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}/messages/page"
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}/messages/page")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://melso.ai/api/tasks/{id}/messages/page")
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{
"messages": [
{
"id": "<string>",
"task_id": "<string>",
"author_type": "<string>",
"author_id": "<string>",
"content": "<string>",
"role": "<string>",
"kind": "<string>",
"created_at": "<string>",
"updated_at": "<string>",
"reactions": [
{
"id": "<string>",
"message_id": "<string>",
"actor_type": "<string>",
"actor_id": "<string>",
"emoji": "<string>",
"created_at": "<string>"
}
],
"attachments": [
{
"id": "<string>",
"workspace_id": "<string>",
"task_id": "<string>",
"message_id": "<string>",
"run_id": "<string>",
"uploader_type": "<string>",
"uploader_id": "<string>",
"filename": "<string>",
"url": "<string>",
"download_url": "<string>",
"markdown_url": "<string>",
"content_type": "<string>",
"size_bytes": 123,
"created_at": "<string>",
"attachment_download_url": "<string>"
}
],
"run_id": "<string>",
"failure_reason": "<string>",
"elapsed_ms": 123,
"final": true
}
],
"limit": 123,
"has_more": true,
"next_cursor": {
"created_at": "<string>",
"id": "<string>"
}
}{
"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.
Query Parameters
Messages per page.
1 <= x <= 100next_cursor.created_at from the previous page. Send with before_id.
next_cursor.id from the previous page. Send with before_created_at.
Response
TaskMessagesPageResponse; default limit 50, valid range 1–100, chronological order within each page. The first page, without a cursor, holds the newest messages. For older ones, pass next_cursor.created_at and next_cursor.id as before_created_at and before_id while has_more is true. Queued follow-ups that are not yet next in line are omitted.