v1

latestOpenAPI 3.0.02026-07-2455104.8 MB
File

View file of a document by id

Returns details of a single file. If you want to access the file itself please use accept-header application/vnd.xentral.file.

get/api/v2/{documentType}/{id}/files/{fileId}

Path parameters

documentType'salesOrders' | 'liabilities' | 'returns' | 'invoices' | 'creditNotes' | 'purchaseOrders' | 'offers' | 'priceInquiries' | 'proformaInvoices' | 'deliveryNotes' | 'productions' | 'serviceOrders' | 'tickets' required

Document Type

fileIdstring required

Resource identifier.

Example:17

ID of document

idstring required

Resource identifier.

Example:17

The resource's identifier.

Response

Operation completed successfully.

Example response

{
  "data": {
    "id": "1",
    "entity": "invoice",
    "entityId": 1234,
    "title": "Invoice Document",
    "description": "Document for invoice 1234",
    "keyword": "attachment",
    "sort": 1,
    "versions": [
      {
        "id": "1",
        "version": 4,
        "remark": "Please process this quickly",
        "filename": "document-2024-1234.pdf",
        "size": {
          "value": 2684,
          "unit": "byte"
        },
        "updatedAt": "2023-01-01T00:00:00+00:00"
      }
    ],
    "currentVersion": {
      "id": "1",
      "version": 4,
      "remark": "Please process this quickly",
      "filename": "document-2024-1234.pdf",
      "size": {
        "value": 2684,
        "unit": "byte"
      },
      "updatedAt": "2023-01-01T00:00:00+00:00"
    },
    "updatedAt": "2024-06-04T12:00:00+00:00"
  }
}