Displaying Details of Maintenance Policies
Use this API to display all the details of the Maintenance Policies configured in the target environment.
URL: http://<eG manager IP:port>/api/eg/orchestration/showMaintenancePolicyDetails
Method: POST
Content-Type: application/json
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 |
{ "policyname":"QMP1, QMP2" } |
Body |
Default: { "policyname":"comma-separated list of Maintenance Policies" } |
Type | Code | Content |
---|---|---|
JSON |
200 |
[ { "policyName": "VDI_maintenance", "policyStatus": "Deactive", "policySchedule": ["Last Day of Month=00:00-23:59"], "nextScheduleDate": "Sep 30, 2020 0:00-23:59", "associatedElements": { "component": ["Vdi_113"] } }, . . . ] |
Type | Code | Content |
---|---|---|
JSON |
401 UNAUTHORIZED |
{ "Error": "One or more maintenance policy does/do not exist." } |
Figure 1 : Displaying the details of the Maintenance Policies in the target environment using Postman REST Client
Displaying Details of Maintenance Policies using cURL
To display the details of the Maintenance Policies in the target environment through the REST API using cURL, the command should be specified in the following format:
curl --location --request POST "http://<eG Manager IP:Port>/api/eg/orchestration/showMaintenancePolicyDetails" -H "managerurl:http://<eG Manager IP:Port>" -H "user:<eG username or domain/eG username>" -H "pwd:Base64 encoded password" -H "Content-Type: application/json" --data-raw "{'policyname':'comma-separated list of Maintenance Policies'}"
Figure 2 shows an example of displaying the details of the Maintenance Policies using cURL.
Figure 2 : Displaying the details of the Maintenance Policies in the target environment using cURL