oncall-engine/engine/apps/alerts
Joey Orlando f905ac5246
Updates to POST /direct_paging internal API endpoint to support Grafana Incident use-cases (#3232)
# What this PR does

- Add a new column, `grafana_incident_id`, to the `AlertGroup` model.
For now this is really just needed to determine if the Alert Group was
created, via a Direct Page, that originated from Grafana Incident.
- I understand that these IDs may be cluster specific. For now we will
not need to make OnCall backend -> Incident API calls. Should we need to
start doing this we will likely need to start syncing the Incident
plugin's provisioned API url into the `organization` in OnCall, such
that we make the API call to the right Incident backend.
- Add two new optional request body parameters to `POST /direct_paging`,
`source_url` and `grafana_incident_id`
- `source_url` - will easily allow Grafana Incident to specify the URL
to the Incident and have this populate the "Source" button
- `grafana_incident_id` - Grafana Incident can specify this such that we
have a link back to Incident (+ we know that the Alert Group was
generated from Incident)
- Hide the "Declare Incident" button in the UI if the Alert Group was
generated from Grafana Incident

## Checklist

- [ ] Unit, integration, and e2e (if applicable) tests updated
- [ ] Documentation added (or `pr:no public docs` PR label added if not
required)
- [ ] `CHANGELOG.md` updated (or `pr:no changelog` PR label added if not
required)
2023-11-01 17:19:44 -04:00
..
escalation_snapshot remove all references to deprecated AlertGroup.is_restricted field (#3228) 2023-10-31 20:10:45 +00:00
grafana_alerting_sync_manager Alerting integration use get for receiver key (#2894) 2023-08-29 02:01:45 +00:00
incident_appearance remove all references to deprecated AlertGroup.is_restricted field (#3228) 2023-10-31 20:10:45 +00:00
incident_log_builder WIP: Direct paging improvements (#3064) 2023-09-28 03:57:49 +00:00
migrations Updates to POST /direct_paging internal API endpoint to support Grafana Incident use-cases (#3232) 2023-11-01 17:19:44 -04:00
models Updates to POST /direct_paging internal API endpoint to support Grafana Incident use-cases (#3232) 2023-11-01 17:19:44 -04:00
tasks Use partial instead of lambda when queuing ack task (#3134) 2023-10-06 18:31:11 +00:00
tests address some minor direct paging backend issues (#3208) 2023-10-27 20:47:00 +00:00
__init__.py World, meet OnCall! 2022-06-03 08:09:47 -06:00
constants.py Public API: Acknowledge & Resolve actions (#3108) 2023-10-05 09:46:48 +01:00
integration_options_mixin.py AlertManager v2 (#2643) 2023-08-01 12:18:52 +08:00
paging.py Updates to POST /direct_paging internal API endpoint to support Grafana Incident use-cases (#3232) 2023-11-01 17:19:44 -04:00
representative.py apps.get_model -> import (#2619) 2023-07-25 09:43:23 +00:00
signals.py Fix warnings when running backend tests (#2079) 2023-06-06 18:38:00 +00:00
utils.py remove deprecated call_ack_url celery task (#2545) 2023-07-25 02:50:18 -04:00