Change VPS firewall
vps_manage_firewallChange a VPS's host firewall over SSH. add_rule and remove_rule need port, proto and ruleAction; remove_rule must match a rule from vps_get_firewall. enable keeps the SSH port open by itself; add rules for every other port in use first (web 80 and 443, game or database ports), or those services become unreachable. disable stops all filtering. Needs ufw, firewalld or Windows Firewall on the VPS; without one the call fails.
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": {
"id": "<id>",
"action": "<action>"
},
"name": "vps_manage_firewall"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | The VPS ID | |
| port | No | Port or port range (e.g. '80', '8000:8100'). Required for add_rule and remove_rule. | |
| proto | No | Protocol. Required for add_rule and remove_rule. | |
| action | Yes | add_rule or remove_rule for one rule; enable or disable for the whole firewall | |
| source | No | Source IP/CIDR or 'any' (default: 'any') | |
| comment | No | Optional comment for the rule | |
| ruleAction | No | Allow or deny. Required for add_rule and remove_rule. |