Retrieve checks for multiple nodes

Retrieve checks for multiple nodes

GET api/nodes/-/checks

Retrieves the checks for multiple nodes. For each check, both the current status and historical data is returned. You can filter the request using the node hostname, node group names, and node groups IDs. You can also filter using any combination of each of those and the response will filter out any duplicates.

Request syntax

get api/nodes/-/checks

Request parameters

The request accepts the following query parameters.

ParameterTypeDescriptionRequiredDefault value
filter_by_nameStringFilter checks by one or more check names, separated by a comma. If no check matches, the response returns an empty checks list.NoN/A
filter_by_statusStringFilter checks by one or more status codes, separated by a comma: 0 (OK), 1 (Warning), or 2 (Critical).NoN/A
hostnamesStringFilter checks by one or more hostnames, separated by a comma.NoN/A
group_namesStringFilter checks by one or more node group names, separated by a comma. All nodes in each node group in the list will be included.NoN/A
group_idsIntegerFilter checks by one or more node group IDs, separated by a comma. All nodes in each node group in the list will be included.NoN/A

Response syntax

{
    "request": {
        "params": {
            "hostnames": "string"
        },
        "at": "timestamp"
    },
    "nodes" : [
        {
            "hostname": "string",
            "checks": [
                {
                    "name": "string",
                    "status": integer,
                    "executed": "timestamp",
                    "output": "string",
                    "last_ok": "timestamp",
                    "history": [
                        {
                            "status": integer,
                            "executed": "timestamp"
                        },
                        {
                            "status": integer,
                            "executed": "timestamp"
                        }
                    ]
                }
            ]
        }
    ] 
}

Response parameters

If the action is successful, an HTTP 200 response is returned. The following data is returned in JSON format.

FieldTypeDescription
requestObjectThe details of the request.
request.paramsObjectThe query parameters sent in the request.
request.atTimestampThe time the request was made.
nodesArray of objectsThe nodes that match the request. Each node contains the following fields.
hostnameStringThe hostname of the node.
checksArray of objectsThe checks run on the node. Each check contains the following fields.
checks.nameStringThe name of the check, for example keepalive or disk_free.
checks.statusIntegerThe status of the most recent run of the check: 0 (OK), 1 (Warning), 2 (Critical), or 3 (Unknown).
checks.executedTimestampThe time the check last ran.
checks.outputStringThe output of the most recent run of the check.
checks.last_okTimestampThe last time the check returned a status of 0. Returns 1970-01-01T00:00:00Z if the check has never returned OK.
checks.historyArray of objectsThe recent results of the check, oldest first. Each entry contains the status and executed time of one run. Up to 21 entries are returned.

Errors

The following are errors returned by this API. For a complete list of common errors, see Common errors.

CodeMessageCause
400Validation failed: filter_by_status is invalidThe value for filter_by_status is invalid. Specify an integer and try again.
422Missing parameters to specify hostnames.The request didn't specify a hostname filter. Specify at least one filter and try again.

Examples

Example 1: Retrieve the checks from multiple nodes, specified by hostname

This example returns the healthcheck details about the nodes with hostnames sit0000red0 and sit0000red1.

ruby api.rb <customer_code> get "api/nodes/-/checks?hostnames=sit0000red0,sit0000red1"

Response

