elastic / kibana

Your window into the Elastic Stack
https://www.elastic.co/products/kibana
Other
19.68k stars 8.23k forks source link

[ResponseOps][Rules] Removal of deprecated Rules APIs #195179

Open cnasikas opened 1 month ago

cnasikas commented 1 month ago

In 7.13 we deprecate the following APIs:

Create rule: POST /api/alerts/alert/ Get rule: GET /api/alerts/alert/ Update rule: PUT /api/alerts/alert/ Delete rule: DELETE: /api/alerts/alert/ Disable rule: POST /api/alerts/alert//_disable Enable rule: POST /api/alerts/alert//_enable Find rules: GET /api/alerts/_find Get Alerting framework health: GET /api/alerts/_health Get alert instance summary: GET /api/alerts//_instance_summary Get alert state: GET /api/alerts//state List rule types: GET /api/alerts/list_alert_types Mute alert: POST /api/alerts/alert//alert_instance//_mute Unmute alert: POST /api/alerts/alert//alert_instance//_unmute Mute all alerts: POST /api/alerts/alert//_mute_all Unmute all alerts: POST /api/alerts/alert//_unmute_all Update API key: PUT /api/alerts/alert//_update_api_key

In 9.0 we should remove the deprecated APIs. Alternatives can be found here.

elasticmachine commented 1 month ago

Pinging @elastic/response-ops (Team:ResponseOps)

jcger commented 1 month ago

I've seen also this issue mentioning adding a deprecated object https://github.com/elastic/kibana/issues/196095. Should we add deprecated info or delete them?

cnasikas commented 1 month ago

Good point @jcger! We should add the deprecated object in 8.17/8.18 so users are being informed.

cnasikas commented 1 month ago

Could you please create an issue about it and add it as a sub-issue here? Same for the Cases APIs here https://github.com/elastic/kibana/issues/194266.

jcger commented 1 month ago

Done, here are the links: for rules: https://github.com/elastic/kibana/issues/196556 for cases: https://github.com/elastic/kibana/issues/196557

jcger commented 1 day ago

It's POST _update_api_key instead of PUT _update_api_key, right? https://github.com/elastic/kibana/blob/main/x-pack/plugins/alerting/server/routes/legacy/update_api_key.ts#L28