curl --request GET \
--url https://agents.nanonets.com/api/v1/tasks \
--header 'Authorization: Bearer <token>'import requests
url = "https://agents.nanonets.com/api/v1/tasks"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://agents.nanonets.com/api/v1/tasks', 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://agents.nanonets.com/api/v1/tasks",
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://agents.nanonets.com/api/v1/tasks"
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://agents.nanonets.com/api/v1/tasks")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://agents.nanonets.com/api/v1/tasks")
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{
"data": [
{
"task_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"agent_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"status": "pending",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"agent_name": "<string>",
"title": "<string>",
"data_fields": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"logical_field_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"key": "<string>",
"value": "<unknown>",
"key_type": "string",
"description": "<string>"
}
]
}
],
"has_more": true,
"next_cursor": "<string>"
}{
"error": "Invalid agent_id format"
}{
"error": "Invalid agent_id format"
}{
"error": "Invalid agent_id format"
}List tasks
List tasks in the caller’s workspace. Cursor-paginated, newest-first. Filter by agent, status, creation date range, and title substring.
curl --request GET \
--url https://agents.nanonets.com/api/v1/tasks \
--header 'Authorization: Bearer <token>'import requests
url = "https://agents.nanonets.com/api/v1/tasks"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://agents.nanonets.com/api/v1/tasks', 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://agents.nanonets.com/api/v1/tasks",
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://agents.nanonets.com/api/v1/tasks"
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://agents.nanonets.com/api/v1/tasks")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://agents.nanonets.com/api/v1/tasks")
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{
"data": [
{
"task_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"agent_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"status": "pending",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"agent_name": "<string>",
"title": "<string>",
"data_fields": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"logical_field_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"key": "<string>",
"value": "<unknown>",
"key_type": "string",
"description": "<string>"
}
]
}
],
"has_more": true,
"next_cursor": "<string>"
}{
"error": "Invalid agent_id format"
}{
"error": "Invalid agent_id format"
}{
"error": "Invalid agent_id format"
}Authorizations
Workspace API key issued from the web app. Pass as
Authorization: Bearer YOUR_API_KEY.
Query Parameters
Opaque pagination cursor returned by a previous response in next_cursor.
Omit on the first request.
Maximum number of items to return. Defaults to 20; max 100.
1 <= x <= 100Only return tasks created from this agent version. Each publish creates a
new version id, so this filter misses tasks run by older versions — use
agent_group_id to match an agent across all of its versions.
Only return tasks created from any version of this agent. The group id is
stable across publishes (see GET /api/v1/agents/{agent_id}/versions).
Comma-separated list of statuses to include (pending, queued, running,
waiting_for_input, awaiting_review, completed, failed, stopped).
ISO-8601 timestamp; only tasks created at or after this instant.
ISO-8601 timestamp; only tasks created at or before this instant.
Substring match against task title (case-insensitive).
Which task bucket to list.
production(default) — live tasks. This is every task in the workspace regardless of how it was started (API, trigger, schedule, chat, …) except test tasks; it is the endpoint's long-standing default, unchanged.test— only runs created withsource: "test".all— both of the above.
Any other value returns 400.
production, test, all When true, each task carries a data_fields array holding that task's
agent data fields (the values shown as columns in the task list in the app).
Omitted from the response entirely unless you ask for it, so the default payload is unchanged.
Two things to know before relying on these values:
- They are extracted by a model when the task completes, not asserted by the platform. A field can be absent, or filled with a plausible but wrong value, on a task whose input never contained it.
- They can contain content extracted from the documents a task processed.
Any non-boolean value returns 400, including a bare
?include_data_fields with no value — so a malformed request can never be
mistaken for tasks that have no data fields.
If the fields cannot be loaded, the request fails with 500; an empty
data_fields always means the task genuinely has none.
Requests that return data fields are recorded in your workspace's audit log
(task.data_fields_read), naming the tasks whose values were read. The
default list, which returns no extracted values, is not recorded.