{
    "request": {
        "params": {
            "hostnames": "sit0000red0,sit0000red1"
        },
        "at": "2024-09-30T22:15:32Z"
    },
    "nodes": [
        {
            "hostname": "sit0000red1",
            "checks": [
                {
                    "name": "disk_free",
                    "status": 0,
                    "executed": "2024-09-30T22:15:08Z",
                    "output": "DISK OK - free space:\n\n[ OK ] 94% /\n[ OK ] 100% /tmp\n[ OK ] 94% /home\n[ OK ] 94% /var\n[ OK ] 94% /var/log\n|  /=94%;20;10;0;100 /tmp=100%;20;10;0;100 /home=94%;20;10;0;100 /var=94%;20;10;0;100 /var/log=94%;20;10;0;100\n",
                    "last_ok": "2024-09-30T22:15:08Z",
                    "history": [
                        {
                            "status": 0,
                            "executed": "2024-09-30T22:15:08Z"
                        }
                    ]
                },
                {
                    "name": "keepalive",
                    "status": 0,
                    "executed": "2024-09-30T22:15:06Z",
                    "output": "Keepalive last sent from sit0000red1 at 2024-09-30 18:15:06 -0400 EDT",
                    "last_ok": "2024-09-30T22:15:06Z",
                    "history": [
                        {
                            "status": 0,
                            "executed": "2024-09-30T22:15:06Z"
                        }
                    ]
                },
                {
                    "name": "fs_writable",
                    "status": 0,
                    "executed": "2024-09-30T22:14:53Z",
                    "output": "Filesystem OK\n\nOK - / Filesystem is writable\n",
                    "last_ok": "2024-09-30T22:14:53Z",
                    "history": [
                        {
                            "status": 0,
                            "executed": "2024-09-30T22:14:53Z"
                        }
                    ]
                },
                {
                    "name": "cpu_utilization",
                    "status": 0,
                    "executed": "2024-09-30T22:14:25Z",
                    "output": "OK - load average: 0.07, 0.09, 0.09|load1=0.075;0.600;1.000;0; load5=0.087;0.600;1.000;0; load15=0.091;0.600;1.000;0; \n",
                    "last_ok": "2024-09-30T22:14:25Z",
                    "history": [
                        {
                            "status": 0,
                            "executed": "2024-09-30T22:14:25Z"
                        }
                    ]
                },
                {
                    "name": "memory_available",
                    "status": 0,
                    "executed": "2024-09-30T22:14:20Z",
                    "output": "CheckMem OK - value = 3.52 | system_memory_used=3.52\n",
                    "last_ok": "2024-09-30T22:14:20Z",
                    "history": [
                        {
                            "status": 0,
                            "executed": "2024-09-30T22:14:20Z"
                        }
                    ]
                },
                {
                    "name": "ssh_server",
                    "status": 0,
                    "executed": "2024-09-30T22:10:15Z",
                    "output": "SSH OK - OpenSSH_6.7p1 Debian-5+deb8u8 (protocol 2.0) | time=0.020429s;;;0.000000;10.000000\n",
                    "last_ok": "2024-09-30T22:10:15Z",
                    "history": [
                        {
                            "status": 0,
                            "executed": "2024-09-30T22:10:15Z"
                        }
                    ]
                },
                {
                    "name": "puppet_errors",
                    "status": 0,
                    "executed": "2024-09-30T21:59:20Z",
                    "output": "OK: Puppet last run had 0 failures\n",
                    "last_ok": "2024-09-30T21:59:20Z",
                    "history": [
                        {
                            "status": 0,
                            "executed": "2024-09-30T21:59:20Z"
                        }
                    ]
                },
                {
                    "name": "puppet_client",
                    "status": 0,
                    "executed": "2024-09-30T21:16:53Z",
                    "output": "OK\n",
                    "last_ok": "2024-09-30T21:16:53Z",
                    "history": [
                        {
                            "status": 0,
                            "executed": "2024-09-30T21:16:53Z"
                        }
                    ]
                }
            ]
        },
        {
            "hostname": "sit0000red0",
            "checks": [
                {
                    "name": "disk_free",
                    "status": 0,
                    "executed": "2024-09-30T22:15:08Z",
                    "output": "DISK OK - free space:\n\n[ OK ] 91% /\n[ OK ] 99% /tmp\n[ OK ] 91% /home\n[ OK ] 91% /var\n[ OK ] 91% /var/log\n[ OK ] 99% /kvm/kvm1\n[ OK ] 99% /docker/shared-main_shared_volume\n[ OK ] 99% /docker/shared-secondary_shared_volume\n[ OK ] 98% /opt/reliant/managed_files/update_nginx_example\n|  /=91%;20;10;0;100 /tmp=99%;20;10;0;100 /home=91%;20;10;0;100 /var=91%;20;10;0;100 /var/log=91%;20;10;0;100 /kvm/kvm1=99%;20;10;0;100 /docker/shared-main_shared_volume=99%;20;10;0;100 /docker/shared-secondary_shared_volume=99%;20;10;0;100 /opt/reliant/managed_files/update_nginx_example=98%;20;10;0;100\n",
                    "last_ok": "2024-09-30T22:15:08Z",
                    "history": [
                        {
                            "status": 0,
                            "executed": "2024-09-30T22:15:08Z"
                        }
                    ]
                },
                {
                    "name": "keepalive",
                    "status": 0,
                    "executed": "2024-09-30T22:15:08Z",
                    "output": "Keepalive last sent from sit0000red0 at 2024-09-30 18:15:08 -0400 EDT",
                    "last_ok": "2024-09-30T22:15:08Z",
                    "history": [
                        {
                            "status": 0,
                            "executed": "2024-09-30T22:15:08Z"
                        }
                    ]
                },
                {
                    "name": "fs_writable",
                    "status": 0,
                    "executed": "2024-09-30T22:14:53Z",
                    "output": "Filesystem OK\n\nOK - / Filesystem is writable\nOK - /opt/reliant/managed_files/update_nginx_example Filesystem is writable\nOK - /docker/shared-secondary_shared_volume Filesystem is writable\nOK - /docker/shared-main_shared_volume Filesystem is writable\nOK - /kvm/kvm1 Filesystem is writable\n",
                    "last_ok": "2024-09-30T22:14:53Z",
                    "history": [
                        {
                            "status": 0,
                            "executed": "2024-09-30T22:14:53Z"
                        }
                    ]
                },
                {
                    "name": "cpu_utilization",
                    "status": 0,
                    "executed": "2024-09-30T22:14:25Z",
                    "output": "OK - load average: 0.05, 0.09, 0.10|load1=0.052;0.600;1.000;0; load5=0.087;0.600;1.000;0; load15=0.104;0.600;1.000;0; \n",
                    "last_ok": "2024-09-30T22:14:25Z",
                    "history": [
                        {
                            "status": 0,
                            "executed": "2024-09-30T22:14:25Z"
                        }
                    ]
                },
                {
                    "name": "memory_available",
                    "status": 0,
                    "executed": "2024-09-30T22:14:20Z",
                    "output": "CheckMem OK - value = 6.48 | system_memory_used=6.48\n",
                    "last_ok": "2024-09-30T22:14:20Z",
                    "history": [
                        {
                            "status": 0,
                            "executed": "2024-09-30T22:14:20Z"
                        }
                    ]
                },
                {
                    "name": "ssh_server",
                    "status": 0,
                    "executed": "2024-09-30T22:10:15Z",
                    "output": "SSH OK - OpenSSH_6.7p1 Debian-5+deb8u8 (protocol 2.0) | time=0.012340s;;;0.000000;10.000000\n",
                    "last_ok": "2024-09-30T22:10:15Z",
                    "history": [
                        {
                            "status": 0,
                            "executed": "2024-09-30T22:10:15Z"
                        }
                    ]
                },
                {
                    "name": "puppet_errors",
                    "status": 0,
                    "executed": "2024-09-30T21:59:20Z",
                    "output": "OK: Puppet last run had 0 failures\n",
                    "last_ok": "2024-09-30T21:59:20Z",
                    "history": [
                        {
                            "status": 0,
                            "executed": "2024-09-30T21:59:20Z"
                        }
                    ]
                },
                {
                    "name": "puppet_client",
                    "status": 0,
                    "executed": "2024-09-30T21:16:53Z",
                    "output": "OK\n",
                    "last_ok": "2024-09-30T21:16:53Z",
                    "history": [
                        {
                            "status": 0,
                            "executed": "2024-09-30T21:16:53Z"
                        }
                    ]
                }
            ]
        }
    ]
}

