network-mcp
MCP server for managing a home network via a UniFi Dream Machine, enabling device lookup, tagging, and blocking/unblocking of clients through natural language.
README
network-mcp
Standalone HTTP MCP server for home network management through a UniFi Dream Machine.
The current controller implementation uses the local UniFi Network UI/controller API because it supports the direct client blocklist behavior needed for plain-text device management. The rest of the application depends on a small NetworkController interface so this can be replaced or supplemented by the official UniFi Network API later.
Setup
bun install
cp .env.example .env
bun run start
The service listens on 127.0.0.1:4123 by default.
Docker
For the hosted/home setup, run it with Docker Compose:
cp .env.example .env
docker compose up -d --build
The compose file binds the service to 0.0.0.0 inside the container, publishes it only on host loopback at 127.0.0.1:4123, and persists LowDB data in ./data.
Rebuild/restart after code changes:
docker compose up -d --build
View logs:
docker compose logs -f network-mcp
Logs are emitted as JSON to stdout with Winston. Set LOG_LEVEL=debug to include UniFi request timing and MCP request diagnostics.
Endpoints
GET /healthPOST /mcpGET /mcpDELETE /mcp
If MCP_AUTH_TOKEN is set, /mcp requires:
Authorization: Bearer <token>
OpenCode Config
Add a remote MCP server to /home/zac/.config/opencode/opencode.json:
{
"mcp": {
"home-network": {
"type": "remote",
"url": "http://127.0.0.1:4123/mcp",
"enabled": true,
"headers": {
"Authorization": "Bearer {env:HOME_NETWORK_MCP_TOKEN}"
}
}
}
}
Restart the hosted OpenCode service after changing MCP config.
Tools
list_clientsfind_deviceadd_tagremove_taglist_tagsadd_displaynameblock_deviceunblock_deviceblock_by_tagunblock_by_tagshow_blockedunblock_allrecent_actions
MAC addresses are the canonical device key. Tags and display names are stored locally in LowDB under DB_PATH.
Recommended Servers
playwright-mcp
A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.
Magic Component Platform (MCP)
An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.
Audiense Insights MCP Server
Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.
VeyraX MCP
Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.
graphlit-mcp-server
The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.
Kagi MCP Server
An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.
E2B
Using MCP to run code via e2b.
Neon Database
MCP server for interacting with Neon Management API and databases
Exa Search
A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.
Qdrant Server
This repository is an example of how to create a MCP server for Qdrant, a vector search engine.