Add specs for alerting namespace - #1186
Open
xluo-aws wants to merge 3 commits into
Open
Conversation
xluo-aws
requested review from
Tokesh,
VachaShah,
Xtansia,
aabeshov,
harshavamsi,
karenyrx,
lucy66hw,
sachetalva and
sean-
as code owners
August 6, 2026 06:23
Add OpenAPI specs for the Alerting plugin's REST API, covering: - Monitor create, get, update, delete, search, and execute - Alert get and acknowledge - Finding search - Destination get (deprecated, kept for backwards compatibility) - Email account and email group get, exists, and search - Scheduled-job stats Update the pre-existing opendistro-to-plugins superseded operation entries for alerting to use the same path parameter names as the new namespace file, since the merger substitutes parameter names from `superseded_by` when generating the legacy `_opendistro` aliases. Closes opensearch-project#221 Signed-off-by: Xuesong Luo <lxuesong@amazon.com>
xluo-aws
force-pushed
the
add-alerting-namespace-spec-221
branch
from
August 6, 2026 13:06
dbb79c6 to
1208986
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Adds OpenAPI specs for the Alerting plugin's REST API (
spec/namespaces/alerting.yamlandspec/schemas/alerting._common.yaml), covering the endpoints listed in #221:The pre-existing
_opendistro->_pluginssuperseded-operation entries foralertinginspec/_superseded_operations.yamlused path parameter names (monitorID,emailAccountID,emailGroupID,destinationID,nodeId,metric) that didn't match the new namespace file's parameter names. I updated thesuperseded_byvalues so the merger correctly generates the legacy_opendistro/_alerting/*aliases.Note:
POST /_plugins/_alerting/destinations, update, and delete were intentionally left out since destinations were deprecated in OpenSearch 2.0 in favor of the Notifications plugin, and the plugin's write REST handlers for destinations were removed. The read APIs remain (and are specced here) for backwards compatibility.Issues Resolved
Closes #221
Testing
npm run lint:spec- no errorsnpm run merge- merges cleanly, no new warningsnpm run lint- no errorsnpm run test:unit- 198 passed, 2 todoopenapi-spec-validatorand the Rubyjson_schemervalidators used by theValidate Spec (Python)andValidate Spec (Ruby)CI workflowsCheck List
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.