|
Revision 46d766e7a7e64b0d0718f552ab01b9ba486892c5, 1.6 kB
(checked in by Theo Schlossnagle <jesus@omniti.com>, 1 year ago)
|
split out the rest doc to make adding new docs less intimidating
|
- Property mode set to
100644
|
| Line | |
|---|
| 1 |
<?xml version="1.0"?> |
|---|
| 2 |
<section> |
|---|
| 3 |
<title>/checks/set/</title> |
|---|
| 4 |
<variablelist> |
|---|
| 5 |
<varlistentry> |
|---|
| 6 |
<term>method</term> |
|---|
| 7 |
<listitem><code>PUT</code></listitem> |
|---|
| 8 |
</varlistentry> |
|---|
| 9 |
<varlistentry> |
|---|
| 10 |
<term>uri</term> |
|---|
| 11 |
<listitem><code>/checks/set/<path/><checkid></code></listitem> |
|---|
| 12 |
</varlistentry> |
|---|
| 13 |
</variablelist> |
|---|
| 14 |
<para> |
|---|
| 15 |
This call accepts a document describing a check. That check is |
|---|
| 16 |
instantiated with the <code>checkid</code> specified in the URL. If the |
|---|
| 17 |
check exists, but is not under the provided optional <code>path</code> a |
|---|
| 18 |
HTTP 403 code is returned. If the check already exists under the specified |
|---|
| 19 |
<code>path</code>, the check is updated to reflect the new configuration. |
|---|
| 20 |
The <code>module</code> cannot be changed for existing checks. All other |
|---|
| 21 |
fields can be changed. All fields are required except the |
|---|
| 22 |
<code>disable</code> field; if disable is omitted, it will inherit the |
|---|
| 23 |
disable attribute from parents in the tree (use the default setting). |
|---|
| 24 |
On success, a HTTP 200 is returned and an XML documented that matches the |
|---|
| 25 |
format of the <code>/check/show</code> REST command. |
|---|
| 26 |
The input is as follows: |
|---|
| 27 |
</para> |
|---|
| 28 |
|
|---|
| 29 |
<example> |
|---|
| 30 |
<title>REST /checks/set XML input.</title> |
|---|
| 31 |
<programlisting><![CDATA[ |
|---|
| 32 |
<?xml version="1.0" encoding="utf8"?> |
|---|
| 33 |
<check> |
|---|
| 34 |
<attributes> |
|---|
| 35 |
<name>http</name> |
|---|
| 36 |
<module>http</module> |
|---|
| 37 |
<target>8.8.38.5</target> |
|---|
| 38 |
<period>60000</period> |
|---|
| 39 |
<timeout>5000</timeout> |
|---|
| 40 |
<filterset>default</filterset> |
|---|
| 41 |
</attributes> |
|---|
| 42 |
<config> |
|---|
| 43 |
<code>200</code> |
|---|
| 44 |
<url>https://labs.omniti.com/</url> |
|---|
| 45 |
</config> |
|---|
| 46 |
</check> |
|---|
| 47 |
]]></programlisting> |
|---|
| 48 |
</example> |
|---|
| 49 |
</section> |
|---|