Module: check_mk
Branch: master
Commit: eaf63f57c60d76d84198e07ac4a1c5eeed8e1e40
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=eaf63f57c60d76…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Mon Apr 24 11:17:20 2017 +0200
Updated some werks
Change-Id: I7dcd9574767e05c761606ff0673e74418b1605f9
---
.werks/2929 | 2 +-
.werks/4484 | 2 +-
.werks/8643 | 30 ++++++++++++++++--------------
3 files changed, 18 insertions(+), 16 deletions(-)
diff --git a/.werks/2929 b/.werks/2929
index f1bbdc3..f7df3ee 100644
--- a/.werks/2929
+++ b/.werks/2929
@@ -1,5 +1,5 @@
Title: Show all metrics of a service in a nicely formatted table in the service details
-Level: 1
+Level: 2
Component: metrics
Compatible: compat
Version: 1.2.7i4
diff --git a/.werks/4484 b/.werks/4484
index a41ddbf..e54c2e4 100644
--- a/.werks/4484
+++ b/.werks/4484
@@ -1,4 +1,4 @@
-Title: Graph iime range previews can be disabled, default can be set
+Title: Graph time range previews can be disabled, default can be set
Level: 1
Component: metrics
Class: feature
diff --git a/.werks/8643 b/.werks/8643
index cae4f5d..fbcde05 100644
--- a/.werks/8643
+++ b/.werks/8643
@@ -1,5 +1,5 @@
Title: Web API: New API for fetching graph data
-Level: 1
+Level: 2
Edition: cee
Component: metrics
Compatible: compat
@@ -12,32 +12,34 @@ action is named <tt>get_graph</tt>.
The request object is structured like this:
-C+:
+F+:
{
"specification": [..., ...],
"data_range": {
"time_range" : [..., ...],
}
}
-C-:
+F-:
-The specification is using the Check_MK internal graph specification format. The
-first element is the specification type (<tt>template</tt>,
<tt>custom</tt> or <tt>explicit</tt>.
-The structure of the second element depends on the type. Please take a look at the
-examples below to get an idea of it.
+The specification is using the Check_MK internal graph specification
+format. The first element is the specification type (<tt>template</tt>,
+<tt>custom</tt> or <tt>explicit</tt>. The structure of the
second element
+depends on the type. Please take a look at the examples below to get an idea
+of it.
-The time range is given in two unix timestamps, the start time and the end time.
+The time range is given in two unix timestamps, the start time and the
+end time.
-For example this command can be used to fetch the first graph of the Check_MK service of
-the host myhost123:
+For example this command can be used to fetch the first graph of the Check_MK
+service of the host myhost123:
C+:
-# curl
"http://mycmkserver/mysite/check_mk/webapi.py?action=get_graph&_username=automation&_secret=af665c15-5728-4541-b5bf-04d1d98deee8"
-d 'request={"specification": ["template",
{"service_description": "Check_MK", "site":
"mysite", "graph_index": 0, "host_name":
"myhost123" }], "data_range": {"time_range": [1480653120,
1480667520]}}'
+UP:curl
"http://mycmkserver/mysite/check_mk/webapi.py?action=get_graph&_username=automation&_secret=af665c15-5728-4541-b5bf-04d1d98deee8"
-d 'request={"specification": ["template",
{"service_description": "Check_MK", "site":
"mysite", "graph_index": 0, "host_name":
"myhost123" }], "data_range": {"time_range": [1480653120,
1480667520]}}'
C-:
The answer may look like this:
-C+:
+F+:
{
"result": {
"step": 60,
@@ -54,10 +56,10 @@ C+:
},
"result_code": 0
}
-C-:
+F-:
This command is used to fetch the data of a custom graph named
<tt>custom_graph_1</tt>:
C+:
-# curl
"http://mycmkserver/mysite/check_mk/webapi.py?action=get_graph&_username=automation&_secret=af665c15-5728-4541-b5bf-04d1d98deee8"
-d 'request={"specification": ["custom",
"custom_graph_1"], "data_range": {"time_range": [1480653120,
1480667520]}}'
+UP:curl
"http://mycmkserver/mysite/check_mk/webapi.py?action=get_graph&_username=automation&_secret=af665c15-5728-4541-b5bf-04d1d98deee8"
-d 'request={"specification": ["custom",
"custom_graph_1"], "data_range": {"time_range": [1480653120,
1480667520]}}'
C-: