home User Guide Getting Started Help Center Documentation Community Training Certification
menu
close
settings
language keyboard_arrow_down
English
Français
Deutsch
日本語
search
print
Alert : Alert

Search Alerts beta

GET/api/4.0/alerts/search
search_alerts(limit, offset, group_by, fields, disabled, frequency, condition_met, last_run_start, last_run_end, all_owners)

Implementation Notes

Search Alerts.

Response Class

  array

Parameters

Parameter Required? Description Parameter Type Data Type
limit false (Optional) Number of results to return (used with `offset`). integer int64
offset false (Optional) Number of results to skip before returning any (used with `limit`). integer int64
group_by false (Optional) Dimension by which to order the results(`dashboard` | `owner`) string string
fields false (Optional) Requested fields. string string
disabled false (Optional) Filter on returning only enabled or disabled alerts. boolean boolean
frequency false (Optional) Filter on alert frequency, such as: monthly, weekly, daily, hourly, minutes string string
condition_met false (Optional) Filter on whether the alert has met its condition when it last executed boolean boolean
last_run_start false (Optional) Filter on the start range of the last time the alerts were run. Example: 2021-01-01T01:01:01-08:00. string string
last_run_end false (Optional) Filter on the start range of the last time the alerts were run. Example: 2021-01-01T01:01:01-08:00. string string
all_owners false (Admin only) (Optional) Filter for all owners. boolean boolean

Response Messages

HTTP Status Code Reason Response Model
400 Bad Request
Error {
message (string, read-only, required): Error details,
documentation_url (string, read-only, required): Documentation link
}
404 Not Found
Error {
message (string, read-only, required): Error details,
documentation_url (string, read-only, required): Documentation link
}
403 Permission Denied
Error {
message (string, read-only, required): Error details,
documentation_url (string, read-only, required): Documentation link
}

Get an alert beta

GET/api/4.0/alerts/{alert_id}
get_alert(alert_id)

Implementation Notes

Get an alert by a given alert ID.

Response Class

Alert {
applied_dashboard_filters (Array[AlertAppliedDashboardFilter]): Filters coming from the dashboard that are applied. Example [{ "filter_title": "Name", "field_name": "distribution_centers.name", "filter_value": "Los Angeles CA" }],
comparison_type (string, required): This property informs the check what kind of comparison we are performing. Only certain condition types are valid for time series alerts. For details, refer to Setting Alert Conditions Valid values are: "EQUAL_TO", "GREATER_THAN", "GREATER_THAN_OR_EQUAL_TO", "LESS_THAN", "LESS_THAN_OR_EQUAL_TO", "INCREASES_BY", "DECREASES_BY", "CHANGES_BY".,
cron (string, required): Vixie-Style crontab specification when to run. At minumum, it has to be longer than 15 minute intervals,
custom_title (string): An optional, user-defined title for the alert,
dashboard_element_id (long): ID of the dashboard element associated with the alert. Refer to dashboard_element(),
description (string): An optional description for the alert. This supplements the title,
destinations (Array[AlertDestination], required): Array of destinations to send alerts to. Must be the same type of destination. Example [{ "destination_type": "EMAIL", "email_address": "test@test.com" }],
field (AlertField, required): The field the alert threshold is compared against when determining when to send notifications,
followed (boolean, read-only): Whether or not the user follows this alert.,
followable (boolean, read-only): Whether or not the alert is followable,
id (long, read-only): ID of the alert,
is_disabled (boolean): Whether or not the alert is disabled,
disabled_reason (string): Reason for disabling alert,
is_public (boolean): Whether or not the alert is public,
investigative_content_type (string): The type of the investigative content Valid values are: "dashboard".,
investigative_content_id (string): The ID of the investigative content. For dashboards, this will be the dashboard ID,
investigative_content_title (string, read-only): The title of the investigative content.,
lookml_dashboard_id (string): ID of the LookML dashboard associated with the alert,
lookml_link_id (string): ID of the LookML dashboard element associated with the alert,
owner_id (long, required): User id of alert owner,
owner_display_name (string, read-only): Alert owner's display name,
threshold (double, required): Value of the alert threshold,
time_series_condition_state (AlertConditionState): (Write-Only) (Optional) Only used when first creating time series alerts. It's used to pick a starting time reference from which alerts will be evaluated again. Without it, alerts be run against all time series data. Refer to docs for details. Example { latest_time_series_id: '2020-09-17', previous_time_series_id: '2020-09-16' }.
}
AlertAppliedDashboardFilter {
filter_title (string, required): Field Title. Refer to DashboardFilter.title in DashboardFilter. Example Name,
field_name (string, required): Field Name. Refer to DashboardFilter.dimension in DashboardFilter. Example distribution_centers.name,
filter_value (string, required): Field Value. Filter Expressions. Example Los Angeles CA,
filter_description (string, read-only): Human Readable Filter Description. This may be null or auto-generated. Example is Los Angeles CA
}
AlertDestination {
destination_type (string, required): Type of destination that the alert will be sent to Valid values are: "EMAIL", "ACTION_HUB".,
email_address (string): Email address for the 'email' type,
action_hub_integration_id (string): Action hub integration id for the 'action_hub' type. Integration,
action_hub_form_params_json (string): Action hub form params json for the 'action_hub' type IntegrationParam
}
AlertField {
title (string, required): Field's title. Usually auto-generated to reflect field name and its filters,
name (string, required): Field's name. Has the format <view>.<field> Refer to docs for more details,
filter (Array[AlertFieldFilter]): (Optional / Advance Use) List of fields filter. This further restricts the alert to certain dashboard element's field values. This can be used on top of dashboard filters applied_dashboard_filters. To keep thing simple, it's suggested to just use dashboard filters. Example: { 'title': '12 Number on Hand', 'name': 'inventory_items.number_on_hand', 'filter': [{ 'field_name': 'inventory_items.id', 'field_value': 12, 'filter_value': null }] }
}
AlertFieldFilter {
field_name (string, required): Field Name. Has format <view>.<field>,
field_value (any, required): Field Value. Depends on the type of field - numeric or string. For location type, it's a list of floats. Example [1.0, 56.0],
filter_value (string): Filter Value. Usually null except for location type. It'll be a string of lat,long ie '1.0,56.0'
}
AlertConditionState {
previous_time_series_id (string): (Write-Only) The second latest time string the alert has seen.,
latest_time_series_id (string): (Write-Only) Latest time string the alert has seen.
}

