opn-mcp
Server Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
| OPNSENSE_URL | Yes | Firewall API URL, e.g. https://opnsense.example.lan/api | |
| OPNSENSE_API_KEY | Yes | API key, created under System → Access → Users → (user) → API keys | |
| OPNSENSE_TIMEOUT | No | Request timeout for OPNsense API calls | |
| OPNSENSE_API_SECRET | Yes | API secret corresponding to OPNSENSE_API_KEY | |
| OPNSENSE_VERIFY_SSL | No | SSL verification setting: false, true, or a CA path | |
| OPNSENSE_ALLOW_WRITES | No | Set to true to enable writes; without it the server is read-only |
Instructions
Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.
This server publishes no instructions, or was last inspected before Glama recorded them.
Capabilities
Features and capabilities supported by this server
Protocol revision2025-11-25
| Capability | Details |
|---|---|
| tools | {
"listChanged": false
} |
| prompts | {
"listChanged": false
} |
| resources | {
"subscribe": false,
"listChanged": false
} |
| experimental | {} |
Tools
Functions exposed to the LLM to take actions
| Name | Description |
|---|---|
| opn_api_searchB | Search OPNsense API endpoints by words in the path, description or model (e.g. "alias", "kea reservation", "unbound host override", "wireguard peer"). |
| opn_api_describeB | Method, path args, body fields (types, required, options) and search params of an endpoint, e.g. "firewall/alias/add_item". |
| opn_apiA | Call any endpoint: path is module/controller/action plus positional args, e.g. "core/service/restart/unbound" or "firewall/alias/set_item/". The method defaults to what the endpoint expects. POST bodies are checked against the model unless strict=false. dry_run=true shows the request without sending it. Changes saved this way are not active until the controller's apply/reconfigure runs (see opn_items). |
| opn_itemsB | Work with the items of any OPNsense model controller. controller + item name the endpoints: ("firewall/alias", "item") -> firewall/alias/search_item, add_item, ...; ("firewall/filter", "rule"), ("firewall/d_nat", "rule"), ("unbound/settings", "host_override"), ("dnsmasq/settings", "host"), ("kea/dhcpv4", "reservation"), ("nginx/settings", "upstream"). data holds just the item's fields (see opn_api_describe on the add_ endpoint). apply=true runs the controller's apply/reconfigure afterwards; for firewall rules that arms the auto-revert (confirm with opn_firewall_confirm). del needs confirm=true. |
| opn_settingsB | Read a controller's whole settings model (controller/get), or change part of it: data is merged into the model and saved with controller/set, e.g. opn_settings("unbound/settings", {"general": {"port": "53"}}). apply=true then runs the service reconfigure. |
| opn_firewall_confirmA | Keep the applied firewall changes and cancel the pending auto-revert. |
| opn_firewall_revert_nowA | Revert the pending firewall changes immediately instead of waiting for the timer. |
| opn_config_historyA | Config history (newest first: id, time, description, user). With diff_with=, the diff between that backup and the newest one. |
| opn_config_revertA | Restore config.xml from a history entry (id from opn_config_history). Services other than the firewall keep running with their old config until reconfigured. Needs confirm=true. |
| opn_overviewA | Version, update status, interfaces, gateways and services in one call, plus whether writes are enabled. |
| opn_serviceA | List services (no name), or start/stop/restart one by name (e.g. "unbound", "dhcpd", "openvpn" with service_id for multi-instance services). stop needs confirm=true. |
| opn_neighborsA | ARP (ipv4) or NDP (ipv6) table, optionally filtered by IP/MAC/hostname substring. |
| opn_firewall_logB | Recent firewall log entries (newest first), optionally filtered by a substring (IP, port, interface). |
| opn_pingA | Ping a host from the firewall and return loss and round-trip times. Works in read-only mode: it only runs a temporary diagnostics job, which is removed afterwards. |
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
No prompts | |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
No resources | |
TDQS
Scored across 14 tools
Most tools have clear, distinct purposes: discovery (search/describe), the generic caller (opn_api), convenience wrappers (opn_items/opn_settings), and domain-specific helpers (ping, neighbors, firewall_log, overview, service, config tools). The main soft overlap is opn_api vs opn_items vs opn_settings, since all can write to model controllers, but descriptions explain the layering (generic escape hatch vs item-level vs whole-model).
All tools share a consistent opn_ snake_case prefix, which is readable and predictable. The verb/noun mix (opn_api_search, opn_config_revert vs opn_items, opn_overview, opn_service) is slightly inconsistent but each name still signals its role clearly.
14 tools is well within the ideal 3-15 range and each one earns its place: discovery, generic call, item/settings helpers, and targeted diagnostics/management tools. Nothing is redundant filler, and the count fits a broad OPNsense management surface.
The surface covers the full lifecycle well: discovery, read/write via opn_api/opn_items/opn_settings, apply/confirm/revert-now for firewall safety, config history/restore, plus diagnostics (ping, neighbors, log, overview, services). The generic opn_api acts as a catch-all for any gap, so coverage is strong, with only minor friction from needing controller/item knowledge to use the wrappers.