---
title: 인시던트 규칙 목록 표시
description: 모든 인시던트 규칙을 나열합니다.
breadcrumbs: 문서 > API > 인시던트 규칙 목록 표시
---

> For the complete documentation index, see [llms.txt](https://dnd37xeb23o8n.cloudfront.net/stefon.simmons/docs-astro-web-10435/llms.txt).

# 인시던트 규칙 목록 표시

## v2 (latest)

{% alert level="warning" %}
**Note**: This endpoint is in preview and is subject to change.
If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help.md).
{% /alert %}

| Datadog site      | API endpoint                                                    |
| ----------------- | --------------------------------------------------------------- |
| app.datadoghq.com | GET https://api.datadoghq.com/api/v2/incidents/config/rules     |
| us3.datadoghq.com | GET https://api.us3.datadoghq.com/api/v2/incidents/config/rules |
| us5.datadoghq.com | GET https://api.us5.datadoghq.com/api/v2/incidents/config/rules |
| app.datadoghq.eu  | GET https://api.datadoghq.eu/api/v2/incidents/config/rules      |
| ap1.datadoghq.com | GET https://api.ap1.datadoghq.com/api/v2/incidents/config/rules |
| ap2.datadoghq.com | GET https://api.ap2.datadoghq.com/api/v2/incidents/config/rules |
| uk1.datadoghq.com | GET https://api.uk1.datadoghq.com/api/v2/incidents/config/rules |
| app.ddog-gov.com  | GET https://api.ddog-gov.com/api/v2/incidents/config/rules      |
| us2.ddog-gov.com  | GET https://api.us2.ddog-gov.com/api/v2/incidents/config/rules  |

### Overview

모든 인시던트 규칙을 나열합니다.

This endpoint requires any of the following permissions:

- `incident_settings_read`
- `incident_notification_settings_read`

