34
Views
5
Comments
Catching the SOAP fault element
Question
Hello,

Is it possible to catch the SOAP fault element in Service Studio when calling a webservice that trows an exception?

Best regards,
FS
2016-08-25 18-41-23
Lúcio Ferrão
Hi Fernando,

at the moment, all you can access is the exception message via the "Session.ExceptionMessage". I think the message contains the FaultCode and FaultMessage, but you have to parse the exception message text in order to retrieve it. If this is having impact in your project, please contact OutSystems support directly.
Greetings,
Lúcio
2019-05-22 11-30-09
Marcelo Ferreira
There is any change on the plataform that make possible to access the SOAP fault element?
2012-03-16 12-21-09
João Rosado
Staff
Hi Marcelo,

Yes, there is a way to access it in the latest versions of the platform (not sure the exact number ..but somewere since around 8.0.1.21 I think)

I will post an app in the forge with a sample for it and reply here again.
What version are you using?

Regards,
João Rosado
2012-03-16 12-21-09
João Rosado
Staff
Hi again Marcelo,

As promissed here is a Forge Component to do what you need:
https://www.outsystems.com/forge/component/1048/ExceptionUtils/

How to use it:
  • Publish the application
  • Reference the actions from the ExceptionUtils extension
  • Call the GetLastSoapExceptionDetails action after the Exception Handler that catches your exception.
That will give you the xml text of the details of the SOAP Exception.

If you need more than that, or prefer to work with the Xml objects directy instead of receiving it as text, then open the extension in Integration Studio and see what it does.
It's meant to be an example of usage :)

Regards,
João Rosado
2019-05-22 11-30-09
Marcelo Ferreira
Unfortunately i'm using version 7 in this project. But for sure that will be very handy in other projects. Thx.
Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.