List jobs
curl --request GET \
--url https://your-sutro-deployment/v1/list-jobs \
--header 'Authorization: <authorization>'import requests
url = "https://your-sutro-deployment/v1/list-jobs"
headers = {"Authorization": "<authorization>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: '<authorization>'}};
fetch('https://your-sutro-deployment/v1/list-jobs', 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://your-sutro-deployment/v1/list-jobs",
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: <authorization>"
],
]);
$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://your-sutro-deployment/v1/list-jobs"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "<authorization>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://your-sutro-deployment/v1/list-jobs")
.header("Authorization", "<authorization>")
.asString();require 'uri'
require 'net/http'
url = URI("https://your-sutro-deployment/v1/list-jobs")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = '<authorization>'
response = http.request(request)
puts response.read_bodyAPI
List jobs
List Batch jobs, newest first.
GET
/
v1
/
list-jobs
List jobs
curl --request GET \
--url https://your-sutro-deployment/v1/list-jobs \
--header 'Authorization: <authorization>'import requests
url = "https://your-sutro-deployment/v1/list-jobs"
headers = {"Authorization": "<authorization>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: '<authorization>'}};
fetch('https://your-sutro-deployment/v1/list-jobs', 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://your-sutro-deployment/v1/list-jobs",
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: <authorization>"
],
]);
$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://your-sutro-deployment/v1/list-jobs"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "<authorization>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://your-sutro-deployment/v1/list-jobs")
.header("Authorization", "<authorization>")
.asString();require 'uri'
require 'net/http'
url = URI("https://your-sutro-deployment/v1/list-jobs")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = '<authorization>'
response = http.request(request)
puts response.read_bodyHeaders
string
required
Deployment API key in the form
Key YOUR_SUTRO_API_KEY.integer
Page size from 1–100. Omit to return all jobs without pagination.
string
Opaque
next_cursor from the previous page. Used only with limit; do not modify it.curl "https://YOUR-SUTRO-DEPLOYMENT/v1/list-jobs?limit=20" \
-H "Authorization: Key YOUR_SUTRO_API_KEY"
limit, the response is { "jobs": [...], "next_cursor": "..." }; next_cursor is null after the last page. Without limit, it is { "message": "...", "jobs": [...] }. Each entry uses the job object returned by the single-job endpoint.⌘I