---
title: List Agent Health issues
description: List open Agent Health issues across your organization.
breadcrumbs: Documentation > API > List Agent Health issues
---

> For the complete documentation index, see [llms.txt](https://docs.datadoghq.com/llms.txt).

# List Agent Health issues

## v2 (latest)

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

### Overview

List open Agent Health issues across your organization. Returns `403` if you
lack the `hosts_read` permission.

Each item in `data` is a JSON:API resource object whose `attributes` hold the issue
fields, including its `issue_type`. Issues use a stable order: severity rank
(`high`, `medium`, `low`, then other values), then `first_seen_at` descending with
missing timestamps last, then issue ID ascending.

The response always includes `meta.page` with the applied `limit`, `offset`, and
`total_count` (the number of open issues matching the filters). Set `count_by=issue_type`
to also include `counts_by_issue_type` with per-issue-type counts.

Each filter accepts up to 50 comma-separated exact values of at most 256 characters
each, combined with OR within a filter and AND across filters. Blank entries are ignored; an all-blank filter
is treated as absent.

This endpoint requires the `hosts_read` permission.

OAuth apps require the `hosts_read` authorization [scope](https://docs.datadoghq.com/fr/api/latest/scopes.md#agent-health) to access this endpoint.

### Arguments

#### Query Strings

| Field                 | Type    | Description                                                                                                                                                                                                                                                   |
| --------------------- | ------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| count_by              | enum    | Set to `issue_type` to also include `counts_by_issue_type` in `meta.page` with per-issue-type counts. Pagination metadata is always included. Only `issue_type` is supported. Allowed enum values: `issue_type`.                                              |
| page[limit]           | integer | The maximum number of issues to return. Defaults to 100, with a minimum of 1 and a maximum of 1000. Default: `100`.                                                                                                                                           |
| page[offset]          | integer | The number of issues to skip before returning results. Defaults to 0, with a minimum of 0. Default: `0`.                                                                                                                                                      |
| filter[severity]      | string  | Filter by a comma-separated list of exact `severity` values, up to 50 values of at most 256 characters each. Values are combined with OR within this filter and AND across filters. Blank entries are ignored; an all-blank filter is treated as absent.      |
| filter[category]      | string  | Filter by a comma-separated list of exact `category` values, up to 50 values of at most 256 characters each. Values are combined with OR within this filter and AND across filters. Blank entries are ignored; an all-blank filter is treated as absent.      |
| filter[issue_type]    | string  | Filter by a comma-separated list of exact `issue_type` values, up to 50 values of at most 256 characters each. Values are combined with OR within this filter and AND across filters. Blank entries are ignored; an all-blank filter is treated as absent.    |
| filter[resource_kind] | string  | Filter by a comma-separated list of exact `resource_kind` values, up to 50 values of at most 256 characters each. Values are combined with OR within this filter and AND across filters. Blank entries are ignored; an all-blank filter is treated as absent. |
| filter[resource_id]   | string  | Filter by a comma-separated list of exact `resource_id` values, up to 50 values of at most 256 characters each. Values are combined with OR within this filter and AND across filters. Blank entries are ignored; an all-blank filter is treated as absent.   |

### Response

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

{% tabs %}
{% tab label="Model" %}
A response containing open Agent Health issues.

| Parent field         | Field                      | Type      | Description                                                                                                                                                                                                                                                                                                                                                             |
| -------------------- | -------------------------- | --------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|                      | data [*required*]          | [object]  | The open Agent Health issues matching the request.                                                                                                                                                                                                                                                                                                                      |
| data                 | attributes [*required*]    | object    | Attributes of an open Agent Health issue, including available remediation.                                                                                                                                                                                                                                                                                              |
| attributes           | category                   | string    | The category of the issue, such as `configuration`. Omitted when not set.                                                                                                                                                                                                                                                                                               |
| attributes           | description                | string    | The description of the issue. Omitted when empty.                                                                                                                                                                                                                                                                                                                       |
| attributes           | extra                      | object    | Free-form, issue-type-specific context. Keys are not part of the stable schema. Omitted when empty.                                                                                                                                                                                                                                                                     |
| attributes           | first_seen_at              | date-time | The time the issue was first seen, in RFC 3339 format. Omitted when empty.                                                                                                                                                                                                                                                                                              |
| attributes           | issue_name [*required*]    | string    | The human-readable name of the issue.                                                                                                                                                                                                                                                                                                                                   |
| attributes           | issue_type [*required*]    | string    | The machine-readable type of the issue.                                                                                                                                                                                                                                                                                                                                 |
| attributes           | remediation                | object    | Remediation for the issue. Omitted when no remediation is available.                                                                                                                                                                                                                                                                                                    |
| remediation          | ai_prompt                  | string    | A suggested prompt for an AI assistant to help remediate the issue.                                                                                                                                                                                                                                                                                                     |
| remediation          | script                     | object    | A script that can be used to remediate the issue.                                                                                                                                                                                                                                                                                                                       |
| script               | content                    | string    | The content of the script.                                                                                                                                                                                                                                                                                                                                              |
| script               | filename                   | string    | The filename of the script.                                                                                                                                                                                                                                                                                                                                             |
| script               | language                   | string    | The language of the script.                                                                                                                                                                                                                                                                                                                                             |
| script               | language_version           | string    | The language version used by the script.                                                                                                                                                                                                                                                                                                                                |
| script               | requires_root [*required*] | boolean   | Whether the script requires root privileges.                                                                                                                                                                                                                                                                                                                            |
| remediation          | steps                      | [object]  | Steps to remediate the issue.                                                                                                                                                                                                                                                                                                                                           |
| steps                | order [*required*]         | int32     | The order in which to perform the step.                                                                                                                                                                                                                                                                                                                                 |
| steps                | text [*required*]          | string    | The instructions for the step.                                                                                                                                                                                                                                                                                                                                          |
| remediation          | summary                    | string    | A summary of how to remediate the issue.                                                                                                                                                                                                                                                                                                                                |
| attributes           | resource_id [*required*]   | string    | The identifier of the affected resource, interpreted according to `resource_kind`: hostname for `host`, DaemonSet UID for `deployment` (node Agent), cluster UUID for `cluster`, hostname of the host running the Cluster Agent for `cluster_agent`, or OpenTelemetry collector ID for `otel`.                                                                          |
| attributes           | resource_kind [*required*] | enum      | The kind of affected resource. The meaning of `resource_id` depends on this: hostname for `host`, DaemonSet UID for `deployment` (node Agent), cluster UUID for `cluster`, hostname of the host running the Cluster Agent for `cluster_agent`, or OpenTelemetry collector ID for `otel`. Allowed enum values: `host`, `deployment`, `cluster`, `cluster_agent`, `otel`. |
| attributes           | resource_type              | string    | The type of the affected resource. Omitted when empty.                                                                                                                                                                                                                                                                                                                  |
| attributes           | severity [*required*]      | enum      | The severity of the issue. Allowed enum values: `low`, `medium`, `high`, `unknown`.                                                                                                                                                                                                                                                                                     |
| attributes           | state [*required*]         | string    | The state of the issue, such as `open`.                                                                                                                                                                                                                                                                                                                                 |
| attributes           | tags                       | [string]  | Tags associated with the issue. Omitted when empty.                                                                                                                                                                                                                                                                                                                     |
| attributes           | title                      | string    | The title of the issue. Omitted when empty.                                                                                                                                                                                                                                                                                                                             |
| attributes           | updated_at                 | date-time | The time the issue was last updated, in RFC 3339 format. Omitted when empty.                                                                                                                                                                                                                                                                                            |
| data                 | id [*required*]            | string    | The unique identifier of the issue.                                                                                                                                                                                                                                                                                                                                     |
| data                 | type [*required*]          | enum      | The Agent Health issue resource type. Allowed enum values: `agent_health_issues`.                                                                                                                                                                                                                                                                                       |
|                      | meta [*required*]          | object    | Pagination metadata for the matching Agent Health issues. Always present. Includes per-issue-type counts only when `count_by=issue_type` is requested.                                                                                                                                                                                                                  |
| meta                 | page [*required*]          | object    | Pagination details and counts for the matching Agent Health issues.                                                                                                                                                                                                                                                                                                     |
| page                 | counts_by_issue_type       | object    | The number of open issues matching the filters in each issue-type group.                                                                                                                                                                                                                                                                                                |
| additionalProperties | <any-key>                  | int64     |                                                                                                                                                                                                                                                                                                                                                                         |
| page                 | limit [*required*]         | int64     | The maximum number of issues returned, echoing the requested `page[limit]`.                                                                                                                                                                                                                                                                                             |
| page                 | offset [*required*]        | int64     | The number of issues skipped, echoing the requested `page[offset]`.                                                                                                                                                                                                                                                                                                     |
| page                 | total_count [*required*]   | int64     | The total number of open issues matching the filters.                                                                                                                                                                                                                                                                                                                   |
{% /tab %}

{% tab label="Example" %}
```json
{
  "data": [
    {
      "attributes": {
        "category": "configuration",
        "description": "The Agent configuration file contains an invalid value.",
        "extra": {
          "agent_hostname": "i-0ea3e96bf45c427e6",
          "client_library": "java"
        },
        "first_seen_at": "2026-11-01T10:00:00Z",
        "issue_name": "Invalid Config",
        "issue_type": "invalid_config",
        "remediation": {
          "ai_prompt": "Help me fix the invalid configuration value in datadog.yaml.",
          "script": {
            "content": "...",
            "filename": "fix.sh",
            "language": "bash",
            "language_version": "5",
            "requires_root": true
          },
          "steps": [
            {
              "order": 1,
              "text": "Open datadog.yaml"
            }
          ],
          "summary": "Fix the invalid configuration value."
        },
        "resource_id": "my-hostname",
        "resource_kind": "host",
        "resource_type": "host",
        "severity": "high",
        "state": "open",
        "tags": [
          "env:prod"
        ],
        "title": "Invalid Agent configuration",
        "updated_at": "2026-11-09T08:00:00Z"
      },
      "id": "invalid-config:4828e7d6c704c4a3",
      "type": "agent_health_issues"
    }
  ],
  "meta": {
    "page": {
      "counts_by_issue_type": {
        "<any-key>": "integer"
      },
      "limit": 100,
      "offset": 0,
      "total_count": 25526
    }
  }
}
```
{% /tab %}
{% /tabs %}
{% /tab %}

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

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

| Parent field | Field               | Type     | Description                                                                     |
| ------------ | ------------------- | -------- | ------------------------------------------------------------------------------- |
|              | errors [*required*] | [object] | A list of errors.                                                               |
| errors       | code                | string   | An application-specific error code.                                             |
| errors       | detail              | string   | A human-readable explanation specific to this occurrence of the error.          |
| errors       | meta                | object   | Non-standard meta-information about the error                                   |
| errors       | source              | object   | References to the source of the error.                                          |
| source       | header              | string   | A string indicating the name of a single request header which caused the error. |
| source       | parameter           | string   | A string indicating which URI query parameter caused the error.                 |
| source       | pointer             | string   | A JSON pointer to the value in the request document that caused the error.      |
| errors       | status              | string   | Status code of the response.                                                    |
| errors       | title               | string   | Short human-readable summary of the error.                                      |
{% /tab %}

{% tab label="Example" %}
```json
{
  "errors": [
    {
      "code": "invalid_request",
      "detail": "Missing required attribute in body",
      "meta": {},
      "source": {
        "header": "Authorization",
        "parameter": "limit",
        "pointer": "/data/attributes/title"
      },
      "status": "400",
      "title": "Bad Request"
    }
  ]
}
```
{% /tab %}
{% /tabs %}
{% /tab %}

{% tab label="401" %}
Unauthorized

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

| Parent field | Field               | Type     | Description                                                                     |
| ------------ | ------------------- | -------- | ------------------------------------------------------------------------------- |
|              | errors [*required*] | [object] | A list of errors.                                                               |
| errors       | code                | string   | An application-specific error code.                                             |
| errors       | detail              | string   | A human-readable explanation specific to this occurrence of the error.          |
| errors       | meta                | object   | Non-standard meta-information about the error                                   |
| errors       | source              | object   | References to the source of the error.                                          |
| source       | header              | string   | A string indicating the name of a single request header which caused the error. |
| source       | parameter           | string   | A string indicating which URI query parameter caused the error.                 |
| source       | pointer             | string   | A JSON pointer to the value in the request document that caused the error.      |
| errors       | status              | string   | Status code of the response.                                                    |
| errors       | title               | string   | Short human-readable summary of the error.                                      |
{% /tab %}

{% tab label="Example" %}
```json
{
  "errors": [
    {
      "code": "invalid_request",
      "detail": "Missing required attribute in body",
      "meta": {},
      "source": {
        "header": "Authorization",
        "parameter": "limit",
        "pointer": "/data/attributes/title"
      },
      "status": "400",
      "title": "Bad Request"
    }
  ]
}
```
{% /tab %}
{% /tabs %}
{% /tab %}

{% tab label="403" %}
Forbidden

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

| Parent field | Field               | Type     | Description                                                                     |
| ------------ | ------------------- | -------- | ------------------------------------------------------------------------------- |
|              | errors [*required*] | [object] | A list of errors.                                                               |
| errors       | code                | string   | An application-specific error code.                                             |
| errors       | detail              | string   | A human-readable explanation specific to this occurrence of the error.          |
| errors       | meta                | object   | Non-standard meta-information about the error                                   |
| errors       | source              | object   | References to the source of the error.                                          |
| source       | header              | string   | A string indicating the name of a single request header which caused the error. |
| source       | parameter           | string   | A string indicating which URI query parameter caused the error.                 |
| source       | pointer             | string   | A JSON pointer to the value in the request document that caused the error.      |
| errors       | status              | string   | Status code of the response.                                                    |
| errors       | title               | string   | Short human-readable summary of the error.                                      |
{% /tab %}

{% tab label="Example" %}
```json
{
  "errors": [
    {
      "code": "invalid_request",
      "detail": "Missing required attribute in body",
      "meta": {},
      "source": {
        "header": "Authorization",
        "parameter": "limit",
        "pointer": "/data/attributes/title"
      },
      "status": "400",
      "title": "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/agenthealth/issues" \
-H "Accept: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN}"
```
{% /tab %}
{% /tabs %}