Parameters

Parameter Required? Description Parameter Type Data Type
alert_id true ID of an alert integer int64

Response Messages

HTTP Status Code Reason Response Model
400 Bad Request
Error {
message (string, read-only, required): Error details,
documentation_url (string, read-only, required): Documentation link
}
404 Not Found
Error {
message (string, read-only, required): Error details,
documentation_url (string, read-only, required): Documentation link
}

Update select fields on an alert beta

PATCH/api/4.0/alerts/{alert_id}
update_alert_field(alert_id, body)

Implementation Notes

Update select alert fields.

Available fields: owner_id, is_disabled, disabled_reason, is_public, threshold

#

Response Class

Alert {
applied_dashboard_filters (Array[AlertAppliedDashboardFilter]): Filters coming from the dashboard that are applied. Example [{ "filter_title": "Name", "field_name": "distribution_centers.name", "filter_value": "Los Angeles CA" }],
comparison_type (string, required): This property informs the check what kind of comparison we are performing. Only certain condition types are valid for time series alerts. For details, refer to Setting Alert Conditions Valid values are: "EQUAL_TO", "GREATER_THAN", "GREATER_THAN_OR_EQUAL_TO", "LESS_THAN", "LESS_THAN_OR_EQUAL_TO", "INCREASES_BY", "DECREASES_BY", "CHANGES_BY".,
cron (string, required): Vixie-Style crontab specification when to run. At minumum, it has to be longer than 15 minute intervals,
custom_title (string): An optional, user-defined title for the alert,
dashboard_element_id (long): ID of the dashboard element associated with the alert. Refer to dashboard_element(),
description (string): An optional description for the alert. This supplements the title,
destinations (Array[AlertDestination], required): Array of destinations to send alerts to. Must be the same type of destination. Example [{ "destination_type": "EMAIL", "email_address": "test@test.com" }],
field (AlertField, required): The field the alert threshold is compared against when determining when to send notifications,
followed (boolean, read-only): Whether or not the user follows this alert.,
followable (boolean, read-only): Whether or not the alert is followable,
id (long, read-only): ID of the alert,
is_disabled (boolean): Whether or not the alert is disabled,
disabled_reason (string): Reason for disabling alert,
is_public (boolean): Whether or not the alert is public,
investigative_content_type (string): The type of the investigative content Valid values are: "dashboard".,
investigative_content_id (string): The ID of the investigative content. For dashboards, this will be the dashboard ID,
investigative_content_title (string, read-only): The title of the investigative content.,
lookml_dashboard_id (string): ID of the LookML dashboard associated with the alert,
lookml_link_id (string): ID of the LookML dashboard element associated with the alert,
owner_id (long, required): User id of alert owner,
owner_display_name (string, read-only): Alert owner's display name,
threshold (double, required): Value of the alert threshold,
time_series_condition_state (AlertConditionState): (Write-Only) (Optional) Only used when first creating time series alerts. It's used to pick a starting time reference from which alerts will be evaluated again. Without it, alerts be run against all time series data. Refer to docs for details. Example { latest_time_series_id: '2020-09-17', previous_time_series_id: '2020-09-16' }.
}
AlertAppliedDashboardFilter {
filter_title (string, required): Field Title. Refer to DashboardFilter.title in DashboardFilter. Example Name,
field_name (string, required): Field Name. Refer to DashboardFilter.dimension in DashboardFilter. Example distribution_centers.name,
filter_value (string, required): Field Value. Filter Expressions. Example Los Angeles CA,
filter_description (string, read-only): Human Readable Filter Description. This may be null or auto-generated. Example is Los Angeles CA
}
AlertDestination {
destination_type (string, required): Type of destination that the alert will be sent to Valid values are: "EMAIL", "ACTION_HUB".,
email_address (string): Email address for the 'email' type,
action_hub_integration_id (string): Action hub integration id for the 'action_hub' type. Integration,
action_hub_form_params_json (string): Action hub form params json for the 'action_hub' type IntegrationParam
}
AlertField {
title (string, required): Field's title. Usually auto-generated to reflect field name and its filters,
name (string, required): Field's name. Has the format <view>.<field> Refer to docs for more details,
filter (Array[AlertFieldFilter]): (Optional / Advance Use) List of fields filter. This further restricts the alert to certain dashboard element's field values. This can be used on top of dashboard filters applied_dashboard_filters. To keep thing simple, it's suggested to just use dashboard filters. Example: { 'title': '12 Number on Hand', 'name': 'inventory_items.number_on_hand', 'filter': [{ 'field_name': 'inventory_items.id', 'field_value': 12, 'filter_value': null }] }
}
AlertFieldFilter {
field_name (string, required): Field Name. Has format <view>.<field>,
field_value (any, required): Field Value. Depends on the type of field - numeric or string. For location type, it's a list of floats. Example [1.0, 56.0],
filter_value (string): Filter Value. Usually null except for location type. It'll be a string of lat,long ie '1.0,56.0'
}
AlertConditionState {
previous_time_series_id (string): (Write-Only) The second latest time string the alert has seen.,
latest_time_series_id (string): (Write-Only) Latest time string the alert has seen.
}

