Retrieving Threshold Data

Using the eG REST API, administrators can retrieve the threshold configured for the measures of a chosen test. The table below specifies the URL and the parameters that should be used to retrieve the measures of the tests.

URL: http://<eG manager IP:port>/api/eg/analytics/getThresholdData

Method: POST

Content-Type: application/json

Inputs to be Specified
Parameters Key values Example

Headers

managerurl: Base URL of the eG Manager i.e., http://<IP address of the eG console:Port>

user: eG username or domain/eG username

pwd: Base64 encoded password

{

"test":"Oracle Latches",

"host":"Oracle",

"port":"1521",

"info":"egurkha+redo allocation",

"type":"Threshold"

}

Body

Default:

{

"test":"Test name",

"host":"Host name",

"port":"Port",

"info":"info"

}

Optional:

"type":"Threshold",

"measure":"comma-separated list of measures",

"searchhost":"Search Host",

"searchinfo":"Search info",

"groupby":"TRGT_HOST",

"orderby":"Ascending/Descending",

}

 

Success Response
Type Code Content

JSON

200

[

"TRGT_HOST PORT_NO SITE_NAME INFO MSMT_HOST MSMT_TIME_START MSMT_TIME_END AVAILABLE_MIN AVAILABLE_MAX RESP_TIME_MIN RESP_TIME_MAX TCP_CONN_AVAIL_MIN TCP_CONN_AVAIL_MAX TCP_CONN_TIME_MIN TCP_CONN_TIME_MAX SVR_RESP_TIME_MIN SVR_RESP_TIME_MAX CONTENT_VAL_MIN CONTENT_VAL_MAX RESP_CODE_MIN RESP_CODE_MAX CONTENT_LEN_MIN CONTENT_LEN_MAX DATA_XFER_TIME_MIN DATA_XFER_TIME_MAX DNS_AVAILABILITY_MIN DNS_AVAILABILITY_MAX DNS_RESP_TIME_MIN DNS_RESP_TIME_MAX ",

"TEZWIN19O365 80 NULL +HomePage 172.16.14.93 2022-04-25 13:30:00 2022-04-25 14:30:00 95/-/- -1 -1 -1 95/-/- -1 -1 -1 -1 -1 95/-/- -1 -1 -1 -1 -1 -1 -1 95/-/- -1 -1 -1",

"TEZWIN19O365 80 NULL +HomePage 172.16.14.93 2022-04-25 14:30:00 2022-04-25 15:30:00 95/-/- -1 -1 -1 95/-/- -1 -1 -1 -1 -1 95/-/- -1 -1 -1 -1 -1 -1 -1 95/-/- -1 -1 -1",

"TEZWIN19O365 80 NULL +HomePage 172.16.14.93 2022-04-25 15:30:00 2022-04-25 16:30:00 95/-/- -1 -1 -1 95/-/- -1 -1 -1 -1 -1 95/-/- -1 -1 -1 -1 -1 -1 -1 95/-/- -1 -1 -1",

.

.

.

]

 

Failure Response
Type Code Content

JSON

401 UNAUTHORIZED

{"code": 401,"error": "Unauthorized user"}

JSON

500 Server Error

{"code": 500,"error": " Server Error "}

Figure 1 : Retrieving Threshold data configured for the measures using Postman REST Client

Retrieving Threshold Data using cURL

To retrieve the threshold configured for the measures of a chosen test using cURL, the command should be specified in the following format:

curl -location -request POST "http://<eG Manager IP:Port>/api/eg/analytics/getThresholdData" -H "user:<eG username or domain/eG username>" -H "pwd:Base64 encoded password" -H "managerurl:http://<eG Manager IP:Port>" -H"Content-Type:application/json" --data-raw "{\"test\":\"Test name\",\"host\":\"Host name\",\"type\":\"Threshold\"}"

Figure 2 shows an example to retrieve the threshold configured for the measures of a chosen test using cURL.

Figure 2 : An example cURL command to retrieve the threshold configured for the measures

Figure 3 shows a sample output that retrieves the threshold configured for the measures of a chosen test reported by eG Enterprise using cURL.

Figure 3 : Sample output with the threshold data configured for the measures of a chosen test