Download document PDF

The PDF of a finalised invoice or quote.

GET https://cotlet.dev/api/v1/lexware-office/documents/{document_id}/pdf/download

read

Returns a download link for the PDF Lexware Office generated when the document was finalised. A draft has no PDF; use get_document to read it instead. For an e-invoice in XRechnung format the document is an XML file, and the link points to that file.

Parameters

Parameters: download_document_pdf
NameTypeDescription
document_id string required string Document ID from list_documents or create_invoice.

Request

cURL
curl https://cotlet.dev/api/v1/lexware-office/documents/document_8c41d2/pdf/download \
  -H "Authorization: Bearer $COTLET_API_KEY"
Python
result = client.call("lexware-office", "download_document_pdf", {"document_id":"document_8c41d2"})
Node.js
const result = await cotlet.call('lexware-office', 'download_document_pdf', {"document_id":"document_8c41d2"});
CLI
cotlet call lexware-office download_document_pdf --data '{"document_id":"document_8c41d2"}'

Example response

JSON

{
  "document_id": "d_9c31be",
  "number": "RE1031",
  "file_name": "RE1031.pdf",
  "download_url": "https://files.example.com/f_3b90aa/RE1031.pdf"
}

Sign in once. Your agent does the rest.

Sign up and add the apps you need. Free 7-day trial with 2,000 credits, no card needed.