---
title: "List agentless hosts"
method: GET
path: "/api/v2/csm/settings/agentless_hosts"
tags: ["CSM Settings"]
---

# List agentless hosts

`GET /api/v2/csm/settings/agentless_hosts`

Get the list of agentless hosts for CSM, with optional pagination and filtering.

## Query parameters

- `page` integer
- `size` integer
- `query` string

## Response `200`

OK

- CsmAgentlessHostsResponse — The response returned when listing agentless hosts.
  - `data` CsmAgentlessHostData[], required — The list of agentless hosts for the current page.
    - `attributes` CsmAgentlessHostAttributes, required — Attributes of an agentless host.
      - `account_id` string, required — The ID of the cloud account that the host belongs to.
      - `cloud_provider` 'aws' | 'gcp' | 'azure' | 'oci', required — The cloud provider of a host resource.
      - `has_posture_management` boolean, required — Whether CSM Misconfigurations is enabled for this host. `true` if enabled; `false` if disabled.
      - `has_vulnerability_scanning` boolean, required — Whether CSM Vulnerabilities is enabled for this host. `true` if enabled; `false` if disabled.
      - `resource_type` 'aws_ec2_instance' | 'azure_virtual_machine_instance' | 'gcp_compute_instance' | 'oci_instance', required — The type of cloud resource for an agentless host.
    - `id` string, required — The resource identifier of the agentless host.
    - `type` 'agentless_host', required — The JSON:API type for agentless host resources. The value should always be `agentless_host`.
  - `meta` CsmSettingsMeta, required — Pagination metadata for a CSM settings list response.
    - `page_index` integer, required — The current page index (zero-based).
    - `page_size` integer, required — The number of resources returned per page.
    - `total_filtered` integer, required — The total number of resources matching the filter criteria.

## Other responses

- `400` — Bad Request
- `403` — Not Authorized
- `429` — Too many requests

---

[API](https://skmtc.net/datadog/apis/api-v2.md) · [All operations](https://skmtc.net/datadog/apis/api-v2/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/datadog/api-v2/versions/da68bf029e4c/schema)