Parameters

Parameter Required? Description Parameter Type Data Type
alert_id true ID of an alert integer int64
body true Alert body
AlertPatch {
owner_id (long): New owner ID of the alert,
is_disabled (boolean): Set alert enabled or disabled,
disabled_reason (string): The reason this alert is disabled,
is_public (boolean): Set alert public or private,
threshold (double): New threshold value
}

Response Messages

HTTP Status Code Reason Response Model
400 Bad Request
Error {
message (string, read-only, required): Error details,
documentation_url (string, read-only, required): Documentation link
}
404 Not Found
Error {
message (string, read-only, required): Error details,
documentation_url (string, read-only, required): Documentation link
}
422 Validation Error
ValidationError {
message (string, read-only, required): Error details,
errors (Array[ValidationErrorDetail], read-only): Error detail array,
documentation_url (string, read-only, required): Documentation link
}
ValidationErrorDetail {
field (string, read-only): Field with error,
code (string, read-only): Error code,
message (string, read-only): Error info message,
documentation_url (string, read-only, required): Documentation link
}
429 Too Many Requests
Error {
message (string, read-only, required): Error details,
documentation_url (string, read-only, required): Documentation link
}
403 Permission Denied
Error {
message (string, read-only, required): Error details,
documentation_url (string, read-only, required): Documentation link
}

Update an alert beta

PUT/api/4.0/alerts/{alert_id}
update_alert(alert_id, body)

Implementation Notes

Update an alert.

Required fields: owner_id, field, destinations, comparison_type, threshold, cron

#

Response Class

