Extensible Markup Language (XML) is a markup language designed to store and transport data. Use the actions in the XML package to automate the processing of XML data generated from web services and cloud computing applications.
Overview
An XML document is structured as an ordered and labeled tree. Each node of the tree is
an XML element and is written with an opening and closing tag. In the following example,
custname and custid are nodes:
<customer>
<custname>XYZ Corp</custname>
<custid>A001</custid>
</customer>
XPath is a query language that uses path expressions to select nodes or node-sets in an XML document. XPath includes built-in functions for manipulation of string, numeric, Boolean, date and time, and so on. The actions in the XML package enable automating tasks to start and end an XML session, insert, delete, update, or get a node, validate an XML document, and execute an XPath function.
Workflow
The generic workflow when using actions in the XML package is as follows:
- Start the XML session using the Start session action. Use this session name for all downstream actions.
- Use the different actions available in the XML package to automate XML-related tasks.
- Save the session using the Save session data action to assign the data to a file or string variable.
- End the session using the End session action to close the session.
Actions in the XML package
The XML includes the following actions:
| Action | Description |
|---|---|
| Delete node | Deletes a specific node from XML file. See Delete node action in XML. |
| End session | Closes an XML session. See End session action in XML. |
| Execute XPath function | Executes an XPath function and stores the results in a variable. See Execute XPath function action in XML package. |
| Get multiple nodes | Retrieves the value of multiple nodes. See Get multiple nodes action in XML. |
| Get single node | Retrieves the value of a single node. See Get single node action in XML. |
| Insert node | Inserts a node in the XML data source. See Using Insert node action. |
| Save session data | Saves the XML session data to a file or a string variable. See Save session data action in XML. |
| Start session | Creates a new XML session based on the specified XML data source. See Start session action in XML. |
| Update node | Updates the value of a node. See Update node action in XML. |
| Validate XML document | Validates the XML data source based on the validation type. See Validate XML document action in XML package. |