curl --request GET \
--url https://app.useqx.com/api/v1/documents/{id} \
--header 'Authorization: Bearer <token>'import requests
url = "https://app.useqx.com/api/v1/documents/{id}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://app.useqx.com/api/v1/documents/{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://app.useqx.com/api/v1/documents/{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://app.useqx.com/api/v1/documents/{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://app.useqx.com/api/v1/documents/{id}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.useqx.com/api/v1/documents/{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_body{
"id": "doc_318",
"document_type": {
"id": "dtp_31",
"name": "Fatura Comercial (Commercial Invoice)"
},
"status": "uploaded",
"reading_status": "complete",
"contact": {
"id": "com_12",
"type": "company",
"name": "Importadora Exemplo Ltda"
},
"collection_id": "col_40",
"in_triage": false,
"discarded": false,
"discard_reason": null,
"replaced_by": null,
"number": "INV-81244/2026",
"arrival_channel": "api",
"arrived_at": "2026-09-25T10:32:05.000-03:00",
"files": [
{
"name": "fatura.pdf",
"content_type": "application/pdf",
"size": 182044
}
],
"created_at": "2026-09-25T10:32:05.000-03:00",
"fields": [
{
"key": "invoice_number",
"label": "Número da Fatura",
"value": "INV-81244/2026"
},
{
"key": "invoice_date",
"label": "Data da Fatura",
"value": "2026-09-18"
},
{
"key": "exporter_name",
"label": "Exportador (Vendedor)",
"value": "Shanghai Example Trading Co., Ltd."
},
{
"key": "invoice_amount",
"label": "Valor da Fatura",
"value": "48,250.00"
},
{
"key": "currency",
"label": "Moeda",
"value": "USD"
},
{
"key": "incoterm",
"label": "Incoterm",
"value": "FOB"
},
{
"key": "line_items",
"label": "Itens da Fatura",
"value": [
{
"part_number": "A-100",
"description": "STAINLESS STEEL VALVE 1/2 IN",
"quantity": "1000",
"quantity_unit": "PCS",
"unit_price": "25.00",
"total_price": "25,000.00"
},
{
"part_number": "B-220",
"description": "BRASS FITTING 3/4 IN",
"quantity": "500",
"quantity_unit": "PCS",
"unit_price": "46.50",
"total_price": "23,250.00"
}
]
}
]
}{
"type": "about:blank",
"title": "Bad Request",
"status": 400,
"detail": "The API could not read the call. Check the shape and the encoding of the path and the query, the JSON of the body and the headers.",
"code": "malformed_request"
}{
"type": "about:blank",
"title": "Unauthorized",
"status": 401,
"detail": "The call did not include a valid API key. Send the key in the Authorization header, in the format Bearer <key>.",
"code": "unauthorized"
}{
"type": "about:blank",
"title": "Payment Required",
"status": 402,
"detail": "The subscription of the organization is blocked. Settle the payment in QX to use the API.",
"code": "subscription_blocked"
}{
"type": "about:blank",
"title": "Forbidden",
"status": 403,
"detail": "The free plan does not include the API. Subscribe to a paid plan in QX to use the API.",
"code": "plan_required"
}{
"type": "about:blank",
"title": "Not Found",
"status": 404,
"detail": "The resource does not exist in the key's organization.",
"code": "not_found"
}{
"type": "about:blank",
"title": "Too Many Requests",
"status": 429,
"detail": "The key went over a per-minute limit. Wait for the seconds in the Retry-After header and call again.",
"code": "rate_limited"
}Read a document
Reads a document of the key’s organization, with the fields that the reading extracted. The call also finds a discarded document. In the previous version of a file swap, discard_reason is replaced, and replaced_by contains the id of the current document.
curl --request GET \
--url https://app.useqx.com/api/v1/documents/{id} \
--header 'Authorization: Bearer <token>'import requests
url = "https://app.useqx.com/api/v1/documents/{id}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://app.useqx.com/api/v1/documents/{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://app.useqx.com/api/v1/documents/{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://app.useqx.com/api/v1/documents/{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://app.useqx.com/api/v1/documents/{id}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.useqx.com/api/v1/documents/{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_body{
"id": "doc_318",
"document_type": {
"id": "dtp_31",
"name": "Fatura Comercial (Commercial Invoice)"
},
"status": "uploaded",
"reading_status": "complete",
"contact": {
"id": "com_12",
"type": "company",
"name": "Importadora Exemplo Ltda"
},
"collection_id": "col_40",
"in_triage": false,
"discarded": false,
"discard_reason": null,
"replaced_by": null,
"number": "INV-81244/2026",
"arrival_channel": "api",
"arrived_at": "2026-09-25T10:32:05.000-03:00",
"files": [
{
"name": "fatura.pdf",
"content_type": "application/pdf",
"size": 182044
}
],
"created_at": "2026-09-25T10:32:05.000-03:00",
"fields": [
{
"key": "invoice_number",
"label": "Número da Fatura",
"value": "INV-81244/2026"
},
{
"key": "invoice_date",
"label": "Data da Fatura",
"value": "2026-09-18"
},
{
"key": "exporter_name",
"label": "Exportador (Vendedor)",
"value": "Shanghai Example Trading Co., Ltd."
},
{
"key": "invoice_amount",
"label": "Valor da Fatura",
"value": "48,250.00"
},
{
"key": "currency",
"label": "Moeda",
"value": "USD"
},
{
"key": "incoterm",
"label": "Incoterm",
"value": "FOB"
},
{
"key": "line_items",
"label": "Itens da Fatura",
"value": [
{
"part_number": "A-100",
"description": "STAINLESS STEEL VALVE 1/2 IN",
"quantity": "1000",
"quantity_unit": "PCS",
"unit_price": "25.00",
"total_price": "25,000.00"
},
{
"part_number": "B-220",
"description": "BRASS FITTING 3/4 IN",
"quantity": "500",
"quantity_unit": "PCS",
"unit_price": "46.50",
"total_price": "23,250.00"
}
]
}
]
}{
"type": "about:blank",
"title": "Bad Request",
"status": 400,
"detail": "The API could not read the call. Check the shape and the encoding of the path and the query, the JSON of the body and the headers.",
"code": "malformed_request"
}{
"type": "about:blank",
"title": "Unauthorized",
"status": 401,
"detail": "The call did not include a valid API key. Send the key in the Authorization header, in the format Bearer <key>.",
"code": "unauthorized"
}{
"type": "about:blank",
"title": "Payment Required",
"status": 402,
"detail": "The subscription of the organization is blocked. Settle the payment in QX to use the API.",
"code": "subscription_blocked"
}{
"type": "about:blank",
"title": "Forbidden",
"status": 403,
"detail": "The free plan does not include the API. Subscribe to a paid plan in QX to use the API.",
"code": "plan_required"
}{
"type": "about:blank",
"title": "Not Found",
"status": 404,
"detail": "The resource does not exist in the key's organization.",
"code": "not_found"
}{
"type": "about:blank",
"title": "Too Many Requests",
"status": 429,
"detail": "The key went over a per-minute limit. Wait for the seconds in the Retry-After header and call again.",
"code": "rate_limited"
}Authorizations
The API key of the organization, in the Authorization: Bearer <key> header. The key starts with qx_.
Path Parameters
The id of the document. The id starts with doc_.
Response
The document, with the fields.
A document, with the fields.
The id of the document.
^doc_[1-9][0-9]*$"doc_310"
Show child attributes
Show child attributes
The progress of the document. pending: the document waits for the upload. uploaded: the document arrived and waits for the review. approved: the operator approved the document. rejected: the operator rejected the document.
pending, uploaded, approved, rejected The progress of the reading of the document. not_started: the reading did not start. extracting, enriching and validating: the reading is in progress. complete: the reading ended. failed: the reading failed. no_reader: the document type has no reading.
not_started, extracting, enriching, validating, complete, failed, no_reader The contact of the document. The value is null when the document has no contact.
Show child attributes
Show child attributes
The id of the collection of the document. The value is null while the document is in Triage.
^col_[1-9][0-9]*$"col_40"
With true, the document is in Triage and has no collection yet.
With true, the document is discarded.
The reason for the discard. The value is null on a document that is not discarded. outside_pack: no active operation pack asks for the type of the document. identical_copy: the document repeats the file of another document. superseded: a newer document replaced this document. operator: the operator discarded the document. replaced: a file swap created a new document, and this document stayed as the previous version.
outside_pack, identical_copy, superseded, operator, replaced, null In the previous version of a file swap, the id of the current document. The current document is the last document in the chain of file swaps. On the other documents, the value is null.
^doc_[1-9][0-9]*$"doc_325"
The printed number that identifies the document, such as the invoice number. The value is null before the reading.
"INV-81244/2026"
The arrival channel of the file. The value is null on an empty slot. email: the file arrived by email. portal_upload: the client sent the file on the portal. operator_upload: the operator sent the file on the QX screen. spreadsheet: the file came from a spreadsheet. vault: the client reused a file from the Vault on the portal. api: the file arrived through the API.
email, portal_upload, operator_upload, spreadsheet, vault, api, null The date and the time when the file arrived, in the time zone of the organization. The value is null on an empty slot.
The files of the document. On an empty slot, the list is empty.
Show child attributes
Show child attributes
The date and the time of the creation, in the time zone of the organization.
"2026-09-25T10:30:00.000-03:00"
The fields of the document type, in the catalog order, without the file fields. A field without an answer has value equal to null.
Show child attributes
Show child attributes