Skip to content
For the complete documentation index, see llms.txt. This page is also available as Markdown.

SLOs

This contains APIs related to CRUD operations of SLOs

Get Error budget reset history

get
Path parameters
identifierstringRequired

SLO identifier for the entity

Query parameters
accountIdstringRequired

Account Identifier for the Entity.

orgIdentifierstringOptional

Organization Identifier for the Entity.

projectIdentifierstringOptional

Project Identifier for the Entity.

Responses
400

Bad Request

This is Failure entity as defied in Harness

statusstring · enumOptionalPossible values:
codestring · enumOptionalPossible values:
messagestringOptional
correlationIdstringOptional
get/slo/{identifier}/errorBudgetResetHistory
GET /slo/{identifier}/errorBudgetResetHistory?accountId=text HTTP/1.1
Host: cv-nextgen-94fb8b655-lbzqs
Accept: */*
{
  "status": "SUCCESS",
  "code": "DEFAULT_ERROR_CODE",
  "message": "text",
  "correlationId": "text",
  "errors": [
    {
      "fieldId": "text",
      "error": "text"
    }
  ]
}

Get notification rules for SLO

get
Path parameters
identifierstringRequired

SLO identifier for the entity

Query parameters
accountIdstringRequired

Account Identifier for the Entity.

orgIdentifierstringOptional

Organization Identifier for the Entity.

projectIdentifierstringOptional

Project Identifier for the Entity.

pageNumberinteger · int32Optional

Page Index of the results to fetch.Default Value: 0

Default: 0
pageSizeinteger · int32Optional

Results per page

Default: 10
Responses
400

Bad Request

This is Failure entity as defied in Harness

statusstring · enumOptionalPossible values:
codestring · enumOptionalPossible values:
messagestringOptional
correlationIdstringOptional
get/slo/{identifier}/notification-rules
GET /slo/{identifier}/notification-rules?accountId=text HTTP/1.1
Host: cv-nextgen-94fb8b655-lbzqs
Accept: */*
{
  "status": "SUCCESS",
  "code": "DEFAULT_ERROR_CODE",
  "message": "text",
  "correlationId": "text",
  "errors": [
    {
      "fieldId": "text",
      "error": "text"
    }
  ]
}

Get SLO logs

get
Path parameters
identifierstringRequired

SLO identifier for the entity

Query parameters
accountIdstringRequired

Account Identifier for the Entity.

orgIdentifierstringOptional

Organization Identifier for the Entity.

projectIdentifierstringOptional

Project Identifier for the Entity.

logTypestring · enumRequiredPossible values:
errorLogsOnlybooleanOptional
startTimeinteger · int64Required
endTimeinteger · int64Required
pageNumberinteger · int32Optional

Page Index of the results to fetch.Default Value: 0

Default: 0
pageSizeinteger · int32Optional

Results per page

Default: 10
Responses
400

Bad Request

This is Failure entity as defied in Harness

