curl --request GET \
--url https://api.prod.payana.cloud/public/api/v1/documents/{reference} \
--header 'api-key: <api-key>'import requests
url = "https://api.prod.payana.cloud/public/api/v1/documents/{reference}"
headers = {"api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'api-key': '<api-key>'}};
fetch('https://api.prod.payana.cloud/public/api/v1/documents/{reference}', 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.prod.payana.cloud/public/api/v1/documents/{reference}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"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://api.prod.payana.cloud/public/api/v1/documents/{reference}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("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://api.prod.payana.cloud/public/api/v1/documents/{reference}")
.header("api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.prod.payana.cloud/public/api/v1/documents/{reference}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["api-key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"reference": "aaea7db4-647c-4d92-9f86-89e34a68e1aa",
"document_number": "FC-2024-001",
"type": "invoice",
"issue_date": "2024-04-14T10:00:00Z",
"expiration_date": "2024-04-30T10:00:00Z",
"fiscal_reference": "e19d3e7867371a12fd53b67a56db087faa871c9797993d9bbf7806ae4e1466ea",
"fiscal_metadata": {
"final_notes": "Factura sujeta a retención en la fuente según artículo 383 del E.T."
},
"amount": 1190000,
"amount_currency": "COP",
"approval_status": "approved",
"payment_status": "partial",
"file_path": "https://storage.payana.cloud/documents/FC-2024-001.pdf",
"is_archived": false,
"purchase_order": "OC-2024-001",
"tags": [],
"is_admited": true,
"created_at": "2024-04-14T10:00:00Z",
"updated_at": "2024-04-14T12:30:00Z",
"created_by": {
"source": "fiscal",
"user": null
},
"beneficiary": {
"reference": "616263a5-a677-4ad1-92ca-7e120adad8d4",
"origin": "fiscal",
"name": "Proveedor Ejemplo S.A.S",
"identifier_type": "NIT",
"identifier_number": "900123456",
"is_deleted": false,
"deleted_at": null,
"contact_information": []
},
"payments": [
{
"reference": "9c1e2f3a-4b5c-6d7e-8f90-1234567890ab",
"date": "2024-04-20T10:00:00Z",
"amount": 600000,
"amount_currency": "COP",
"payment_method": "bank_transfer"
}
],
"support_document": {
"issue_date": "2024-04-14",
"document_number": "FV-0001"
},
"invoice_reception_events": [
{
"event": "acuse",
"issue_date": "2024-04-14T10:30:00Z"
}
],
"payment_receipt_complements": [],
"line_items": [
{
"reference": "c3f5c8e1-8b2d-4e6f-9a0b-1c2d3e4f5a6b",
"name": "Servicio de consultoría técnica",
"description": null,
"code": "43232313",
"quantity": 1,
"unit_code": "E48",
"unit_price": 1000000,
"currency": "COP",
"subtotal": 1000000,
"total": 1190000,
"position": 0,
"metadata": {
"externalId": "line-001"
},
"adjustments": [
{
"type": "tax",
"code": "IVA",
"rate": 0.19,
"rate_percentage": 19,
"base_amount": 1000000,
"amount": 190000,
"is_inclusive": false,
"metadata": {}
}
],
"created_at": "2024-04-14T10:00:00Z",
"updated_at": "2024-04-14T10:00:00Z"
}
],
"expenses": null,
"logs": [
{
"event": "document.created",
"created_at": "2024-04-14T10:00:00Z",
"actor": {
"type": "system",
"source": "fiscal"
},
"metadata": {}
},
{
"event": "document.approved",
"created_at": "2024-04-14T12:30:00Z",
"actor": {
"type": "user",
"name": "María García"
},
"metadata": {}
},
{
"event": "document.updated",
"created_at": "2024-04-14T14:00:00Z",
"actor": {
"type": "agent",
"source": "agent"
},
"metadata": {}
}
],
"erp_document": {
"registered": true,
"data": {
"document_id": "7256571",
"document_number": "E341-37582",
"document_reference": "aaea7db4-647c-4d92-9f86-89e34a68e1aa",
"document_type_id": 4,
"external_reference": "",
"origin": "API",
"status": "draft",
"vendor_id": 113,
"issue_date": "2026-04-13",
"due_date": "2026-07-09",
"expiration_date": "2026-07-09",
"accounting_date": "2026-04-13",
"observation": "Pago a término en 1 cuotas CxP",
"items": [
{
"description": "Servicio de consultoría técnica",
"product_id": 6,
"quantity": 1,
"unit_price": 1000000,
"discount": 0,
"amount_total": 1190000,
"taxes": [
{
"id": 3,
"base": 1000000
}
],
"cost_centers": [
{
"id": 14,
"value": 50
},
{
"id": 13,
"value": 40
}
]
}
],
"summary": {
"subtotal": 1000000,
"gross_total": 1000000,
"net_total": 1190000,
"discount": 0,
"iva_8": 0,
"iva_16": 0
},
"payment_lines": [
{
"amount": 1190000,
"due_date": "2026-05-09",
"book_account_id": 1558
}
],
"erp_journal": {
"id": 4,
"external_id": 12,
"company_id": 4,
"code": "BILL",
"name": "Facturas de proveedores",
"journal_type": "purchase",
"description": null,
"metadata": {},
"created_at": "2026-04-13T09:48:40.905-03:00",
"updated_at": "2026-04-13T09:48:40.905-03:00",
"deleted_at": null
},
"erp_vendor": {
"id": 113,
"external_id": 60,
"company_id": 4,
"alias_name": "Proveedor Ejemplo",
"legal_name": "Proveedor Ejemplo S.A.S",
"taxpayer_identifier": null,
"taxpayer_identifier_type": null,
"vendor_type": "company",
"metadata": {
"id": 60,
"name": "Proveedor Ejemplo",
"active": true,
"taxpayer_identifier_type": "NIT"
},
"created_at": "2026-04-13T09:48:36.109-03:00",
"updated_at": "2026-04-13T09:48:36.109-03:00",
"deleted_at": null,
"beneficiary_id": null
},
"erp_journal_entry_lines": [
{
"id": 17,
"external_id": null,
"company_id": "4",
"erp_journal_entry_id": 11,
"erp_book_account_id": null,
"erp_product_id": 6,
"debit_cents": "119000000",
"credit_cents": "0",
"description": "Servicio de consultoría técnica",
"source": "document",
"metadata": {
"taxes": [
{
"id": 3,
"base": 1000000
}
],
"source": "document",
"discount": 0,
"quantity": 1,
"line_order": 1,
"unit_price": 1000000,
"amount_total": 1190000,
"cost_centers": [
{
"id": 14,
"value": 50
},
{
"id": 13,
"value": 40
}
]
},
"erp_product": {
"id": 6,
"external_id": 24,
"company_id": 4,
"sku": "TRANS & ACC",
"name": "Viaje y alojamiento",
"unit_type": "Unidades",
"default_price_cents": "100",
"ac_account_id": null,
"tax_id": 3,
"product_category_id": 1,
"metadata": {
"type": "service",
"active": true
},
"created_at": "2026-04-13T09:48:38.337-03:00",
"updated_at": "2026-04-13T09:48:38.337-03:00",
"deleted_at": null
},
"erp_book_account": null,
"erp_journal_entry_line_cost_centers": [
{
"id": 7,
"erp_journal_entry_line_id": 17,
"erp_cost_center_id": 14,
"value": 5000,
"created_at": "2026-04-13T10:59:06.866-03:00",
"updated_at": "2026-04-13T10:59:06.866-03:00",
"erpCostCenter": {
"id": 14,
"external_id": 6,
"company_id": 4,
"code": null,
"name": "Bogotá",
"description": null,
"parent_id": null,
"metadata": {
"planId": 3
},
"created_at": null,
"updated_at": null,
"deleted_at": null
}
}
],
"erp_journal_entry_line_taxes": [
{
"id": 7,
"erp_journal_entry_line_id": 17,
"erp_tax_id": 3,
"base_cents": 100000000,
"created_at": "2026-04-13T10:59:06.865-03:00",
"updated_at": "2026-04-13T10:59:06.865-03:00",
"erpTax": {
"id": 3,
"external_id": 3,
"company_id": 4,
"code": "19% IVA",
"name": "IVA Compra 19%",
"rate": "19.0000",
"base_cents": null,
"tax_type": 0,
"purchase_ac_account_code": null,
"sales_ac_account_code": null,
"default_book_account_id": null,
"metadata": {},
"created_at": "2026-04-13T09:48:37.620-03:00",
"updated_at": "2026-04-13T09:48:37.620-03:00",
"deleted_at": null
}
}
],
"erp_purchase_order_line_id": null,
"erp_goods_receipt_line_id": null,
"created_at": "2026-04-13T10:59:06.860-03:00",
"updated_at": "2026-04-13T10:59:06.860-03:00",
"deleted_at": null
},
{
"id": 18,
"external_id": null,
"company_id": "4",
"erp_journal_entry_id": 11,
"erp_book_account_id": 1558,
"erp_product_id": null,
"debit_cents": "0",
"credit_cents": "119000000",
"description": "Cuota CxP 1",
"source": "payable_line",
"metadata": {
"amount": 1190000,
"source": "payable_line",
"due_date": "2026-05-09",
"line_order": 1
},
"erp_product": null,
"erp_book_account": {
"id": 1558,
"external_id": "916",
"company_id": "4",
"code": "20501255",
"name": "Test CxP",
"description": null,
"parent_id": null,
"account_type": "liability",
"normal_balance": "credit",
"metadata": {
"odooAccountType": "liability_payable"
},
"created_at": "2026-04-13T09:48:37.052-03:00",
"updated_at": "2026-04-13T09:48:37.052-03:00",
"deleted_at": null
},
"erp_journal_entry_line_cost_centers": [],
"erp_journal_entry_line_taxes": [],
"erp_purchase_order_line_id": null,
"erp_goods_receipt_line_id": null,
"created_at": "2026-04-13T10:59:06.868-03:00",
"updated_at": "2026-04-13T10:59:06.868-03:00",
"deleted_at": null
}
],
"erp_purchase_order_line_ids": [],
"has_purchase_order_association": false,
"associated_purchase_orders": [],
"paymentLines": [],
"created_at": "2026-04-13T10:34:23.981-03:00",
"updated_at": "2026-04-13T10:59:06.857-03:00",
"deleted_at": null
}
},
"notes": [
{
"comment": "Documento revisado y aprobado por el área contable.",
"file_path": "https://storage.payana.cloud/documents/notes/soporte.pdf",
"file_name": "soporte.pdf",
"created_by": {
"name": "Integración ERP"
},
"created_at": "2026-06-12T13:05:00.000+00:00",
"updated_at": "2026-06-12T13:05:00.000+00:00"
}
]
}{
"success": false,
"error": {
"code": "VALIDATION_ERROR",
"message": "The request contains invalid data",
"details": {
"amount": [
"Amount must be greater than 0"
],
"beneficiary_id": [
"Beneficiary does not exist"
]
}
}
}{
"success": false,
"error": {
"code": "VALIDATION_ERROR",
"message": "The request contains invalid data",
"details": {
"amount": [
"Amount must be greater than 0"
],
"beneficiary_id": [
"Beneficiary does not exist"
]
}
}
}{
"success": false,
"error": {
"code": "VALIDATION_ERROR",
"message": "The request contains invalid data",
"details": {
"amount": [
"Amount must be greater than 0"
],
"beneficiary_id": [
"Beneficiary does not exist"
]
}
}
}{
"success": false,
"error": {
"code": "VALIDATION_ERROR",
"message": "The request contains invalid data",
"details": {
"amount": [
"Amount must be greater than 0"
],
"beneficiary_id": [
"Beneficiary does not exist"
]
}
}
}{
"success": false,
"error": {
"code": "VALIDATION_ERROR",
"message": "The request contains invalid data",
"details": {
"amount": [
"Amount must be greater than 0"
],
"beneficiary_id": [
"Beneficiary does not exist"
]
}
}
}Get Document
Obtiene un documento por referencia (UUID) con el payload completo: incluye beneficiario, ítems de línea, pagos, soporte, eventos de recepción, complementos de pago, asiento ERP asociado, logs, gastos/proyectos y notas cuando apliquen.
A diferencia del listado, el detalle siempre incluye el campo notes con las notas del documento (creadas vía POST /documents/{reference}/notes).
curl --request GET \
--url https://api.prod.payana.cloud/public/api/v1/documents/{reference} \
--header 'api-key: <api-key>'import requests
url = "https://api.prod.payana.cloud/public/api/v1/documents/{reference}"
headers = {"api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'api-key': '<api-key>'}};
fetch('https://api.prod.payana.cloud/public/api/v1/documents/{reference}', 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.prod.payana.cloud/public/api/v1/documents/{reference}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"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://api.prod.payana.cloud/public/api/v1/documents/{reference}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("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://api.prod.payana.cloud/public/api/v1/documents/{reference}")
.header("api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.prod.payana.cloud/public/api/v1/documents/{reference}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["api-key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"reference": "aaea7db4-647c-4d92-9f86-89e34a68e1aa",
"document_number": "FC-2024-001",
"type": "invoice",
"issue_date": "2024-04-14T10:00:00Z",
"expiration_date": "2024-04-30T10:00:00Z",
"fiscal_reference": "e19d3e7867371a12fd53b67a56db087faa871c9797993d9bbf7806ae4e1466ea",
"fiscal_metadata": {
"final_notes": "Factura sujeta a retención en la fuente según artículo 383 del E.T."
},
"amount": 1190000,
"amount_currency": "COP",
"approval_status": "approved",
"payment_status": "partial",
"file_path": "https://storage.payana.cloud/documents/FC-2024-001.pdf",
"is_archived": false,
"purchase_order": "OC-2024-001",
"tags": [],
"is_admited": true,
"created_at": "2024-04-14T10:00:00Z",
"updated_at": "2024-04-14T12:30:00Z",
"created_by": {
"source": "fiscal",
"user": null
},
"beneficiary": {
"reference": "616263a5-a677-4ad1-92ca-7e120adad8d4",
"origin": "fiscal",
"name": "Proveedor Ejemplo S.A.S",
"identifier_type": "NIT",
"identifier_number": "900123456",
"is_deleted": false,
"deleted_at": null,
"contact_information": []
},
"payments": [
{
"reference": "9c1e2f3a-4b5c-6d7e-8f90-1234567890ab",
"date": "2024-04-20T10:00:00Z",
"amount": 600000,
"amount_currency": "COP",
"payment_method": "bank_transfer"
}
],
"support_document": {
"issue_date": "2024-04-14",
"document_number": "FV-0001"
},
"invoice_reception_events": [
{
"event": "acuse",
"issue_date": "2024-04-14T10:30:00Z"
}
],
"payment_receipt_complements": [],
"line_items": [
{
"reference": "c3f5c8e1-8b2d-4e6f-9a0b-1c2d3e4f5a6b",
"name": "Servicio de consultoría técnica",
"description": null,
"code": "43232313",
"quantity": 1,
"unit_code": "E48",
"unit_price": 1000000,
"currency": "COP",
"subtotal": 1000000,
"total": 1190000,
"position": 0,
"metadata": {
"externalId": "line-001"
},
"adjustments": [
{
"type": "tax",
"code": "IVA",
"rate": 0.19,
"rate_percentage": 19,
"base_amount": 1000000,
"amount": 190000,
"is_inclusive": false,
"metadata": {}
}
],
"created_at": "2024-04-14T10:00:00Z",
"updated_at": "2024-04-14T10:00:00Z"
}
],
"expenses": null,
"logs": [
{
"event": "document.created",
"created_at": "2024-04-14T10:00:00Z",
"actor": {
"type": "system",
"source": "fiscal"
},
"metadata": {}
},
{
"event": "document.approved",
"created_at": "2024-04-14T12:30:00Z",
"actor": {
"type": "user",
"name": "María García"
},
"metadata": {}
},
{
"event": "document.updated",
"created_at": "2024-04-14T14:00:00Z",
"actor": {
"type": "agent",
"source": "agent"
},
"metadata": {}
}
],
"erp_document": {
"registered": true,
"data": {
"document_id": "7256571",
"document_number": "E341-37582",
"document_reference": "aaea7db4-647c-4d92-9f86-89e34a68e1aa",
"document_type_id": 4,
"external_reference": "",
"origin": "API",
"status": "draft",
"vendor_id": 113,
"issue_date": "2026-04-13",
"due_date": "2026-07-09",
"expiration_date": "2026-07-09",
"accounting_date": "2026-04-13",
"observation": "Pago a término en 1 cuotas CxP",
"items": [
{
"description": "Servicio de consultoría técnica",
"product_id": 6,
"quantity": 1,
"unit_price": 1000000,
"discount": 0,
"amount_total": 1190000,
"taxes": [
{
"id": 3,
"base": 1000000
}
],
"cost_centers": [
{
"id": 14,
"value": 50
},
{
"id": 13,
"value": 40
}
]
}
],
"summary": {
"subtotal": 1000000,
"gross_total": 1000000,
"net_total": 1190000,
"discount": 0,
"iva_8": 0,
"iva_16": 0
},
"payment_lines": [
{
"amount": 1190000,
"due_date": "2026-05-09",
"book_account_id": 1558
}
],
"erp_journal": {
"id": 4,
"external_id": 12,
"company_id": 4,
"code": "BILL",
"name": "Facturas de proveedores",
"journal_type": "purchase",
"description": null,
"metadata": {},
"created_at": "2026-04-13T09:48:40.905-03:00",
"updated_at": "2026-04-13T09:48:40.905-03:00",
"deleted_at": null
},
"erp_vendor": {
"id": 113,
"external_id": 60,
"company_id": 4,
"alias_name": "Proveedor Ejemplo",
"legal_name": "Proveedor Ejemplo S.A.S",
"taxpayer_identifier": null,
"taxpayer_identifier_type": null,
"vendor_type": "company",
"metadata": {
"id": 60,
"name": "Proveedor Ejemplo",
"active": true,
"taxpayer_identifier_type": "NIT"
},
"created_at": "2026-04-13T09:48:36.109-03:00",
"updated_at": "2026-04-13T09:48:36.109-03:00",
"deleted_at": null,
"beneficiary_id": null
},
"erp_journal_entry_lines": [
{
"id": 17,
"external_id": null,
"company_id": "4",
"erp_journal_entry_id": 11,
"erp_book_account_id": null,
"erp_product_id": 6,
"debit_cents": "119000000",
"credit_cents": "0",
"description": "Servicio de consultoría técnica",
"source": "document",
"metadata": {
"taxes": [
{
"id": 3,
"base": 1000000
}
],
"source": "document",
"discount": 0,
"quantity": 1,
"line_order": 1,
"unit_price": 1000000,
"amount_total": 1190000,
"cost_centers": [
{
"id": 14,
"value": 50
},
{
"id": 13,
"value": 40
}
]
},
"erp_product": {
"id": 6,
"external_id": 24,
"company_id": 4,
"sku": "TRANS & ACC",
"name": "Viaje y alojamiento",
"unit_type": "Unidades",
"default_price_cents": "100",
"ac_account_id": null,
"tax_id": 3,
"product_category_id": 1,
"metadata": {
"type": "service",
"active": true
},
"created_at": "2026-04-13T09:48:38.337-03:00",
"updated_at": "2026-04-13T09:48:38.337-03:00",
"deleted_at": null
},
"erp_book_account": null,
"erp_journal_entry_line_cost_centers": [
{
"id": 7,
"erp_journal_entry_line_id": 17,
"erp_cost_center_id": 14,
"value": 5000,
"created_at": "2026-04-13T10:59:06.866-03:00",
"updated_at": "2026-04-13T10:59:06.866-03:00",
"erpCostCenter": {
"id": 14,
"external_id": 6,
"company_id": 4,
"code": null,
"name": "Bogotá",
"description": null,
"parent_id": null,
"metadata": {
"planId": 3
},
"created_at": null,
"updated_at": null,
"deleted_at": null
}
}
],
"erp_journal_entry_line_taxes": [
{
"id": 7,
"erp_journal_entry_line_id": 17,
"erp_tax_id": 3,
"base_cents": 100000000,
"created_at": "2026-04-13T10:59:06.865-03:00",
"updated_at": "2026-04-13T10:59:06.865-03:00",
"erpTax": {
"id": 3,
"external_id": 3,
"company_id": 4,
"code": "19% IVA",
"name": "IVA Compra 19%",
"rate": "19.0000",
"base_cents": null,
"tax_type": 0,
"purchase_ac_account_code": null,
"sales_ac_account_code": null,
"default_book_account_id": null,
"metadata": {},
"created_at": "2026-04-13T09:48:37.620-03:00",
"updated_at": "2026-04-13T09:48:37.620-03:00",
"deleted_at": null
}
}
],
"erp_purchase_order_line_id": null,
"erp_goods_receipt_line_id": null,
"created_at": "2026-04-13T10:59:06.860-03:00",
"updated_at": "2026-04-13T10:59:06.860-03:00",
"deleted_at": null
},
{
"id": 18,
"external_id": null,
"company_id": "4",
"erp_journal_entry_id": 11,
"erp_book_account_id": 1558,
"erp_product_id": null,
"debit_cents": "0",
"credit_cents": "119000000",
"description": "Cuota CxP 1",
"source": "payable_line",
"metadata": {
"amount": 1190000,
"source": "payable_line",
"due_date": "2026-05-09",
"line_order": 1
},
"erp_product": null,
"erp_book_account": {
"id": 1558,
"external_id": "916",
"company_id": "4",
"code": "20501255",
"name": "Test CxP",
"description": null,
"parent_id": null,
"account_type": "liability",
"normal_balance": "credit",
"metadata": {
"odooAccountType": "liability_payable"
},
"created_at": "2026-04-13T09:48:37.052-03:00",
"updated_at": "2026-04-13T09:48:37.052-03:00",
"deleted_at": null
},
"erp_journal_entry_line_cost_centers": [],
"erp_journal_entry_line_taxes": [],
"erp_purchase_order_line_id": null,
"erp_goods_receipt_line_id": null,
"created_at": "2026-04-13T10:59:06.868-03:00",
"updated_at": "2026-04-13T10:59:06.868-03:00",
"deleted_at": null
}
],
"erp_purchase_order_line_ids": [],
"has_purchase_order_association": false,
"associated_purchase_orders": [],
"paymentLines": [],
"created_at": "2026-04-13T10:34:23.981-03:00",
"updated_at": "2026-04-13T10:59:06.857-03:00",
"deleted_at": null
}
},
"notes": [
{
"comment": "Documento revisado y aprobado por el área contable.",
"file_path": "https://storage.payana.cloud/documents/notes/soporte.pdf",
"file_name": "soporte.pdf",
"created_by": {
"name": "Integración ERP"
},
"created_at": "2026-06-12T13:05:00.000+00:00",
"updated_at": "2026-06-12T13:05:00.000+00:00"
}
]
}{
"success": false,
"error": {
"code": "VALIDATION_ERROR",
"message": "The request contains invalid data",
"details": {
"amount": [
"Amount must be greater than 0"
],
"beneficiary_id": [
"Beneficiary does not exist"
]
}
}
}{
"success": false,
"error": {
"code": "VALIDATION_ERROR",
"message": "The request contains invalid data",
"details": {
"amount": [
"Amount must be greater than 0"
],
"beneficiary_id": [
"Beneficiary does not exist"
]
}
}
}{
"success": false,
"error": {
"code": "VALIDATION_ERROR",
"message": "The request contains invalid data",
"details": {
"amount": [
"Amount must be greater than 0"
],
"beneficiary_id": [
"Beneficiary does not exist"
]
}
}
}{
"success": false,
"error": {
"code": "VALIDATION_ERROR",
"message": "The request contains invalid data",
"details": {
"amount": [
"Amount must be greater than 0"
],
"beneficiary_id": [
"Beneficiary does not exist"
]
}
}
}{
"success": false,
"error": {
"code": "VALIDATION_ERROR",
"message": "The request contains invalid data",
"details": {
"amount": [
"Amount must be greater than 0"
],
"beneficiary_id": [
"Beneficiary does not exist"
]
}
}
}Authorizations
API key provista por Payana.
Path Parameters
Referencia del documento (UUID).
Response
Document response
Documento (factura, nota crédito/débito o gasto). Los campos marcados como expandibles se incluyen únicamente cuando se solicitan vía el query param fields.
Referencia interna del documento en Payana (UUID).
Número del documento (ej. FC-2024-001).
Tipo de documento.
invoice, debit_note, credit_note, expense Monto total del documento.
USD, COP, MXN, EUR Estado del flujo de aprobación del documento (pendiente, aprobado, rechazado). Distinto de payment_status, que refleja cobro/pago respecto al monto.
pending, in_review, approved, rejected Estado de pago del documento.
pending, partial, paid Fecha de emisión del documento.
Fecha de vencimiento del documento.
Referencia fiscal (CUFE en Colombia, UUID del SAT en México).
Metadata fiscal complementaria proveniente de la DIAN o SAT.
Show child attributes
Show child attributes
URL al archivo PDF/XML del documento.
Referencia de orden de compra del comprador extraída del XML fiscal (UBL cac:OrderReference / cbc:ID), cuando está disponible en el documento. Siempre se incluye en el payload base de documentos y en webhooks de documento; es null cuando el XML no trae orden de compra o aún no fue extraída.
Indica si el documento fue marcado como admitido (tag de sistema admitido), por ejemplo mediante POST /documents/{reference}/acknowledge. No modifica approval_status.
Información sobre cómo y quién creó el documento (origen fiscal automático, usuario manual, legalizaciones, etc.).
Show child attributes
Show child attributes
Beneficiario asociado al documento. Expandible vía fields=beneficiaries.
Show child attributes
Show child attributes
Pagos asociados al documento. Expandible vía fields=payments.
Show child attributes
Show child attributes
Documento soporte asociado. Expandible vía fields=document_supports.
Show child attributes
Show child attributes
Eventos de recepción de la factura electrónica (acuse, aceptación, rechazo, etc.). Expandible vía fields=invoice_reception_events.
Show child attributes
Show child attributes
Complementos de pago (CFDI México). Expandible vía fields=payment_receipt_complements.
Detalle de gastos asociados al documento. Expandible vía fields=expenses.
Historial de eventos del documento. Expandible vía fields=logs.
Show child attributes
Show child attributes
Información del documento en el ERP. Expandible vía fields=erp_document.
Show child attributes
Show child attributes
Notas (comentarios y/o adjuntos) agregadas al documento vía POST /documents/{reference}/notes. Siempre presente en GET /documents/{reference}; en el listado GET /documents solo se incluye cuando se solicita fields=notes.
Show child attributes
Show child attributes