The License Server Uptime endpoint delivers license usage metrics specific to license server status for the currently selected license server during any period the server status was monitored.
Obtaining information about license server status
You can easily fetch metrics about license server status history by sending the following HTTP request.
GET /api/v1/report/uptime/server/${licenseServerId}/json?sd=${YYYY-MM-DD}&ed=${YYYY-MM-DD}
where $ indicates a variable value that you can replace with a value that best suits your needs. The possible parameters are described below.
Parameter | Required | Type | Description |
---|---|---|---|
${licenseServerId} | Yes | integer | Internal License Statistics identification of the license server for which you want to view status information. |
sd | Yes | string | Start date for which you want to generate the report. |
ed | Yes | string | End date for which you want to generate the report. |
This report supports only JSON format.
This report does not support standard options (filtering, limiting or ordering).
Response
On success, this report will contain one row for each event, such as query failure, server being disabled, successful query after period of failures, etc. See license server status descriptions for further details.
Each row consists of the following columns.
Column | Full name | Type | Description |
---|---|---|---|
lsucd | Time | date and time | Time when the event occurred. |
lssid | Status Id | integer | Numeric value of license server status. See license server status descriptions for further details. |
errmsg | Message | string | Optional message describing what went wrong. |
Example
The following example shows a command that obtains information about the uptime of license server "1" in January 2017.
curl --data "sd=2017-01-01" --data "ed=2017-01-31" -H "X-Auth-token: token" "http://yourdomain/api/v1/report/uptime/server/1/json"
You can also put parameters directly into the URL. For the above example, the command would look like the following.
curl -H "X-Auth-token: token" "http://yourdomain/api/v1/report/uptime/server/1/json?sd=2017-01-01&ed=2017-01-31"