Skip to main content

mcp-server-vyos

CI codecov PyPI Python License: MIT

MCP server for VyOS router management via the HTTPS REST API. Provides both router management tools and live VyOS documentation lookup.

Installation

pip install mcp-server-vyos

Configuration

Set environment variables:

  • VYOS_URL — Router API endpoint (e.g., https://vyos.example.com)
  • VYOS_API_KEY — API key for authentication
  • VYOS_READ_ONLY — Set to true to disable all mutating tools (config changes, reboot, poweroff, etc.)

VyOS Router Setup

Enable the HTTPS API on your VyOS router:

configure
set service https api keys id my-mcp-key key <your-api-key>
set service https api rest
commit
save

Claude Code

Add to your MCP client configuration:

{
  "mcpServers": {
    "vyos": {
      "command": "mcp-server-vyos",
      "env": {
        "VYOS_URL": "https://vyos.example.com",
        "VYOS_API_KEY": "your-api-key"
      }
    }
  }
}

Read-Only Mode

For safe, query-only access (monitoring, investigation, documentation lookup), enable read-only mode:

{
  "mcpServers": {
    "vyos": {
      "command": "mcp-server-vyos",
      "env": {
        "VYOS_URL": "https://vyos.example.com",
        "VYOS_API_KEY": "your-api-key",
        "VYOS_READ_ONLY": "true"
      }
    }
  }
}

This registers only non-mutating tools: vyos_info, vyos_retrieve, vyos_return_values, vyos_exists, vyos_config_diff, vyos_config_history, vyos_show, vyos_traceroute, vyos_interface_stats, vyos_system_resources, vyos_route_table, vyos_firewall_stats, vyos_bgp_summary, vyos_docs_search, and vyos_docs_read.

Tools

Router Management

Tool Description
vyos_info System info (no auth required)
vyos_retrieve Read configuration at a path
vyos_return_values Get multi-valued config node values
vyos_exists Check if a config path exists
vyos_config_diff Show config differences (saved vs running, or by revision)
vyos_config_history List config revision history (number, timestamp, user, method)
vyos_show Run operational show commands
vyos_validate Validate config syntax (temporary apply with auto-rollback)
vyos_configure Apply config with commit-confirm (safe default)
vyos_confirm Confirm a pending commit-confirm
vyos_save Save running config to disk
vyos_load Load a configuration file
vyos_merge Merge config file or string into running config
vyos_generate Generate keys, certificates, etc.
vyos_reset Reset operations
vyos_reboot Reboot the router
vyos_poweroff Power off the router
vyos_image_add Add a system image from URL
vyos_image_delete Delete a system image

Diagnostics

Tool Description
vyos_traceroute Traceroute to a host (structured mtr report)
vyos_interface_stats Interface RX/TX counters, errors, and link state
vyos_system_resources CPU, memory, storage, and uptime snapshot
vyos_route_table Routing table (RIB) by family/protocol (show ip route)
vyos_firewall_stats Firewall and NAT rule hit counters
vyos_bgp_summary BGP neighbor summary (state, prefixes received)

Documentation

Tool Description
vyos_docs_search Search VyOS docs by topic and page content (returns snippets)
vyos_docs_read Read a specific documentation page

Documentation is fetched live from the vyos-documentation repository, so it stays in sync with the latest VyOS releases. Results are cached for 1 hour.

Safety

  • Configuration changes use commit-confirm by default -- changes auto-revert after 5 minutes unless confirmed with vyos_confirm
  • vyos_configure accepts a list of operations applied atomically in one commit-confirm -- batch related changes into a single call so they commit or roll back together
  • Destructive operations (vyos_reboot, vyos_poweroff, vyos_image_delete) include warning descriptions
  • API keys are never logged or included in tool outputs
  • Self-signed TLS certificates are accepted by default (common on VyOS)

Development

uv sync --extra dev
uv run pytest
uv run ruff check .

Dependencies are pinned in the committed uv.lock. Add --locked to uv sync to fail rather than re-resolve when the lock is out of date with pyproject.toml, which is how CI installs.

License

MIT

Metadata

Release files for mcp-server-vyos 0.4.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for mcp-server-vyos 0.4.1
File Size Uploaded Provenance
mcp_server_vyos-0.4.1.tar.gz 93.6 kB With provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for mcp-server-vyos 0.4.1
File Interpreter ABI Platform
mcp_server_vyos-0.4.1-py3-none-any.whl Python 3 none any Details

Total release size: 109.3 kB

Release files / mcp_server_vyos-0.4.1.tar.gz

Download URL mcp_server_vyos-0.4.1.tar.gz
Size 93.6 kB
Tags Source
SHA-256 checksum
How to use checksums
d4e1fea1bd14faf2ea4ff60b10a9138c1d342299f96ca552d0975a65f89b5e31
BLAKE2b-256 checksum
How to use checksums
6e391575a016d2dc20adfd126a2021dc6c5fe6d1fa2da4c757d18751f3c689b5
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 8, 2026.

Transparency log

Release files / mcp_server_vyos-0.4.1-py3-none-any.whl

Download URL mcp_server_vyos-0.4.1-py3-none-any.whl
Size 15.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
335063b18c15e3313c13566f1974d5300df6a78452ee73e7ea841d91be3083e0
BLAKE2b-256 checksum
How to use checksums
102700bafa4bb06f91a9805b53b14dc2c11a090398bd410b61f0ec931fea6101
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 8, 2026.

Transparency log

Security for mcp-server-vyos 0.4.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

All 2 files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for mcp_server_vyos-0.4.1.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 8, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page