proxmox_add_firewall_rule
Add a confirmed Proxmox VE firewall rule at cluster, node, or guest scope to control inbound, outbound, or security-group traffic. Use confirm:true to perform the write.
Instructions
Add a firewall rule at the cluster, node, or guest scope (POST {base}/firewall/rules). Tier-2 write; requires confirm:true.
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": {
"scope": "<scope>",
"type": "<type>",
"action": "<action>",
"confirm": "<confirm>"
},
"name": "proxmox_add_firewall_rule"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| pos | No | Insert position (default: prepend at 0). | |
| dest | No | Destination CIDR/IP/alias. | |
| node | No | Node name (required when scope='node'). | |
| type | Yes | Rule direction: 'in', 'out', or 'group' (attach a security group). | |
| vmid | No | Guest VMID (required when scope='guest'). | |
| dport | No | Destination port(s), e.g. '22' or '8000:8100'. | |
| macro | No | Predefined macro, e.g. 'SSH', 'HTTP'. | |
| proto | No | Protocol, e.g. tcp, udp, icmp. | |
| scope | Yes | Firewall scope: 'cluster', 'node' (needs node), or 'guest' (needs vmid). | |
| sport | No | Source port(s). | |
| action | Yes | ACCEPT, DROP, REJECT, or a security-group name when type='group'. | |
| enable | No | Whether the rule is active (default true). | |
| source | No | Source CIDR/IP/alias. | |
| comment | No | Human-readable comment. | |
| confirm | Yes | Must be true to write. Tier-2 safe-write gate. |