GO

gaspareduard/omada-mcp

开发工具

本页由 AI 翻译,技术细节请以原文为准。 查看原文

30 stars 13 forks 质量 83 趋势 14MIT

TP-Link Omada 以安全为先的 MCP 服务器,具备以标准为先的运行时、能力门控工具和基于 OpenAPI 的网络自动化。

概览

以安全为核心的 TP-Link Omada 开放 API 工作流程 MCP 服务器。 - 生产安全的基线使用标准 - Omada凭证仅限环境 - 能力配置文件和类别门控控制暴露的工具 - HTTP仅作为显式不安全的实验室路径保留在代码库中 - 与实时的Omada Controller 6.x环境进行验证,并围绕文档中的5.x/6.x开放API表层设计 如果你还没有发布图片,建议在本地构建: 2. 编辑你的Claude桌面MCP配置:- macOS: ~/Library/Application Support/Claude/claude_desktop_config.json - Windows: %APPDATA%\Claude\claude_desktop_config.json 4. 重启Claude Desktop,并通过列出网站或设备验证服务器。 服务器从环境变量读取配置。完整参考见 .env.example。

概述(AI 翻译)

以安全为核心的 TP-Link Omada 开放 API 工作流程 MCP 服务器。

一览

  • 生产安全基线使用 stdio
  • Omada的资质仅限环境
  • 能力配置文件和类别门槛控制暴露的工具
  • HTTP 仅作为显式不安全的实验室路径保留在代码库中
  • 基于实时的 Omada 控制器 6.x 环境进行验证,并围绕文档中的 5.x/6.x 开放 API 表面设计

快速启动

选项1:通过Docker与Claude Desktop一起使用

  1. 拉取或构建图像:

如果你还没有发布图片,建议在本地构建:

  1. 编辑你的Claude桌面MCP配置:
  • macOS:~/Library/Application Support/Claude/claude_desktop_config.json
  • 窗口:%APPDATA%\Claude\claude_desktop_config.json
  1. 添加服务器条目:

  2. 重启Claude Desktop,并通过列出网站或设备验证服务器。

选项2:直接运行容器

选项3:本地运行开发

配置

服务器读取环境变量中的配置。完整参考见 .env.example。

必需的 Omada 变量

变量 必需 默认 描述

本页由 AI 翻译,技术细节请以原文为准。

README

以下为原文 README 节选,完整内容请查看原文。

Safe Omada MCP

Security-focused MCP server for TP-Link Omada Open API workflows.

At a Glance

  • Production-safe baseline uses stdio
  • Omada credentials are environment-only
  • Capability profiles and category gating control what tools are exposed
  • HTTP remains in the codebase only as an explicitly unsafe, lab-only path
  • Uses documented Open API routes; controller/device validation is operation-specific (see support matrix)

0.19 release candidate

This branch prepares 0.19.0-rc.2 with 68 additional preview-first networking tools and a bundled server icon for compatible MCP clients. Write previews, compact discovery, diagnostics and reliability changes are described in the migration guide. Stable write-tool release awaits disposable-controller and hardware validation; latest remains the existing stable version.

Quick Start

Option 1: Use with Claude Desktop via Docker

  1. Pull or build an image:

    docker pull ghcr.io/gaspareduard/omada-mcp:latest
    

    If you do not publish an image yet, build locally instead:

    npm run docker:build
    
  2. Edit your Claude Desktop MCP config:

    • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
    • Windows: %APPDATA%\Claude\claude_desktop_config.json
  3. Add the server entry:

    {
      "mcpServers": {
        "safe-omada": {
          "command": "docker",
          "args": [
            "run",
            "-i",
            "--rm",
            "-e", "OMADA_BASE_URL=https://your-omada-controller.local",
            "-e", "OMADA_CLIENT_ID=your-client-id",
            "-e", "OMADA_CLIENT_SECRET=your-client-secret",
            "-e", "OMADA_OMADAC_ID=your-omadac-id",
            "-e", "OMADA_SITE_ID=your-site-id",
            "-e", "OMADA_STRICT_SSL=true",
            "ghcr.io/gaspareduard/omada-mcp:latest"
          ]
        }
      }
    }
    
  4. Restart Claude Desktop and verify the server by listing sites or devices.

Option 2: Run the container directly

docker run --rm -it \
  --env-file .env \
  ghcr.io/gaspareduard/omada-mcp:latest

Option 3: Run locally for development

npm install
npm run build
npm start

Configuration

The server reads configuration from environment variables. See .env.example for the complete reference.

Required Omada Variables

Variable Required Default Description
在 GitHub 查看完整 README

安装

docker run -i --rm -e OMADA_BASE_URL=https://your-omada-controller.local -e OMADA_CLIENT_ID=your-client-id -e OMADA_CLIENT_SECRET=your-client-secret -e OMADA_OMADAC_ID=your-omadac-id -e OMADA_SITE_ID=your-site-id -e OMADA_STRICT_SSL=true ghcr.io/gaspareduard/omada-mcp:latest
新手?先看 mcpskill.org 教程 →

配置

{ "mcpServers": { "safe-omada": { "command": "docker", "args": [ "run", "-i", "--rm", "-e", "OMADA_BASE_URL=https://your-omada-controller.local", "-e", "OMADA_CLIENT_ID=your-client-id", "-e", "OMADA_CLIENT_SECRET=your-client-secret", "-e", "OMADA_OMADAC_ID=your-omadac-id", "-e", "OMADA_SITE_ID=your-site-id", "-e", "OMADA_STRICT_SSL=true", "ghcr.io/gaspareduard/omada-mcp:latest" ] } } }