And finally in my alertmanager receiver config:receivers:
- hipchat_configs:
auth_token: secret
from: FRIENDLY.ALERT.MANAGER
message: '{{ .GroupLabels.hipchatroom }}'
message_format: text
notify: true
room_id: '{{ .GroupLabels.hipchatroom }}'
send_resolved: true
name: hipchat-notifier
And this all results in the following errors (when log.level=debug):
level=debug ts=2018-07-11T00:57:22.557263748Z caller=notify.go:605 component=dispatcher msg="Notify attempt failed" attempt=1 integration=hipchat receiver=hipchat-notifier err="unexpected status code 404"
level=error ts=2018-07-11T00:57:22.557372944Z caller=notify.go:303 component=dispatcher msg="Error on notify" err="cancelling notify retry for \"hipchat\" due to unrecoverable error: unexpected status code 404"
For debugging I have hardcoded the correct room id into the receiver as room_id: 8675309 and then the messages go to hipchat and the templating in the message field (the same template as I try to used in room_id) correctly prints the room_id from the label I set in my alert. According to the docs at https://prometheus.io/docs/alerting/configuration/#%3Chipchat_config%3E the room_id field should be a tmpl_string same as the message field but for some reason it doesn't seem to work. Is this a bug or am I doing something wrong?