XML output format

When Tungsten AP Essentials exports invoice images and information, one XML file is created for each invoice using a format described below. The invoice data and document history are included in the XML output for each invoice.

XML schema

AP Essentials uses an XML schema to format data for XML output. You specify the schema in the target system settings. We recommend using the latest schema, ReadSoft Online XML 2.0, to ensure your output contains the most up-to-date and relevant output data. Purchase orders (accounts receivable documents) can only use ReadSoft Online XML 2.0. These XML schemas are available:

  • ReadSoft Online XML 2.0 - The latest, recommended format. Use this format for new accounts. Purchase orders (accounts receivable documents) can only use this format.
  • ReadSoft Online XML 1.1 - This format is only kept for backwards compatibility and is not recommended for use unless you have an old INVOICES solution with an existing XML transform that you must utilize. Even if you have an old transform, however, we recommend that you create a new one that utilizes ReadSoft Online XML 2.0 because this format is not completely compatible with the INVOICES format.
  • ReadSoft Online XML 1.0 - This format is only kept for backwards compatibility and is not recommended for use. Do not use this option if you are setting up a new target system.
  • Internal XML - This format is only kept for backwards compatibility and is not recommended for use. Do not use this option if you are setting up a new target system.

The version numbers refer to the version of the XML schema itself. They do not refer to the version of the XML specification.

Basic structure

Parties

For accounts payable documents, this element contains buyer and supplier information.

For accounts receivable documents, this element contains customer and seller information.

HeaderFields Contains all single-item field data.
HeaderField

Describes a field by its type and contains the captured value.  

ValidationError - specifies the level of certainty that the interpreted value is correct:
  • 0 - No errors, the value is correct or Accept empty value is selected. If Accept empty value is selected, ValidationError can be "0" even if no value is found.  
  • 1 - Possible interpretation error. For example, the interpretation seems correct, but it does not match a calculated value.
  • 2 - Error. The field has probably not been interpreted correctly.

Position - specifies the coordinates of the field value on the invoice image using the format X1, Y1, X2, Y2 where X1, Y1 specifies the coordinates of the left, top corner and X2, Y2 specifies the right, bottom corner of the rectangle that contains the field value.

Tables Contains line-item field data.

Output file creation

Output files are created in the target system in a specific order. The order depends on which output method you use, as described in the sections below. Note that the file order differs between AP Essentials Connect and SFTP (not zipped).

AP Essentials Connect

  1. The extension of the image file is .img.tmp when the file transfer begins.
  2. The extension of the data file (XML or text) is .out.tmp when the file transfer begins.
  3. When the image-file transfer is complete, the file extension changes to the correct extension (.tif or .pdf).
  4. When the data-file transfer is complete, the file extension changes to the correct extension (.xml or .txt).

SFTP (zipped)

  1. The extension of the ZIP file is .tmp when transfer begins.
  2. When the transfer is complete, the extension is changed to .zip.

SFTP (not zipped)

  1. The extension of the image file is .tmp when the file transfer begins.
  2. When the image-file transfer is complete, the file extension changes to the correct extension (.tif or .pdf).
  3. The extension of the data file (XML or text) is .tmp when the file transfer begins.
  4. When the data-file transfer is complete, the file extension changes to the correct extension (.xml or .txt).