vShield API Programming Guide
Example:
POST /api/1.0/network/network-244/dhcp/config HTTP/1.1
content-type: application/xml; charset=UTF-8
Authorization: Basic YWRtaW46ZGVmYXVsdA==
Host: 10.112.196.213
accept: text/html, image/gif, image/jpeg, *; q=.2, */*; q=.2
content-length: 655
<?xml version="1.0" encoding="UTF-8"
standalone="yes"?><VShieldEdgeConfig><DHCPConfig><DHCPBinding><vmId>vm-70</vmI d>
Get the Configuration for All DHCP Hosts and Pools
You can retrieve the current DHCP configuration for a vShield Edge, including all configured hosts and IP
pools.
Example 5-6. Getting the Configuration of All DHCP Hosts and Pools
Request:
GET <vshield_manager-uri>/api/1.0/network/<portgroup-moid>/dhcp/config
Example:
GET /api/1.0/network/network-244/dhcp/config HTTP/1.1
Authorization: Basic YWRtaW46ZGVmYXVsdA==
Host: 10.112.196.213
Get Timestamps of Last 10 DHCP Configurations
You can get a list of the last 10 DHCP configurations by timestamp.
Example 5-7. Getting Last 10 DHCP Configurations
Request:
GET <vshield_manager-uri>/api/1.0/network/<portgroup-moid>/dhcp/snapshots
Get a DHCP Configuration by Timestamp
You can view the details of a past DHCP configuration by specifying the timestamp of the snapshot.
Example 5-8. Getting a DHCP Configuration by Snapshot Timestamp
Request:
GET <vshield_manager-uri>/api/1.0/network/<portgroup-moid>/
28
<interfaceId>1</interfaceId><hostName>vmware</hostName><internalIPAddress>17
2.16.1.54</internalIPAddress><DHCPConfigParams><domainName>vmware.com</domainN
ame><primaryNameServer>10.112.192.1</primaryNameServer><secondaryNameServer>
10 .112.192.2</secondaryNameServer><leaseTime>3000</leaseTime></DHCPConfigParams>
</DHCPBinding><DHCPPool><PoolRange><rangeStart>172.16.1.50</rangeStart>
<rangeEnd>172.16.1.53</rangeEnd></PoolRange><DHCPConfigParams><leaseTime>infinite
</leaseTime></DHCPConfigParams></DHCPPool></DHCPConfig></VShieldEdgeConfig>
dhcp/snapshot/<snapshot-timestamp>
VMware, Inc.
Need help?
Do you have a question about the VSHIELD APP 1.0 - API and is the answer not in the manual?
Questions and answers