Module: check_mk
Branch: master
Commit: 59a6008e5d18e6748de5095749206107e1fa528a
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=59a6008e5d18e6…
Author: Andreas Boesl <ab(a)mathias-kettner.de>
Date: Thu Feb 2 12:54:37 2017 +0100
updated werk text
Change-Id: I134e24dac835643fee026b2f6405598d0d3917b9
---
.werks/4018 | 16 ++++++++++++----
1 file changed, 12 insertions(+), 4 deletions(-)
diff --git a/.werks/4018 b/.werks/4018
index 2167e3b..90402c3 100644
--- a/.werks/4018
+++ b/.werks/4018
@@ -14,7 +14,9 @@ First of all you can get all groups of a specific type with the url
parameter ac
<tt>
Example calls:
curl
http://localhost/heute/check_mk/webapi.py?action=get_all_hostgroups&_us…
+
curl
http://localhost/heute/check_mk/webapi.py?action=get_all_servicegroups&…
+
curl
http://localhost/heute/check_mk/webapi.py?action=get_all_contactgroups&…
</tt>
<br>
@@ -25,23 +27,29 @@ Furthermore you can add, edit and delete these groups
<tt>
# All group types can be managed with similar requests
- # Add
+ # Add group<br>
curl
"http://localhost/heute/check_mk/webapi.py?action=add_hostgroup&_username=automation&_secret=1122"
-d 'request={"groupname": "hostgroup1", "alias":
"the hg alias"}'<br>
+
curl
"http://localhost/heute/check_mk/webapi.py?action=add_servicegroup&_username=automation&_secret=1122"
-d 'request={"groupname": "servicegroup1", "alias":
"the sg alias"}'<br>
+
curl
"http://localhost/heute/check_mk/webapi.py?action=add_contactgroup&_username=automation&_secret=1122"
-d 'request={"groupname": "contactgroup1", "alias":
"the cg alias"}'<br>
- # Edit group
+ # Edit group<br>
curl
"http://localhost/heute/check_mk/webapi.py?action=edit_hostgroup&_username=automation&_secret=1122"
-d 'request={"groupname": "hostgroup1", "alias":
"the hg alias"}'<br>
+
curl
"http://localhost/heute/check_mk/webapi.py?action=edit_servicegroup&_username=automation&_secret=1122"
-d 'request={"groupname": "servicegroup1", "alias":
"the sg alias"}'<br>
+
curl
"http://localhost/heute/check_mk/webapi.py?action=edit_contactgroup&_username=automation&_secret=1122"
-d 'request={"groupname": "contactgroup1", "alias":
"the cg alias"}'<br>
- # Delete group
+ # Delete group<br>
curl
"http://localhost/heute/check_mk/webapi.py?action=delete_hostgroup&_username=automation&_secret=1122"
-d 'request={"groupname": "hostgroup1"}'<br>
+
curl
"http://localhost/heute/check_mk/webapi.py?action=delete_servicegroup&_username=automation&_secret=1122"
-d 'request={"groupname": "servicegroup1"}'<br>
+
curl
"http://localhost/heute/check_mk/webapi.py?action=delete_contactgroup&_username=automation&_secret=1122"
-d 'request={"groupname": "contactgroup1"}'<br>
- # For contact groups you may also specify a list of nagvis maps in the extra
attribute nagivs_maps
+ # For contact groups you may also specify a list of nagvis maps in the extra
attribute nagivs_maps<br>
curl
"http://localhost/heute/check_mk/webapi.py?action=add_contactgroup&_username=automation&_secret=1122"
-d 'request={"groupname": "newgroup2", "alias":
"the alias", "nagvis_maps": ["dfdf"]}'
</tt>