npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@archawat/mcp-cloudflare

v1.0.1

Published

MCP server for managing Cloudflare DNS records across multiple domains from one API token

Readme

@archawat/mcp-cloudflare

Model Context Protocol (MCP) server for managing Cloudflare DNS across multiple zones (domains) from a single API token. Built for bulk workflows — flipping proxy on/off across many records, auditing DNS across zones, and batched record updates.

Features

  • Multi-zone from one token — pass a domain name like "example.com" and the server resolves the zone for you. Zone IDs also accepted.
  • Bulk operationsbulk_toggle_proxy, bulk_update_dns_record, and bulk_list_dns_records run concurrently and share a per-invocation zone-ID cache so repeated zones don't cost extra lookups.
  • Safe defaults — new A/CNAME records are created with proxied: false (DNS-only, grey cloud). Proxy is opt-in.
  • Auto-paginationlist_dns_records fetches every page in parallel unless you ask for a specific one.

Install

No local install required — use npx or bunx to run it on demand.

Claude Code / Claude Desktop (.mcp.json)

Via npx (Node):

{
  "mcpServers": {
    "cloudflare": {
      "command": "npx",
      "args": ["-y", "@archawat/mcp-cloudflare"],
      "env": { "CLOUDFLARE_API_TOKEN": "cf-token-here" }
    }
  }
}

Via bunx (Bun):

{
  "mcpServers": {
    "cloudflare": {
      "command": "bunx",
      "args": ["-y", "@archawat/mcp-cloudflare"],
      "env": { "CLOUDFLARE_API_TOKEN": "cf-token-here" }
    }
  }
}

Claude Code CLI

claude mcp add cloudflare -s user \
  -e CLOUDFLARE_API_TOKEN="cf-token-here" \
  -- npx -y @archawat/mcp-cloudflare

Global install (fastest cold-start)

npm install -g @archawat/mcp-cloudflare
# or: bun add -g @archawat/mcp-cloudflare

The global bin is named mcp-cloudflare (unscoped), so:

{
  "mcpServers": {
    "cloudflare": {
      "command": "mcp-cloudflare",
      "env": { "CLOUDFLARE_API_TOKEN": "cf-token-here" }
    }
  }
}

API Token

Create a Cloudflare token at https://dash.cloudflare.com/profile/api-tokens with:

  • Zone:Read
  • Zone:DNS:Edit

Scope the token to the zones you want to manage, or grant "All zones".

Tools

| Tool | Purpose | |---|---| | list_zones | Discover which domains the token can manage. | | list_dns_records | List records in a zone; auto-paginates across all pages unless page is set. | | bulk_list_dns_records | List records across many zones in one call. Concurrent per-zone. | | create_a_record | Create an A record. proxied defaults to false. | | create_cname_record | Create a CNAME record. proxied defaults to false. | | toggle_proxy | Flip proxy on/off by record ID, or by name (+ optional type). | | bulk_toggle_proxy | Flip proxy for many records in one call (shared proxied value). | | update_dns_record | Patch content, ttl, proxied, or comment on a record. | | bulk_update_dns_record | Patch many records in one call with per-item fields. | | delete_dns_record | Delete a record by ID. Destructive. |

All tools accept either a domain name ("example.com") or a 32-char zone ID as the zone argument.

Bulk result shape

Bulk tools return per-item results; a single failure doesn't abort the batch:

{
  "succeeded": 10,
  "failed": 1,
  "results": [
    { "zone": "example.com", "ok": true,  "record": { "id": "…", "proxied": true } },
    { "zone": "other.com",   "ok": false, "error": "No proxyable record found for 'www.other.com'." }
  ]
}

isError: true is set on the tool response whenever any item fails, while still returning every result.

Development

Requires Bun (recommended) or Node 18+.

bun install
bun run dev         # run src/index.ts with --watch
bun run start       # run src/index.ts once
bun run typecheck   # tsc --noEmit
bun run build       # emit dist/ for publishing

To run the dev copy as the MCP server instead of the published package, point .mcp.json at your local build:

{
  "mcpServers": {
    "cloudflare": {
      "command": "bun",
      "args": ["/abs/path/to/mcp-cloudflare/src/index.ts"],
      "env": { "CLOUDFLARE_API_TOKEN": "cf-token-here" }
    }
  }
}

The server speaks stdio — your MCP client spawns the process and communicates over stdin/stdout.

License

MIT