Alert {
applied_dashboard_filters (Array[AlertAppliedDashboardFilter]): Filters coming from the dashboard that are applied. Example [{ "filter_title": "Name", "field_name": "distribution_centers.name", "filter_value": "Los Angeles CA" }],
comparison_type (string, required): This property informs the check what kind of comparison we are performing. Only certain condition types are valid for time series alerts. For details, refer to Setting Alert Conditions Valid values are: "EQUAL_TO", "GREATER_THAN", "GREATER_THAN_OR_EQUAL_TO", "LESS_THAN", "LESS_THAN_OR_EQUAL_TO", "INCREASES_BY", "DECREASES_BY", "CHANGES_BY".,
cron (string, required): Vixie-Style crontab specification when to run. At minumum, it has to be longer than 15 minute intervals,
custom_title (string): An optional, user-defined title for the alert,
dashboard_element_id (long): ID of the dashboard element associated with the alert. Refer to dashboard_element(),
description (string): An optional description for the alert. This supplements the title,
destinations (Array[AlertDestination], required): Array of destinations to send alerts to. Must be the same type of destination. Example [{ "destination_type": "EMAIL", "email_address": "test@test.com" }],
field (AlertField, required): The field the alert threshold is compared against when determining when to send notifications,
followed (boolean, read-only): Whether or not the user follows this alert.,
followable (boolean, read-only): Whether or not the alert is followable,
id (long, read-only): ID of the alert,
is_disabled (boolean): Whether or not the alert is disabled,
disabled_reason (string): Reason for disabling alert,
is_public (boolean): Whether or not the alert is public,
investigative_content_type (string): The type of the investigative content Valid values are: "dashboard".,
investigative_content_id (string): The ID of the investigative content. For dashboards, this will be the dashboard ID,
investigative_content_title (string, read-only): The title of the investigative content.,
lookml_dashboard_id (string): ID of the LookML dashboard associated with the alert,
lookml_link_id (string): ID of the LookML dashboard element associated with the alert,
owner_id (long, required): User id of alert owner,
owner_display_name (string, read-only): Alert owner's display name,
threshold (double, required): Value of the alert threshold,
time_series_condition_state (AlertConditionState): (Write-Only) (Optional) Only used when first creating time series alerts. It's used to pick a starting time reference from which alerts will be evaluated again. Without it, alerts be run against all time series data. Refer to docs for details. Example { latest_time_series_id: '2020-09-17', previous_time_series_id: '2020-09-16' }.
}
AlertAppliedDashboardFilter {
filter_title (string, required): Field Title. Refer to DashboardFilter.title in DashboardFilter. Example Name,
field_name (string, required): Field Name. Refer to DashboardFilter.dimension in DashboardFilter. Example distribution_centers.name,
filter_value (string, required): Field Value. Filter Expressions. Example Los Angeles CA,
filter_description (string, read-only): Human Readable Filter Description. This may be null or auto-generated. Example is Los Angeles CA
}
AlertDestination {
destination_type (string, required): Type of destination that the alert will be sent to Valid values are: "EMAIL", "ACTION_HUB".,
email_address (string): Email address for the 'email' type,
action_hub_integration_id (string): Action hub integration id for the 'action_hub' type. Integration,
action_hub_form_params_json (string): Action hub form params json for the 'action_hub' type IntegrationParam
}
AlertField {
title (string, required): Field's title. Usually auto-generated to reflect field name and its filters,
name (string, required): Field's name. Has the format <view>.<field> Refer to docs for more details,
filter (Array[AlertFieldFilter]): (Optional / Advance Use) List of fields filter. This further restricts the alert to certain dashboard element's field values. This can be used on top of dashboard filters applied_dashboard_filters. To keep thing simple, it's suggested to just use dashboard filters. Example: { 'title': '12 Number on Hand', 'name': 'inventory_items.number_on_hand', 'filter': [{ 'field_name': 'inventory_items.id', 'field_value': 12, 'filter_value': null }] }
}
AlertFieldFilter {
field_name (string, required): Field Name. Has format <view>.<field>,
field_value (any, required): Field Value. Depends on the type of field - numeric or string. For location type, it's a list of floats. Example [1.0, 56.0],
filter_value (string): Filter Value. Usually null except for location type. It'll be a string of lat,long ie '1.0,56.0'
}
AlertConditionState {
previous_time_series_id (string): (Write-Only) The second latest time string the alert has seen.,
latest_time_series_id (string): (Write-Only) Latest time string the alert has seen.
}

Parameters

