Add API spec for severity modifiers automation pipelines - #4765
Open
api-clients-generation-pipeline[bot] wants to merge 1 commit into
Open
Add API spec for severity modifiers automation pipelines#4765api-clients-generation-pipeline[bot] wants to merge 1 commit into
api-clients-generation-pipeline[bot] wants to merge 1 commit into
Conversation
api-clients-generation-pipeline
Bot
requested review from
a team
as code owners
August 3, 2026 08:42
api-clients-generation-pipeline
Bot
force-pushed
the
datadog-api-spec/generated/6306
branch
from
August 3, 2026 09:41
37aa25d to
adc1ba6
Compare
Comment on lines
+10920
to
+11004
| const body: DueDateRuleResponse = ObjectSerializer.deserialize( | ||
| ObjectSerializer.parse(await response.body.text(), contentType), | ||
| "DueDateRuleResponse" | ||
| ) as DueDateRuleResponse; | ||
| return body; | ||
| } | ||
| if (response.httpStatusCode === 400 || response.httpStatusCode === 422) { | ||
| const bodyText = ObjectSerializer.parse( | ||
| await response.body.text(), | ||
| contentType | ||
| ); | ||
| let body: JSONAPIErrorResponse; | ||
| try { | ||
| body = ObjectSerializer.deserialize( | ||
| bodyText, | ||
| "JSONAPIErrorResponse" | ||
| ) as JSONAPIErrorResponse; | ||
| } catch (error) { | ||
| logger.debug(`Got error deserializing error: ${error}`); | ||
| throw new ApiException<JSONAPIErrorResponse>( | ||
| response.httpStatusCode, | ||
| bodyText | ||
| ); | ||
| } | ||
| throw new ApiException<JSONAPIErrorResponse>( | ||
| response.httpStatusCode, | ||
| body | ||
| ); | ||
| } | ||
| if (response.httpStatusCode === 403 || response.httpStatusCode === 429) { | ||
| const bodyText = ObjectSerializer.parse( | ||
| await response.body.text(), | ||
| contentType | ||
| ); | ||
| let body: APIErrorResponse; | ||
| try { | ||
| body = ObjectSerializer.deserialize( | ||
| bodyText, | ||
| "APIErrorResponse" | ||
| ) as APIErrorResponse; | ||
| } catch (error) { | ||
| logger.debug(`Got error deserializing error: ${error}`); | ||
| throw new ApiException<APIErrorResponse>( | ||
| response.httpStatusCode, | ||
| bodyText | ||
| ); | ||
| } | ||
| throw new ApiException<APIErrorResponse>(response.httpStatusCode, body); | ||
| } | ||
|
|
||
| // Work around for missing responses in specification, e.g. for petstore.yaml | ||
| if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) { | ||
| const body: DueDateRuleResponse = ObjectSerializer.deserialize( | ||
| ObjectSerializer.parse(await response.body.text(), contentType), | ||
| "DueDateRuleResponse", | ||
| "" | ||
| ) as DueDateRuleResponse; | ||
| return body; | ||
| } | ||
|
|
||
| const body = (await response.body.text()) || ""; | ||
| throw new ApiException<string>( | ||
| response.httpStatusCode, | ||
| 'Unknown API Status Code!\nBody: "' + body + '"' | ||
| ); | ||
| } | ||
|
|
||
| /** | ||
| * Unwraps the actual response sent by the server from the response context and deserializes the response content | ||
| * to the expected objects | ||
| * | ||
| * @params response Response returned by the server for a request to createSecurityFindingsAutomationMuteRule | ||
| * @throws ApiException if the response code was not in [200, 299] | ||
| */ | ||
| public async createSecurityFindingsAutomationMuteRule( | ||
| response: ResponseContext | ||
| ): Promise<MuteRuleResponse> { | ||
| const contentType = ObjectSerializer.normalizeMediaType( | ||
| response.headers["content-type"] | ||
| ); | ||
| if (response.httpStatusCode === 201) { | ||
| const body: MuteRuleResponse = ObjectSerializer.deserialize( | ||
| ObjectSerializer.parse(await response.body.text(), contentType), | ||
| "DueDateRuleResponse" | ||
| ) as DueDateRuleResponse; | ||
| "MuteRuleResponse" | ||
| ) as MuteRuleResponse; |
There was a problem hiding this comment.
There is no due date / mute rules change, it's just the git diff algorithm being confused about which lines were "moved" vs "added".
BusyBeaver-42
approved these changes
Aug 3, 2026
BusyBeaver-42
left a comment
There was a problem hiding this comment.
No diff unrelated to severity modifiers.
api-clients-generation-pipeline
Bot
force-pushed
the
datadog-api-spec/generated/6306
branch
from
August 4, 2026 16:48
adc1ba6 to
c509281
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.
See DataDog/datadog-api-spec#6306 Test branch datadog-api-spec/test/romain.ageron/severity-modifiers-spec