Type to search.

Create an SLO

Base URL
https://{kibana_url}
  • POST /api/observability/slos
  • POST /s/{space_id}/api/observability/slos
Auth

You must have all privileges for the SLOs feature in the Observability section of the Kibana feature privileges.

Required privileges

Privileges slo_write

Path parameters

space_id string optional

An identifier for the space. If space_id is not provided in the URL, the default space is used. Refer to Spaces for more information.

Header parameters

kbn-xsrf string required

A required header to protect against CSRF attacks

Request body

budgetingMethod union anyOf required

The budgeting method to use when computing the rollup data.

Values: occurrences timeslices
description string required

A description for the SLO.

groupBy union anyOf

optional group by field or fields to use to generate an SLO per distinct value

Values: *
id string · min length: 8 · max length: 48 · pattern: ^[a-z0-9-_]+$

The identifier of the SLO.

indicator union oneOf required

The indicator to use to compute the SLI

One of: (determined by type)
type: sli.apm.transactionDuration

Defines properties for the APM latency indicator type

type enum required

The type of indicator.

Values: sli.apm.transactionDuration
params object required

An object containing the indicator parameters.

dataViewId string

The kibana data view id to use, primarily used to include data view runtime mappings. Make sure to save SLO again if you add/update run time fields to the data view and if those fields are being used in slo queries.

environment union enum | string required

The APM service environment or "*"

Values: *
filter union anyOf

KQL query used for filtering the data

Any of:

the KQL query to filter the documents with.

index string required

The index used by APM metrics

service union enum | string required

The APM service name

Values: *
threshold number required

The latency threshold in milliseconds

transactionName union enum | string required

The APM transaction name or "*"

Values: *
transactionType union enum | string required

The APM transaction type or "*"

Values: *
name string required

A name for the SLO.

objective object required

Defines properties for the SLO objective

target number · > 0 · < 1 required

the target objective between 0 and 1 excluded

timesliceTarget number · min: 0 · max: 1

the target objective for each slice when using a timeslices budgeting method

timesliceWindow string · max length: 16

the duration of each slice when using a timeslices budgeting method, as {duraton}{unit}

revision number
tags string[]

List of tags

timeWindow union oneOf required

Defines properties for the SLO time window

One of: (determined by type)
type: rolling
type enum required

Indicates weither the time window is a rolling or a calendar aligned time window.

Values: rolling
duration string · max length: 16 required

the duration formatted as {duration}{unit}. Accepted values for rolling: 7d, 30d, 90d

Responses

Successful request

application/json
id string · min length: 8 · max length: 48 · pattern: ^[a-z0-9-_]+$ required

The identifier of the SLO.