Parameter Required? Description Parameter Type Data Type
alert_id true ID of an alert integer int64
body true Alert body
Alert {
applied_dashboard_filters (Array[AlertAppliedDashboardFilter]): Filters coming from the dashboard that are applied. Example [{ "filter_title": "Name", "field_name": "distribution_centers.name", "filter_value": "Los Angeles CA" }],
comparison_type (string, required): This property informs the check what kind of comparison we are performing. Only certain condition types are valid for time series alerts. For details, refer to Setting Alert Conditions Valid values are: "EQUAL_TO", "GREATER_THAN", "GREATER_THAN_OR_EQUAL_TO", "LESS_THAN", "LESS_THAN_OR_EQUAL_TO", "INCREASES_BY", "DECREASES_BY", "CHANGES_BY".,
cron (string, required): Vixie-Style crontab specification when to run. At minumum, it has to be longer than 15 minute intervals,
custom_title (string): An optional, user-defined title for the alert,
dashboard_element_id (long): ID of the dashboard element associated with the alert. Refer to dashboard_element(),
description (string): An optional description for the alert. This supplements the title,
destinations (Array[AlertDestination], required): Array of destinations to send alerts to. Must be the same type of destination. Example [{ "destination_type": "EMAIL", "email_address": "test@test.com" }],
field (AlertField, required): The field the alert threshold is compared against when determining when to send notifications,
followed (boolean, read-only): Whether or not the user follows this alert.,
followable (boolean, read-only): Whether or not the alert is followable,
id (long, read-only): ID of the alert,
is_disabled (boolean): Whether or not the alert is disabled,
disabled_reason (string): Reason for disabling alert,
is_public (boolean): Whether or not the alert is public,
investigative_content_type (string): The type of the investigative content Valid values are: "dashboard".,
investigative_content_id (string): The ID of the investigative content. For dashboards, this will be the dashboard ID,
investigative_content_title (string, read-only): The title of the investigative content.,
lookml_dashboard_id (string): ID of the LookML dashboard associated with the alert,
lookml_link_id (string): ID of the LookML dashboard element associated with the alert,
owner_id (long, required): User id of alert owner,
owner_display_name (string, read-only): Alert owner's display name,
threshold (double, required): Value of the alert threshold,
time_series_condition_state (AlertConditionState): (Write-Only) (Optional) Only used when first creating time series alerts. It's used to pick a starting time reference from which alerts will be evaluated again. Without it, alerts be run against all time series data. Refer to docs for details. Example { latest_time_series_id: '2020-09-17', previous_time_series_id: '2020-09-16' }.
}
AlertAppliedDashboardFilter {
filter_title (string, required): Field Title. Refer to DashboardFilter.title in DashboardFilter. Example Name,
field_name (string, required): Field Name. Refer to DashboardFilter.dimension in DashboardFilter. Example distribution_centers.name,
filter_value (string, required): Field Value. Filter Expressions. Example Los Angeles CA,
filter_description (string, read-only): Human Readable Filter Description. This may be null or auto-generated. Example is Los Angeles CA
}
AlertDestination {
destination_type (string, required): Type of destination that the alert will be sent to Valid values are: "EMAIL", "ACTION_HUB".,
email_address (string): Email address for the 'email' type,
action_hub_integration_id (string): Action hub integration id for the 'action_hub' type. Integration,
action_hub_form_params_json (string): Action hub form params json for the 'action_hub' type IntegrationParam
}
AlertField {
title (string, required): Field's title. Usually auto-generated to reflect field name and its filters,
name (string, required): Field's name. Has the format <view>.<field> Refer to docs for more details,
filter (Array[AlertFieldFilter]): (Optional / Advance Use) List of fields filter. This further restricts the alert to certain dashboard element's field values. This can be used on top of dashboard filters applied_dashboard_filters. To keep thing simple, it's suggested to just use dashboard filters. Example: { 'title': '12 Number on Hand', 'name': 'inventory_items.number_on_hand', 'filter': [{ 'field_name': 'inventory_items.id', 'field_value': 12, 'filter_value': null }] }
}
AlertFieldFilter {
field_name (string, required): Field Name. Has format <view>.<field>,
field_value (any, required): Field Value. Depends on the type of field - numeric or string. For location type, it's a list of floats. Example [1.0, 56.0],
filter_value (string): Filter Value. Usually null except for location type. It'll be a string of lat,long ie '1.0,56.0'
}
AlertConditionState {
previous_time_series_id (string): (Write-Only) The second latest time string the alert has seen.,
latest_time_series_id (string): (Write-Only) Latest time string the alert has seen.
}

Response Messages

