The HTTP client module supports sending of HTTP requests and handling of HTTP responses. It defines just one function -<code>send-request</code>, preceded by the<code>http:</code>prefix, which is based on the[http://expath.org/spec/http-client EXPath]specification. As the module is currently under development, it does not support all features described in the specification. Here are listed only the ones currently supported and most probably the documentation will change over time.
==http:send-request==
|-
| valign='top' | '''Rules'''
|<code>$request</code>contains the parameters of the HTTP request like HTTP method and headers. In addition to this it can also contain the URI to which the request will be sent and the body of the HTTP method. If the URI is not given with the parameter<code>$href</code>, its value in<code>$request</code>is used instead. The structures of<code>http:request</code>,<code>http:header</code>and<code>http:body</code>elements follow the[http://expath.org/spec/http-client EXPath]specification. The attribute<code>auth-method</code>of<code>$request</code>is not considered in our implementation because we are handling only basic authentication. Furthermore, currently if any serialization parameters are provided in the<code>http:body</code>child of<code>$request</code>, they are always considered, i.e. the case when the<code>src</code>attribute is set, is not handled. Sending of multipart HTTP requests and handling of responses with content different from XML, HTML and text is not supported.<br />
|}
[[Category:XQuery]]