OAuth apps require the `incident_settings_read` authorization [scope](https://dnd37xeb23o8n.cloudfront.net/stefon.simmons/docs-astro-web-10435/ko/api/latest/scopes.md#incidents) to access this endpoint.

### Arguments

#### Query Strings

| Field            | Type   | Description                         |
| ---------------- | ------ | ----------------------------------- |
| filter[task_id]  | string | Filter rules by task ID.            |
| filter[trigger]  | string | Filter rules by trigger.            |
| incidentTypeUUID | string | Filter rules by incident type UUID. |

### Response

{% tabs %}
{% tab label="200" %}
OK

{% tabs %}
{% tab label="Model" %}
Response with a list of incident rules.

| Parent field | Field                              | Type      | Description                                                                   |
| ------------ | ---------------------------------- | --------- | ----------------------------------------------------------------------------- |
|              | data [*required*]                  | [object]  | List of incident rules.                                                       |
| data         | attributes [*required*]            | object    | Attributes of an incident rule in a response.                                 |
| attributes   | condition                          | object    | A query-based condition for an incident rule.                                 |
| condition    | normalized_query                   | string    | The normalized query string.                                                  |
| condition    | raw_query                          | string    | The raw query string.                                                         |
| attributes   | condition_table_type               | int64     | The condition table type.                                                     |
| attributes   | conditions                         | [object]  | List of field-based conditions.                                               |
| conditions   | field [*required*]                 | string    | The field to match on.                                                        |
| conditions   | values [*required*]                | [string]  | The values to match.                                                          |
| attributes   | created                            | date-time | Timestamp when the rule was created.                                          |
| attributes   | created_by_uuid                    | uuid      | UUID of the user who created the rule.                                        |
| attributes   | deleted                            | date-time | Timestamp when the rule was deleted.                                          |
| attributes   | enabled                            | boolean   | Whether the rule is enabled.                                                  |
| attributes   | execution_type                     | int64     | The execution type of the rule.                                               |
| attributes   | incident_settings_association_uuid | uuid      | The incident settings association UUID.                                       |
| attributes   | match_any_condition                | boolean   | Whether any condition should match.                                           |
| attributes   | modified                           | date-time | Timestamp when the rule was last modified.                                    |
| attributes   | modified_by_uuid                   | uuid      | UUID of the user who last modified the rule.                                  |
| attributes   | org_id                             | int64     | The organization ID.                                                          |
| attributes   | task_id                            | string    | The task ID.                                                                  |
| attributes   | task_payload                       | string    | The JSON-encoded task payload.                                                |
| attributes   | trigger                            | string    | The trigger event for the rule.                                               |
| data         | id [*required*]                    | uuid      | The rule identifier.                                                          |
| data         | type [*required*]                  | enum      | Incident rule response resource type. Allowed enum values: `incidents_rules`. |
{% /tab %}

{% tab label="Example" %}
```json
{
  "data": [
    {
      "attributes": {
        "condition": {
          "normalized_query": "severity:SEV-1",
          "raw_query": "severity:SEV-1"
        },
        "condition_table_type": 1,
        "conditions": [
          {
            "field": "severity",
            "values": [
              "SEV-1",
              "SEV-2"
            ]
          }
        ],
        "created": "2024-01-01T00:00:00.000Z",
        "created_by_uuid": "00000000-0000-0000-0000-000000000001",
        "deleted": null,
        "enabled": true,
        "execution_type": 1,
        "incident_settings_association_uuid": null,
        "match_any_condition": false,
        "modified": "2024-01-01T00:00:00.000Z",
        "modified_by_uuid": "00000000-0000-0000-0000-000000000001",
        "org_id": 123456,
        "task_id": "notify-incident-handles-job",
        "task_payload": "{}",
        "trigger": "incident_created_trigger"
      },
      "id": "00000000-0000-0000-0000-000000000000",
      "type": "incidents_rules"
    }
  ]
}
```
{% /tab %}
{% /tabs %}
{% /tab %}

{% tab label="400" %}
Bad Request

{% tabs %}
{% tab label="Model" %}
API error response.

| Field               | Type     | Description       |
| ------------------- | -------- | ----------------- |
| errors [*required*] | [string] | A list of errors. |
{% /tab %}

{% tab label="Example" %}
```json
{
  "errors": [
    "Bad Request"
  ]
}
```
{% /tab %}
{% /tabs %}
{% /tab %}

{% tab label="401" %}
Unauthorized

{% tabs %}
{% tab label="Model" %}
API error response.

| Field               | Type     | Description       |
| ------------------- | -------- | ----------------- |
| errors [*required*] | [string] | A list of errors. |
{% /tab %}

{% tab label="Example" %}
```json
{
  "errors": [
    "Bad Request"
  ]
}
```
{% /tab %}
{% /tabs %}
{% /tab %}

{% tab label="403" %}
Forbidden

{% tabs %}
{% tab label="Model" %}
API error response.

| Field               | Type     | Description       |
| ------------------- | -------- | ----------------- |
| errors [*required*] | [string] | A list of errors. |
{% /tab %}

{% tab label="Example" %}
```json
{
  "errors": [
    "Bad Request"
  ]
}
```
{% /tab %}
{% /tabs %}
{% /tab %}

{% tab label="429" %}
Too many requests

{% tabs %}
{% tab label="Model" %}
API error response.

| Field               | Type     | Description       |
| ------------------- | -------- | ----------------- |
| errors [*required*] | [string] | A list of errors. |
{% /tab %}

{% tab label="Example" %}
```json
{
  "errors": [
    "Bad Request"
  ]
}
```
{% /tab %}
{% /tabs %}
{% /tab %}
{% /tabs %}

### Code Example

{% tabs %}
{% tab label="Curl" %}
```bash
# Set your Datadog site and credentials
export DD_SITE="datadoghq.com" # Or us3.datadoghq.com, us5.datadoghq.com, datadoghq.eu, ap1.datadoghq.com, ap2.datadoghq.com, uk1.datadoghq.com, ddog-gov.com, us2.ddog-gov.com
# Use a Personal Access Token or Service Access Token
export DD_BEARER_TOKEN="<PERSONAL_ACCESS_TOKEN OR SERVICE_ACCESS_TOKEN>"

curl -X GET "https://api.${DD_SITE}/api/v2/incidents/config/rules" \
-H "Accept: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN}"
```
{% /tab %}
{% /tabs %}