HTTP Status Code Reason Response Model
400 Bad Request
Error {
message (string, read-only, required): Error details,
documentation_url (string, read-only, required): Documentation link
}
404 Not Found
Error {
message (string, read-only, required): Error details,
documentation_url (string, read-only, required): Documentation link
}
422 Validation Error
ValidationError {
message (string, read-only, required): Error details,
errors (Array[ValidationErrorDetail], read-only): Error detail array,
documentation_url (string, read-only, required): Documentation link
}
ValidationErrorDetail {
field (string, read-only): Field with error,
code (string, read-only): Error code,
message (string, read-only): Error info message,
documentation_url (string, read-only, required): Documentation link
}
429 Too Many Requests
Error {
message (string, read-only, required): Error details,
documentation_url (string, read-only, required): Documentation link
}

Delete an alert beta

DELETE/api/4.0/alerts/{alert_id}
delete_alert(alert_id)

Implementation Notes

Delete an alert by a given alert ID.

Response Class

  None

Parameters

Parameter Required? Description Parameter Type Data Type
alert_id true ID of an alert integer int64

Response Messages

HTTP Status Code Reason Response Model
400 Bad Request
Error {
message (string, read-only, required): Error details,
documentation_url (string, read-only, required): Documentation link
}
404 Not Found
Error {
message (string, read-only, required): Error details,
documentation_url (string, read-only, required): Documentation link
}
429 Too Many Requests
Error {
message (string, read-only, required): Error details,
documentation_url (string, read-only, required): Documentation link
}
403 Permission Denied
Error {
message (string, read-only, required): Error details,
documentation_url (string, read-only, required): Documentation link
}
204 Alert successfully deleted.

Create an alert beta

POST/api/4.0/alerts
create_alert(body)

Implementation Notes

Create a new alert and return details of the newly created object.

Required fields: field, destinations, comparison_type, threshold, cron

Example Request: Run alert on dashboard element ‘103’ at 5am every day. Send an email to ‘test@test.com’ if inventory for Los Angeles (using dashboard filter Warehouse Name) is lower than 1,000

{
  "cron": "0 5 * * *",
  "custom_title": "Alert when LA inventory is low",
  "dashboard_element_id": 103,
  "applied_dashboard_filters": [
    {
      "filter_title": "Warehouse Name",
      "field_name": "distribution_centers.name",
      "filter_value": "Los Angeles CA",
      "filter_description": "is Los Angeles CA"
    }
  ],
  "comparison_type": "LESS_THAN",
  "destinations": [
    {
      "destination_type": "EMAIL",
      "email_address": "test@test.com"
    }
  ],
  "field": {
    "title": "Number on Hand",
    "name": "inventory_items.number_on_hand"
  },
  "is_disabled": false,
  "is_public": true,
  "threshold": 1000
}

Response Class

