convez.ai
MCP ServerIntegração & APIsIntermediário
oborseth

Porkbun MCP Server

oborseth/Porkbun-MCP

Gerenciamento completo de domínios e DNS via Claude e agentes IA

Ver no GitHub
InicialPluginScore · de 0 a 100

Servidor MCP oficial que expõe a API v3 da Porkbun como 31 ferramentas nativas para Claude Desktop, Cursor e outros agentes IA. Oferece controle completo do ciclo de vida de domínios (registro, renovação, transferência) e gerenciamento de DNS, DNSSEC, redirecionamentos e registros glue, com proteção contra duplicação em retentativas.

Instalação

$npx convez-ai oborseth/Porkbun-MCP

1 comando no terminal: detecta o formato do repositório (marketplace ou plugin avulso) e instala via Claude Code. Requer Node 18+ e o Claude Code instalado.

Métricas

Estrelas
36
Forks
3
Acompanhando
0
Saúde
42%
Último commit
há 2 dias
Versão
v0.65.14
Issues abertas
3
Contribuidores
1

Casos de uso

  • Automatizar registro e renovação de domínios sem UI
  • Gerenciar DNS e DNSSEC programaticamente via agentes
  • Integrar operações de domínio em workflows de IA
  • Monitorar saldo de conta e status de transferências

Veredito

MCP server maduro (v0.3.2) e bem estruturado que leva a Porkbun para agentes IA de forma segura. Implementação profissional com idempotência nativa, cobertura abrangente e documentação clara — recomendado para quem precisa automação de domínios em pipelines IA.

README

A tradução para o português deste README ainda está na fila.

Porkbun MCP Server

npm version npm downloads License: MIT

A Model Context Protocol server that exposes the Porkbun v3 API as native tools for AI agents — Claude Desktop, Cursor, Cline, and any other MCP-compatible client.

Status: v0.3.2 — covers everything you can do in the Porkbun web UI. All write operations attach an Idempotency-Key automatically, so retries within 24 hours don't double-charge.

What's included (31 tools)

Read tools (free, no spend, no state changes)

ToolDescription
pingVerify API connectivity and credentials
check_domainCheck availability and pricing for a single domain
get_pricingGet registration/renewal/transfer pricing for all TLDs (no auth needed)
list_marketplaceBrowse the Porkbun aftermarket — filter by TLD, max price, name substring
list_domainsPaginate through domains; filter by tld, expiry, auto-renew, API access
get_domainGet metadata for a single domain in the account
get_balanceGet account credit balance
get_api_settingsGet monthly spend limit, low-balance alert, auto top-up config, MTD spend
get_nameserversGet current nameservers for a domain
list_dns_recordsList DNS records for a domain
list_dnssec_recordsList DNSSEC DS records published at the registry
list_url_forwardsList URL forwarding rules for a domain
list_glue_recordsList glue records (host-to-IP mappings) for a domain
list_transfersList in-progress and recent inbound transfers
get_transfer_statusGet status of a specific inbound transfer
get_ssl_bundleRetrieve the free Porkbun-issued SSL bundle for a domain

Domain lifecycle writes (spend account credit)

ToolDescription
register_domainRegister a new domain — call check_domain first to confirm price
renew_domainRenew an existing domain
transfer_domainInitiate an inbound transfer (returns transferId; takes 5-7 days)

Domain settings writes (free)

ToolDescription
update_auto_renewTurn auto-renewal on or off
update_nameserversReplace the nameserver list for a domain (full replace, not append)

DNS / DNSSEC / URL-forwarding / glue writes (free)

ToolDescription
create_dns_recordCreate a new DNS record (A, AAAA, CNAME, MX, TXT, etc.)
update_dns_recordUpdate an existing DNS record by its ID
delete_dns_recordDelete a DNS record by its ID
create_dnssec_recordSubmit a DNSSEC DS record to the registry
delete_dnssec_recordRemove a DNSSEC DS record by key tag
create_url_forwardCreate a URL forwarding rule
delete_url_forwardDelete a URL forwarding rule by ID
create_glue_recordCreate a glue record (host-to-IP mapping at the registry)
update_glue_recordReplace the IP list for a glue record
delete_glue_recordDelete a glue record by host

Install

You'll need Node.js 18 or newer.

npx -y @porkbunllc/mcp-server

This downloads and runs the latest version on demand. No global install needed.

Configure your MCP client

Claude Desktop

Add this to ~/Library/Application Support/Claude/claude_desktop_config.json (macOS) or %APPDATA%\Claude\claude_desktop_config.json (Windows):

{
  "mcpServers": {
    "porkbun": {
      "command": "npx",
      "args": ["-y", "@porkbunllc/mcp-server"],
      "env": {
        "PORKBUN_API_KEY": "pk1_your_public_key_here",
        "PORKBUN_SECRET_API_KEY": "sk1_your_secret_key_here"
      }
    }
  }
}

Restart Claude Desktop. Porkbun tools should appear in the tool picker.

Cursor / Cline / Continue

Most MCP-aware editors use a similar mcpServers config block. See your client's documentation for the exact location.

Get API keys

Create API keys at porkbun.com/account/api. You'll need both the public key (pk1_…) and the secret key (sk1_…).

By default, API access is opt-in per domain. To use the API to manage all your domains, enable the "Opt In All Domains" toggle in the same settings page. Otherwise you'll need to enable API access for each domain individually under Domain Management.

Recommended: scope the key to your agent

Each API key supports two optional restrictions, set via the gear icon next to the key in porkbun.com/account/api:

  • Allowed IPs — one entry per line; supports bare IPv4/IPv6 plus CIDR ranges (198.51.100.0/24, 2001:db8::/32). Requests from other IPs fail with HTTP 403 IP_NOT_ALLOWED before any other check runs.
  • Allowed domains — one entry per line, exact match. Operations against domains not in the list fail with HTTP 403 DOMAIN_NOT_ALLOWED.

Empty fields = no restriction (matches current behavior). When you give an MCP server a key, the recommended pattern is:

  1. Create a fresh key dedicated to the agent (not your master key).
  2. List the specific domains the agent should manage.
  3. If you know the agent's egress IP, list it too.

The blast radius of an accidentally-leaked key drops to "operations on these domains from this IP" instead of "anything on the account."

Environment variables

VariableRequiredPurpose
PORKBUN_API_KEYyesYour Porkbun public API key
PORKBUN_SECRET_API_KEYyesYour Porkbun secret API key
PORKBUN_BASE_URLnoOverride the API base URL (e.g. for testing against api-betamax.porkbun.com/api/json/v3)

Local development

git clone https://github.com/oborseth/Porkbun-MCP.git
cd Porkbun-MCP
npm install
npm run build
npm start          # or: node dist/index.js

The server speaks JSON-RPC 2.0 over stdio. Smoke test from a shell:

(printf '%s\n' \
  '{"jsonrpc":"2.0","id":1,"method":"initialize","params":{"protocolVersion":"2024-11-05","capabilities":{},"clientInfo":{"name":"test","version":"1.0"}}}' \
  '{"jsonrpc":"2.0","method":"notifications/initialized"}' \
  '{"jsonrpc":"2.0","id":2,"method":"tools/list"}') \
  | PORKBUN_API_KEY=pk1_… PORKBUN_SECRET_API_KEY=sk1_… node dist/index.js

Reliability

All write operations (when added in future releases) will automatically attach a per-call Idempotency-Key header. Retried calls within 24 hours return the cached response — your agent can safely retry on network errors without double-charging.

License

MIT

Links

Ver o original no GitHub

Bom para

Relacionados