I’m unable to find detailed documentation on the usage of the alert-notifications API, so I’m kind of shooting in the dark here. My goal is to create a new notification channel to integrate with our PagerDuty service via the API as part of a new deployment, and I can create the notification channel with the correct ‘type’ selected as ‘pagerduty’, and I can make it default to send on all alerts… but, I can’t figure out how to add the integration key, select the option to include images in the notification, or allow the ability to auto resolve the incident in pagerduty once the alert goes back to the OK state.
Here is my API POST code:
curl -s -X POST --header “Content-Type:application/json” https://user:firstname.lastname@example.org/api/alert-notifications --data-binary @- <<EOF
“name”: “new PD notification channel”,
“Integration Key”: “6c5906d55d0d657db1acd1220cfd4ae4”
Can anyone help me figure out how to add the integration key and also the other 2 options I listed above?