Gandi MCP Server

Manage Gandi domains and LiveDNS records directly via the Gandi API v5.

README.md

Gandi MCP Server

A comprehensive Model Context Protocol (MCP) server for managing Gandi domains and DNS records via the Gandi API v5. This server enables AI assistants like Claude to manage domains and LiveDNS records directly through Gandi's API.

Features

🌐 Domain Management

  • List Domains: View all domains in your account
  • Domain Details: Get comprehensive domain information
  • Domain Check: Check domain availability for registration
  • Contact Management: List domain contacts

📝 LiveDNS Management

  • DNS Records: Full CRUD operations for DNS records
  • Record Types: Support for A, AAAA, CNAME, MX, NS, PTR, SRV, TXT, CAA
  • Smart Filtering: Filter records by type or name
  • TTL Control: Manage record time-to-live settings

🛡️ Security & Reliability

  • Secure Authentication: Environment-based API token management
  • Error Handling: Comprehensive error handling with clear messages
  • Type Safety: Full TypeScript support with proper type definitions

Quick Start

Run the server directly with npx (requires Node.js 18+):

npx @artik0din/mcp-gandi

Or install locally:

npm install -g @artik0din/mcp-gandi
mcp-gandi

Environment Variables

Create a .env file in your working directory:

Variable Required Description
GANDI_API_TOKEN Your Gandi API token with domain and LiveDNS permissions

Getting Your Gandi API Token

  1. Log in to Gandi Dashboard
  2. Go to Organizations > [Your Organization] > Billing & Cards
  3. Click on Account Settings > Security
  4. In the API Keys section, click Generate API keys
  5. Create a new API key with:
    • Domain: See and edit permissions
    • LiveDNS: See and edit permissions
    • Billing: See permission (optional, for domain pricing)

MCP Client Configuration

Claude Desktop

Add this to your Claude Desktop configuration:

{
  "mcpServers": {
    "gandi": {
      "command": "npx",
      "args": ["@artik0din/mcp-gandi"],
      "env": {
        "GANDI_API_TOKEN": "your_api_token_here"
      }
    }
  }
}

Other MCP Clients

Use the command npx @artik0din/mcp-gandi with the appropriate environment variables set.

Available Tools

Domain Management Tools

gandi_domains_list

List all domains in your Gandi account.

Parameters: None

Example:

List all my Gandi domains
gandi_domains_get

Get detailed information about a specific domain.

Parameters:

  • domain (string, required): Domain name (e.g., example.com)

Example:

Get details for domain example.com
Show information about mydomain.net
gandi_domains_check

Check if a domain name is available for registration.

Parameters:

  • domain (string, required): Domain name to check

Example:

Check if newdomain.com is available
Is example.org available for registration?
gandi_domains_contacts

List contacts associated with a domain.

Parameters:

  • domain (string, required): Domain name

Example:

Show contacts for example.com
List contact information for mydomain.net

DNS Management Tools

gandi_dns_records_list

List all DNS records for a domain.

Parameters:

  • domain (string, required): Domain name
  • type (string, optional): Filter by record type (A, AAAA, CNAME, MX, NS, PTR, SRV, TXT, CAA)

Example:

List all DNS records for example.com
Show A records for mydomain.net
Get MX records for example.org
gandi_dns_record_get

Get a specific DNS record by name and type.

Parameters:

  • domain (string, required): Domain name
  • name (string, required): Record name (e.g., www, @, subdomain)
  • type (string, required): Record type

Example:

Get A record for www.example.com
Show CNAME record for blog subdomain of mydomain.net
gandi_dns_record_create

Create a new DNS record.

Parameters:

  • domain (string, required): Domain name
  • name (string, required): Record name (e.g., www, @, subdomain)
  • type (string, required): Record type (A, AAAA, CNAME, MX, NS, PTR, SRV, TXT, CAA)
  • values (array, required): Record values (IP addresses, hostnames, text content)
  • ttl (number, optional): TTL in seconds (300-2592000, defaults to 300)

Example:

Create an A record for www pointing to 1.2.3.4 for example.com
Add CNAME record for blog pointing to www.example.com with TTL 3600
Create MX record for @ pointing to mail.example.com with TTL 1800
gandi_dns_record_update

Update an existing DNS record.

Tools 7

gandi_domains_listList all domains in your Gandi account.
gandi_domains_getGet detailed information about a specific domain.
gandi_domains_checkCheck if a domain name is available for registration.
gandi_domains_contactsList contacts associated with a domain.
gandi_dns_records_listList all DNS records for a domain.
gandi_dns_record_getGet a specific DNS record by name and type.
gandi_dns_record_createCreate a new DNS record.

Environment Variables

GANDI_API_TOKENrequiredYour Gandi API token with domain and LiveDNS permissions

Try it

List all the domains currently registered in my Gandi account.
Check if the domain name 'example-startup.com' is available for registration.
Show me all the A records for my domain example.com.
Create a new CNAME record for 'blog' pointing to 'www.example.com' on my domain example.com.
Get the contact information associated with mydomain.net.

Frequently Asked Questions

What are the key features of Gandi MCP Server?

Comprehensive domain management including listing, details, and availability checks.. Full CRUD operations for LiveDNS records including A, AAAA, CNAME, MX, and TXT types.. Smart filtering for DNS records by type or name.. Configurable TTL settings for DNS record management.. Secure environment-based API token authentication..

What can I use Gandi MCP Server for?

Automating DNS record updates for development environments via AI chat.. Quickly checking domain availability during brainstorming sessions with an AI assistant.. Auditing domain contact information and DNS configurations across multiple domains.. Programmatically managing DNS records for new project deployments..

How do I install Gandi MCP Server?

Install Gandi MCP Server by running: npx @artik0din/mcp-gandi

What MCP clients work with Gandi MCP Server?

Gandi MCP Server works with any MCP-compatible client including Claude Desktop, Claude Code, Cursor, and other editors with MCP support.

Turn this server into reusable context

Keep Gandi MCP Server docs, env vars, and workflow notes in Conare so your agent carries them across sessions.

Open Conare