curl "https://platform.u1.archetypeai.app/api/batch/jobs/job_2abc3def4ghj5jkm6mnp7pqrst/inputs/progress/counts?port_name=worker.inference" \
-H "Authorization: Bearer $ATAI_API_KEY"
import requests
import os
api_key = os.environ.get("ATAI_API_KEY")
job_id = "job_2abc3def4ghj5jkm6mnp7pqrst"
response = requests.get(
f"https://platform.u1.archetypeai.app/api/batch/jobs/{job_id}/inputs/progress/counts",
headers={"Authorization": f"Bearer {api_key}"},
params={"port_name": "worker.inference"},
)
counts = response.json()
print(f" pending={counts['pending']} processing={counts['processing']} "
f"completed={counts['completed']} failed={counts['failed']}")
const jobId = 'job_2abc3def4ghj5jkm6mnp7pqrst';
const params = new URLSearchParams({ port_name: 'worker.inference' });
const response = await fetch(`https://platform.u1.archetypeai.app/api/batch/jobs/${jobId}/inputs/progress/counts?${params}`, {
headers: { 'Authorization': `Bearer ${process.env.ATAI_API_KEY}` }
});
const counts = await response.json();
console.log(`pending=${counts.pending} processing=${counts.processing} completed=${counts.completed} failed=${counts.failed}`);
{
"job_id": "job_2abc3def4ghj5jkm6mnp7pqrst",
"pending": 0,
"processing": 1,
"completed": 8,
"failed": 1,
"processed_bytes": 40551733,
"total_bytes": 105332974
}
{
"code": "NOT_FOUND",
"message": "Job not found",
"error_uid": "err_abc123"
}
{
"detail": "Invalid access with key: api_key_not_found"
}
I/O
Get Inputs Progress Counts
Per-status counts of tracked inputs for a job
GET
/
batch
/
jobs
/
{id}
/
inputs
/
progress
/
counts
curl "https://platform.u1.archetypeai.app/api/batch/jobs/job_2abc3def4ghj5jkm6mnp7pqrst/inputs/progress/counts?port_name=worker.inference" \
-H "Authorization: Bearer $ATAI_API_KEY"
import requests
import os
api_key = os.environ.get("ATAI_API_KEY")
job_id = "job_2abc3def4ghj5jkm6mnp7pqrst"
response = requests.get(
f"https://platform.u1.archetypeai.app/api/batch/jobs/{job_id}/inputs/progress/counts",
headers={"Authorization": f"Bearer {api_key}"},
params={"port_name": "worker.inference"},
)
counts = response.json()
print(f" pending={counts['pending']} processing={counts['processing']} "
f"completed={counts['completed']} failed={counts['failed']}")
const jobId = 'job_2abc3def4ghj5jkm6mnp7pqrst';
const params = new URLSearchParams({ port_name: 'worker.inference' });
const response = await fetch(`https://platform.u1.archetypeai.app/api/batch/jobs/${jobId}/inputs/progress/counts?${params}`, {
headers: { 'Authorization': `Bearer ${process.env.ATAI_API_KEY}` }
});
const counts = await response.json();
console.log(`pending=${counts.pending} processing=${counts.processing} completed=${counts.completed} failed=${counts.failed}`);
{
"job_id": "job_2abc3def4ghj5jkm6mnp7pqrst",
"pending": 0,
"processing": 1,
"completed": 8,
"failed": 1,
"processed_bytes": 40551733,
"total_bytes": 105332974
}
{
"code": "NOT_FOUND",
"message": "Job not found",
"error_uid": "err_abc123"
}
{
"detail": "Invalid access with key: api_key_not_found"
}
Requires version 1.1.0 or later of the Archetype platform.
Overview
Returns per-status counts across the job’s tracked (non-reference) inputs. Mirrors the input_progress field embedded on GET /batch/jobs/{id} but lets you scope by port. Cheaper than walking the input list to compute badges.
Request
Response
Present when
total_bytes is known and all processing inputs that have reported progress
include the input_bytes metric. Otherwise, this property is absent. The value is the sum of
the most recent input_bytes reported by all processing inputs, plus the file sizes
(num_bytes) of all completed and failed inputs.The total file size across all tracked inputs, scoped to the
port_name filter if provided. Present only when there’s at least one tracked
input and all sizes are known. Otherwise, this value is absent.curl "https://platform.u1.archetypeai.app/api/batch/jobs/job_2abc3def4ghj5jkm6mnp7pqrst/inputs/progress/counts?port_name=worker.inference" \
-H "Authorization: Bearer $ATAI_API_KEY"
import requests
import os
api_key = os.environ.get("ATAI_API_KEY")
job_id = "job_2abc3def4ghj5jkm6mnp7pqrst"
response = requests.get(
f"https://platform.u1.archetypeai.app/api/batch/jobs/{job_id}/inputs/progress/counts",
headers={"Authorization": f"Bearer {api_key}"},
params={"port_name": "worker.inference"},
)
counts = response.json()
print(f" pending={counts['pending']} processing={counts['processing']} "
f"completed={counts['completed']} failed={counts['failed']}")
const jobId = 'job_2abc3def4ghj5jkm6mnp7pqrst';
const params = new URLSearchParams({ port_name: 'worker.inference' });
const response = await fetch(`https://platform.u1.archetypeai.app/api/batch/jobs/${jobId}/inputs/progress/counts?${params}`, {
headers: { 'Authorization': `Bearer ${process.env.ATAI_API_KEY}` }
});
const counts = await response.json();
console.log(`pending=${counts.pending} processing=${counts.processing} completed=${counts.completed} failed=${counts.failed}`);
{
"job_id": "job_2abc3def4ghj5jkm6mnp7pqrst",
"pending": 0,
"processing": 1,
"completed": 8,
"failed": 1,
"processed_bytes": 40551733,
"total_bytes": 105332974
}
{
"code": "NOT_FOUND",
"message": "Job not found",
"error_uid": "err_abc123"
}
{
"detail": "Invalid access with key: api_key_not_found"
}
Was this page helpful?