Example 2: Retrieve the checks from multiple nodes, specified by node group name

This example returns the checks for the nodes in the Edge Platform - UA - Cluster and Edge Platform - UA - Singleton node groups. Encode spaces in node group names as %20, and separate the names with a comma. Don't wrap the names in quotes.

ruby api.rb <customer_code> get "api/nodes/-/checks?group_names=Edge%20Platform%20-%20UA%20-%20Cluster,Edge%20Platform%20-%20UA%20-%20Singleton"

Response

{
    "request": {
        "params": {
            "group_names": "Edge Platform - UA - Cluster,Edge Platform - UA - Singleton"
        },
        "at": "2026-10-11T01:36:36Z"
    },
    "nodes": [
        {
            "hostname": "rde9996red0",
            "checks": [
                {
                    "name": "keepalive",
                    "status": 1,
                    "executed": "2026-10-11T01:34:38Z",
                    "output": "No keepalive sent from rde9996red0 for 49960424 seconds (>= 120)",
                    "last_ok": "2025-03-11T19:40:55Z",
                    "history": [
                        {
                            "status": 1,
                            "executed": "2026-10-11T01:32:38Z"
                        },
                        {
                            "status": 1,
                            "executed": "2026-10-11T01:34:38Z"
                        }
                    ]
                }
            ]
        },
        {
            "hostname": "rde9997red0",
            "checks": [
                {
                    "name": "keepalive",
                    "status": 0,
                    "executed": "2026-10-11T01:35:56Z",
                    "output": "Keepalive last sent from rde9997red0 at 2026-10-10 20:35:56 -0500 CDT",
                    "last_ok": "2026-10-11T01:35:56Z",
                    "history": [
                        {
                            "status": 0,
                            "executed": "2026-10-11T01:35:36Z"
                        },
                        {
                            "status": 0,
                            "executed": "2026-10-11T01:35:56Z"
                        }
                    ]
                }
            ]
        },
        {
            "hostname": "rde9998red0",
            "checks": [
                {
                    "name": "keepalive",
                    "status": 0,
                    "executed": "2026-10-11T01:36:00Z",
                    "output": "Keepalive last sent from rde9998red0 at 2026-10-10 20:36:00 -0500 CDT",
                    "last_ok": "2026-10-11T01:36:00Z",
                    "history": [
                        {
                            "status": 0,
                            "executed": "2026-10-11T01:35:40Z"
                        },
                        {
                            "status": 0,
                            "executed": "2026-10-11T01:36:00Z"
                        }
                    ]
                }
            ]
        },
        {
            "hostname": "rde9998red1",
            "checks": [
                {
                    "name": "keepalive",
                    "status": 1,
                    "executed": "2026-10-11T01:34:42Z",
                    "output": "No keepalive sent from rde9998red1 for 3256882 seconds (>= 120)",
                    "last_ok": "2026-09-03T08:53:21Z",
                    "history": [
                        {
                            "status": 1,
                            "executed": "2026-10-11T01:32:42Z"
                        },
                        {
                            "status": 1,
                            "executed": "2026-10-11T01:34:42Z"
                        }
                    ]
                }
            ]
        }
    ]
}

