Retrieve a batch
curl --request GET \
--url https://api.pdfbase.dev/v1/batches/{id} \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.pdfbase.dev/v1/batches/{id}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.pdfbase.dev/v1/batches/{id}', 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://api.pdfbase.dev/v1/batches/{id}",
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://api.pdfbase.dev/v1/batches/{id}"
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://api.pdfbase.dev/v1/batches/{id}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.pdfbase.dev/v1/batches/{id}")
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_bodyBatches
Retrieve a batch
Get the status, progress, and results of a batch job.
GET
/
v1
/
batches
/
{id}
Retrieve a batch
curl --request GET \
--url https://api.pdfbase.dev/v1/batches/{id} \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.pdfbase.dev/v1/batches/{id}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.pdfbase.dev/v1/batches/{id}', 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://api.pdfbase.dev/v1/batches/{id}",
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://api.pdfbase.dev/v1/batches/{id}"
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://api.pdfbase.dev/v1/batches/{id}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.pdfbase.dev/v1/batches/{id}")
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_bodyPhase
Phase 1 (Launch)Path parameters
string
required
Batch ID, e.g.,
bat_def456.Response
While processing
{
"id": "bat_def456",
"object": "batch",
"status": "processing",
"total_items": 50,
"completed_items": 23,
"failed_items": 1,
"output": "individual",
"progress": 0.48,
"metadata": {},
"created_at": "2026-05-19T11:00:00Z",
"estimated_completion": "2026-05-19T11:02:30Z"
}
When completed (individual output)
{
"id": "bat_def456",
"object": "batch",
"status": "completed",
"total_items": 50,
"completed_items": 49,
"failed_items": 1,
"output": "individual",
"progress": 1.0,
"results": [
{
"index": 0,
"status": "completed",
"pdf_id": "pdf_item1",
"url": "https://files.pdfbase.dev/pdf_item1.pdf?token=sig_a",
"pages": 2,
"bytes": 89000
},
{
"index": 1,
"status": "failed",
"error": {
"type": "rendering_error",
"code": "timeout_exceeded",
"message": "Rendering exceeded 30s timeout."
}
}
],
"metadata": {},
"created_at": "2026-05-19T11:00:00Z",
"completed_at": "2026-05-19T11:02:15Z",
"total_render_time_ms": 62400
}
When completed (merged output)
{
"id": "bat_merged1",
"object": "batch",
"status": "completed",
"total_items": 50,
"completed_items": 50,
"failed_items": 0,
"output": "merged",
"merged_pdf": {
"id": "pdf_merged1",
"url": "https://files.pdfbase.dev/pdf_merged1.pdf?token=sig_b",
"pages": 100,
"bytes": 4200000
},
"completed_at": "2026-05-19T11:02:15Z"
}
When completed (zip output)
{
"id": "bat_zipped1",
"object": "batch",
"status": "completed",
"output": "zip",
"zip_url": "https://files.pdfbase.dev/bat_zipped1.zip?token=sig_c",
"zip_bytes": 3800000,
"completed_at": "2026-05-19T11:02:15Z"
}
Example
curl https://api.pdfbase.dev/v1/batches/bat_def456 \
-H "Authorization: Bearer pk_live_xxx"