We are trying to catch webhooks for status page incidents. Specifically, we'd like to catch the webhook when a post mortem is added, but we aren't seeing it in the webhook body.
Where can this be located, or how can this be achieved?
Hey Jordan, Alan from the Statuspage Support team here.
As long as you have the option "Notify my subscribers of this postmortem" when publishing the postmortem, your active webhook subscriptions should be receiving a payload similar to the ones sent for incident creation and updates, with the postmortem body being in the most recent item inside the "incident_updates" array.
That item will have the "status" of "postmortem".
Something like the below, from my test page:
}, "incident": { "name": "TEST WEBHOOK", "status": "postmortem", "created_at": "2024-05-31T14:03:25.368-03:00", "updated_at": "2024-05-31T14:03:51.306-03:00", "monitoring_at": null, "resolved_at": "2024-05-31T14:03:37.774-03:00", "impact": "minor", "shortlink": "XXX", "scheduled_for": null, "scheduled_until": null, "scheduled_remind_prior": false, "scheduled_reminded_at": null, "impact_override": null, "scheduled_auto_in_progress": false, "scheduled_auto_completed": false, "metadata": {}, "started_at": "2024-05-31T14:03:25.363-03:00", "reminder_intervals": null, "id": "XXX", "page_id": "XXX", "incident_updates": [ { "status": "postmortem", "body": "THIS IS A PORTMORTEM TEST FOR A WEBHOOK", "created_at": "2024-05-31T14:03:43.433-03:00", "wants_twitter_update": false, "twitter_updated_at": null, "updated_at": "2024-05-31T14:03:51.304-03:00", "display_at": null, "deliver_notifications": true, "tweet_id": null, "id": "XXX", "incident_id": "XXX", "custom_tweet": null, "affected_components": null },
The postmortem data can also be found below in the request data, in these fields:
"postmortem_body": "THIS IS A PORTMORTEM TEST FOR A WEBHOOK", "postmortem_body_last_updated_at": "2024-05-31T14:03:51.295-03:00", "postmortem_ignored": false, "postmortem_published_at": "2024-05-31T14:03:51.295-03:00", "postmortem_notified_subscribers": true, "postmortem_notified_twitter": false,
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.