From 018a352ab8f193c9d6a2c04a0404d6f63b07d662 Mon Sep 17 00:00:00 2001 From: Faisal Kanout Date: Tue, 10 Dec 2024 17:00:43 +0100 Subject: [PATCH] [OBS-UX-MGTM][Uptime] Change API access to new authz authorization paradigm (#203415) ## Summary It fixes #203319 And mostly covered by https://github.com/elastic/kibana/pull/198374 --- .../server/legacy_uptime/routes/monitors/monitor_list.ts | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/x-pack/plugins/observability_solution/uptime/server/legacy_uptime/routes/monitors/monitor_list.ts b/x-pack/plugins/observability_solution/uptime/server/legacy_uptime/routes/monitors/monitor_list.ts index f0d24a8316729..9e33ea01612af 100644 --- a/x-pack/plugins/observability_solution/uptime/server/legacy_uptime/routes/monitors/monitor_list.ts +++ b/x-pack/plugins/observability_solution/uptime/server/legacy_uptime/routes/monitors/monitor_list.ts @@ -23,8 +23,10 @@ export const createMonitorListRoute: UMRestApiRouteFactory = (libs) => ({ pageSize: schema.number(), }), }, - options: { - tags: ['access:uptime-read'], + security: { + authz: { + requiredPrivileges: ['uptime-read'], + }, }, handler: async ({ uptimeEsClient, request, response }): Promise => { const { dateRangeStart, dateRangeEnd, filters, pagination, statusFilter, pageSize, query } =