Convert XML to String


NEW IN 20.18.01 For an input XML, the utility returns strings suitable to be used as value in a JSON data.

If your XML contains double quotes, they are escaped and XML values are converted into XML strings.

Convert XML to String workflow input

Input

Description

Required

input xml

Contains the XML that you want to convert to strings.

Sample input XML
<inputParameters>
 <inputParameter>
   <name>adapter name</name>
   <value>text with double-quotes - "</value>
 </inputParameter>
 <inputParameter>
   <name>target connection data</name>
   <value>
     <connection-details>
      <hostname>blah.doodle.com</hostname>
       <username>somename</username>
        <password>
         <EncryptedData Type="http://www.w3.org/2001/04/xmlenc#Content">
           <CipherData>
             <CipherValue>some-encrypted-data</CipherValue>
           </CipherData>
         </EncryptedData>
       </password>
       <invocation-mechanism>ssh</invocation-mechanism>
       <timeout>120</timeout>
       <adapter-name>SSHAdapter</adapter-name>
     </connection-details>
   </value>
 </inputParameter>
</inputParameters>

Yes


Convert XML to String workflow output

Output

Description

string output

Returns string output. If the input XML contains double quotes, they are escaped.

<inputParameters><inputParameter><name>adapter name</name><value>text with double-quotes - \\"</value></inputParameter><inputParameter><name>target connection data</name><value><connection-details><hostname>blah.doodle.com</hostname><username>somename</username><password><EncryptedData xmlns=\"\" Type=\"http://www.w3.org/2001/04/xmlenc#Content\"><CipherData><CipherValue>some-encrypted-data</CipherValue></CipherData></EncryptedData></password><invocation-mechanism>ssh</invocation-mechanism><timeout>120</timeout><adapter-name>SSHAdapter</adapter-name></connection-details></value></inputParameter></inputParameters>

 

Tip: For faster searching, add an asterisk to the end of your partial query. Example: cert*