Alon1980
Alon1980

Reputation: 1267

How can I make the generated service wsdl (wcf service) contain soap headers?

I have developed a WCF service which use SOAP headers as part of the validation of the request process. In my service side I verify that the SOAP headers sent and valid. I generated WSDL files using SOAPUI in order to send to my costumer. When testing the generated wsdls, I noticed that SOAPUI does not add SOAP headers to the requests automatically. Is there any way to mark the service (with attribute or something similar) like a service which needs SOAP headers?

Thanks

Upvotes: 2

Views: 1205

Answers (1)

Ladislav Mrnka
Ladislav Mrnka

Reputation: 364389

If you are only using some interceptors / inspectors to validate that header is present you cannot expect that it will be mentioned in WSDL. Header is mentioned in WSDL only if it is part of message contract used by your operation or if you add them to message description manually.

Upvotes: 3

Related Questions