Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
Bedrock Mission!

Learn more

View all

Sign in to view all badges

Invoke webserice with attachment

Jan_Babicky
Level 3
Level 3

Hi,

I am strugling with simple scenario. I have two short-lived processes. One for document transformation, in this case, it will simply take document as input and as output string with basename of the input variable. One setValue step can handle this.

Than I have another process, that has document as input parameter and as the wsdl notes, it consists of base64 data and content type (this is what I get from outside livecycle app that will call this second process). I tried to construct the SOAP envelope with attachmentID and attachment as variable part0 with no luck. I also tried to fetch base64 data as string in there to see if I get it working, but no luck too.

The error I get is :

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
   <soapenv:Body>
      <soapenv:Fault>
         <faultcode>soapenv:Server.userException</faultcode>
         <faultstring>org.xml.sax.SAXException: SimpleDeserializer encountered a child element, which is NOT expected, in something it was trying to deserialize.</faultstring>
         <detail>
            <faultData>
               <ns1:exception xsi:nil="true" xmlns:ns1="http://adobe.com/idp/services"/>
               <ns2:message xmlns:ns2="http://adobe.com/idp/services">SimpleDeserializer encountered a child element, which is NOT expected, in something it was trying to deserialize.</ns2:message>
            </faultData>
            <ns3:hostname xmlns:ns3="http://xml.apache.org/axis/">D-Adobe</ns3:hostname>
         </detail>
      </soapenv:Fault>
   </soapenv:Body>
</soapenv:Envelope>

I am not sure if I should post pictures of one or two step process here. The idea is that external application will pass a document to process A, the process A will take that document and pass it to process B which will convert the file to PDF and returns that document to process A for furhter work.

Thanks for any advices.

J.

0 Replies
Jan_Babicky
Level 3
Level 3

This is example of that SOAP envelope I have used:

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ser="http://adobe.com/idp/services">
   <soapenv:Header/>
   <soapenv:Body>
      <ser:invoke>
          <ser:dokument>
               <ser:contentType>             
                     plain/text         
                  </ser:contentType>                
               <ser:binaryData>              
                   dGVzdG92YWNpIHN0cmluZw==         
                  </ser:binaryData>              
          </ser:dokument>
     </ser:invoke>
   </soapenv:Body>
</soapenv:Envelope>

And if I dont get error, I get empty output value from process B.

With remoteURL parameter, it works fine:

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ser="http://adobe.com/idp/services">
   <soapenv:Header/>
   <soapenv:Body>
      <ser:invoke>
         <ser:dokument>
            <ser:remoteURL>http://help.adobe.com/en_US/livecycle/es/overview.pdf</ser:remoteURL>
         </ser:dokument>
      </ser:invoke>
   </soapenv:Body>
</soapenv:Envelope>

response:

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
   <soapenv:Body>
      <invokeResponse xmlns="http://adobe.com/idp/services">
         <vysledky>overview.pdf</vysledky>
      </invokeResponse>
   </soapenv:Body>
</soapenv:Envelope>

Thanks

J.

Jan_Babicky
Level 3
Level 3

Hi,

thanks for the input. Problem was that the filename had to be passes as a separate variable. The file did get through the SOAP, however conversion didnt went through as there was no filename associated with the attachment (??? wierd, I know)

J