diff --git a/src/modules/http_client/doc/http_client_admin.xml b/src/modules/http_client/doc/http_client_admin.xml index 6f1c897690d..2c8295f07f5 100644 --- a/src/modules/http_client/doc/http_client_admin.xml +++ b/src/modules/http_client/doc/http_client_admin.xml @@ -897,6 +897,35 @@ http_client_query("http://api.com/index.php", # POST-Request http_client_query("http://api.com/index.php", "src=$si", "Content-Type: text/plain", "$var(result)"); +... + + + +
+ + <function moreinfo="none">http_client_get(url, body, hdrs, respv)</function> + + + Perform a HTTP GET request to "url", storing the response body + in the "respv" variable. The "body" and "hdrs" can be empty strings + to skip setting them. The first three parameters can contain + variables that are evaluated at runtime. The "respv" has to be + the name of a writable variable. + + + Note: usually HTTP GET requests should have no body, according to + specs the body in HTTP GET does not affect the response, but is + not explicitely forbidden. + + + <function>http_client_get()</function> usage + +... +http_client_get("http://api.com/index.php?r_uri=$(ru{s.escape.param})&f_uri=$(fu{s.escape.param})", + "", "X-Token: abc", "$var(result)"); +switch ($rc) { + ... +} ...