List agents
Query parameters
-
perPage integer
The number of items to return
Default value is
20
. -
page integer
Default value is
1
. -
kuery string
-
showInactive boolean
-
showUpgradeable boolean
-
sortOrder string
Values are
asc
ordesc
. -
withMetrics boolean
Return agent metrics, false by default
-
getStatusSummary boolean
GET /api/fleet/agents
curl \
-X GET https://localhost:5601/api/fleet/agents
Response examples (200)
{
"items": [
{
"access_api_key": "string",
"access_api_key_id": "string",
"active": true,
"components": [
{
"id": "string",
"message": "string",
"status": "starting",
"type": "string",
"units": [
{
"id": "string",
"message": "string",
"payload": {},
"status": "starting",
"type": "input"
}
]
}
],
"default_api_key": "string",
"default_api_key_id": "string",
"enrolled_at": "string",
"id": "string",
"last_checkin": "string",
"local_metadata": {},
"metrics": {
"cpu_avg": 42.0,
"memory_size_byte_avg": 42.0
},
"policy_id": "string",
"policy_revision": 42.0,
"status": "offline",
"type": "PERMANENT",
"unenrolled_at": "string",
"unenrollment_started_at": "string",
"user_provided_metadata": {}
}
],
"list": [
{
"access_api_key": "string",
"access_api_key_id": "string",
"active": true,
"components": [
{
"id": "string",
"message": "string",
"status": "starting",
"type": "string",
"units": [
{
"id": "string",
"message": "string",
"payload": {},
"status": "starting",
"type": "input"
}
]
}
],
"default_api_key": "string",
"default_api_key_id": "string",
"enrolled_at": "string",
"id": "string",
"last_checkin": "string",
"local_metadata": {},
"metrics": {
"cpu_avg": 42.0,
"memory_size_byte_avg": 42.0
},
"policy_id": "string",
"policy_revision": 42.0,
"status": "offline",
"type": "PERMANENT",
"unenrolled_at": "string",
"unenrollment_started_at": "string",
"user_provided_metadata": {}
}
],
"page": 42.0,
"perPage": 42.0,
"statusSummary": {
"degraded'": 42.0,
"enrolling": 42.0,
"error": 42.0,
"inactive": 42.0,
"offline": 42.0,
"online": 42.0,
"unenrolled": 42.0,
"unenrolling": 42.0,
"updating": 42.0
},
"total": 42.0
}
Response examples (400)
{
"error": "string",
"message": "string",
"statusCode": 42.0
}