create_device_dhcp_server
Create a DHCP server scope on a managed FortiGate device, defining the interface, IP range, netmask, gateway, DNS servers, and lease time for client address assignment.
Instructions
Create a DHCP server scope in a device's device DB.
Args: device: Managed device name interface: Interface the scope serves (e.g. "vlan15") start_ip: First address of the lease range end_ip: Last address of the lease range netmask: Scope netmask (e.g. "255.255.255.0") default_gateway: Gateway handed to clients (defaults to the interface address if omitted, per FortiOS behavior) dns_servers: Up to three DNS servers to hand out; omitted means the device's system DNS is used (dns-service default) lease_time: Lease time in seconds vdom: VDOM the scope lives in (default "root")
Returns: Creation result including the new scope id
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| vdom | No | root | |
| device | Yes | ||
| end_ip | Yes | ||
| netmask | Yes | ||
| start_ip | Yes | ||
| interface | Yes | ||
| lease_time | No | ||
| dns_servers | No | ||
| default_gateway | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||