porkbun-mcp-server
v1.4.0
Published
MCP server for Porkbun API v3 — domain registration, DNS management, SSL certificates, and more
Downloads
405
Maintainers
Readme
porkbun-mcp
MCP server for the Porkbun API v3 — 33 tools covering domain registration, DNS management, SSL certificates, email hosting, marketplace, and more. Supports multiple Porkbun accounts in a single server instance.
Installation
npm
npm install -g porkbun-mcp-serverGitHub Packages
npm install -g @eyalm321/porkbun-mcp-server --registry=https://npm.pkg.github.comConfiguration
Single account
export PORKBUN_API_KEY="pk1_..."
export PORKBUN_SECRET_API_KEY="sk1_..."Get your API keys at porkbun.com/account/api.
Multiple accounts
Create a JSON file listing your accounts and point PORKBUN_ACCOUNTS_FILE at it:
// ~/.porkbun-accounts.json
[
{ "user": "default", "PORKBUN_API_KEY": "pk1_...", "PORKBUN_SECRET_API_KEY": "sk1_..." },
{ "user": "alice", "PORKBUN_API_KEY": "pk1_...", "PORKBUN_SECRET_API_KEY": "sk1_..." },
{ "user": "acme-corp", "PORKBUN_API_KEY": "pk1_...", "PORKBUN_SECRET_API_KEY": "sk1_..." }
]export PORKBUN_ACCOUNTS_FILE="$HOME/.porkbun-accounts.json"The shorthand aliases apiKey and secretApiKey are also accepted inside the file.
Then pass user to any authenticated tool:
// Use the default credentials
{ "name": "porkbun_domain_list_all", "arguments": {} }
// Use Alice's credentials
{ "name": "porkbun_domain_list_all", "arguments": { "user": "alice" } }
// User identifiers are case-insensitive
{ "name": "porkbun_domain_list_all", "arguments": { "user": "Acme-Corp" } }Resolution rules:
- The default account (used when
useris omitted) isPORKBUN_API_KEY/PORKBUN_SECRET_API_KEY, or — if defined — the entry inPORKBUN_ACCOUNTS_FILEwithuser: "default". - A
userargument matches a configured account by lowercased identifier. - Use
porkbun_list_usersto discover which user identifiers are configured.
Usage with Claude Desktop
Add to your Claude Desktop config (claude_desktop_config.json):
{
"mcpServers": {
"porkbun": {
"command": "npx",
"args": ["-y", "porkbun-mcp-server"],
"env": {
"PORKBUN_API_KEY": "pk1_...",
"PORKBUN_SECRET_API_KEY": "sk1_...",
"PORKBUN_ACCOUNTS_FILE": "/Users/you/.porkbun-accounts.json"
}
}
}
}PORKBUN_ACCOUNTS_FILE is optional — leave it out for a single-account setup.
Tools (33)
Utility
porkbun_ping— Test credentials and get IPporkbun_get_ip— Get public IP (no auth)porkbun_list_users— List configured user identifiers
Pricing
porkbun_get_pricing— Get domain pricing for all TLDs (no auth)
API Key Management
porkbun_apikey_request— Initiate API key authorizationporkbun_apikey_retrieve— Poll for API key approval
Domain (13 tools)
porkbun_domain_list_all— List all domainsporkbun_domain_get_ns— Get nameserversporkbun_domain_update_ns— Update nameserversporkbun_domain_update_auto_renew— Update auto-renewporkbun_domain_check— Check availability & pricingporkbun_domain_create— Register a domainporkbun_domain_add_url_forward— Add URL forwardporkbun_domain_get_url_forwarding— List URL forwardsporkbun_domain_delete_url_forward— Delete URL forwardporkbun_domain_create_glue— Create glue recordporkbun_domain_update_glue— Update glue recordporkbun_domain_delete_glue— Delete glue recordporkbun_domain_get_glue— Get glue records
DNS (11 tools)
porkbun_dns_retrieve— Retrieve all DNS recordsporkbun_dns_retrieve_by_id— Get record by IDporkbun_dns_retrieve_by_name_type— Get records by name/typeporkbun_dns_create— Create DNS recordporkbun_dns_edit— Edit record by IDporkbun_dns_edit_by_name_type— Edit records by name/typeporkbun_dns_delete— Delete record by IDporkbun_dns_delete_by_name_type— Delete records by name/typeporkbun_dns_create_dnssec— Create DNSSEC recordporkbun_dns_get_dnssec— Get DNSSEC recordsporkbun_dns_delete_dnssec— Delete DNSSEC record
SSL
porkbun_ssl_retrieve— Retrieve SSL certificate bundle
Email Hosting
porkbun_email_set_password— Set email hosting password
Marketplace
porkbun_marketplace_list— List marketplace domains
Every authenticated tool accepts an optional user parameter that selects which account from PORKBUN_ACCOUNTS_FILE to use. Omit it to use the default account.
Development
npm install
npm run build
npm testLicense
MIT
