{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "title": "create_dhcp_server",
  "type": "object",
  "properties": {
    "name": {
      "type": "string"
    },
    "interface": {
      "type": "string"
    },
    "lease_time": {
      "default": "1d",
      "description": "Lease duration e.g. \"1d\", \"12h\", \"30m\", \"1h30m\"",
      "type": "string"
    },
    "address_pool": {
      "type": "string"
    },
    "disabled": {
      "default": false,
      "type": "boolean"
    },
    "authoritative": {
      "default": "yes",
      "type": "string",
      "enum": ["yes", "no", "after-2sec-delay"]
    },
    "delay_threshold": {
      "type": "string"
    },
    "add_arp": {
      "description": "Add dynamic ARP entry for each lease (use with reply-only ARP on the interface)",
      "type": "boolean"
    },
    "always_broadcast": {
      "description": "Always send replies as broadcast",
      "type": "boolean"
    },
    "ipv6_only_preferred": {
      "description": "RouterOS 7.25+ advertise DHCP option 108 for IPv6-only preferred clients",
      "type": "boolean"
    },
    "bootp_support": {
      "description": "Which BOOTP requests to answer",
      "type": "string",
      "enum": ["none", "static", "dynamic"]
    },
    "conflict_detection": {
      "description": "Ping/ARP-probe an address before offering it to detect conflicts",
      "type": "boolean"
    },
    "use_radius": {
      "description": "Use RADIUS for leases (accounting = RADIUS accounting only)",
      "type": "string",
      "enum": ["yes", "no", "accounting"]
    },
    "relay": {
      "description": "DHCP relay address this server services",
      "type": "string"
    },
    "server_address": {
      "description": "Override the server identifier address sent to clients",
      "type": "string"
    },
    "lease_script": {
      "description": "Script run on lease assign/release",
      "type": "string"
    },
    "comment": {
      "type": "string"
    }
  },
  "required": ["name", "interface", "lease_time", "disabled", "authoritative"],
  "additionalProperties": false
}
