influxdata / kapacitor

Open source framework for processing, monitoring, and alerting on time series data
MIT License
2.32k stars 492 forks source link

OpsGenie2 - Allow arbitrary Alert Tags #1958

Open notfol opened 6 years ago

notfol commented 6 years ago

The OpsGenie V2 API /alerts endpoint supports supplying a list of arbitrary tags in the tags JSON body field when submitting a POST request to create an alert. It would be nice if kapacitor exposed this functionality in the OpsGenie2 event handler.

var ogTags = ['Awesome', '{{ index .Tags "awesome_tag" }}']
stream
  |alert()
    .opsGenie2()
    .tags(ogTags)
    .teams('AwesomeTeam')

https://docs.opsgenie.com/docs/alert-api#section-create-alert

coultonluke commented 5 years ago

Is there a work around for adding tags using TICKscript? It would be nice if there was the ability to add any additional values that opsgenie expose to using the script.