defined-mcp

defined-mcp

MCP server for managing Defined Networking infrastructure through API tools. It enables network administration including host management, firewall rules, tags, and network configuration with Claude Code integration for interactive network design and auditing.

Category
访问服务器

README

defined-mcp

MCP server for the Defined Networking API.

Installation

uv tool install git+https://github.com/quickvm/defined-mcp.git

To install a specific version or branch:

uv tool install git+https://github.com/quickvm/defined-mcp.git@main

For local development:

git clone git@github.com:quickvm/defined-mcp.git
cd defined-mcp
uv tool install --editable .

Configuration

Set the DEFINED_API_KEY environment variable to your Defined Networking API key. Get one from your admin panel.

export DEFINED_API_KEY=dnkey-...

Usage

Add to Claude Code

claude mcp add defined_mcp -- defined-mcp serve

Then restart Claude Code.

Verify connectivity

defined-mcp check

Run standalone

defined-mcp serve

Available Tools

Hosts

  • list_hosts — List hosts with filters (role, blocked, lighthouse, relay)
  • get_host — Get host details
  • create_host — Create a host/lighthouse/relay
  • update_host — Update a host (full replacement)
  • delete_host — Delete a host
  • block_host / unblock_host — Block/unblock a host
  • add_host_tag / remove_host_tag — Add/remove a tag on a host
  • create_enrollment_code — Generate enrollment code
  • create_host_and_enrollment_code — Create host + enrollment code

Roles & Firewall Rules

  • list_roles / get_role — List/get roles with firewall rules
  • create_role / update_role — Create/update roles (full replacement)
  • delete_role — Delete a role
  • add_firewall_rule — Add a firewall rule to a role (flat params, no JSON)
  • remove_firewall_rule — Remove a firewall rule by index

Tags

  • list_tags / get_tag — List/get tags
  • create_tag / update_tag — Create/update tags with config overrides
  • delete_tag — Delete a tag
  • add_tag_config_override — Add/replace a config override on a tag
  • remove_tag_config_override — Remove a config override by key

Networks

  • list_networks / get_network — List/get networks
  • create_network / update_network — Create/update networks

Routes

  • list_routes / get_route — List/get routes with firewall rules
  • create_route / update_route — Create/update routes (full replacement)
  • delete_route — Delete a route
  • add_route_firewall_rule — Add a firewall rule to a route
  • remove_route_firewall_rule — Remove a route firewall rule by index

Other

  • list_audit_logs — Audit log with filters
  • list_downloads — Software download links (unauthenticated)

Claude Code Skills

This repo includes a Claude Code skill for interactive network management. When you run Claude Code from this repo, the /network-architect command is available automatically.

To use the skill from any project, copy it to your Claude Code profile:

cp -r .claude/skills/network-architect ~/.claude/skills/

/network-architect audit

Performs a security and configuration audit of your Defined Networking account. Fetches all networks, roles, tags, and hosts, then reports:

  • Roles with missing or overly permissive firewall rules
  • Dead tags (zero hosts assigned)
  • Hosts with no tags, outdated dnclient versions, or stale last-seen times
  • Firewall coverage summary per role with port/protocol/tag details

/network-architect design

Interactive firewall policy design session. Asks about your services, access requirements, and segmentation needs, then proposes:

  • Role structure (what each host type IS)
  • Tag taxonomy (access tags like ssh:allow, identity tags like user-type:admin)
  • Firewall rules per role in table format with AND logic (role + tags)

/network-architect apply

Implements a network design using atomic tools (add_firewall_rule, add_host_tag, etc.). Reads current state first, shows a diff, asks for confirmation, then verifies after applying.

License

MIT

推荐服务器

Baidu Map

Baidu Map

百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。

官方
精选
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。

官方
精选
本地
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。

官方
精选
本地
TypeScript
VeyraX

VeyraX

一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。

官方
精选
本地
graphlit-mcp-server

graphlit-mcp-server

模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。

官方
精选
TypeScript
Kagi MCP Server

Kagi MCP Server

一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。

官方
精选
Python
e2b-mcp-server

e2b-mcp-server

使用 MCP 通过 e2b 运行代码。

官方
精选
Neon MCP Server

Neon MCP Server

用于与 Neon 管理 API 和数据库交互的 MCP 服务器

官方
精选
Exa MCP Server

Exa MCP Server

模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。

官方
精选