Reorder Firewall Policies
unifi_reorder_firewall_policiesReorder user-defined firewall policies for a source→destination zone pair by setting ordered before- and after-system-defined lists; rule order determines what traffic is allowed or blocked.
Instructions
Set the evaluation order of user-defined firewall policies for one source→destination zone pair. The API splits user policies into those evaluated BEFORE the zone's system-defined policies and those AFTER, so pass two ordered lists. Use unifi_get_firewall_policy_ordering (or model on the current order) to see the existing split. CAUTION: order determines which rule wins — reordering changes what traffic is allowed/blocked; confirm with the user. Zone IDs come from unifi_list_firewall_zones; policy IDs from unifi_list_firewall_policies.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"sourceFirewallZoneId": "<sourceFirewallZoneId>",
"destinationFirewallZoneId": "<destinationFirewallZoneId>",
"beforeSystemDefined": "<beforeSystemDefined>",
"afterSystemDefined": "<afterSystemDefined>"
},
"name": "unifi_reorder_firewall_policies"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| siteId | No | Site ID (UUID from unifi_list_sites). Optional — when the console has exactly one site it is used automatically. | |
| afterSystemDefined | Yes | User-defined policy IDs evaluated AFTER the system-defined policies for this zone pair, in order | |
| beforeSystemDefined | Yes | User-defined policy IDs evaluated BEFORE the system-defined policies for this zone pair, in order | |
| sourceFirewallZoneId | Yes | Source firewall zone ID (from unifi_list_firewall_zones) | |
| destinationFirewallZoneId | Yes | Destination firewall zone ID (from unifi_list_firewall_zones) |