Expose an OutSystems SOAP service with SOAP headers

Hello,

I've recently come across with a requirement to add SOAP headers to an OutSystems exposed service. I have an external system that needs my service to follow certain rules and once we are not able to specify any headers neither we can manipulate those in the platform, I've found a way to workaround this, basically what I've done was to change the WSDL definition manually. Let me share what I've done:

I've started with creating a new SOAP Service:

Published it and copied the WSDL definition, there I've added the needed properties to the WSDL so the external system considers my definition as a valid one:


When I loaded the service on SOAP UI, the soap header is already available to be passed in:

As you can see below, by using the system action GetWebServiceSoapHeaders from EnhancedWebReferences, I'm now able to get the soap header:


Hope this helps someone else out there.


Cheers,

João

Hi João,

Was looking for something like this. Thanks for sharing.

Regards,

Marcelo

Marcelo Ferreira wrote:

Hi João,

Was looking for something like this. Thanks for sharing.

Regards,

Marcelo


Hi Marcelo,

Thank you for the feedback :) let us know if you've implemented something similar.

Regards,

João