Skip to content

Commit

Permalink
fix: add field validation for anomaly detector results (#1126) (#1194) (
Browse files Browse the repository at this point in the history
#1207)

(cherry picked from commit eb8a099)

Signed-off-by: Laurin Heilmeyer <me@heilmela.eu>
Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Laurin Heilmeyer <me@heilmela.eu>
  • Loading branch information
3 people authored Feb 6, 2025
1 parent b697099 commit b62c1ad
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion server/routes/anomalyDetector.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,11 @@ export default function (services, router, dataSourceEnabled) {
params: schema.object({
detectorId: schema.string(),
}),
query: createValidateQuerySchema(dataSourceEnabled),
query: createValidateQuerySchema(dataSourceEnabled, {
startTime: schema.maybe(schema.number()),
endTime: schema.maybe(schema.number()),
preview: schema.maybe(schema.boolean()),
}),
},
},
anomalyDetectorService.getDetectorResults
Expand Down

0 comments on commit b62c1ad

Please sign in to comment.