curl --request GET \
--url https://transform.unstructured.io/api/v2/jobs/{jobId} \
--header 'unstructured-api-key: <api-key>'import requests
url = "https://transform.unstructured.io/api/v2/jobs/{jobId}"
headers = {"unstructured-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'unstructured-api-key': '<api-key>'}};
fetch('https://transform.unstructured.io/api/v2/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 => "https://transform.unstructured.io/api/v2/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 => [
"unstructured-api-key: <api-key>"
],
]);
$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://transform.unstructured.io/api/v2/jobs/{jobId}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("unstructured-api-key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://transform.unstructured.io/api/v2/jobs/{jobId}")
.header("unstructured-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://transform.unstructured.io/api/v2/jobs/{jobId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["unstructured-api-key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"id": "9eb6c914-02a5-4c5d-8490-a06476946a38",
"status": "completed",
"file_id": "invoice-9eb6c914.pdf",
"source": {
"file_id": "invoice-9eb6c914.pdf",
"filename": "invoice.pdf",
"mimetype": "application/pdf",
"expires_at": "2026-09-18T18:34:26Z"
},
"error": null,
"result": {
"id": "9eb6c914-02a5-4c5d-8490-a06476946a38",
"status": "completed",
"profile": "balanced",
"warnings": [],
"markdown": null,
"format_version": "2.0",
"metadata": {
"page_count": 1
},
"extracted_data": [],
"elements": [
{
"element_id": "el-1",
"type": "NarrativeText",
"text": "Invoice number: INV-1001",
"metadata": {
"page_number": 1,
"coordinates": null,
"text_as_html": null
}
}
],
"source": {
"file_id": "invoice-9eb6c914.pdf",
"filename": "invoice.pdf",
"mimetype": "application/pdf",
"expires_at": "2026-09-18T18:34:26Z"
}
},
"request_source": "transform-api"
}{
"code": "unauthorized",
"message": "Authentication required: send either an 'unstructured-api-key' header or 'Authorization: Bearer <token>'."
}{
"code": "forbidden",
"message": "You are not permitted to read this job."
}{
"code": "not_found",
"message": "No such job."
}{
"code": "result_expired",
"message": "The result for job 9eb6c914-02a5-4c5d-8490-a06476946a38 is no longer available."
}{
"code": "parse_job_failed",
"message": "The upstream service could not retrieve the job. Try again."
}{
"code": "authorization_unavailable",
"message": "The authorization service could not be reached. Try again."
}Get the status or result of a job
Retrieve a job status and its result when available. Review the result wrapper or request server-sent events to follow progress.
curl --request GET \
--url https://transform.unstructured.io/api/v2/jobs/{jobId} \
--header 'unstructured-api-key: <api-key>'import requests
url = "https://transform.unstructured.io/api/v2/jobs/{jobId}"
headers = {"unstructured-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'unstructured-api-key': '<api-key>'}};
fetch('https://transform.unstructured.io/api/v2/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 => "https://transform.unstructured.io/api/v2/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 => [
"unstructured-api-key: <api-key>"
],
]);
$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://transform.unstructured.io/api/v2/jobs/{jobId}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("unstructured-api-key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://transform.unstructured.io/api/v2/jobs/{jobId}")
.header("unstructured-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://transform.unstructured.io/api/v2/jobs/{jobId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["unstructured-api-key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"id": "9eb6c914-02a5-4c5d-8490-a06476946a38",
"status": "completed",
"file_id": "invoice-9eb6c914.pdf",
"source": {
"file_id": "invoice-9eb6c914.pdf",
"filename": "invoice.pdf",
"mimetype": "application/pdf",
"expires_at": "2026-09-18T18:34:26Z"
},
"error": null,
"result": {
"id": "9eb6c914-02a5-4c5d-8490-a06476946a38",
"status": "completed",
"profile": "balanced",
"warnings": [],
"markdown": null,
"format_version": "2.0",
"metadata": {
"page_count": 1
},
"extracted_data": [],
"elements": [
{
"element_id": "el-1",
"type": "NarrativeText",
"text": "Invoice number: INV-1001",
"metadata": {
"page_number": 1,
"coordinates": null,
"text_as_html": null
}
}
],
"source": {
"file_id": "invoice-9eb6c914.pdf",
"filename": "invoice.pdf",
"mimetype": "application/pdf",
"expires_at": "2026-09-18T18:34:26Z"
}
},
"request_source": "transform-api"
}{
"code": "unauthorized",
"message": "Authentication required: send either an 'unstructured-api-key' header or 'Authorization: Bearer <token>'."
}{
"code": "forbidden",
"message": "You are not permitted to read this job."
}{
"code": "not_found",
"message": "No such job."
}{
"code": "result_expired",
"message": "The result for job 9eb6c914-02a5-4c5d-8490-a06476946a38 is no longer available."
}{
"code": "parse_job_failed",
"message": "The upstream service could not retrieve the job. Try again."
}{
"code": "authorization_unavailable",
"message": "The authorization service could not be reached. Try again."
}Authorizations
Path Parameters
Identifies one piece of work, whichever path submitted it. The same id the blocking call returns.
"9eb6c914-02a5-4c5d-8490-a06476946a38"
Query Parameters
Shape of the parsed output.
markdown, elements Optional list of projection fields to include in elements output. Allowed values are 'coordinates' and 'table_html'. Only valid when output='elements'.
Response
The job's state, carrying parsed content as soon as it is available. As an event stream, progress events then one terminal result or error event.
A job's state, carrying parsed content as soon as it is available.
Identifies one piece of work, whichever path submitted it. The same id the blocking call returns.
"9eb6c914-02a5-4c5d-8490-a06476946a38"
Terminal values match the blocking call's own status values.
queued, processing, failed, completed, completed_with_warnings, cancelled The authoritative source/input file ID. This is the ID accepted by GET /api/v2/upload/{fileId}, never a job ID, result artifact ID, storage key, or signed URL. Null for legacy or unassociated jobs.
Where the job was created, when known.
transform-ui, transform-api The document's original uploaded filename.
True after cancellation has been requested for this job.
The associated original uploaded source file, when known.
Show child attributes
Show child attributes
A machine-readable code and an actionable message.
Show child attributes
Show child attributes
Null until parsed content is available.
Show child attributes
Show child attributes
Was this page helpful?

