IBM Support

Using the DataPower XML Management interface to get and set files and configuration

Question & Answer


Question

How can you use the XML Management interface to get and set WebSphere DataPower appliance files and configuration?

Answer

The XML Management interface must first be enabled on the DataPower device. This can be done as an administrator in the default domain. Select Network > XML Management Interface from the navigation bar. Be sure that the Admin State is Enabled and note the port number which is 5550 by default.

Construct a SOAP message using the examples below for the object you would like to get or set.


Get Config Example:

<env:Envelope xmlns:env="http://schemas.xmlsoap.org/soap/envelope/">
  <env:Body>
  <dp:request xmlns:dp="http://www.datapower.com/schemas/management ">
  <dp:get-config/>
  </dp:request>
  </env:Body>
</env:Envelope>


Export File Example:

<env:Envelope xmlns:env="http://schemas.xmlsoap.org/soap/envelope/">
  <env:Body>
  <dp:request xmlns:dp="http://www.datapower.com/schemas/management">
  <dp:do-export all-files="true" format="ZIP"/>
  </dp:request>
  </env:Body>
</env:Envelope>


Set File Example:

<env:Envelope xmlns:env="http://schemas.xmlsoap.org/soap/envelope/">
  <env:Body>
  <dp:request xmlns:dp="http://www.datapower.com/schemas/management">
  <dp:set-file name="store://autoconfig.cfg">***BASE64 Encoded Data***</dp:set-file>
  </dp:request>
  </env:Body>
</env:Envelope>


Get File Example:

<env:Envelope xmlns:env="http://schemas.xmlsoap.org/soap/envelope/">
  <env:Body>
  <dp:request xmlns:dp="http://www.datapower.com/schemas/management">
  <dp:get-file name="config://autoconfig.cfg"/>
  </dp:request>
  </env:Body>
</env:Envelope>

Then post the message to the XML Management interface of the device. For example, if your SOAP message is saved in a file called getfile.xml, you could use a cURL command as follows:

curl -k -u admin:adminpw -d @getfile.xml https://<addr>:<port>

-k enables an insecure SSL connection
-u identifies the user name and password
-d sends data as an HTTP POST
<addr> DataPower appliance address
<port> XML Management interface port

For each get operation, the response element contains an element with the corresponding result.

Note: Additional information and examples are available in the IBM WebSphere DataPower WebGUI Guide, Network Objects appendix, XML Management Interface section and in the IBM WebSphere DataPower CLI Reference Guide, Global Configuration Mode chapter, xml-mgmt command.

[{"Product":{"code":"SS9H2Y","label":"IBM DataPower Gateway"},"Business Unit":{"code":"BU053","label":"Cloud & Data Platform"},"Component":"General","Platform":[{"code":"PF009","label":"Firmware"}],"Version":"4.0.2;4.0.1;4.0;3.8.2;5.0.0","Edition":"Edition Independent","Line of Business":{"code":"LOB45","label":"Automation"}}]

Document Information

Modified date:
08 June 2021

UID

swg21239354