Alert {
applied_dashboard_filters (Array[AlertAppliedDashboardFilter]): Filters coming from the dashboard that are applied. Example [{ "filter_title": "Name", "field_name": "distribution_centers.name", "filter_value": "Los Angeles CA" }],
comparison_type (string, required): This property informs the check what kind of comparison we are performing. Only certain condition types are valid for time series alerts. For details, refer to Setting Alert Conditions Valid values are: "EQUAL_TO", "GREATER_THAN", "GREATER_THAN_OR_EQUAL_TO", "LESS_THAN", "LESS_THAN_OR_EQUAL_TO", "INCREASES_BY", "DECREASES_BY", "CHANGES_BY".,
cron (string, required): Vixie-Style crontab specification when to run. At minumum, it has to be longer than 15 minute intervals,
custom_title (string): An optional, user-defined title for the alert,
dashboard_element_id (long): ID of the dashboard element associated with the alert. Refer to dashboard_element(),
description (string): An optional description for the alert. This supplements the title,
destinations (Array[AlertDestination], required): Array of destinations to send alerts to. Must be the same type of destination. Example [{ "destination_type": "EMAIL", "email_address": "test@test.com" }],
field (AlertField, required): The field the alert threshold is compared against when determining when to send notifications,
followed (boolean, read-only): Whether or not the user follows this alert.,
followable (boolean, read-only): Whether or not the alert is followable,
id (long, read-only): ID of the alert,
is_disabled (boolean): Whether or not the alert is disabled,
disabled_reason (string): Reason for disabling alert,
is_public (boolean): Whether or not the alert is public,
investigative_content_type (string): The type of the investigative content Valid values are: "dashboard".,
investigative_content_id (string): The ID of the investigative content. For dashboards, this will be the dashboard ID,
investigative_content_title (string, read-only): The title of the investigative content.,
lookml_dashboard_id (string): ID of the LookML dashboard associated with the alert,
lookml_link_id (string): ID of the LookML dashboard element associated with the alert,
owner_id (long, required): User id of alert owner,
owner_display_name (string, read-only): Alert owner's display name,
threshold (double, required): Value of the alert threshold,
time_series_condition_state (AlertConditionState): (Write-Only) (Optional) Only used when first creating time series alerts. It's used to pick a starting time reference from which alerts will be evaluated again. Without it, alerts be run against all time series data. Refer to docs for details. Example { latest_time_series_id: '2020-09-17', previous_time_series_id: '2020-09-16' }.
}
AlertAppliedDashboardFilter {
filter_title (string, required): Field Title. Refer to DashboardFilter.title in DashboardFilter. Example Name,
field_name (string, required): Field Name. Refer to DashboardFilter.dimension in DashboardFilter. Example distribution_centers.name,
filter_value (string, required): Field Value. Filter Expressions. Example Los Angeles CA,
filter_description (string, read-only): Human Readable Filter Description. This may be null or auto-generated. Example is Los Angeles CA
}
AlertDestination {
destination_type (string, required): Type of destination that the alert will be sent to Valid values are: "EMAIL", "ACTION_HUB".,
email_address (string): Email address for the 'email' type,
action_hub_integration_id (string): Action hub integration id for the 'action_hub' type. Integration,
action_hub_form_params_json (string): Action hub form params json for the 'action_hub' type IntegrationParam
}
AlertField {
title (string, required): Field's title. Usually auto-generated to reflect field name and its filters,
name (string, required): Field's name. Has the format <view>.<field> Refer to docs for more details,
filter (Array[AlertFieldFilter]): (Optional / Advance Use) List of fields filter. This further restricts the alert to certain dashboard element's field values. This can be used on top of dashboard filters applied_dashboard_filters. To keep thing simple, it's suggested to just use dashboard filters. Example: { 'title': '12 Number on Hand', 'name': 'inventory_items.number_on_hand', 'filter': [{ 'field_name': 'inventory_items.id', 'field_value': 12, 'filter_value': null }] }
}
AlertFieldFilter {
field_name (string, required): Field Name. Has format <view>.<field>,
field_value (any, required): Field Value. Depends on the type of field - numeric or string. For location type, it's a list of floats. Example [1.0, 56.0],
filter_value (string): Filter Value. Usually null except for location type. It'll be a string of lat,long ie '1.0,56.0'
}
AlertConditionState {
previous_time_series_id (string): (Write-Only) The second latest time string the alert has seen.,
latest_time_series_id (string): (Write-Only) Latest time string the alert has seen.
}

Parameters

