MikroTik MCP / Docs / Integrations

Integrations

Three first-class ways to talk to the server: an AI desktop client (Claude), an interactive testing harness (MCP Inspector), and a REST shim (MCPO) for anything that doesn't speak MCP natively.

Claude Desktop

Native MCP support. Drop a JSON snippet into the config file, restart, and the tools appear in the conversation.

● readystdio · uvx

MCP Inspector

Browser-based tool catalog and ad-hoc invoker. Best way to learn the API without a model in the loop.

● readynpx · UI

MCPO (REST shim)

Exposes every tool as a REST endpoint with OpenAPI docs. Use for ChatGPT actions, n8n, curl scripts.

● readyHTTP · OpenAPI

Claude Desktop

Claude Desktop reads its MCP server list from claude_desktop_config.json~/Library/Application Support/Claude/ on macOS, and %APPDATA%\Claude\ on Windows. Add the server, restart, and Claude will discover the tools on its next session.

claude_desktop_config.json
{
  "mcpServers": {
    "mikrotik": {
      "command": "uvx",
      "args": [
        "mcp-server-mikrotik",
        "--host",     "<HOST>",
        "--username", "<USERNAME>",
        "--password", "<PASSWORD>",
        "--port",     "22"
      ]
    }
  }
}
SECURITY
The model never sees your password — only the tool catalog and parameter schemas. That said, the password lives in the config file in plain text. Use a dedicated, scoped RouterOS user rather than admin for day-to-day operation.

Verifying the connection

After restarting Claude Desktop, look for the connector indicator in the prompt box. A first easy test:

MCP Inspector

The Inspector is the official debugging tool for MCP servers. It launches a server, connects to it, and gives you a browser UI to browse the tool catalog and invoke them by hand. No LLM involved — pure introspection.

Quick one-liner

# Inspector + server in one shot
$ npx @modelcontextprotocol/inspector \
    uvx mcp-server-mikrotik \
    --host <HOST> \
    --username <USERNAME> \
    --password <PASSWORD> \
    --port 22

Against an mcp-config.json

If you've already prepared a config file (recommended for MCPO too), install the inspector globally and point it at the file:

# Persistent config
$ npm install -g @modelcontextprotocol/inspector
$ cp mcp-config.json.example mcp-config.json
$ nano mcp-config.json   # edit credentials
$ mcp-inspector --config mcp-config.json --server mikrotik-mcp-server

Open the URL it prints. The left pane lists every tool; clicking one opens a form for its arguments and a "Call" button. The response JSON appears beneath. Excellent for learning the schema before you wire a real client.

MCPO — REST API

MCPO ("MCP-to-OpenAPI") wraps any MCP server in a FastAPI shell. Each tool becomes a POST endpoint, and you get auto-generated OpenAPI docs at /docs. Use this for:

PREREQ
Python 3.8+, a MikroTik MCP server already set up, and the uv package manager (recommended) or pip.

Install

# pick one
# Option 1 — uvx (recommended, no install)
$ uvx mcpo --help

# Option 2 — pip
$ pip install mcpo

Config file

Create mcp-config.json in your project directory. Adjust the connection parameters (host, username, password, port) to match your setup:

mcp-config.json
{
  "mcpServers": {
    "mikrotik-mcp-server": {
      "command": "python",
      "args": [
        "src/mcp_mikrotik/server.py",
        "--password", "admin",
        "--host",     "192.168.1.1",
        "--port",     "22",
        "--username", "admin"
      ],
      "env": {}
    }
  }
}

Run the server

# With API-key auth (recommended)
# With API key authentication
$ uvx mcpo --port 8000 \
    --api-key "your-secret-key" \
    --config ./mcp-config.json

# Or without auth (not recommended for production)
$ uvx mcpo --port 8000 --config ./mcp-config.json

You'll see two URLs in the startup log:

SERVE http://0.0.0.0:8000
DOCS http://localhost:8000/docs

Calling a tool

Each tool is exposed at /<server-name>/<tool-name>. POST a JSON body containing the tool's arguments.

# curl — list IP addresses
$ curl -X POST http://localhost:8000/mikrotik-mcp-server/mikrotik_list_ip_addresses \
    -H "Authorization: Bearer your-secret-key" \
    -H "Content-Type: application/json" \
    -d '{}'
POST /mikrotik-mcp-server/mikrotik_list_ip_addresses
POST /mikrotik-mcp-server/mikrotik_create_filter_rule
POST /mikrotik-mcp-server/mikrotik_create_vlan_interface
TIP
The Swagger UI at /docs auto-generates a "Try it out" form for every tool — much faster than handcrafting curl commands when you're exploring.