SOLVED/WORK AROUND: SOAP Activity doesn't display full XML responses

Hi all!

Recently I have started working on the SOAP activity. I was able to setup the full process from start - receiving a token to finish - closing the session. However, in the response of the SOAP request I don’t see any XML tags. The only thing I see is the response value. In the image below you can see that the first response is a token (no xml).

Then I send a query and I am awaiting a xml response that should look the same as below xml. But the only thing I see is SelectionResult. Finally I close the session and still I don’t receive a XML response, which looks like the final block of code. So, I have created my own text response.

    <?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
    <soap:Body>
        <FindByNameResponse xmlns="omitted">
            <FindByNameResult>
                <Token>0</Token>
                <SelectionCount>12</SelectionCount>
            </FindByNameResult>
        </FindByNameResponse>
    </soap:Body>
</soap:Envelope>


<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
    <soap:Body>
        <CloseResponse xmlns="omitted" />
    </soap:Body>
</soap:Envelope>

So, the question is why don’t I see the XML responses? I tried to solve the problem myself by watching the video tutorial but I don’t see this issue coming up in the video

Thank you in advance guys!

Regards

Hi all, it has been 5 days since I posted the issue. I haven’t found a solution yet. So, I would appreciate your response and sincere help.

Regards,
Vladislav

Hi,

Did you covered all our articles about SOAP? Here is an article about how to use SOAP activity: https://www.uipath.com/kb-articles/consuming-soap-web-service-get-weather
SOAP activity result is a string that must be deserialized to obtain XML file.

Thanks,
Cosmin

Hi Cosmin, thanks for the response. I have read the article but I haven’t found an answer there. To deserialize XML the response should contain XML tags. However, the responses I have are just plain text with no tags at all. I only receive a value which theoretically should be enclosed in a tag. So, at this moment the workflow works if the response has 1 parameter with only 1 value, but if there are multiples then it doesn’t work. It shows me an aggregated value “SelectionResults”.

Hope the description of the issue is more clear now.

Thanks!

Hi,
Could you share your WF (if possible)? If not, i am not sure we could help, as the problem could reside in the service that you are using.
If you are making a request using other third party tool you are able to get an XML from the service?

Thanks,
Cosmin

Hi, unfortunately I can’t show you the WF because I am connecting to a API with sensitive data. But I can share it with you without the login details.

SOAP_VanDijk.xaml (17.4 KB)

I have tried to connect to the API using Postman app. That application displays the XML data correctly. So, I suppose that it is a problem within UiPath.

Is the token that you received in first request used in the second request for authentication/authorization?
Regarding that we don’t have access to the service, it is on your own to debug this.
Thanks

hi Cosmin,
What I can do is I can send you the token which has a limited life span. Using that you can authenticate yourself and test the service.
Thanks

hello vsadykov

can you send us that token to test? you have also a zendesk issue raised?

1 Like

Hi all! Thank you for your help. This issue has been solved. I’ve been advised to use the HTTP Request instead of the SOAP request. It works a bit different but the result is satisfactory. Thanks again!

1 Like

Hi @vsadykov May I know how did you manage to use the HTTP request activiity for the SOAP request? I’mfacing some trouble with the SOAP request activity and I’m not able to get the results using HTTP request activity as well. But I’m not sure if I’m using the activity in the right way. Could you please tell me what has to be done to use the same xml code in HTTP request to get the results?

Hi @midhunsug661 I don’t have that particular workflow anymore, so I can’t really provide you with a clear answer. You should play around with the HTTP request activity. Let me know if you will not be able to run it and I will try to create a workflow for you.

Hi @vsadykov, I had been trying with the HTTP request activity for the last couple of days and still I’m not able to run it. It doesn’t return an error, making it more difficult for me to identify the issue. The problem with this SOAP request is, they are using a custom datatype as the input type. It works well by SOAP UI. But using UiPath I’m not able to run it. Would you be kind enough to explain the steps for executing the request using HTTP activity?

Hi @vsadykov It worked!! I just had to change the body Format from application/xml to text/xml and it worked perfectly! Thank you very much! :slight_smile:

Great! Thank you for sharing the solution! Good luck with your further developments.

1 Like