Want an easy way to use SOAP web services? WSDL might be the answer.
When scripting a web service with SOAP [Hack #65] , you create a proxy object in the browser to represent the object or service you're controlling on the server. Other scripts in the browser can use that proxy as if it were the actual server resource. This is an intuitive approach to web service scripting.
Creating your own proxies can be tedious, however. You must write
methods to mirror all of the endpoint's methods that you plan to use.
These methods will all do basically the same thing: stuff the input into
SOAP parameters, invoke the
, and extract the results. Some of this process can be
abstracted, but for a web service with more than a couple of methods,
you're going to spend a lot of time writing and testing your
WSDL (Web Services Description Language) is an XML grammar to describe all of the methods, parameters, and faults (errors) of a web service. A WSDL file lists everything, including the endpoints that can be accessed, the methods available on those endpoints, the parameters and types expected by the methods, and the parameters and faults returned by the methods.