Renaming a Zone
Administrators can use this API to rename an existing Zone in eG Enterprise.
URL: http://<eG manager IP:port>/api/eg/orchestration/renamezone
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 |
{ "zonename":"Northzone", "newzonename":"North_zone" } |
Body |
Default: { "zonename":"Zone name", "newzonename":"New zone name" } |
Type | Code | Content |
---|---|---|
JSON |
200 |
{ "Succeed": "Zone has been renamed successfully." } |
Type | Code | Content |
---|---|---|
JSON |
401 UNAUTHORIZED |
{ "Error": "The given zone does not exist." } |
Figure 1 : Example to rename an existing Zone using Postman REST Client
Renaming a Zone using cURL
To rename an existing zone 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/renamezone" -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 "{'zonename':'Zone name', 'newzonename':'New zone name'}"
Figure 2 shows an example of renaming a zone using cURL.