Overview


A Web service client is a client-side application that accesses a Web service hosted on a server. Communication between the client machine and host server typically occurs over the Internet using the HTTP protocol. Communication can be direct, or client requests and server responses can be routed through a series of gateways, proxy servers, and tunnels.

DataDirect XQuery provides two types of built-in functions to help you write Web service clients – ddtek:wscall and DataDirect HTTP functions.

Choosing a Function Type

Deciding whether to use ddtek:wscall or HTTP functions for your XQuery Web service client depends on a number of factors, the most basic of which is understanding which protocols the Web service supports. For example, if the XQuery Web service supports HTTP, then you must write the XQuery Web service client using HTTP functions. On the other hand, if the XQuery Web service supports SOAP, then you can use either HTTP functions or ddtek:wscall.

Other factors you should consider when designing your XQuery Web service client application include:

If the origin server uses REST or plain XML, or if you require direct control over the Web service payload or client-server connection, consider using the DataDirect XQuery HTTP functions to build your XQuery Web service client.