keenetic-mcp — Claude Code MCP server: what it does, how to install
An MCP server that lets your agent read Keenetic router state and change settings: devices, Wi-Fi, segments, routing.
claude mcp add --env KEENETIC_HOST=<KEENETIC_HOST> --env KEENETIC_USER=<KEENETIC_USER> --env KEENETIC_PASSWORD=<KEENETIC_PASSWORD> --transport stdio keenetic-mcp -- npx -y keenetic-mcpWhat keenetic-mcp does
The server sits between the agent and the router's own HTTP API on the LAN, so nothing gets installed on the Keenetic. Read tools return devices with traffic and signal figures, interfaces and WireGuard peers, radio status, internet reachability, the routing table and connection policies. Write tools rename or block a device, bring an interface up or down, and create a segment with its own Wi-Fi and DHCP. Anything outside that surface goes through rci_call, which takes a raw API path.
Writes land in the running configuration only. A reboot throws them away unless save_config is called, and the server will not call it by itself. The first change of a session triggers a backup. Every write is read back and compared, since the router sometimes accepts a bad command and quietly does nothing. Launch it with --read-only and the write tools are never registered at all.
npx -y keenetic-mcp init runs a wizard that finds the router through the default gateway, tests the password against it and stores it in the OS keychain. For containers, set KEENETIC_HOST, KEENETIC_USER and KEENETIC_PASSWORD instead. Four skills come along: the RCI tree, safe changes, segment building and a diagnostic order.
What it helps with
- find which device is hogging the uplink right now
- block a camera overnight without making it permanent
- stand up an isolated guest network with DHCP
- see which config edits are still waiting for a save
- follow an ordered check when the internet drops
Example prompts for the agent
- Which device is using the most bandwidth right now? Sort by traffic and show signal.
- Block
hallway-cameraand tell me if the change is saved or reverts on reboot. - Create a segment
guestwith Wi-Fi and DHCP, no VPN routing.
How to install keenetic-mcp
Platform CLI
claude mcp add --env KEENETIC_HOST=<KEENETIC_HOST> --env KEENETIC_USER=<KEENETIC_USER> --env KEENETIC_PASSWORD=<KEENETIC_PASSWORD> --transport stdio keenetic-mcp -- npx -y keenetic-mcpReplace <…> with your own values
Platform CLI
codex mcp add keenetic-mcp --env KEENETIC_HOST=<KEENETIC_HOST> --env KEENETIC_USER=<KEENETIC_USER> --env KEENETIC_PASSWORD=<KEENETIC_PASSWORD> -- npx -y keenetic-mcpReplace <…> with your own values
Config file
{
"mcpServers": {
"keenetic-mcp": {
"command": "npx",
"args": [
"-y",
"keenetic-mcp"
],
"env": {
"KEENETIC_HOST": "<KEENETIC_HOST>",
"KEENETIC_USER": "<KEENETIC_USER>",
"KEENETIC_PASSWORD": "<KEENETIC_PASSWORD>"
}
}
}
}Replace <…> with your own values
Config file
{
"servers": {
"keenetic-mcp": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"keenetic-mcp"
],
"env": {
"KEENETIC_HOST": "<KEENETIC_HOST>",
"KEENETIC_USER": "<KEENETIC_USER>",
"KEENETIC_PASSWORD": "<KEENETIC_PASSWORD>"
}
}
}
}Replace <…> with your own values
Platform CLI
gemini mcp add -e KEENETIC_HOST=<KEENETIC_HOST> -e KEENETIC_USER=<KEENETIC_USER> -e KEENETIC_PASSWORD=<KEENETIC_PASSWORD> keenetic-mcp npx -y keenetic-mcpReplace <…> with your own values
Step by step, with commands for each platform: How to add an MCP server to Claude Code, Codex, Cursor, VS Code, Gemini CLI and more
Questions about keenetic-mcp
How do I install keenetic-mcp in Claude Code?
With a single command: `claude mcp add --env KEENETIC_HOST=<KEENETIC_HOST> --env KEENETIC_USER=<KEENETIC_USER> --env KEENETIC_PASSWORD=<KEENETIC_PASSWORD> --transport stdio keenetic-mcp -- npx -y keenetic-mcp`. Replace the placeholders with your router address, login and password.
What does keenetic-mcp do?
It hands the agent read and write tools for a Keenetic router: device lists with traffic, interfaces, Wi-Fi, segments and routing policies. Changes go into the running configuration and get verified by reading them back.
Do I need to install anything on the router?
No. The server talks to the Keenetic HTTP API over your LAN, with no firmware change and no Entware. The password stays in the system keychain and requests go only to the router.