In this response, each node shows only its keepalive check and the last two history entries. The full response includes every check on each node and up to 21 history entries per check.

Example 3: Retrieve the checks from multiple nodes, specified by node group ID

This example returns the checks for the nodes in the node groups with IDs 2392 and 2393. These are the same node groups as in Example 2, so the response contains the same nodes.

ruby api.rb <customer_code> get "api/nodes/-/checks?group_ids=2392,2393"

Response

{
    "request": {
        "params": {
            "group_ids": "2392,2393"
        },
        "at": "2026-10-11T01:36:37Z"
    },
    "nodes": [
        {
            "hostname": "rde9996red0",
            "checks": [
                {
                    "name": "keepalive",
                    "status": 1,
                    "executed": "2026-10-11T01:34:38Z",
                    "output": "No keepalive sent from rde9996red0 for 49960424 seconds (>= 120)",
                    "last_ok": "2025-03-11T19:40:55Z",
                    "history": [
                        {
                            "status": 1,
                            "executed": "2026-10-11T01:32:38Z"
                        },
                        {
                            "status": 1,
                            "executed": "2026-10-11T01:34:38Z"
                        }
                    ]
                }
            ]
        },
        {
            "hostname": "rde9997red0",
            "checks": [
                {
                    "name": "keepalive",
                    "status": 0,
                    "executed": "2026-10-11T01:35:56Z",
                    "output": "Keepalive last sent from rde9997red0 at 2026-10-10 20:35:56 -0500 CDT",
                    "last_ok": "2026-10-11T01:35:56Z",
                    "history": [
                        {
                            "status": 0,
                            "executed": "2026-10-11T01:35:36Z"
                        },
                        {
                            "status": 0,
                            "executed": "2026-10-11T01:35:56Z"
                        }
                    ]
                }
            ]
        },
        {
            "hostname": "rde9998red0",
            "checks": [
                {
                    "name": "keepalive",
                    "status": 0,
                    "executed": "2026-10-11T01:36:00Z",
                    "output": "Keepalive last sent from rde9998red0 at 2026-10-10 20:36:00 -0500 CDT",
                    "last_ok": "2026-10-11T01:36:00Z",
                    "history": [
                        {
                            "status": 0,
                            "executed": "2026-10-11T01:35:40Z"
                        },
                        {
                            "status": 0,
                            "executed": "2026-10-11T01:36:00Z"
                        }
                    ]
                }
            ]
        },
        {
            "hostname": "rde9998red1",
            "checks": [
                {
                    "name": "keepalive",
                    "status": 1,
                    "executed": "2026-10-11T01:34:42Z",
                    "output": "No keepalive sent from rde9998red1 for 3256882 seconds (>= 120)",
                    "last_ok": "2026-09-03T08:53:21Z",
                    "history": [
                        {
                            "status": 1,
                            "executed": "2026-10-11T01:32:42Z"
                        },
                        {
                            "status": 1,
                            "executed": "2026-10-11T01:34:42Z"
                        }
                    ]
                }
            ]
        }
    ]
}

