Skip to content

Commit

Permalink
[ResponseOps][Rules] Delete legacy routes (#203148)
Browse files Browse the repository at this point in the history
## Summary

Resolves #195179
Resolves #192558

This PR deletes deprecated legacy alerts routes `api/alerts/alert` in
v9.0.
It also updates docs to reflect the same.


### Checklist

- [x]
[Documentation](https://www.elastic.co/guide/en/kibana/master/development-documentation.html)
was added for features that require explanation or tutorials



### Release notes
Deleted deprecated alerts routes.

---------

Co-authored-by: kibanamachine <[email protected]>
  • Loading branch information
js-jankisalvi and kibanamachine authored Dec 16, 2024
1 parent 3a6d27a commit 279f4ae
Show file tree
Hide file tree
Showing 82 changed files with 36 additions and 9,761 deletions.
808 changes: 0 additions & 808 deletions oas_docs/output/kibana.yaml

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ export interface QueryParams {
to: string | null;
}

const LEGACY_BASE_ALERT_API_PATH = '/api/alerts';
const BASE_ALERTING_API_PATH = '/api/alerting';

const buildTimeRangeFilter = (
dataView: DataView,
Expand Down Expand Up @@ -77,7 +77,7 @@ export const getAlertUtils = (
const fetchAlert = async (id: string) => {
try {
return await core.http.get<Rule<SearchThresholdAlertParams>>(
`${LEGACY_BASE_ALERT_API_PATH}/alert/${id}`
`${BASE_ALERTING_API_PATH}/rule/${id}`
);
} catch (error) {
const errorTitle = i18n.translate('discover.viewAlert.alertRuleFetchErrorTitle', {
Expand Down
Loading

0 comments on commit 279f4ae

Please sign in to comment.