Parameter Required? Description Parameter Type Data Type
body true Alert body
Alert {
applied_dashboard_filters (Array[AlertAppliedDashboardFilter]): Filters coming from the dashboard that are applied. Example [{ "filter_title": "Name", "field_name": "distribution_centers.name", "filter_value": "Los Angeles CA" }],
comparison_type (string, required): This property informs the check what kind of comparison we are performing. Only certain condition types are valid for time series alerts. For details, refer to Setting Alert Conditions Valid values are: "EQUAL_TO", "GREATER_THAN", "GREATER_THAN_OR_EQUAL_TO", "LESS_THAN", "LESS_THAN_OR_EQUAL_TO", "INCREASES_BY", "DECREASES_BY", "CHANGES_BY".,
cron (string, required): Vixie-Style crontab specification when to run. At minumum, it has to be longer than 15 minute intervals,
custom_title (string): An optional, user-defined title for the alert,
dashboard_element_id (long): ID of the dashboard element associated with the alert. Refer to dashboard_element(),
description (string): An optional description for the alert. This supplements the title,
destinations (Array[AlertDestination], required): Array of destinations to send alerts to. Must be the same type of destination. Example [{ "destination_type": "EMAIL", "email_address": "test@test.com" }],
field (AlertField, required): The field the alert threshold is compared against when determining when to send notifications,
followed (boolean, read-only): Whether or not the user follows this alert.,
followable (boolean, read-only): Whether or not the alert is followable,
id (long, read-only): ID of the alert,
is_disabled (boolean): Whether or not the alert is disabled,
disabled_reason (string): Reason for disabling alert,
is_public (boolean): Whether or not the alert is public,
investigative_content_type (string): The type of the investigative content Valid values are: "dashboard".,
investigative_content_id (string): The ID of the investigative content. For dashboards, this will be the dashboard ID,
investigative_content_title (string, read-only): The title of the investigative content.,
lookml_dashboard_id (string): ID of the LookML dashboard associated with the alert,
lookml_link_id (string): ID of the LookML dashboard element associated with the alert,
owner_id (long, required): User id of alert owner,
owner_display_name (string, read-only): Alert owner's display name,
threshold (double, required): Value of the alert threshold,
time_series_condition_state (AlertConditionState): (Write-Only) (Optional) Only used when first creating time series alerts. It's used to pick a starting time reference from which alerts will be evaluated again. Without it, alerts be run against all time series data. Refer to docs for details. Example { latest_time_series_id: '2020-09-17', previous_time_series_id: '2020-09-16' }.
}
AlertAppliedDashboardFilter {
filter_title (string, required): Field Title. Refer to DashboardFilter.title in DashboardFilter. Example Name,
field_name (string, required): Field Name. Refer to DashboardFilter.dimension in DashboardFilter. Example distribution_centers.name,
filter_value (string, required): Field Value. Filter Expressions. Example Los Angeles CA,
filter_description (string, read-only): Human Readable Filter Description. This may be null or auto-generated. Example is Los Angeles CA
}
AlertDestination {
destination_type (string, required): Type of destination that the alert will be sent to Valid values are: "EMAIL", "ACTION_HUB".,
email_address (string): Email address for the 'email' type,
action_hub_integration_id (string): Action hub integration id for the 'action_hub' type. Integration,
action_hub_form_params_json (string): Action hub form params json for the 'action_hub' type IntegrationParam
}
AlertField {
title (string, required): Field's title. Usually auto-generated to reflect field name and its filters,
name (string, required): Field's name. Has the format <view>.<field> Refer to docs for more details,
filter (Array[AlertFieldFilter]): (Optional / Advance Use) List of fields filter. This further restricts the alert to certain dashboard element's field values. This can be used on top of dashboard filters applied_dashboard_filters. To keep thing simple, it's suggested to just use dashboard filters. Example: { 'title': '12 Number on Hand', 'name': 'inventory_items.number_on_hand', 'filter': [{ 'field_name': 'inventory_items.id', 'field_value': 12, 'filter_value': null }] }
}
AlertFieldFilter {
field_name (string, required): Field Name. Has format <view>.<field>,
field_value (any, required): Field Value. Depends on the type of field - numeric or string. For location type, it's a list of floats. Example [1.0, 56.0],
filter_value (string): Filter Value. Usually null except for location type. It'll be a string of lat,long ie '1.0,56.0'
}
AlertConditionState {
previous_time_series_id (string): (Write-Only) The second latest time string the alert has seen.,
latest_time_series_id (string): (Write-Only) Latest time string the alert has seen.
}

Response Messages

HTTP Status Code Reason Response Model
400 Bad Request
Error {
message (string, read-only, required): Error details,
documentation_url (string, read-only, required): Documentation link
}
404 Not Found
Error {
message (string, read-only, required): Error details,
documentation_url (string, read-only, required): Documentation link
}
409 Resource Already Exists
Error {
message (string, read-only, required): Error details,
documentation_url (string, read-only, required): Documentation link
}
422 Validation Error
ValidationError {
message (string, read-only, required): Error details,
errors (Array[ValidationErrorDetail], read-only): Error detail array,
documentation_url (string, read-only, required): Documentation link
}
ValidationErrorDetail {
field (string, read-only): Field with error,
code (string, read-only): Error code,
message (string, read-only): Error info message,
documentation_url (string, read-only, required): Documentation link
}
429 Too Many Requests
Error {
message (string, read-only, required): Error details,
documentation_url (string, read-only, required): Documentation link
}
405 Resource Can’t Be Modified
Error {
message (string, read-only, required): Error details,
documentation_url (string, read-only, required): Documentation link
}

Enqueue an alert beta

POST/api/4.0/alerts/{alert_id}/enqueue
enqueue_alert(alert_id, force)

Implementation Notes

Enqueue an Alert by ID.

Response Class

  None

Parameters

Parameter Required? Description Parameter Type Data Type
alert_id true ID of an alert integer int64
force false Whether to enqueue an alert again if its already running. boolean boolean

Response Messages

HTTP Status Code Reason Response Model
400 Bad Request
Error {
message (string, read-only, required): Error details,
documentation_url (string, read-only, required): Documentation link
}
403 Permission Denied
Error {
message (string, read-only, required): Error details,
documentation_url (string, read-only, required): Documentation link
}
404 Not Found
Error {
message (string, read-only, required): Error details,
documentation_url (string, read-only, required): Documentation link
}
204 Alert successfully added to the queue. Does not indicate it has been run
Top