Deleting a Group
Administrators can use this API to delete a group from the eG manager.
URL: http://<eG manager IP:port>/api/eg/orchestration/deletegroup
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 |
{ "groupname":"mynewgroup,egdbgroup" } |
Body |
Default: { "groupname":"comma-separated list of groups" } |
Type | Code | Content |
---|---|---|
JSON |
200 |
{ "Succeed": "Group has been deleted successfully." } |
Type | Code | Content |
---|---|---|
JSON |
401 UNAUTHORIZED |
{ "Error": "One or more given groups do not exist or is not associated to any zone/segment/services. Invalid groups : <comma-separated list of group names>" } |
Figure 1 : Deleting a Group using Postman REST Client
Deleting a Group using cURL
To delete a group 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/deletegroup" -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 "{'groupname':'comma-separated list of groups'}"
Note that the command specified above contains both the Default and Optional key values.
Figure 2 shows an example of deleting a group using cURL.