This feature introduces a native Model Context Protocol (MCP) server to the VyOS HTTP API, establishing a standardized interface for autonomous AI agents and Large Language Models (LLMs) to interact safely with the routing environment. Deployed as an additional service running alongside the existing REST and GraphQL APIs, the MCP server - when enabled - utilizes a Server-Sent Events (SSE) transport mechanism and inherits the robust API key and JWT authentication frameworks already natively present in VyOS.
To ensure a zero-maintenance lifecycle, MCP integration abandons statically defined toolsets. Instead, it dynamically harvests VyOS' capabilities on-the-fly by introspecting the internal vyos.xml_ref cache and abstract syntax tree. As new features or protocols are added in future VyOS updates, they are instantly exposed through MCP without requiring manual code changes.
Key Capabilities:
- Dynamic Context via Resources: Exposes the active VyOS configuration tree and schema definitions through dynamic URIs (e.g., vyos-config://running/{path}), allowing AI clients to extract localized, read-only slices of the routing state rather than consuming massive configuration files.
- Operational & Configuration Meta-Tools: Mirrors the VyOS CLI bifurcation by offering dedicated tools for operational commands (diagnostics, monitoring) and configuration modifications.
- Atomic Configuration Integrity: Configuration tools strictly leverage the internal ConfigSession API, ensuring that AI-generated modifications undergo the exact same validation, commit, and rollback safety checks as human-driven inputs.
- Strict Access Controls: Introduces a read-only enforcement mode within the service https api mcp configuration tree, structurally preventing AI agents from executing destructive commands or altering the network state without human-in-the-loop approval.