UniFi Network MCP Server
Exposes the UniFi Network Integration API as MCP tools, dynamically loaded from JSON manifests, with read-only mode by default.
README
UniFi Network MCP Server
This project exposes the UniFi Network Integration API as Model Context Protocol
tools. Runtime tools are loaded from JSON manifests in skills/network, so adding
or updating endpoints does not require hardcoding every command in Python.
By default the server is read-only: only GET endpoints are exposed, and a second
executor guard rejects write methods while READ_ONLY=true.
Quick Start
Generate or refresh runtime skills from the bundled docs:
python3 scripts/import_unifi_docs.py --source docs/network --output skills/network
Run locally:
python3 -m venv .venv
. .venv/bin/activate
pip install -e '.[dev]'
UNIFI_BASE_URL='https://172.16.1.1/proxy/network/integration' \
UNIFI_API_KEY='<api-key>' \
python -m unifi_mcp
The default Streamable HTTP endpoint is:
http://127.0.0.1:8000/mcp
For stdio MCP clients:
MCP_TRANSPORT=stdio UNIFI_BASE_URL='https://172.16.1.1/proxy/network/integration' \
UNIFI_API_KEY='<api-key>' python -m unifi_mcp
Configuration
Required:
UNIFI_BASE_URL: UniFi Network Integration API base URL, normallyhttps://<console>/proxy/network/integration. If the value already ends in/v1, the server avoids adding a second/v1.UNIFI_API_KEY: UniFi API key. Do not commit this value.
Security and runtime:
READ_ONLY=true: default. Exposes onlyGETtools and blocks write execution.READ_ONLY=false: exposes POST, PUT, PATCH, and DELETE tools.ALLOW_CONNECTOR_PROXY=false: default. Connector wildcard proxy endpoints are disabled because they are less constrained than curated endpoint manifests.UNIFI_VERIFY_TLS=true: default TLS verification.UNIFI_CA_CERT=/path/to/ca.pem: trust a self-signed UniFi certificate.UNIFI_INSECURE_SKIP_VERIFY=false: dev-only equivalent ofcurl -k.MCP_TRANSPORT=streamable-http: also supportsstdioandsse.MCP_HOST=127.0.0.1,MCP_PORT=8000.MCP_PATH=/mcp: Streamable HTTP endpoint path. The bundled devdocker-compose.ymlsets this to/so browser clients can usehttp://127.0.0.1:8000directly.MCP_AUTH_TOKEN: optional Bearer token for Streamable HTTP.MCP_CORS_ALLOW_ORIGINS: comma-separated allowed browser origins for Streamable HTTP, for examplehttp://localhost:8080,http://127.0.0.1:8080. The bundled devdocker-compose.ymluses*for browser clients such as llama.cpp.MCP_COMPACT_TOOLS=true: default. Advertises compact tool descriptions and schemas to reduce MCP context size while keeping full skill manifests on disk.MCP_TOOL_MODE=dispatcher: default. Exposes a small dispatcher tool surface: list skills, then call one by name. Setindividualto advertise every endpoint as its own MCP tool.MCP_ALLOW_UNAUTHENTICATED_REMOTE=false: required to bind HTTP to a non-local host withoutMCP_AUTH_TOKEN.
Docker Compose
./build.sh
docker-compose.yml includes the test UniFi controller IP/API key from
PLAN.md, keeps READ_ONLY=true, and accepts the self-signed UniFi certificate
by default for local development.
The compose file binds the MCP endpoint to localhost:
http://127.0.0.1:8000
Inside the container the server binds to 0.0.0.0 so Docker can publish the
port, but compose publishes it only to the host loopback address.
Tool Inputs
Each MCP tool uses this shape:
{
"pathParams": { "siteId": "..." },
"queryParams": { "limit": 25, "offset": 0 },
"body": {}
}
body is only accepted for write operations. Tool schemas are generated from the
source docs and preserve path parameters, query parameters, request body fields,
response fields, descriptions, required flags, types, and discriminators.
Development
python3 -m venv .venv
. .venv/bin/activate
pip install -e '.[dev]'
pytest
ruff check .
The importer intentionally ignores guide files without endpoint methods, including
_index.json, gettingstarted.json, filtering.json, error-handling.json, and
quick_start.ansible.json.
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.