In this response, each node shows only its keepalive check and the last two history entries. The full response includes every check on each node and up to 21 history entries per check.

Example 4: Filter the response for a specific check

This example returns the details of the keepalive check for the rde9998red0 and rde9998red1 nodes. In this example, rde9998red1 has stopped sending keepalives, so its check returns a non-zero status.

ruby api.rb <customer_code> get "api/nodes/-/checks?hostnames=rde9998red0,rde9998red1&filter_by_name=keepalive"

Response

{
    "request": {
        "params": {
            "hostnames": "rde9998red0,rde9998red1",
            "filter_by_name": "keepalive"
        },
        "at": "2026-10-11T01:36:38Z"
    },
    "nodes": [
        {
            "hostname": "rde9998red0",
            "checks": [
                {
                    "name": "keepalive",
                    "status": 0,
                    "executed": "2026-10-11T01:36:00Z",
                    "output": "Keepalive last sent from rde9998red0 at 2026-10-10 20:36:00 -0500 CDT",
                    "last_ok": "2026-10-11T01:36:00Z",
                    "history": [
                        {
                            "status": 0,
                            "executed": "2026-10-11T01:35:40Z"
                        },
                        {
                            "status": 0,
                            "executed": "2026-10-11T01:36:00Z"
                        }
                    ]
                }
            ]
        },
        {
            "hostname": "rde9998red1",
            "checks": [
                {
                    "name": "keepalive",
                    "status": 1,
                    "executed": "2026-10-11T01:34:42Z",
                    "output": "No keepalive sent from rde9998red1 for 3256882 seconds (>= 120)",
                    "last_ok": "2026-09-03T08:53:21Z",
                    "history": [
                        {
                            "status": 1,
                            "executed": "2026-10-11T01:32:42Z"
                        },
                        {
                            "status": 1,
                            "executed": "2026-10-11T01:34:42Z"
                        }
                    ]
                }
            ]
        }
    ]
}

The history arrays are shortened to the last two entries.

Example 5: Filter the response for multiple checks

This example returns the details of the disk_free and memory_available checks for the nodes with hostnames rde9998red0 and rde9998red1.

ruby api.rb <customer_code> get "api/nodes/-/checks?hostnames=rde9998red0,rde9998red1&filter_by_name=disk_free,memory_available"

Response

{
    "request": {
        "params": {
            "hostnames": "rde9998red0,rde9998red1",
            "filter_by_name": "disk_free,memory_available"
        },
        "at": "2026-10-11T01:36:38Z"
    },
    "nodes": [
        {
            "hostname": "rde9998red0",
            "checks": [
                {
                    "name": "memory_available",
                    "status": 0,
                    "executed": "2026-10-11T01:36:00Z",
                    "output": "CheckMem OK - value = 1.14 | system_memory_used=1.14\n",
                    "last_ok": "2026-10-11T01:36:00Z",
                    "history": [
                        {
                            "status": 0,
                            "executed": "2026-10-11T01:35:00Z"
                        },
                        {
                            "status": 0,
                            "executed": "2026-10-11T01:36:00Z"
                        }
                    ]
                },
                {
                    "name": "disk_free",
                    "status": 0,
                    "executed": "2026-10-11T01:34:52Z",
                    "output": "DISK OK - free space:\n\n[ OK ] 86% /\n[ OK ] 100% /tmp\n[ OK ] 99% /home\n[ OK ] 66% /var\n[ OK ] 83% /var/log\n|  /=86%;20;10;0;100 /tmp=100%;20;10;0;100 /home=99%;20;10;0;100 /var=66%;20;10;0;100 /var/log=83%;20;10;0;100\n",
                    "last_ok": "2026-10-11T01:34:52Z",
                    "history": [
                        {
                            "status": 0,
                            "executed": "2026-10-11T01:29:52Z"
                        },
                        {
                            "status": 0,
                            "executed": "2026-10-11T01:34:52Z"
                        }
                    ]
                }
            ]
        }
    ]
}

Only rde9998red0 is returned. A node that has none of the checks named in filter_by_name is left out of the response, rather than being returned with an empty checks list. Here, rde9998red1 runs only the keepalive check. The history arrays are shortened to the last two entries.

You can also combine the hostnames, group_names, and group_ids filters in one request. Nodes that match more than one filter are returned once.