Validate SOAP Payload against WSDL/XSD and list all validation errors

Is there a way we can validate SOAP or XML payload against WSDL/XSD and get all the validation errors at once. Currently when i tested the SOAP validation policy on APIGEE, it is throwing exception on first error and stooping. I want it to continue on the first and next errors and show all the error together at the end

0 5 5,431
5 REPLIES 5

Not applicable

@Dhundi Acharya,

I guess this is the default behaviour of any functionality which validates a SOAP message. As soon as it gets an elements which does no conform to SOAP schema or if its an unformed XML, it will throw an error. This is the behaviour which i observed in tools which i had used earlier for testing SOAP services like SOAP UI etc....

@Dino, @Anil Sagar, Can you validate this statement?

Actually on the soapUi version i am using (SoapUi 5.2), it shows all the validation errors at once. I know by default lot of the validation tools terminate after first error but i was thinking if there is workaround on apigee where we can configure it to not terminate after first error and show all errors together

According to the link,

https://docs.apigee.com/api-services/reference/message-validation-policy

one purpose of soap message validation policy is

Blocks XML or SOAP messages with structures that might cause unpredictable behavior, protecting backend services.

Im not sure whether there is workaround for this or not, but the behaviour observed is the intended behaviour.

nsaini
New Member

Hi

Has anyone figured out solution to this or do we need to use javascript to list all error??

This callout is collecting all validation errors.

https://github.com/yuriylesyuk/edge-soap-validate


Can you try it and see if it fulfills your requirements?