RESTAPI Manual
Layer 2
DHCP Server
28 min
urls summary urls summary url get post patch put delete /rest/v1/running/dhcp server y n n n n /rest/v1/running/dhcp server/class/{name} y y y n y /rest/v1/running/dhcp server/class/{name}/rule/{id} y y y n y /rest/v1/running/dhcp server/failover/{name} y y y n y /rest/v1/running/dhcp server/interfaces/{name} y n y n n /rest/v1/running/dhcp server/option group/{id} y y y n y /rest/v1/running/dhcp server/v4 pool/{name} y y y n y /rest/v1/running/dhcp server/v4 pool/{name}/class/{class name} y y y n y /rest/v1/running/dhcp server/v6 pool/{name} y y y n y /rest/v1/rpc/show dhcp pool expired n y n n n /rest/v1/rpc/show dhcp pool info n y n n n /rest/v1/rpc/show dhcp pool ip in use n y n n n examples examples show dhcp pool expired show dhcp pool expired post https //{switch ip}/rest/v1/rpc/show dhcp pool expired show dhcp pool information show dhcp pool information post https //{switch ip}/rest/v1/rpc/show dhcp pool info show dhcp pool ip in use show dhcp pool ip in use post https //{switch ip}/rest/v1/rpc/show dhcp pool ip in use get dhcp server information get dhcp server information get https //{switch ip}/rest/v1/running/dhcp server create a dhcp server class create a dhcp server class post https //{switch ip}/rest/v1/running/dhcp server/class { "name" "class2", "rule" \[ {"id" 1, "option" "circuit id", "option value" "123"}, {"id" 2, "option" "remote id", "option value" "456"}, {"id" 3, "option" "pxe system type", "option value" "0x4569"}, ] } create a rule for dhcp server class create a rule for dhcp server class post https //{switch ip}/rest/v1/running/dhcp server/class/{name}/rule/3 { "option" "circuit id", "option value" "123fs" } create a failover for dhcp server create a failover for dhcp server post https //{switch ip}/rest/v1/running/dhcp server/failover { "name" "failover2", "peer down wait time" 650, "max response delay time" 630, "local address" "6 66 9 5", "peer address" "6 66 2 3", "role" "primary", "address pool allocation percentage" 10 } modify dhcp server configuration on an interface modify dhcp server configuration on an interface patch https //{switch ip}/rest/v1/running/dhcp server/interfaces { "name" "ethernet1", "enabled" "true" } create a dhcp server option group create a dhcp server option group post https //{switch ip}/rest/v1/running/dhcp server/option group { "id" 1, "vendor specific information" "0x123" } create a dhcp server ipv4 address pool create a dhcp server ipv4 address pool post https //{switch ip}/rest/v1/running/dhcp server/v4 pool { "name" "pool1", "network" "2 2 2 2/24", "start ip" "2 2 2 10", "end ip" "2 2 2 20", "next server" "3 3 3 3", "failover" "failover1", "bootfile name" "file1", "capwap ac address" "6 6 5 5", "vendor specific information" "0x5636", "default gateway" "6 5 4 5", "tftp server" "www com", "default lease time" 305, "max lease time" 405, "domain name server" "8 8 8 8", "class" \[ { "class name" "class1", "start ip" "2 2 2 30", "end ip" "2 2 2 40", "failover" "failover2", "option group" "2", } ] } create a dhcp server class for an ipv4 address pool create a dhcp server class for an ipv4 address pool post https //{switch ip}/rest/v1/running/dhcp server/v4 pool/pool1/class { "class name" "pool class1", "start ip" "2 2 2 60", "end ip" "2 2 2 70" } create a dhcp server ipv6 address pool create a dhcp server ipv6 address pool post https //{switch ip}/rest/v1/running/dhcp server/v6 pool { "name" "pool2", "network" "2001 3/64", "start ip" "2001 30", "end ip" "2001 40", "default lease time" 305, "max lease time" 405, "domain name server" "2003 4", "vlan" "vlan100" } properties descriptions properties descriptions dhcp server class instance dhcp server class instance tree diagrams + rw dhcp server + rw class \[name] \| + rw name \| + rw rule \[id] \| + rw id \| + rw option \| + rw option value table of properties name required type/range description dhcp server m path only node, has no configurable value class m (sub property of dhcp server) path only node, has no configurable value class of dhcp server name m string (sub property of class) rule m (sub property of class) path only node, has no configurable value id m 1 16 (sub property of rule) dhcp server class rule id option m "circuit id" "remote id" "pxe system type" (sub property of rule) some option fields in the dhcp protocol option value m string (sub property of rule) the value of option in the dhcp protocol dhcp server failover instance dhcp server failover instance tree diagrams + rw dhcp server + rw failover \[name] \| + rw name \| + rw peer down wait time? \| + rw max response delay time? \| + rw local address? \| + rw peer address? \| + rw role? \| + rw address pool allocation percentage? table of properties name required type/range description dhcp server m path only node, has no configurable value failover m (sub property of dhcp server) path only node, has no configurable value the list of dhcp failover name m string (sub property of failover) dhcp failover name peer down wait time o 1 3600 (sub property of failover) waiting time to mark the peer as down after the communication is disconnected max response delay time o 30 3600 (sub property of failover) the maximum time the current server waits for a response from the peer server default value 60 local address o "a b c d" "loopback0" (sub property of failover) the address of local peer address o a b c d (sub property of failover) the ip address of peer role o "primary" "secondary" (sub property of failover) the current server role address pool allocation percentage o 1 100 (sub property of failover) the ratio of the address pool allocated to the primary server and the backup server this parameter can only be configured on the primary server default value 50 dhcp server option group instance dhcp server option group instance tree diagrams + rw dhcp server + rw option group \[id] \| + rw id \| + rw bootfile name \| | + rw bootfile name? \| | + rw force? \| + rw capwap ac address? \| + rw vendor specific information \| | + rw vendor specific information? \| | + rw force? \| + rw default gateway? \| + rw tftp server? table of properties name required type/range description dhcp server m path only node, has no configurable value option group m (sub property of dhcp server) path only node, has no configurable value id m 1 65535 (sub property of option group) id of dhcp option group bootfile name m (sub property of option group) path only node, has no configurable value the location of the boot file used by the client to start the system bootfile name o string (sub property of bootfile name) the location of the boot file used by the client to start the system force o "true" "false" (sub property of bootfile name) force send this option to client default value "false" capwap ac address o a b c d (sub property of option group) ip address of ac vendor specific information m (sub property of option group) path only node, has no configurable value set option43 vendor specific information o a hexadecimal number string (sub property of vendor specific information) the value of option43 is usually in hexadecimal eg "0x5636" force o "true" "false" (sub property of vendor specific information) force send this option to client default value "false" default gateway o a b c d (sub property of option group) specify the ip address of the default gateway tftp server o string (sub property of option group) specify the ip address or domain name of the tftp server dhcp server ipv4 pool dhcp server ipv4 pool tree diagrams + rw dhcp server + rw v4 pool \[name] \| + rw name \| + rw network? \| + rw start ip? \| + rw end ip? \| + rw domain name server? \| + rw bootfile name \| | + rw bootfile name? \| | + rw force? \| + rw capwap ac address? \| + rw vendor specific information \| | + rw vendor specific information? \| | + rw force? \| + rw default gateway? \| + rw tftp server? \| + rw default lease time? \| + rw max lease time? \| + rw vlan? \| + rw next server? \| + rw failover? \| + rw class \[class name] \| + rw class name \| + rw start ip? \| + rw end ip? \| + rw failover? \| + rw option group? table of properties name required type/range description dhcp server m path only node, has no configurable value v4 pool m (sub property of dhcp server) path only node, has no configurable value name m string (sub property of v4 pool) dhcp pool name network o a b c d/m (sub property of v4 pool) specify the network segment of the dhcp pool start ip o a b c d (sub property of v4 pool) specify the starting ip address of the dhcp pool end ip o a b c d (sub property of v4 pool) specify the end ip address of the dhcp pool domain name server o a b c d (sub property of v4 pool) ip address of dns server bootfile name m (sub property of v4 pool) path only node, has no configurable value the location of the boot file used by the client to start the system bootfile name o string (sub property of bootfile name) the location of the boot file used by the client to start the system force o "true" "false" (sub property of bootfile name) force send this option to client default value "false" capwap ac address o a b c d (sub property of v4 pool) ip address of ac vendor specific information m (sub property of v4 pool) path only node, has no configurable value set option43 vendor specific information o a hexadecimal number string (sub property of vendor specific information) the value of option43 is usually in hexadecimal eg "0x1f" force o "true" "false" (sub property of vendor specific information) force send this option to client default value "false" default gateway o a b c d (sub property of v4 pool) specify the ip address of the default gateway tftp server o string (sub property of v4 pool) specify the ip address or domain name of the tftp server default lease time o 300 100000000 (sub property of v4 pool) default lease time default value 604800 max lease time o 300 100000000 (sub property of v4 pool) maximum lease time default value 2592000 vlan o vlan1 4094 (sub property of v4 pool) next server o a b c d (sub property of v4 pool) ip address of tftp server failover o string (sub property of v4 pool) class bound failover class m (sub property of v4 pool) path only node, has no configurable value class bound to dhcp pool class name m string (sub property of class) the bound class name start ip o a b c d (sub property of class) set the rules in this class to apply to the starting ip address of the ip segment end ip o a b c d (sub property of class) set the rules in this class to apply to the end ip address of the ip segment failover o string (sub property of class) class bound failover option group o 0 65535 (sub property of class) class bound option group dhcp server ipv6 pool dhcp server ipv6 pool tree diagrams + rw dhcp server + rw v6 pool \[name] \| + rw name \| + rw network? \| + rw start ip? \| + rw end ip? \| + rw domain name server? \| + rw default lease time? \| + rw max lease time? \| + rw vlan? table of properties name required type/range description dhcp server m path only node, has no configurable value v6 pool m (sub property of dhcp server) path only node, has no configurable value name m string (sub property of v6 pool) dhcp pool name network o xx\ xx\ xx\ xx\ xx\ xx\ xx\ xx/m (sub property of v6 pool) specify the network segment of the dhcp pool v6 start ip o xx\ xx\ xx\ xx\ xx\ xx\ xx\ xx (sub property of v6 pool) specify the starting ipv6 address of the dhcp pool v6 end ip o xx\ xx\ xx\ xx\ xx\ xx\ xx\ xx (sub property of v6 pool) specify the end ipv6 address of the dhcp pool v6 domain name server o xx\ xx\ xx\ xx\ xx\ xx\ xx\ xx (sub property of v6 pool) ip address of dns server default lease time o 300 100000000 (sub property of v6 pool) default lease time default value 604800 max lease time o 300 100000000 (sub property of v6 pool) maximum lease time default value 2592000 vlan o vlan1 4094 (sub property of v6 pool) dhcp server interfaces dhcp server interfaces tree diagrams + rw dhcp server + rw interfaces \[name] + rw name + rw enabled? table of properties name required type/range description dhcp server m path only node, has no configurable value interfaces m (sub property of dhcp server) path only node, has no configurable value list of interfaces enabled to the dhcp pool name m ethernet name vlan1 4094 (sub property of interfaces) enabled o "true" "false" (sub property of interfaces) show dhcp pool expired show dhcp pool expired tree diagrams + x show dhcp pool expired \| + w input \| | + w version? \| + ro output \| + ro data? table of properties name required type/range description show dhcp pool expired m path only node, has no configurable value show dhcp server expired lease version o "v4" "v6" (sub property of input) the family of the pool data ro \<anydata> (sub property of output) show dhcp pool info show dhcp pool info tree diagrams + x show dhcp pool info \| + w input \| | + w version? \| + ro output \| + ro data? table of properties name required type/range description show dhcp pool info m path only node, has no configurable value show dhcp server pool info version o "v4" "v6" (sub property of input) the family of the pool data ro \<anydata> (sub property of output) show dhcp pool ip in use show dhcp pool ip in use tree diagrams + x show dhcp pool ip in use + w input \| + w version? \| + w address? + ro output + ro data? table of properties name required type/range description show dhcp pool ip in use m path only node, has no configurable value show dhcp server lease version o "v4" "v6" (sub property of input) the family of the pool address o a b c d xx\ xx\ xx\ xx\ xx\ xx\ xx\ xx (sub property of input) data ro \<anydata> (sub property of output)
