Skip to main content
GET
/
1
/
triggers
/
{datasetSlug}
/
{triggerId}
Get a Trigger
curl --request GET \
  --url https://api.honeycomb.io/1/triggers/{datasetSlug}/{triggerId} \
  --header 'X-Honeycomb-Team: <api-key>'
{
  "id": "<string>",
  "dataset_slug": "<string>",
  "name": "<string>",
  "description": "<string>",
  "tags": [
    {
      "key": "team",
      "value": "blue"
    }
  ],
  "threshold": {
    "op": ">",
    "value": 123,
    "exceeded_limit": 1
  },
  "frequency": 123,
  "alert_type": "on_change",
  "disabled": false,
  "triggered": true,
  "recipients": [
    {
      "id": "<string>",
      "type": "pagerduty",
      "target": "<string>",
      "details": {
        "pagerduty_severity": "critical",
        "variables": [
          {
            "name": "severity",
            "value": "warning"
          }
        ]
      }
    }
  ],
  "evaluation_schedule_type": "frequency",
  "evaluation_schedule": {
    "window": {
      "days_of_week": [
        "sunday"
      ],
      "start_time": "14:00",
      "end_time": "21:00"
    }
  },
  "created_at": "2023-11-07T05:31:56Z",
  "updated_at": "2023-11-07T05:31:56Z",
  "baseline_details": {
    "offset_minutes": 60,
    "type": "percentage"
  },
  "query": {},
  "query_id": "<string>"
}

Authorizations

X-Honeycomb-Team
string
header
required

A Honeycomb Configuration Key is required to use this API. A Configuration Key can be found in the API Keys section of the environment configuration, which can be found under Environment Settings -> API Keys -> Configuration tab. Check out our documentation to find your API Keys.

More information can be found in Manage Environments.

Path Parameters

datasetSlug
string
required

The dataset slug or use __all__ for endpoints that support environment-wide operations.

triggerId
string
required

The unique identifier (ID) of a Trigger.

Response

Success

id
string

The unique identifier (ID) for this Trigger.

dataset_slug
string

The slug of the dataset this trigger belongs to. For environment-wide triggers, this will be "all".

name
string

A short, human-readable name for this Trigger, which will be displayed in the UI and when the trigger fires.

Required string length: 1 - 120
description
string

A longer description, displayed on the Trigger's detail page.

Maximum string length: 1023
tags
object[]

A list of key-value pairs to help identify the Trigger.

Maximum array length: 10
Example:
[{ "key": "team", "value": "blue" }]
threshold
object

The threshold over which the trigger will fire, specified as both an operator and a value.

frequency
integer

The interval in seconds in which to check the results of the query’s calculation against the threshold. Cannot be more than 4 times the query's duration (i.e. duration <= frequency*4). See A Caveat on Time for more information on specifying a query's duration. minimum: 60 maximum: 86400 multipleOf: 60 default: 900

alert_type
enum<string>
default:on_change

How often to fire an alert when a trigger threshold is crossed.

  • on_change sends a trigger notification when the result of the specified calculation crosses the threshold. The trigger resolves only when the result of the query no longer satisfies the threshold condition.
  • on_true keeps sending a trigger notification at current frequency when and while the threshold is met. (This reflects the same behavior as the "Send an alert every time a threshold is met" checkbox in the Honeycomb UI.)
Available options:
on_change,
on_true
disabled
boolean
default:false

If true, the trigger will not be evaluated and alerts will not be sent.

triggered
boolean

If true, the trigger has crossed its specified threshold without resolving.

recipients
object[]

A list of Recipients to notify when the Trigger fires. Using type+target is deprecated. First, create the Recipient via the Recipients API, and then specify the ID.

evaluation_schedule_type
enum<string>

The schedule type used by the trigger. The default is frequency, where the trigger runs at the specified frequency. The window type means that the trigger will run at the specified frequency, but only in the time window specified in the evaluation_schedule field.

Available options:
frequency,
window
evaluation_schedule
object

A schedule that determines when the trigger is run. When the time is within the scheduled window, the trigger will be run at the specified frequency. Outside of the window, the trigger will not be run.

created_at
string<date-time>
updated_at
string<date-time>
baseline_details
object

Additional properties needed to configure this trigger with a dynamic baseline threshold.

Example:
{
"offset_minutes": 60,
"type": "percentage"
}
query
object

A query ID or an inline query that is a strict subset of a Query Specification.

query_id
string

The ID of a Query that meets the criteria for being used as a Trigger, per above.