Get a fiscal request
curl --request GET \
--url https://api.example.com/api/v1/external/fiscal/numbering/{fiscalRequestId}import requests
url = "https://api.example.com/api/v1/external/fiscal/numbering/{fiscalRequestId}"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.example.com/api/v1/external/fiscal/numbering/{fiscalRequestId}', 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.example.com/api/v1/external/fiscal/numbering/{fiscalRequestId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$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.example.com/api/v1/external/fiscal/numbering/{fiscalRequestId}"
req, _ := http.NewRequest("GET", url, nil)
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.example.com/api/v1/external/fiscal/numbering/{fiscalRequestId}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/api/v1/external/fiscal/numbering/{fiscalRequestId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"success": true,
"data": {
"fiscalRequestId": "9afef543-56ce-4911-a92e-5908366fa980",
"orderCode": "EC-K004-42-1786579046934",
"reused": false,
"countryCode": "EC",
"requestStatus": "GENERATED",
"documentStatus": "AUTHORIZED",
"retryable": false,
"environment": "PRODUCTION",
"document": {
"documentType": "SALE_INVOICE",
"documentLabel": "FACTURA",
"documentNumber": "005-004-000000045",
"authorizationMode": "ONLINE",
"authorizationLabel": "EMISION NORMAL",
"issuedAt": "2026-08-13T13:33:41.438Z",
"compensates": null
},
"printing": { "printable": true, "mode": "FISCAL_DOCUMENT", "reason": null },
"graphic": { "qr": "1208202601000000000000110050040000000451234567817" },
"failure": null,
"countryData": {
"claveAcceso": "1208202601000000000000110050040000000451234567817",
"establecimiento": "005",
"puntoEmision": "004",
"secuencial": "000000045",
"ambiente": "PRODUCCION"
}
}
}
{
"success": true,
"data": {
"fiscalRequestId": "c1a7f0e2-9b34-4d21-8e55-3f60ab12cd90",
"orderCode": "CO-K039-1786901234",
"reused": false,
"countryCode": "CO",
"requestStatus": "GENERATED",
"documentStatus": "AUTHORIZED",
"retryable": false,
"environment": "PRODUCTION",
"document": {
"documentType": "SALE_INVOICE",
"documentLabel": "FACTURA ELECTRONICA DE VENTA",
"documentNumber": "SETP990000001",
"authorizationMode": "ONLINE",
"authorizationLabel": "VALIDACION PREVIA",
"issuedAt": "2026-08-16T14:21:03.118Z",
"compensates": null
},
"printing": { "printable": true, "mode": "FISCAL_DOCUMENT", "reason": null },
"graphic": null,
"failure": null,
"countryData": {
"numeroComprobante": "SETP990000001",
"cufe": "9c4f1e… (96 caracteres hexadecimales)",
"prefijo": "SETP",
"numeroDian": "990000001",
"qrCode": "https://catalogo-vpfe.dian.gov.co/document/searchqr?documentkey=9c4f1e…",
"ambiente": "PRODUCCION"
}
}
}
{
"success": false,
"error": "NOT_FOUND",
"message": "FiscalRequest not found"
}
API
Get a fiscal request
Returns the current state of a numbering request by its identifier — including the authority’s verdict once it arrives.
GET
/
api
/
v1
/
external
/
fiscal
/
numbering
/
{fiscalRequestId}
Get a fiscal request
curl --request GET \
--url https://api.example.com/api/v1/external/fiscal/numbering/{fiscalRequestId}import requests
url = "https://api.example.com/api/v1/external/fiscal/numbering/{fiscalRequestId}"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.example.com/api/v1/external/fiscal/numbering/{fiscalRequestId}', 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.example.com/api/v1/external/fiscal/numbering/{fiscalRequestId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$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.example.com/api/v1/external/fiscal/numbering/{fiscalRequestId}"
req, _ := http.NewRequest("GET", url, nil)
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.example.com/api/v1/external/fiscal/numbering/{fiscalRequestId}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/api/v1/external/fiscal/numbering/{fiscalRequestId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"success": true,
"data": {
"fiscalRequestId": "9afef543-56ce-4911-a92e-5908366fa980",
"orderCode": "EC-K004-42-1786579046934",
"reused": false,
"countryCode": "EC",
"requestStatus": "GENERATED",
"documentStatus": "AUTHORIZED",
"retryable": false,
"environment": "PRODUCTION",
"document": {
"documentType": "SALE_INVOICE",
"documentLabel": "FACTURA",
"documentNumber": "005-004-000000045",
"authorizationMode": "ONLINE",
"authorizationLabel": "EMISION NORMAL",
"issuedAt": "2026-08-13T13:33:41.438Z",
"compensates": null
},
"printing": { "printable": true, "mode": "FISCAL_DOCUMENT", "reason": null },
"graphic": { "qr": "1208202601000000000000110050040000000451234567817" },
"failure": null,
"countryData": {
"claveAcceso": "1208202601000000000000110050040000000451234567817",
"establecimiento": "005",
"puntoEmision": "004",
"secuencial": "000000045",
"ambiente": "PRODUCCION"
}
}
}
{
"success": true,
"data": {
"fiscalRequestId": "c1a7f0e2-9b34-4d21-8e55-3f60ab12cd90",
"orderCode": "CO-K039-1786901234",
"reused": false,
"countryCode": "CO",
"requestStatus": "GENERATED",
"documentStatus": "AUTHORIZED",
"retryable": false,
"environment": "PRODUCTION",
"document": {
"documentType": "SALE_INVOICE",
"documentLabel": "FACTURA ELECTRONICA DE VENTA",
"documentNumber": "SETP990000001",
"authorizationMode": "ONLINE",
"authorizationLabel": "VALIDACION PREVIA",
"issuedAt": "2026-08-16T14:21:03.118Z",
"compensates": null
},
"printing": { "printable": true, "mode": "FISCAL_DOCUMENT", "reason": null },
"graphic": null,
"failure": null,
"countryData": {
"numeroComprobante": "SETP990000001",
"cufe": "9c4f1e… (96 caracteres hexadecimales)",
"prefijo": "SETP",
"numeroDian": "990000001",
"qrCode": "https://catalogo-vpfe.dian.gov.co/document/searchqr?documentkey=9c4f1e…",
"ambiente": "PRODUCCION"
}
}
}
{
"success": false,
"error": "NOT_FOUND",
"message": "FiscalRequest not found"
}
Returns the same contract as
It is the same scope as issuing, deliberately: whoever can number can read what
they numbered. There is no read-only scope that grants less.
The tenant comes from the key, never from the request. A request belonging to
another account returns
POST /numbering,
with the state refreshed. What changes between calls is documentStatus: it starts
as PENDING and becomes AUTHORIZED once the authority rules.
You should not need this in day-to-day operation. The identifiers already
reach you in
data.fiscalRepresentation on the order events, and the authority’s
verdict in lastKnown.fiscal.status. This endpoint exists for when the normal
path is not enough: you lost the synchronous response to a network drop, or you
want to confirm the state without waiting for the event.Authentication
| Header | x-api-key: pk_live_… |
| Scope | fiscal:write |
404, exactly like one that does not exist — the two are
indistinguishable so we don’t leak which identifiers are real.
Path parameters
string
required
The
fiscalRequestId returned by the numbering call. A UUID.Response
Identical toPOST /numbering — see
the full contract reference.
{
"success": true,
"data": {
"fiscalRequestId": "9afef543-56ce-4911-a92e-5908366fa980",
"orderCode": "EC-K004-42-1786579046934",
"reused": false,
"countryCode": "EC",
"requestStatus": "GENERATED",
"documentStatus": "AUTHORIZED",
"retryable": false,
"environment": "PRODUCTION",
"document": {
"documentType": "SALE_INVOICE",
"documentLabel": "FACTURA",
"documentNumber": "005-004-000000045",
"authorizationMode": "ONLINE",
"authorizationLabel": "EMISION NORMAL",
"issuedAt": "2026-08-13T13:33:41.438Z",
"compensates": null
},
"printing": { "printable": true, "mode": "FISCAL_DOCUMENT", "reason": null },
"graphic": { "qr": "1208202601000000000000110050040000000451234567817" },
"failure": null,
"countryData": {
"claveAcceso": "1208202601000000000000110050040000000451234567817",
"establecimiento": "005",
"puntoEmision": "004",
"secuencial": "000000045",
"ambiente": "PRODUCCION"
}
}
}
{
"success": true,
"data": {
"fiscalRequestId": "c1a7f0e2-9b34-4d21-8e55-3f60ab12cd90",
"orderCode": "CO-K039-1786901234",
"reused": false,
"countryCode": "CO",
"requestStatus": "GENERATED",
"documentStatus": "AUTHORIZED",
"retryable": false,
"environment": "PRODUCTION",
"document": {
"documentType": "SALE_INVOICE",
"documentLabel": "FACTURA ELECTRONICA DE VENTA",
"documentNumber": "SETP990000001",
"authorizationMode": "ONLINE",
"authorizationLabel": "VALIDACION PREVIA",
"issuedAt": "2026-08-16T14:21:03.118Z",
"compensates": null
},
"printing": { "printable": true, "mode": "FISCAL_DOCUMENT", "reason": null },
"graphic": null,
"failure": null,
"countryData": {
"numeroComprobante": "SETP990000001",
"cufe": "9c4f1e… (96 caracteres hexadecimales)",
"prefijo": "SETP",
"numeroDian": "990000001",
"qrCode": "https://catalogo-vpfe.dian.gov.co/document/searchqr?documentkey=9c4f1e…",
"ambiente": "PRODUCCION"
}
}
}
{
"success": false,
"error": "NOT_FOUND",
"message": "FiscalRequest not found"
}
Errors
| Code | When |
|---|---|
401 | The API key is missing, unknown or revoked |
403 | The key lacks the fiscal:write scope |
404 | The fiscalRequestId does not exist or belongs to another account |
Related
- Request fiscal numbering — the
POSTthat creates it - List an order’s requests — when all you have is the
orderCode - Fiscal print data — what the till reads to reprint
⌘I

