The XML transform task transforms an XML file in the data payload into a different XML structure, or converts the file to a JSON object. The output data will be appended to the data payload.
When creating an XML transform task, you need to specify an object (an XML file) as the input and select a transformation mode.
There are two modes available.
- XML Transform: Transforms the specified XML file to a different structure. A new XML file will be added to the Files object in the data payload.
- Convert to JSON: Converts the specified XML file to a JSON object. The output JSON object is placed in the XMLTransform object. The object name (Data in the example below) is the name of the outermost tag in the XML file.
If the XML Transform mode is selected, you need to enter XSLT code to transform the XML data, and XSD code to validate the output XML.
For an example of using the XML transform task, see the template "Billing > Invoice to XML Document - XSLT Transform". The template is explained in Retrieve and format tax data for bulk upload.