Get batch job status
curl --request GET \
--url http://api.gu1.ai/batch-import/jobs/{jobId} \
--header 'Authorization: Bearer <token>'import requests
url = "http://api.gu1.ai/batch-import/jobs/{jobId}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('http://api.gu1.ai/batch-import/jobs/{jobId}', 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 => "http://api.gu1.ai/batch-import/jobs/{jobId}",
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 := "http://api.gu1.ai/batch-import/jobs/{jobId}"
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("http://api.gu1.ai/batch-import/jobs/{jobId}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("http://api.gu1.ai/batch-import/jobs/{jobId}")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"success": true,
"job.jobId": "<string>",
"job.kind": "<string>",
"job.status": "<string>",
"job.totalItems": {},
"job.succeeded": {},
"job.failed": {},
"job.skipped": {},
"job.heartbeatAt": {},
"job.leaseExpiresAt": {},
"job.workerError": {},
"job.createdAt": "<string>",
"job.completedAt": {},
"job.metadata": {},
"job.jobFailure": {}
}API Reference
Get batch job status
Poll batch import job status, progress, and row counters by jobId for entity, transaction, and user-event CSV imports in the gu1 batch API.
GET
/
batch-import
/
jobs
/
{jobId}
Get batch job status
curl --request GET \
--url http://api.gu1.ai/batch-import/jobs/{jobId} \
--header 'Authorization: Bearer <token>'import requests
url = "http://api.gu1.ai/batch-import/jobs/{jobId}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('http://api.gu1.ai/batch-import/jobs/{jobId}', 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 => "http://api.gu1.ai/batch-import/jobs/{jobId}",
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 := "http://api.gu1.ai/batch-import/jobs/{jobId}"
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("http://api.gu1.ai/batch-import/jobs/{jobId}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("http://api.gu1.ai/batch-import/jobs/{jobId}")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"success": true,
"job.jobId": "<string>",
"job.kind": "<string>",
"job.status": "<string>",
"job.totalItems": {},
"job.succeeded": {},
"job.failed": {},
"job.skipped": {},
"job.heartbeatAt": {},
"job.leaseExpiresAt": {},
"job.workerError": {},
"job.createdAt": "<string>",
"job.completedAt": {},
"job.metadata": {},
"job.jobFailure": {}
}Endpoint
GET https://api.gu1.ai/batch-import/jobs/{jobId}
202 with a jobId. It resolves the job kind automatically and performs a direct lookup β it does not scan the full import history.
Authentication
Authorization: Bearer YOUR_API_KEY
transactions:create, entities:bulk_import, events:create.
Query parameters
| Parameter | Description |
|---|---|
include | Optional comma-separated list. Use include=failures to return the same JSON body as the kind-specific failures endpoint (row-level failures[], skips[] for entities, etc.). Omit for a lightweight status payload during polling. |
HTTP responses
| Status | When |
|---|---|
200 | Job found |
401 | Not authenticated |
403 | Missing batch-import permission |
404 | Unknown jobId or job belongs to another organization |
Recommended polling flow
- Upload (entities, transactions, or user events) β store
jobIdfrom the202response. - Poll
GET /batch-import/jobs/{jobId}every 2β5 seconds. - Stop when
statusis terminal:completed,failed,cancelled, orinterrupted. - If you need row-level detail, call again with
?include=failuresor use the kind-specific failures endpoint (see Bulk imports overview).
For listing recent jobs (dashboard-style), use Unified history. For polling a single job, prefer this endpoint.
JSON response (default β status only)
{
"success": true,
"job": {
"jobId": "550e8400-e29b-41d4-a716-446655440000",
"kind": "entity_batch",
"status": "running",
"totalItems": 100,
"succeeded": 45,
"failed": 2,
"skipped": 1,
"heartbeatAt": "2026-06-26T12:00:00.000Z",
"leaseExpiresAt": "2026-06-26T12:10:00.000Z",
"workerError": null,
"createdAt": "2026-06-26T11:59:00.000Z",
"completedAt": null,
"metadata": { "fileName": "entities.csv" }
}
}
boolean
Always
true when the job exists.string
Batch job identifier from the upload response.
string
entity_batch (alias entity_automatic), transaction_batch, or user_event_batch.string
queued, running, completed, failed, cancelled, or interrupted. While a cancel is in progress the job may still show running with metadata.batchCancelRequested.number | null
Total rows/items in the job.
number | null
Successfully processed count.
number | null
Failed row count.
number | null
Skipped row count (e.g. duplicate taxId on entity imports).
string | null
Last worker heartbeat (ISO 8601).
string | null
Worker lease expiry (ISO 8601).
string | null
Truncated worker error when the job failed at job level.
string
Job creation time (ISO 8601).
string | null
Completion time when terminal (ISO 8601).
object | null
Job metadata (e.g.
fileName, import mode).object | null
Present when
status is failed and the whole job aborted. Includes stable code and message β see Failure codes.JSON response with ?include=failures
Same contract as the kind-specific failures JSON endpoints:
- Entities: Entity batch failures
- Transactions: Transaction batch failures
- User events: User-event batch failures
failures is an empty array (failuresTotal: 0).
See also: Bulk imports overview, Unified history.Was this page helpful?