enable-nz-mcp
Enables full-text search and retrieval of public content from enable.co.nz via MCP tools.
README
enable-nz-mcp
A public, hosted MCP server that exposes the content of enable.co.nz as searchable tools, connectable from Copilot Studio, VS Code Copilot, Claude Desktop, or any MCP client.
This is a personal portfolio project. It is not affiliated with Enable New Zealand or any employer, and reads only publicly available content from a public website.
- Server:
https://enable-nz-mcp.duckdns.org/mcp(Streamable HTTP) - Health check:
https://enable-nz-mcp.duckdns.org/health
Architecture
GitHub Actions (weekly cron)
└─ crawl enable.co.nz → build index.db.new
└─ rsync over SSH → droplet:/opt/enable-nz-mcp/data/index.db.new
└─ atomic mv → index.db
DigitalOcean droplet (Ubuntu 24.04, Sydney)
├─ Caddy → TLS termination + reverse proxy on enable-nz-mcp.duckdns.org
└─ pm2 → node dist/server.js (port 8081, localhost only)
└─ opens a fresh SQLite read connection per query
The server never caches the index in memory — every tool call opens a fresh readonly
connection against index.db on disk. A weekly crawl rebuilds the index and swaps it in
with a single atomic mv, so the index refreshes with zero downtime and no restart.
Read-only in every direction: the crawler only reads enable.co.nz, and the MCP tools only read the local SQLite index. No write operations of any kind.
Tools
search_enable_nz
Full-text search across enable.co.nz.
| Param | Type | Required | Notes |
|---|---|---|---|
query |
string | yes | Search terms |
limit |
integer | no | Default 5, max 20 |
section |
string | no | Restrict to one section, e.g. services |
Returns matching pages ranked by relevance, each with url, title, section, and a
highlighted snippet.
get_page
Retrieve one page's full text by URL.
| Param | Type | Required |
|---|---|---|
url |
string | yes |
Returns url, title, section, description, content, and crawled_at. Content over
~15,000 characters is truncated, with truncated: true in the response.
list_sections
No input. Lists the site's top-level sections with page counts, and the index's
crawled_at timestamp — useful for orienting before a search, or checking how fresh the
data is.
Example queries
Once connected, ask your MCP client things like:
- "Search enable.co.nz for wheelchair funding information."
- "What sections does the enable.co.nz index cover?"
- "Get the full content of https://www.enable.co.nz/services and summarise it."
Connecting an MCP client
Copilot Studio
- Open your agent → Tools → Add a tool → New tool → Model Context Protocol.
- Server name:
enable-nz-mcp(or anything you like — this is just a label). - Server URL:
https://enable-nz-mcp.duckdns.org/mcp - Authentication: No authentication (leave as-is unless the server has
API_KEYset, in which case choose an API key/bearer auth option and supply it). - Create → Copilot Studio connects over Streamable HTTP (the only transport it supports
since it dropped SSE in August 2025) and lists
search_enable_nz,get_page, andlist_sections. Add the tool to your agent and test with a prompt like "search enable.co.nz for wheelchair funding".
VS Code Copilot
- Open the Command Palette → MCP: Add Server.
- Choose HTTP and enter
https://enable-nz-mcp.duckdns.org/mcp. - VS Code will list
search_enable_nz,get_page, andlist_sectionsas available tools once connected.
Claude Desktop
- Settings → Connectors → Add custom connector.
- URL:
https://enable-nz-mcp.duckdns.org/mcp. - Claude will negotiate the Streamable HTTP transport automatically.
Any other MCP client
Point it at https://enable-nz-mcp.duckdns.org/mcp using the Streamable HTTP transport. If
API_KEY is set on the server, send Authorization: Bearer <key>.
Local development
npm ci
cp .env.example .env # edit as needed
npm run crawl # builds data/index.db.new
mv data/index.db.new data/index.db
npm run dev # starts the server with tsx, reading .env
Test the running server with MCP Inspector:
npx @modelcontextprotocol/inspector
# connect to http://127.0.0.1:8081/mcp
Or smoke-test by hand:
curl http://127.0.0.1:8081/health
curl -X POST http://127.0.0.1:8081/mcp \
-H "Content-Type: application/json" \
-H "Accept: application/json, text/event-stream" \
-d '{"jsonrpc":"2.0","id":1,"method":"tools/list"}'
Run the test suite:
npm test
Deployment
The server runs on an existing DigitalOcean droplet under its own unprivileged system user
(mcpsvc), isolated from other services on the same box — mcpsvc has no sudo and no read
access outside /opt/enable-nz-mcp. See deploy/ecosystem.config.cjs for the pm2 process
config and deploy/Caddyfile.example for the reverse-proxy block.
Both pm2 and Caddy config changes need root, so mcpsvc can go no further than pm2 save
on its own — an administrator has to run pm2 startup (to persist the process across
reboots) and install/reload the Caddy site block. Rate limiting is not currently applied at
the Caddy layer: it requires the third-party caddy-ratelimit plugin, which isn't in this
box's Caddy build.
The .github/workflows/refresh-index.yml workflow re-crawls the site weekly (Sunday 02:00
UTC, or manually via workflow_dispatch), gates on a minimum page count/size, and deploys
the new index via rsync + an atomic mv over SSH. It needs three repository secrets:
DEPLOY_SSH_KEY, DEPLOY_HOST, DEPLOY_USER — using a dedicated deploy keypair restricted
via a command= directive in authorized_keys so it can only run the rsync/mv, not an
arbitrary shell.
Out of scope for v1
- Embeddings / semantic search (keyword search via SQLite FTS5 is sufficient for one marketing site)
- Headless-browser rendering
- Multi-site support
- Write operations of any kind
- User-level auth or per-tenant isolation
推荐服务器
Baidu Map
百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。
Playwright MCP Server
一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。
Magic Component Platform (MCP)
一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。
Audiense Insights MCP Server
通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。
VeyraX
一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。
graphlit-mcp-server
模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。
Kagi MCP Server
一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。
e2b-mcp-server
使用 MCP 通过 e2b 运行代码。
Neon MCP Server
用于与 Neon 管理 API 和数据库交互的 MCP 服务器
Exa MCP Server
模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。