mcp_vyos
Server Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
| VYOS_URL | No | Base HTTPS URL of the API listener (e.g. https://192.168.1.1 or https://192.168.1.1:8443). | https://127.0.0.1 |
| VYOS_API_KEY | Yes | Plaintext API key configured on VyOS. | |
| VYOS_TIMEOUT | No | HTTP timeout in seconds. | 30 |
| VYOS_READONLY | No | Block all modifying operations. | false |
| VYOS_SSH_HOST | No | SSH host (defaults to the host in VYOS_URL). | Auto |
| VYOS_SSH_PORT | No | SSH port. | 22 |
| VYOS_SSH_USER | No | SSH username. | vyos |
| VYOS_VERIFY_SSL | No | Verify TLS certificate (false for the self-signed default). | false |
| VYOS_REST_STRICT | No | Informational hint mirroring api rest strict. | false |
| VYOS_SSH_ENABLED | No | Enable SSH operational fallback tools. | true |
| VYOS_SSH_TIMEOUT | No | SSH command timeout in seconds. | 20 |
| VYOS_SSH_KEY_PATH | No | Path to a private SSH key. | None |
| VYOS_SSH_PASSWORD | No | SSH password (if not using a key). | None |
| VYOS_SSH_KEY_PASSPHRASE | No | Passphrase for an encrypted key. | None |
Instructions
Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.
VyOS Router MCP Server. Configure and operate a VyOS router over the HTTPS API (and optional SSH). Generic primitives (vyos_show_config, vyos_set, vyos_delete, vyos_configure_batch, vyos_show, vyos_generate) reach every node in the configuration tree; typed wrappers cover interfaces, firewall, NAT, routing (BGP/OSPF/static), services (DHCP/DNS/SSH/NTP), VPN (WireGuard/IPsec/OpenVPN) and system. vyos_raw_api_call hits any endpoint directly. IMPORTANT: every /configure request commits immediately but is NOT saved to disk — use vyos_save_config (or save=True) to persist. Fields validated together (a firewall rule's action+protocol+port, a NAT rule's translation, a scheduler task's interval) MUST be sent in one request; use vyos_configure_batch or the wrappers, which build complete transactions. Use confirm_time for commit-confirm as a safety net when reconfiguring remotely. Secrets are redacted by default; pass include_secrets=true only when a value is needed.
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 |
|---|---|
| vyos_show_configA | Retrieve the VyOS configuration tree (or a subtree) as structured JSON. Args: path: Configuration path to read (list or space-separated string). Omit or pass an empty list to return the entire configuration. include_secrets: Return credential values unredacted (default False). A valid path that holds no configuration returns {"configured": false} rather than raising, so desired-state comparisons work on a fresh system. |
| vyos_config_existsA | Check whether a configuration path currently exists. Returns {"exists": bool}. Use this before a desired-state apply to avoid the "empty configuration" error on fresh systems. Args: path: Configuration path (list or space-separated string). |
| vyos_return_valuesA | Return the value(s) of a multi-valued configuration node. Example: path ["interfaces","dummy","dum0","address"] returns the list of configured addresses. Args: path: Configuration path to the multi-valued node. include_secrets: Return values unredacted (default False). |
| vyos_show_config_commandsA | Export the running configuration as flat Equivalent to the operational command Args: include_secrets: Return secrets unredacted (default False). |
| vyos_setA | Apply a single Args: path: Configuration path (list or space-separated string), e.g. "interfaces dummy dum1 address". value: Optional final value appended to the path, e.g. "10.11.0.1/32". confirm_time: If > 0, commit-confirm: the change reverts after this many minutes unless vyos_confirm_commit is called. Use as a remote safety net. save: Persist to /config/config.boot after a successful commit (default False). NOTE: fields validated together must be set in one request — use vyos_configure_batch for those. A single set that leaves a rule/object incomplete will fail validation. |
| vyos_deleteA | Apply a single Args: path: Configuration path to delete (list or space-separated string). Include a trailing value to delete only one entry of a multi-valued node. confirm_time: If > 0, commit-confirm (reverts unless confirmed). save: Persist to /config/config.boot after a successful commit (default False). |
| vyos_commentA | Attach a comment to a configuration node. Args: path: Configuration path to annotate. comment: Comment text (empty string removes the comment). save: Persist after commit (default False). |
| vyos_configure_batchA | Apply multiple set/delete/comment operations as a single commit transaction. This is the workhorse for anything whose fields are validated together: a firewall rule (action + protocol + ports), a NAT rule (translation), a VXLAN or tunnel block, a scheduler task (executable + interval). Sending such fields in separate requests fails validation because each request commits on its own. Args: operations: List of objects, each {"op": "set"|"delete"|"comment", "path": [...] or "a b c", optional "value": "..."}. The value, if given, is appended to the path. confirm_time: If > 0, commit-confirm for the whole transaction. save: Persist to /config/config.boot after a successful commit (default False). A list is applied atomically per component: if one operation fails, nothing is committed for that component. The error names the component and missing field. |
| vyos_showA | Run an operational-mode Examples of path: "interfaces", "ip route", "system image", "vpn ipsec sa", "interfaces wireguard wg0". Args: path: The show command tokens (list or space-separated string), WITHOUT the leading word "show". include_secrets: Return output unredacted (default False). |
| vyos_generateA | Run a Example path: "pki wireguard key-pair". Args: path: The generate command tokens, WITHOUT the leading word "generate". Secrets in the output are NOT redacted — generated keys are the point. |
| vyos_get_infoA | Get general system information from the public /info endpoint. Returns the VyOS version, hostname and welcome banner. This endpoint does not require authentication and is a good connectivity check. |
| vyos_pingB | Ping a host from the VyOS router. Args: host: Target IP address or hostname. count: Number of echo requests (1-20, default 4). |
| vyos_tracerouteB | Run a traceroute from the VyOS router to a destination. Args: host: Target IP address or hostname. |
| vyos_dns_lookupC | Resolve a hostname from the VyOS router. Args: host: Hostname or IP to resolve. nameserver: Optional DNS server to query. |
| vyos_save_configA | Save the running configuration to disk so it survives a reboot. The /configure endpoint commits but never saves; call this to persist. Args: file: Optional target path. Defaults to /config/config.boot. |
| vyos_load_configC | Replace the running configuration from a file or a config string. Args: file: Path to a configuration file on the router (e.g. /config/test.config). string: A full configuration in curly-brace format (alternative to file). |
| vyos_merge_configB | Merge a configuration file or string into the running configuration. Args: file: Path to a configuration file on the router. string: A configuration fragment in curly-brace format. confirm_time: If > 0, commit-confirm (reverts unless vyos_confirm_commit runs). |
| vyos_confirm_commitA | Confirm a pending commit-confirm, stopping the auto-revert timer. Call this after a change applied with confirm_time once you have verified the router is still reachable and behaving correctly. |
| vyos_resetA | Run an operational Example path: "ip bgp 192.0.2.11". Args: path: The reset command tokens, WITHOUT the leading word "reset". |
| vyos_reconnectB | Bring a connection-oriented interface down and up again (PPPoE, WWAN). Args: interface: Interface name, e.g. "pppoe0". |
| vyos_rebootA | Reboot the VyOS router. WARNING: interrupts all traffic. Requires confirm=True and write access. Args: confirm: Must be explicitly True to proceed. now: Reboot immediately (default True). |
| vyos_poweroffA | Power off the VyOS router. WARNING: the router must be powered back on manually. Requires confirm=True and write access. Args: confirm: Must be explicitly True to proceed. |
| vyos_image_addA | Download and install a VyOS system image from a URL. Args: url: HTTPS URL of the VyOS ISO image. confirm: Must be explicitly True to proceed (large, state-changing operation). |
| vyos_image_deleteA | Delete an installed VyOS system image by name. Args: name: Image name, e.g. "1.3-rolling-202006070117". confirm: Must be explicitly True to proceed. |
| vyos_list_interfacesB | List all configured interfaces and their configuration subtree. Args: include_secrets: Return WireGuard/tunnel keys unredacted (default False). |
| vyos_get_interfaceA | Get the configuration of a single interface. Args: type: Interface type, e.g. "ethernet", "wireguard", "bridge", "dummy". name: Interface name, e.g. "eth0", "wg0", "br0". include_secrets: Return keys unredacted (default False). |
| vyos_show_interfaces_statusA | Show live operational status of all interfaces (link, addresses, counters). |
| vyos_set_interface_addressB | Assign an IP address (or "dhcp"/"dhcpv6") to an interface. Args: type: Interface type, e.g. "ethernet", "dummy", "bridge". name: Interface name, e.g. "eth0". address: CIDR address like "192.0.2.1/24", or "dhcp"/"dhcpv6". save: Persist after commit (default False). |
| vyos_configure_interfaceA | Configure an interface with a set of leaf settings in one commit. All settings are applied together, so interdependent fields validate correctly. Args: type: Interface type, e.g. "ethernet", "bridge", "bonding", "vxlan", "wireguard", "tunnel", "dummy", "loopback". name: Interface name, e.g. "eth1", "br0", "wg0". settings: Map of setting path (relative to the interface) to value. The key may be space-separated for nested nodes. Examples: {"address": "192.0.2.1/24", "mtu": "1500"} {"vni": "100", "remote": "203.0.113.9", "source-address": "198.51.100.1"} {"private-key": "...", "peer WG0 allowed-ips": "0.0.0.0/0"} A value of null/empty creates a valueless node. description: Optional interface description. save: Persist after commit (default False). |
| vyos_delete_interfaceB | Delete an interface or disconnect a physical interface's configuration. Args: type: Interface type, e.g. "dummy", "wireguard", "vxlan". name: Interface name, e.g. "dum1", "wg0". save: Persist after commit (default False). |
| vyos_show_firewallA | Show the firewall configuration tree (optionally a subsection). Args: section: Optional subsection, e.g. "ipv4", "group", "ipv6 forward filter". |
| vyos_list_firewall_rulesB | List the rules of a firewall filter hook. Args: family: "ipv4" or "ipv6". hook: "forward", "input" or "output". |
| vyos_add_firewall_ruleA | Create or update a firewall filter rule in a single commit. The action is always included so the rule validates. Protocol-dependent fields
(destination/source port) require 'protocol' to be present in Args: rule: Rule number (lower numbers are evaluated first). action: "accept", "drop", "reject", "jump", "return", "continue". family: "ipv4" or "ipv6". hook: "forward", "input" or "output". fields: Map of rule setting to value, space-separated keys for nested nodes. Examples: {"protocol": "tcp", "destination port": "443", "state established": "enable"} {"source address": "192.0.2.0/24", "destination group address-group WEB": ""} {"log": "enable"} description: Optional rule description. save: Persist after commit (default False). |
| vyos_delete_firewall_ruleB | Delete a firewall filter rule. Args: rule: Rule number to delete. family: "ipv4" or "ipv6". hook: "forward", "input" or "output". save: Persist after commit (default False). |
| vyos_set_firewall_default_actionB | Set the default action of a firewall filter hook. Args: action: "accept", "drop" or "reject". family: "ipv4" or "ipv6". hook: "forward", "input" or "output". save: Persist after commit (default False). |
| vyos_configure_firewall_groupA | Create or extend a firewall group (address/network/port/interface/...). Args: group_type: One of address-group, network-group, port-group, interface-group, mac-group, domain-group, ipv6-address-group, ipv6-network-group. name: Group name. members: List of members (addresses, networks, ports or interface names) added to the group. description: Optional group description. save: Persist after commit (default False). |
| vyos_show_natC | Show the NAT configuration tree. Args: direction: Optional "source" or "destination" to narrow the view. |
| vyos_add_source_nat_ruleB | Create a source NAT (SNAT/masquerade) rule in one commit. Args: rule: Rule number. outbound_interface: Egress interface, e.g. "eth0". translation_address: "masquerade" (default) or a specific/pool address. source_address: Optional source match, e.g. "192.168.0.0/24". destination_address: Optional destination match. protocol: Optional protocol match, e.g. "tcp", "udp", "tcp_udp". extra_fields: Additional {space-separated path: value} settings. description: Optional description. save: Persist after commit (default False). |
| vyos_add_destination_nat_ruleA | Create a destination NAT (DNAT / port-forward) rule in one commit. The translation address is always included so the rule validates. If you specify a port, also specify protocol (tcp/udp). Args: rule: Rule number. inbound_interface: Ingress interface, e.g. "eth0". translation_address: Internal host to forward to, e.g. "192.168.1.10". translation_port: Optional internal port. destination_port: Optional matched external port. protocol: Protocol, e.g. "tcp", "udp", "tcp_udp" (required if a port is set). destination_address: Optional external/matched destination address. extra_fields: Additional {space-separated path: value} settings. description: Optional description. save: Persist after commit (default False). |
| vyos_delete_nat_ruleB | Delete a NAT rule. Args: direction: "source" or "destination". rule: Rule number to delete. save: Persist after commit (default False). |
| vyos_show_routesA | Show the operational routing table (FIB). Args: family: "ip" for IPv4 (default) or "ipv6". prefix: Optional destination prefix to look up, e.g. "10.0.0.0/8". |
| vyos_add_static_routeA | Add a static route (IPv4 or IPv6) in one commit. Provide a next_hop, an interface, or both. Args: destination: Destination prefix, e.g. "10.0.0.0/8" or "::/0". next_hop: Gateway address, e.g. "192.0.2.1". interface: Egress interface for an interface route, e.g. "eth1". distance: Optional administrative distance. family: "ipv4" (default) or "ipv6". save: Persist after commit (default False). |
| vyos_delete_static_routeA | Delete a static route. Args: destination: Destination prefix to remove. family: "ipv4" (default) or "ipv6". save: Persist after commit (default False). |
| vyos_configure_bgpB | Configure BGP: local AS, global settings and neighbors in one commit. Args: local_as: Local autonomous system number. settings: Global BGP settings as {space-separated path: value}, e.g. {"parameters router-id": "192.0.2.1", "address-family ipv4-unicast network": "203.0.113.0/24"}. neighbors: Map of neighbor IP -> settings map, e.g. {"192.0.2.2": {"remote-as": "65002", "address-family ipv4-unicast soft-reconfiguration": "inbound"}}. save: Persist after commit (default False). |
| vyos_configure_ospfA | Configure OSPF settings in one commit. Args: settings: {space-separated path: value} under "protocols ospf", e.g. {"parameters router-id": "192.0.2.1", "area 0 network": "192.0.2.0/24", "interface eth1 cost": "10"}. save: Persist after commit (default False). |
| vyos_show_bgp_summaryA | Show the operational BGP summary (neighbors and session states). |
| vyos_show_ospf_neighborA | Show operational OSPF neighbor adjacencies. |
| vyos_list_servicesA | Show the configured |
| vyos_show_dhcp_leasesB | Show active DHCP server leases. |
| vyos_configure_dhcp_serverA | Configure a DHCP server shared-network subnet in one commit. Args: shared_network: Shared-network name, e.g. "LAN". subnet: Subnet CIDR, e.g. "192.168.0.0/24". settings: {space-separated path: value} under the subnet, e.g. {"subnet-id": "1", "option default-router": "192.168.0.1", "option name-server": "192.168.0.1", "range 0 start": "192.168.0.100", "range 0 stop": "192.168.0.200"}. save: Persist after commit (default False). |
| vyos_configure_dns_forwardingB | Configure the DNS forwarding service in one commit. Args: settings: {space-separated path: value} under "service dns forwarding", e.g. {"listen-address": "192.168.0.1", "allow-from": "192.168.0.0/24", "name-server": "1.1.1.1", "cache-size": "10000"}. save: Persist after commit (default False). |
| vyos_configure_sshA | Enable/configure the SSH service in one commit. Args: port: Optional listen port (default VyOS uses 22 when the service exists). settings: Additional {space-separated path: value} under "service ssh", e.g. {"disable-password-authentication": "", "listen-address": "192.168.0.1"}. save: Persist after commit (default False). |
| vyos_configure_ntpB | Configure NTP servers in one commit. Args: servers: List of NTP server hostnames/IPs. settings: Additional {space-separated path: value} under "service ntp". save: Persist after commit (default False). |
| vyos_show_vpn_configA | Show VPN/WireGuard configuration (keys redacted by default). Args: kind: One of "wireguard", "ipsec", "openvpn", "l2tp", "pptp", "sstp". Omit to show all VPN and WireGuard config. include_secrets: Return keys/PSKs unredacted (default False). |
| vyos_show_vpn_statusA | Show live VPN status. Args: kind: "ipsec" (security associations), "wireguard" (peer handshakes), or "openvpn" (sessions). |
| vyos_configure_wireguardA | Configure a WireGuard interface and its peers in one commit. Generate a key-pair first with vyos_generate(path="pki wireguard key-pair"). Args: interface: WireGuard interface name, e.g. "wg0". address: Interface address, e.g. "10.0.0.1/24". private_key: The interface private key. listen_port: UDP listen port. peers: Map of peer name -> settings, e.g. {"to-site-b": {"public-key": "...", "allowed-ips": "10.0.0.2/32", "address": "203.0.113.5", "port": "51820", "persistent-keepalive": "15"}}. "allowed-ips" accepts a single value; pass a list via extra batch calls for multiple. Nested keys may be space-separated. save: Persist after commit (default False). |
| vyos_configure_ipsec_site_to_siteA | Configure an IPsec site-to-site peer in one commit. Args: peer: Peer identifier (name or address), e.g. "203.0.113.5". settings: {space-separated path: value} under "vpn ipsec site-to-site peer ", e.g. {"authentication mode": "pre-shared-secret", "authentication pre-shared-secret": "SECRET", "ike-group": "IKE-1", "connection-type": "initiate", "tunnel 0 local prefix": "192.168.0.0/24", "tunnel 0 remote prefix": "192.168.1.0/24", "tunnel 0 esp-group": "ESP-1"}. save: Persist after commit (default False). |
| vyos_configure_openvpnB | Configure an OpenVPN interface in one commit. Args: interface: OpenVPN interface name, e.g. "vtun0". settings: {space-separated path: value} under "interfaces openvpn ", e.g. {"mode": "site-to-site", "protocol": "udp", "local-address": "10.255.0.1", "remote-address": "10.255.0.2", "shared-secret-key": "KEY"}. save: Persist after commit (default False). |
| vyos_show_system_configA | Show the Args: include_secrets: Return password hashes unredacted (default False). |
| vyos_show_system_infoA | Show operational system information (version, uptime, memory, storage). |
| vyos_show_logA | Show recent system log entries. Args: count: Number of lines to return (1-1000, default 50). path: Optional log subtree, e.g. "firewall" or "image". Omit for the main log. |
| vyos_set_hostnameA | Set the system host name. Args: hostname: New host name. save: Persist after commit (default False). |
| vyos_set_name_serverA | Set system DNS name servers (replacing the configured list). Args: name_servers: List of resolver IP addresses. save: Persist after commit (default False). |
| vyos_set_time_zoneB | Set the system time zone. Args: time_zone: Zone identifier, e.g. "Europe/Prague" or "UTC". save: Persist after commit (default False). |
| vyos_configure_userA | Create or update a login user in one commit. Args: username: Login name. plaintext_password: Optional plaintext password (VyOS hashes it on commit). public_keys: Map of key identifier -> {"type": "ssh-ed25519"|"ssh-rsa"|..., "key": ""}. level: Optional privilege level, e.g. "admin" or "operator". save: Persist after commit (default False). |
| vyos_configure_task_schedulerA | Configure a scheduled task in one commit. VyOS validators require the executable together with either interval OR crontab-spec in the same commit, so this tool bundles them. Args: name: Task name. executable_path: Path to the executable to run. interval: Run interval, e.g. "1h" or "30m" (mutually exclusive with crontab_spec). crontab_spec: Crontab specification (mutually exclusive with interval). arguments: Optional arguments passed to the executable. save: Persist after commit (default False). |
| vyos_raw_api_callA | Call any VyOS API endpoint directly with a raw operation payload. Use this for anything the higher-level tools do not cover. Write endpoints (configure, config-file, reset, reconnect, reboot, poweroff, image, generate) are blocked when VYOS_READONLY=true. Args: endpoint: Endpoint name without the leading slash, e.g. "retrieve", "configure", "show", "generate", "config-file", "reset", "image". data: The operation object (or list of objects for /configure), e.g. {"op": "showConfig", "path": ["firewall"]} or [{"op": "set", "path": ["interfaces","dummy","dum1","address","10.0.0.1/32"]}]. confirm_time: Optional commit-confirm window (minutes) for write endpoints. include_secrets: Return results unredacted (default False). Returns the unwrapped "data" field of the VyOS response envelope. |
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 67 tools
The specific per-resource tools (e.g. vyos_add_firewall_rule, vyos_configure_interface) coexist with generic catch-alls (vyos_set, vyos_delete, vyos_configure_batch, vyos_raw_api_call) that can accomplish the same changes, so an agent must decide which layer to use. Similarly, read tools overlap (vyos_show_config vs vyos_show vs vyos_show_system_config vs vyos_list_interfaces vs vyos_get_interface), though descriptions do clarify most boundaries.
Nearly all tools use a consistent vyos_verb_noun pattern (vyos_get_interface, vyos_add_firewall_rule, vyos_configure_bgp). A few outliers break the pattern slightly (vyos_return_values, vyos_config_exists, vyos_raw_api_call), but overall the naming is predictable and readable.
67 tools is heavy for the surface, and much of the volume comes from per-feature wrappers duplicating what vyos_set/vyos_configure_batch already do. The VyOS domain is genuinely broad, so many tools earn a place, but the redundancy pushes the count beyond what is well-scoped.
Coverage spans interfaces, firewall, NAT, static/BGP/OSPF routing, DHCP/DNS/SSH/NTP services, WireGuard/IPsec/OpenVPN, system settings, images, and operational diagnostics, with vyos_raw_api_call as an escape hatch. Some areas (QoS/traffic policy, VRRP/HA, prefix-lists/route-maps, policy-based routing) lack dedicated tools but can be reached via the generic batch/raw tools.