RESTAPI Manual
Layer 2
DHCP Relay
7 min
dhcp (dynamic host configuration protocol) relay urls summary urls summary url get post patch put delete /rest/v1/running/dhcp relay/{name} y y y n y /rest/v1/running/dhcp relay/{name}/downlink vlans/{vlan} y y n n y /rest/v1/rpc/show dhcp relay n y n n n examples examples create a dhcp relay instance create a dhcp relay instance post https //{switch ip}/rest/v1/running/dhcp relay { "name" "test1", "type" "v4", "vrf" "vrf1", "downlink vlans" \[ {"vlan" "vlan100", "option82 sub5" "100 0 0 1"}, {"vlan" "vlan300", "gateway ip address" "3 3 3 4"}, ], "uplink interfaces" \["vlan200"], "server ips" \["12 3 3 3", "15 3 3 3"] } create a downlink vlan for a dhcp relay instance named {name} create a downlink vlan for a dhcp relay instance named {name} post https //{switch ip}/rest/v1/running/dhcp relay/test/downlink vlans/vlan100 { "gateway ip address" "10 0 0 1" } properties descriptions properties descriptions dhcp relay instance dhcp relay instance tree diagrams + rw dhcp relay + rw dhcp relay agent \[name] + rw name + rw type? + rw vrf? + rw downlink vlans \[vlan] \| + rw vlan \| + rw gateway ip address? \| + rw option82 sub5? \| + rw rfc6939 support? + rw uplink interfaces + rw gateway interface? + rw server ips table of properties name required type/range description dhcp relay m path only node, has no configurable value dhcp relay name m word not contain ' ' (sub property of dhcp relay) dhcp relay name type o "v4" "v6" (sub property of dhcp relay) default value "v4" vrf o "default" vrf name (sub property of dhcp relay) set dhcp relay vrf downlink vlans m (sub property of dhcp relay) path only node, has no configurable value vlan m vlan1 4094 (sub property of downlink vlans) downlink vlan gateway ip address o a b c d (sub property of downlink vlans) ip address of dhcp relay agent default value "0 0 0 0" option82 sub5 o a b c d xx\ xx\ xx\ xx\ xx\ xx\ xx\ xx (sub property of downlink vlans) one ip address of downlink vlan default value "0 0 0 0" rfc6939 support o "true" "false" (sub property of downlink vlans) set rfc6939 for the relay default value "false" uplink interfaces o ethernet name vlan name (sub property of dhcp relay) uplink interface gateway interface o loopback0 199 (sub property of dhcp relay) set loopback interface as dhcp relay gateway #server ips o a b c d xx\ xx\ xx\ xx\ xx\ xx\ xx\ xx (sub property of dhcp relay) the ip address of dhcp server show dhcp relay show dhcp relay tree diagrams + x show dhcp relay + ro output + ro data? table of properties name required type/range description show dhcp relay m path only node, has no configurable value show dhcp relay info data ro \<anydata> (sub property of output)