statusstring · enumOptionalPossible values:
codestring · enumOptionalPossible values:
messagestringOptional
correlationIdstringOptional
get/slo/{identifier}/logs
GET /slo/{identifier}/logs?accountId=text&logType=ApiCallLog&startTime=1&endTime=1 HTTP/1.1
Host: cv-nextgen-94fb8b655-lbzqs
Accept: */*
{
  "status": "SUCCESS",
  "code": "DEFAULT_ERROR_CODE",
  "message": "text",
  "correlationId": "text",
  "errors": [
    {
      "fieldId": "text",
      "error": "text"
    }
  ]
}

Reset Error budget history

post
Path parameters
identifierstringRequired

SLO identifier for the entity

Query parameters
accountIdstringRequired

Account Identifier for the Entity.

orgIdentifierstringOptional

Organization Identifier for the Entity.

projectIdentifierstringOptional

Project Identifier for the Entity.

Body

This is the SLO Error Budget Reset entity defined in Harness

serviceLevelObjectiveIdentifierstringOptional
errorBudgetIncrementPercentagenumber · doubleOptional
errorBudgetIncrementMinutesinteger · int32Optional
remainingErrorBudgetAtResetinteger · int32Optional
errorBudgetAtResetinteger · int32Optional
reasonstringOptional
validUntilinteger · int64Optional
createdAtinteger · int64Optional
Responses
400

Bad Request

This is Failure entity as defied in Harness

statusstring · enumOptionalPossible values:
codestring · enumOptionalPossible values:
messagestringOptional
correlationIdstringOptional
post/slo/{identifier}/resetErrorBudget
POST /slo/{identifier}/resetErrorBudget?accountId=text HTTP/1.1
Host: cv-nextgen-94fb8b655-lbzqs
Content-Type: */*
Accept: */*
Content-Length: 209

{
  "serviceLevelObjectiveIdentifier": "text",
  "errorBudgetIncrementPercentage": 1,
  "errorBudgetIncrementMinutes": 1,
  "remainingErrorBudgetAtReset": 1,
  "errorBudgetAtReset": 1,
  "reason": "text",
  "validUntil": 1,
  "createdAt": 1
}
{
  "status": "SUCCESS",
  "code": "DEFAULT_ERROR_CODE",
  "message": "text",
  "correlationId": "text",
  "errors": [
    {
      "fieldId": "text",
      "error": "text"
    }
  ]
}

Get Metric Graph For SLO

get

Get Underlying Metrics Graph for SLO

Authorizations
Path parameters
orgstringRequired

Organization identifier

projectstringRequired

Project identifier

slo-identifierstringRequired

SLO identifier.

Query parameters
start_timeinteger · int64Optional

Start Time for the metric graphs.

end_timeinteger · int64Optional

End Time for the metric graphs.

Header parameters
Harness-AccountstringOptional

Identifier field of the account the resource is scoped to. This is required for Authorization methods other than the x-api-key header. If you are using the x-api-key header, this can be skipped.

Responses
200

Metric Graph response

application/json

Metric Graph

start_timeinteger · int64Required

Start time of the Graph Values.

end_timeinteger · int64Optional

End time of the Graph Values.

metric_namestringOptional

Name of the Metric.

metric_identifierstringOptional

Identifier of the Metric.

get/v1/orgs/{org}/projects/{project}/metric-graph/{slo-identifier}
GET /v1/orgs/{org}/projects/{project}/metric-graph/{slo-identifier} HTTP/1.1
Host: cv-nextgen-94fb8b655-lbzqs
Accept: */*
[
  {
    "start_time": 1,
    "end_time": 1,
    "data_points": [
      {
        "value": 1,
        "timestamp": 1
      }
    ],
    "metric_name": "text",
    "metric_identifier": "text"
  }
]

List SLOs

get

Returns a list of Service Level Objectives

Authorizations
Path parameters
orgstringRequired

Organization identifier

projectstringRequired

Project identifier

Query parameters
pageinteger · int32Optional

Pagination page number strategy: Specify the page number within the paginated collection related to the number of items on each page.

Default: 0
limitinteger · int32 · max: 100Optional

Pagination: Number of items to return.

Default: 20
composite_slo_identifierstringOptional

Identifier for the Composite SLO for which underlying SLOs needs to be listed.

monitored_service_identifierstringOptional

For filtering on the basis of monitored service identifier

user_journey_identifiersstring[]Optional

List of User Journey identifiers on the basis of which the SLOs are filtered.

filterstringOptional

SLO Name on the basis of which the SLOs are filtered.

Pattern: ^[a-zA-Z_][0-9a-zA-Z-_ ]{0,127}$
slo_typestring · max: 1024Optional

SLO Types on the basis of which the SLOs are filtered.

env_identifiersstring[] · max: 128Optional

Identifiers of Environments on the basis of which the SLOs are filtered.

target_typesstring[]Optional

Target Types on the basis of which the SLOs are filtered.

error_budget_risksstring[]Optional

Error Budgets on the basis of which the SLOs are filtered.

evaluation_typestringOptional

Evaluation Type on the basis of which the SLOs are filtered.

child_resourcebooleanOptional

For filtering the simple slo's on the basis of accountId. Set it to true for Account Level SLOs.

Default: false
Header parameters
Harness-AccountstringOptional

