Document toolboxDocument toolbox

Querying Server Statuses Using the API

The Infoblox platform provides the statuses API call, so you can query the following statuses on a specific NIOS-X server:

  • Server status

  • Platform service status

  • Protocol service status


You can use the following curl command to query server statuses:

curl -k "https://<Server IP address>/api/hostmonitoring/v1/statuses" --header 'Accept: application/json' | jq

Server Metric Connector returns a response based on the following schema:

{
    Object    string  // ntp, cdc, host, platform etc.
    SubObject string  // health, network-connectivity, upgrade etc.
    State     string  // started, stopped, online, degraded etc.
    Severity  string  // info, warn, error etc.

    Messages  json
    Metadata  json     // ophid, pool_id, service_id (if applicable), host, account_id, identity_account_id, host_id, host_uuid and other relevant labels
    UpdatedAt time.Time  This is the timestamp when Infoblox Platform last polled the health-reporter and got an update about changes in the status.
}

The following is an example of a response:

The screenshot shows an example of a response returned for the query for host statuses.

Severity Levels for Status Events

The following table lists all possible severity levels for the status events:

Displayed NameSeverity LevelSystem Response
emergEmergencySystem unusable
alertAlertImmediate action needed
critCriticalCritical conditions exist
errorErrorError conditions exist
warnWarningWarning conditions exist
noticeNoticeNormal but significant conditions exist
infoInformationalInformational messages
debugDebugDebug messages

In addition, you can query a server's metrics, by using the following curl command:

    curl -k "https://<server IP address>/api/hostmonitoring/v1/metrics" --header 'Accept: application/json' | jq

Server Metric Connector returns a response based on the following schema:

{

    Name string // The name of the metric.
    Help string // Help text for the metric.
    Type string // Type of the metric (e.g., GAUGE, COUNTER, HISTOGRAM etc).
    Metrics json // ophid, pool_id, host, account_id, identity_account_id, host_id, host_uuid and other relevant labels along with the value of the metric.
}

The following is an example of a response:

The screenshot shows an example of a response returned for the query for host metrics.