Can alerts be added to a Grafana Panel on a dashboard using API?

Multi tool use
up vote
0
down vote
favorite
There is a Grafana dashboard with a panel inside it. Is it possible to add (or define) an API?
grafana grafana-api
add a comment |
up vote
0
down vote
favorite
There is a Grafana dashboard with a panel inside it. Is it possible to add (or define) an API?
grafana grafana-api
add a comment |
up vote
0
down vote
favorite
up vote
0
down vote
favorite
There is a Grafana dashboard with a panel inside it. Is it possible to add (or define) an API?
grafana grafana-api
There is a Grafana dashboard with a panel inside it. Is it possible to add (or define) an API?
grafana grafana-api
grafana grafana-api
asked Nov 9 at 20:43


Aref
75731229
75731229
add a comment |
add a comment |
1 Answer
1
active
oldest
votes
up vote
0
down vote
To create new alerts or modify them you need to update the dashboard json that contains the alerts. Use dashboard API and edit particular panel alert section. You need to define an alert there. For example:
"alert": {
"conditions": [
"type": "query",
"query":
"params": [
"A",
"5m",
"now"
]
,
"reducer":
"type": "avg",
"params":
,
"evaluator":
"type": "gt",
"params": [
null
]
,
"operator":
"type": "and"
],
add a comment |
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
0
down vote
To create new alerts or modify them you need to update the dashboard json that contains the alerts. Use dashboard API and edit particular panel alert section. You need to define an alert there. For example:
"alert": {
"conditions": [
"type": "query",
"query":
"params": [
"A",
"5m",
"now"
]
,
"reducer":
"type": "avg",
"params":
,
"evaluator":
"type": "gt",
"params": [
null
]
,
"operator":
"type": "and"
],
add a comment |
up vote
0
down vote
To create new alerts or modify them you need to update the dashboard json that contains the alerts. Use dashboard API and edit particular panel alert section. You need to define an alert there. For example:
"alert": {
"conditions": [
"type": "query",
"query":
"params": [
"A",
"5m",
"now"
]
,
"reducer":
"type": "avg",
"params":
,
"evaluator":
"type": "gt",
"params": [
null
]
,
"operator":
"type": "and"
],
add a comment |
up vote
0
down vote
up vote
0
down vote
To create new alerts or modify them you need to update the dashboard json that contains the alerts. Use dashboard API and edit particular panel alert section. You need to define an alert there. For example:
"alert": {
"conditions": [
"type": "query",
"query":
"params": [
"A",
"5m",
"now"
]
,
"reducer":
"type": "avg",
"params":
,
"evaluator":
"type": "gt",
"params": [
null
]
,
"operator":
"type": "and"
],
To create new alerts or modify them you need to update the dashboard json that contains the alerts. Use dashboard API and edit particular panel alert section. You need to define an alert there. For example:
"alert": {
"conditions": [
"type": "query",
"query":
"params": [
"A",
"5m",
"now"
]
,
"reducer":
"type": "avg",
"params":
,
"evaluator":
"type": "gt",
"params": [
null
]
,
"operator":
"type": "and"
],
answered Nov 10 at 16:15


Jan Garaj
2,239618
2,239618
add a comment |
add a comment |
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53233012%2fcan-alerts-be-added-to-a-grafana-panel-on-a-dashboard-using-api%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
K98 Q8 fCt6SlzF cWIS804FFD,kFHEAT XOZkD9uQ,T L4h pPpCEe4bX852Vjy 1Dl4HPZBHdEK we1 LjBn,hI