mirror of
https://github.com/elastic/kibana.git
synced 2025-04-24 09:48:58 -04:00
chore(o11y): add missing access options to routes (#197511)
This commit is contained in:
parent
f25ef61d52
commit
b3d5c4b46e
3 changed files with 20 additions and 0 deletions
|
@ -98,6 +98,9 @@ export function registerAnnotationAPIs({
|
|||
validate: {
|
||||
body: unknowns,
|
||||
},
|
||||
options: {
|
||||
access: 'public',
|
||||
},
|
||||
},
|
||||
wrapRouteHandler(t.type({ body: createAnnotationRt }), ({ data, client }) => {
|
||||
return client.create(data.body);
|
||||
|
@ -110,6 +113,9 @@ export function registerAnnotationAPIs({
|
|||
validate: {
|
||||
body: unknowns,
|
||||
},
|
||||
options: {
|
||||
access: 'public',
|
||||
},
|
||||
},
|
||||
wrapRouteHandler(t.type({ body: updateAnnotationRt }), ({ data, client }) => {
|
||||
return client.update(data.body);
|
||||
|
@ -122,6 +128,9 @@ export function registerAnnotationAPIs({
|
|||
validate: {
|
||||
params: unknowns,
|
||||
},
|
||||
options: {
|
||||
access: 'public',
|
||||
},
|
||||
},
|
||||
wrapRouteHandler(t.type({ params: deleteAnnotationRt }), ({ data, client }) => {
|
||||
return client.delete(data.params);
|
||||
|
@ -134,6 +143,9 @@ export function registerAnnotationAPIs({
|
|||
validate: {
|
||||
params: unknowns,
|
||||
},
|
||||
options: {
|
||||
access: 'public',
|
||||
},
|
||||
},
|
||||
wrapRouteHandler(t.type({ params: getAnnotationByIdRt }), ({ data, client }) => {
|
||||
return client.getById(data.params);
|
||||
|
@ -146,6 +158,9 @@ export function registerAnnotationAPIs({
|
|||
validate: {
|
||||
query: unknowns,
|
||||
},
|
||||
options: {
|
||||
access: 'public',
|
||||
},
|
||||
},
|
||||
wrapRouteHandler(t.type({ query: findAnnotationRt }), ({ data, client }) => {
|
||||
return client.find(data.query);
|
||||
|
@ -158,6 +173,9 @@ export function registerAnnotationAPIs({
|
|||
validate: {
|
||||
query: unknowns,
|
||||
},
|
||||
options: {
|
||||
access: 'public',
|
||||
},
|
||||
},
|
||||
wrapRouteHandler(t.type({}), ({ client }) => {
|
||||
return client.permissions();
|
||||
|
|
|
@ -13,6 +13,7 @@ const getObservabilityAlertDetailsContextRoute = createObservabilityServerRoute(
|
|||
endpoint: 'GET /internal/observability/assistant/alert_details_contextual_insights',
|
||||
options: {
|
||||
tags: [],
|
||||
access: 'internal',
|
||||
},
|
||||
params: t.type({
|
||||
query: alertDetailsContextRt,
|
||||
|
|
|
@ -13,6 +13,7 @@ const alertsDynamicIndexPatternRoute = createObservabilityServerRoute({
|
|||
endpoint: 'GET /api/observability/rules/alerts/dynamic_index_pattern 2023-10-31',
|
||||
options: {
|
||||
tags: [],
|
||||
access: 'public',
|
||||
},
|
||||
params: t.type({
|
||||
query: t.type({
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue