Developers API

getHostSensorStatus

Fetches the current state of all sensors belonging to the specified host.

Request Parameters

Parameter Data Type Description Required Default
hostid integer The HostID identifying the host whose sensors' state you wish to query Required -

Response Data

Response Variable Data Type Description
errorcode integer Returns an errorcode of 0 if call is successful.
sensors This is an array - its' contents follow:
hsid integer The HostSensorID of the sensor
lasttestmoment integer UNIX timestamp of the most recent test conducted, or null if no data is available
result boolean True if the most recent test of this sensor passed, false if it failed, null if no data is available
errormsg string The error message if the most recent test failed, otherwise null
Try it out with the API Explorer:

Your API Key

API command to be called

Desired response format

The HostID identifying the host whose sensors' state you wish to query (integer)