Identifier field of the account the resource is scoped to. This is required for Authorization methods other than the x-api-key header. If you are using the x-api-key header, this can be skipped.

Responses
200

SLO List Response body

application/json

Health List View of SLO.

slo_identifierstringRequired

Identifier of the SLO.

namestringRequired

Name of the SLO.

org_namestringOptional

Organization Name to which the SLO belongs.

project_namestringOptional

Project Name to which the SLO belongs.

monitored_service_identifierstringOptional

Identifier of the Monitored Service to which the SLO is associated.

monitored_service_namestringOptional

Name of the Monitored Service to which the SLO is associated.

service_identifierstringOptional

Identifier of the Service to which the SLO is associated.

health_source_identifierstringOptional

Identifier of the Health Source to which the SLO is associated.

health_source_namestringOptional

Identifier of the Health Source to which the SLO is associated.

service_namestringOptional

Name of the Service to which the SLO is associated.

environment_identifierstringOptional

Identifier of the Environment to which the SLO is associated.

environment_namestringOptional

Name of the Environment to which the SLO is associated.

tagsstring[]Optional

List of tags for SLO.

descriptionstringOptional

Description for the SLO.

user_journey_namestringOptional

Name of the first User Journey for the SLO.

burn_ratenumber · doubleRequired

Burn rate per day of the SLO. The unit is "Minutes" if the Evaluation type is Window, for Request based it's "Request".

error_budget_remaining_percentagenumber · doubleRequired

Error Budget Remaining Percentage of the SLO.

error_budget_remaininginteger · int32Required

Error Budget Remaining of the SLO. The unit is "Minutes" if the Evaluation type is Window, for Request based it's "Request".

total_error_budgetinteger · int32Required

Total Error Budget of the SLO. The unit is "Minutes" if the Evaluation type is Window, for Request based it's "Request".

slo_target_percentagenumber · doubleRequired

Target Percentage of the SLO defined by the user.

no_of_active_alertsinteger · int32Required

Number of Notification Rules defined for the SLO.

error_budget_riskstringOptional

Error Budget Risk for the SLO. - It's Healthy if Error Budget Remaining Percentage >= 75. - It's Observe if Error Budget Remaining Percentage >= 50 < 75. - It's Need Attention if Error Budget Remaining Percentage >= 25 < 50. - It's Unhealthy if Error Budget Remaining Percentage >= 0 < 25. - It's Exhausted if Error Budget Remaining Percentage < 0.

get/v1/orgs/{org}/projects/{project}/slo
GET /v1/orgs/{org}/projects/{project}/slo HTTP/1.1
Host: cv-nextgen-94fb8b655-lbzqs
Accept: */*
[
  {
    "slo_identifier": "text",
    "name": "text",
    "org_name": "text",
    "project_name": "text",
    "monitored_service_identifier": "text",
    "monitored_service_name": "text",
    "service_identifier": "text",
    "health_source_identifier": "text",
    "health_source_name": "text",
    "service_name": "text",
    "environment_identifier": "text",
    "environment_name": "text",
    "tags": [
      "text"
    ],
    "description": "text",
    "user_journey_name": "text",
    "user_journeys": [
      {
        "name": "text",
        "identifier": "text"
      }
    ],
    "burn_rate": 1,
    "error_budget_remaining_percentage": 1,
    "error_budget_remaining": 1,
    "total_error_budget": 1,
    "slo_target_type": {
      "type": "text"
    },
    "slo_type": {
      "type": "text"
    },
    "slo_target_percentage": 1,
    "no_of_active_alerts": 1,
    "evaluation_type": {
      "type": "text"
    },
    "downtime_status_details": {
      "status": {
        "status": "text"
      },
      "start_time": 1,
      "end_time": 1,
      "end_date_time": "text"
    },
    "project_params": {
      "account_identifier": "text",
      "org_identifier": "text",
      "project_identifier": "text"
    },
    "slo_error": {
      "failed_state": true,
      "error_message": "text",
      "slo_error_type": "text"
    },
    "error_budget_risk": "text"
  }
]

Last updated

Was this helpful?