From 0237bc4a61e917b180b5802da5d6ad7d2c25f04e Mon Sep 17 00:00:00 2001 From: "ci.datadog-api-spec" Date: Fri, 31 Jul 2026 08:41:27 +0000 Subject: [PATCH] Regenerate client from commit 98daffc of spec repo --- .generator/schemas/v2/openapi.yaml | 17 +++++++++++++++++ services/test_optimization/src/v2/index.ts | 1 + .../src/v2/models/FlakyTestAttributes.ts | 18 ++++++++++++++++++ .../src/v2/models/FlakyTestImpactLevel.ts | 13 +++++++++++++ .../src/v2/models/TypingInfo.ts | 1 + 5 files changed, 50 insertions(+) create mode 100644 services/test_optimization/src/v2/models/FlakyTestImpactLevel.ts diff --git a/.generator/schemas/v2/openapi.yaml b/.generator/schemas/v2/openapi.yaml index 0f86b6106238..80e4a6214607 100644 --- a/.generator/schemas/v2/openapi.yaml +++ b/.generator/schemas/v2/openapi.yaml @@ -38276,6 +38276,17 @@ components: items: $ref: "#/components/schemas/FlakyTestHistory" type: array + impact_level: + $ref: "#/components/schemas/FlakyTestImpactLevel" + nullable: true + impact_score: + description: A score from 0 to 1 indicating the impact of this flaky test, based on factors such as how often it fails and how many pipelines it affects. + example: 0.78 + format: double + maximum: 1 + minimum: 0 + nullable: true + type: number last_flaked_branch: description: The branch name where the test exhibited flakiness for the last time. example: main @@ -38484,6 +38495,12 @@ components: nullable: true type: array type: object + FlakyTestImpactLevel: + description: The impact level of the flaky test, derived from its impact score. + enum: [low, medium, high] + example: medium + type: string + x-enum-varnames: [LOW, MEDIUM, HIGH] FlakyTestPipelineStats: description: CI pipeline related statistics for the flaky test. This information is only available if test runs are associated with CI pipeline events from CI Visibility. properties: diff --git a/services/test_optimization/src/v2/index.ts b/services/test_optimization/src/v2/index.ts index 35b4a541f95a..39fdadd36913 100644 --- a/services/test_optimization/src/v2/index.ts +++ b/services/test_optimization/src/v2/index.ts @@ -17,6 +17,7 @@ export { FlakyTestHistory } from "./models/FlakyTestHistory"; export { FlakyTestHistoryPolicyId } from "./models/FlakyTestHistoryPolicyId"; export { FlakyTestHistoryPolicyMeta } from "./models/FlakyTestHistoryPolicyMeta"; export { FlakyTestHistoryPolicyMetaConfig } from "./models/FlakyTestHistoryPolicyMetaConfig"; +export { FlakyTestImpactLevel } from "./models/FlakyTestImpactLevel"; export { FlakyTestPipelineStats } from "./models/FlakyTestPipelineStats"; export { FlakyTestRunMetadata } from "./models/FlakyTestRunMetadata"; export { FlakyTestsPagination } from "./models/FlakyTestsPagination"; diff --git a/services/test_optimization/src/v2/models/FlakyTestAttributes.ts b/services/test_optimization/src/v2/models/FlakyTestAttributes.ts index 877b93b36375..29329d4dd46c 100644 --- a/services/test_optimization/src/v2/models/FlakyTestAttributes.ts +++ b/services/test_optimization/src/v2/models/FlakyTestAttributes.ts @@ -2,6 +2,7 @@ import { AttributeTypeMap } from "@datadog/datadog-api-client"; import { FlakyTestAttributesFlakyState } from "./FlakyTestAttributesFlakyState"; import { FlakyTestHistory } from "./FlakyTestHistory"; +import { FlakyTestImpactLevel } from "./FlakyTestImpactLevel"; import { FlakyTestPipelineStats } from "./FlakyTestPipelineStats"; import { FlakyTestRunMetadata } from "./FlakyTestRunMetadata"; import { FlakyTestStats } from "./FlakyTestStats"; @@ -50,6 +51,14 @@ export class FlakyTestAttributes { * Includes state transitions like new -> quarantined -> fixed, along with the associated commit SHA when available. */ "history"?: Array; + /** + * The impact level of the flaky test, derived from its impact score. + */ + "impactLevel"?: FlakyTestImpactLevel; + /** + * A score from 0 to 1 indicating the impact of this flaky test, based on factors such as how often it fails and how many pipelines it affects. + */ + "impactScore"?: number; /** * The branch name where the test exhibited flakiness for the last time. */ @@ -150,6 +159,15 @@ export class FlakyTestAttributes { baseName: "history", type: "Array", }, + impactLevel: { + baseName: "impact_level", + type: "FlakyTestImpactLevel", + }, + impactScore: { + baseName: "impact_score", + type: "number", + format: "double", + }, lastFlakedBranch: { baseName: "last_flaked_branch", type: "string", diff --git a/services/test_optimization/src/v2/models/FlakyTestImpactLevel.ts b/services/test_optimization/src/v2/models/FlakyTestImpactLevel.ts new file mode 100644 index 000000000000..54a9da1bdd91 --- /dev/null +++ b/services/test_optimization/src/v2/models/FlakyTestImpactLevel.ts @@ -0,0 +1,13 @@ +import { UnparsedObject } from "@datadog/datadog-api-client"; + +/** + * The impact level of the flaky test, derived from its impact score. + */ +export type FlakyTestImpactLevel = + | typeof LOW + | typeof MEDIUM + | typeof HIGH + | UnparsedObject; +export const LOW = "low"; +export const MEDIUM = "medium"; +export const HIGH = "high"; diff --git a/services/test_optimization/src/v2/models/TypingInfo.ts b/services/test_optimization/src/v2/models/TypingInfo.ts index f85638352e21..ccbdb45597db 100644 --- a/services/test_optimization/src/v2/models/TypingInfo.ts +++ b/services/test_optimization/src/v2/models/TypingInfo.ts @@ -74,6 +74,7 @@ export const TypingInfo: ModelTypingInfo = { "ftm_policy.quarantine.days_active", "unknown", ], + FlakyTestImpactLevel: ["low", "medium", "high"], FlakyTestType: ["flaky_test"], FlakyTestsSearchRequestDataType: ["search_flaky_tests_request"], FlakyTestsSearchSort: [