---
title: Get an Agent Health issue
description: Get an Agent Health issue and its available remediation in your organization.
breadcrumbs: Documentation > API > Get an Agent Health issue
---

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

# Get an Agent Health issue

## v2 (latest)

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

### Overview

Get an Agent Health issue and its available remediation in your organization.
The `remediation` attribute is omitted when the issue has no remediation.

Returns `404` if the issue does not exist, belongs to another organization, or
you do not have access to its data. This response does not reveal whether the
issue exists. Returns `403` if you lack the `hosts_read` permission.

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

#### Path Parameters

| Field                 | Type   | Description                                                                                                              |
| --------------------- | ------ | ------------------------------------------------------------------------------------------------------------------------ |
| issue_id [*required*] | string | The unique identifier of the issue. It can contain `:` and must be percent-encoded by clients when included in the path. |

### Response

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

{% tabs %}
{% tab label="Model" %}
A response containing an open Agent Health issue and available remediation.

| Parent field | Field                      | Type      | Description                                                                                                                                                                                                                                                                                                                                                             |
| ------------ | -------------------------- | --------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|              | data [*required*]          | object    | An open Agent Health issue with available remediation.                                                                                                                                                                                                                                                                                                                  |
| 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`.                                                                                                                                                                                                                                                                                       |
{% /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"
  }
}
```
{% /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="404" %}
Not Found

{% 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
# Path parameters
export issue_id="invalid-config:4828e7d6c704c4a3"

# 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/${issue_id}" \
-H "Accept: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN}"
```
{% /tab %}
{% /tabs %}
