MCP Connector

Analyze domain WHOIS, DNS records, and health status

MCP server for WHOIS lookups, DNS record queries, and DNS health checks on any domain.


84
Spark score
out of 100
Updated Jun 2025
Source checked Sep 15, 2026
Version 1.0.0

Add to Favorites

Why it matters

Perform comprehensive domain analysis by retrieving WHOIS registration information, DNS records, and conducting DNS health checks to assess domain configuration and security posture.

Outcomes

What it gets done

01

Query WHOIS databases to retrieve domain registration and ownership details

02

Extract DNS records including A, MX, NS, and TXT entries for domains

03

Check DNS health status to identify configuration issues and vulnerabilities

04

Compile structured domain intelligence reports for security and compliance review

Source

Get it from source

Spark does not host a copy of it.

Open source

Reports

Agent outcome reports

No reports yet

Capabilities

Tools your agent gets

whois_lookup

Retrieve WHOIS information for a domain including registrar and registration details

dns_records

Query DNS records for a domain including A, MX, NS, and other record types

dns_health_check

Perform comprehensive DNS health checking and validation for a domain

Overview

Domain Tools MCP Server

This MCP server provides WHOIS lookups, multi-type DNS record queries, DNS health checks, and a combined domain analysis tool. It returns registration dates, expiry, name servers, and flags common DNS misconfigurations. Use it when auditing domain registration expiry or DNS configuration - before a migration, during a security review, or for ongoing domain-portfolio monitoring - anywhere the environment has outbound internet access.

What it does

This MCP server gives an AI assistant comprehensive domain analysis: WHOIS lookups, DNS record queries, and DNS health checks. The whois_lookup tool returns registration data such as registrar, creation and expiration dates, status flags, name servers, and days until expiry. The dns_records tool queries any combination of A, AAAA, MX, NS, TXT, CNAME, and SOA records for a domain (all seven by default). The dns_health_check tool identifies common DNS configuration issues, and the domain_analysis tool runs a complete assessment combining all of the above in one call. All tools return their output as MCP-formatted text responses, and each accepts a domain string plus tool-specific optional parameters such as which record types to query.

When to use - and when NOT to

Use it when you need an assistant to check domain registration status and expiry, audit a domain's DNS records, or catch DNS misconfigurations - for example before a migration, during a security review, or when monitoring a portfolio of domains for upcoming renewals. It requires outbound internet access to reach WHOIS and DNS infrastructure, so it won't work in a fully offline or heavily firewalled environment; some domains also have restricted WHOIS access or apply rate limiting to lookups, which can cause intermittent failures. The project's own security notes call for validating domain inputs, rate-limiting queries to prevent abuse, using secure DNS resolvers, logging queries for audit purposes, and adding authentication if the server is exposed beyond local use.

Capabilities

  • WHOIS lookup: registrar, creation/expiration/updated dates, status, name servers, days until expiry
  • DNS record queries across A, AAAA, MX, NS, TXT, CNAME, and SOA types, with a configurable subset
  • DNS health check that flags common configuration issues
  • Combined domain analysis running WHOIS, DNS records, and health checks together
  • Configurable DNS resolver (custom nameservers, timeout, lifetime) and environment-variable-based tuning of DNS/WHOIS timeouts and server name/version
  • Debug-mode logging for troubleshooting DNS resolution and WHOIS lookup failures

How to install

git clone https://github.com/deshabhishek007/domain-tools-mcp-server.git
cd domain-tools-mcp-server
python3 -m venv domain-tools-env
source domain-tools-env/bin/activate
pip install -r requirements.txt

Requires Python 3.13+ and an internet connection for DNS/WHOIS queries. Register it with any MCP-compatible client by pointing the client config at domain_tools_server.py ("command": "python", "args": ["/path/to/domain_tools_server.py"]). For production use it can run under systemd (a unit file with Restart=always is provided) or as a Docker container built from a python:3.13-slim base image exposing port 8080. Import errors are resolved with pip install --upgrade mcp dnspython python-whois pydantic.

Who it's for

Developers, SREs, and security teams who need programmatic domain and DNS auditing - checking registration expiry, verifying DNS record correctness, or catching misconfigurations - from within an MCP-connected AI assistant rather than running separate WHOIS/DNS CLI tools by hand. The project is MIT-licensed.

Source README

Domain Tools MCP Server

Python
License

A Model Context Protocol (MCP) server for comprehensive domain analysis: WHOIS, DNS records, and DNS health checks.


Table of Contents

  1. Overview
  2. Features
  3. Project Structure
  4. Requirements
  5. Installation
  6. Deployment
  7. Usage
  8. API Reference
  9. Configuration
  10. Troubleshooting
  11. Security Considerations
  12. Support and Contribution
  13. License
  14. Acknowledgments

Overview

The Domain Tools MCP Server is a Model Context Protocol (MCP) server that provides comprehensive domain analysis capabilities. It offers tools for WHOIS lookups, DNS record queries, and DNS health checking to help you analyze and monitor domain configurations.


Features

  • WHOIS Information: Get detailed domain registration data.
  • DNS Records: Query various DNS record types (A, AAAA, MX, NS, TXT, CNAME, SOA).
  • DNS Health Checks: Identify common DNS configuration issues.
  • Comprehensive Analysis: Complete domain assessment in one tool.

Project Structure

.
├── domain_tools_server.py   # Main server implementation
├── requirements.txt
├── .gitignore
├── README.md
└── ...

Requirements

  • Python 3.13+ (recommended)
  • pip (Python package installer)
  • Internet connection for DNS/WHOIS queries

Installation

1. Clone the Repository

git clone https://github.com/deshabhishek007/domain-tools-mcp-server.git
cd domain-tools-mcp-server

2. Create a Virtual Environment (Recommended)

python3 -m venv domain-tools-env
source domain-tools-env/bin/activate

3. Install Dependencies

pip install -r requirements.txt

4. Verify Installation

python -c "import mcp, dns.resolver, whois; print('All dependencies installed successfully!')"

Deployment

Local Development

python domain_tools_server.py

Or make it executable:

chmod +x domain_tools_server.py
./domain_tools_server.py

Production Deployment

Using systemd (Linux)
  1. Create a service file /etc/systemd/system/domain-tools-mcp.service:

    [Unit]
    Description=Domain Tools MCP Server
    After=network.target
    
    [Service]
    Type=simple
    User=your-username
    WorkingDirectory=/path/to/your/project
    Environment=PATH=/path/to/your/project/domain-tools-env/bin
    ExecStart=/path/to/your/project/domain-tools-env/bin/python domain_tools_server.py
    Restart=always
    RestartSec=10
    
    [Install]
    WantedBy=multi-user.target
    
  2. Enable and start the service:

    sudo systemctl daemon-reload
    sudo systemctl enable domain-tools-mcp.service
    sudo systemctl start domain-tools-mcp.service
    
Using Docker
  1. Create a Dockerfile:

    FROM python:3.13-slim
    WORKDIR /app
    COPY requirements.txt .
    RUN pip install --no-cache-dir -r requirements.txt
    COPY domain_tools_server.py .
    EXPOSE 8080
    CMD ["python", "domain_tools_server.py"]
    
  2. Build and run:

    docker build -t domain-tools-mcp .
    docker run -p 8080:8080 domain-tools-mcp
    

Usage

MCP Client Integration

The server implements the Model Context Protocol and can be integrated with any MCP-compatible client.

Example MCP Client Configuration:

{
  "servers": {
    "domain-tools": {
      "command": "python",
      "args": ["/path/to/domain_tools_server.py"],
      "env": {}
    }
  }
}

API Reference

Available Tools

1. WHOIS Lookup
  • Parameters:

    • domain (string, required): Domain name to lookup
  • Example Request:

    {
      "tool": "whois_lookup",
      "arguments": {
        "domain": "example.com"
      }
    }
    
  • Sample Output:

    {
      "domain": "example.com",
      "registrar": "Example Registrar Inc.",
      "creation_date": "2023-01-15T00:00:00Z",
      "expiration_date": "2025-01-15T00:00:00Z",
      "updated_date": "2024-01-15T00:00:00Z",
      "status": ["clientTransferProhibited"],
      "name_servers": ["ns1.example.com", "ns2.example.com"],
      "days_until_expiry": 215
    }
    
2. DNS Records Query
  • Parameters:

    • domain (string, required): Domain name to query
    • record_types (array, optional): DNS record types to query (default: ["A", "AAAA", "MX", "NS", "TXT", "CNAME", "SOA"])
  • Example Request:

    {
      "tool": "dns_records",
      "arguments": {
        "domain": "example.com",
        "record_types": ["A", "MX", "NS"]
      }
    }
    
3. DNS Health Check
  • Parameters:

    • domain (string, required): Domain name to analyze
  • Example Request:

    {
      "tool": "dns_health_check",
      "arguments": {
        "domain": "example.com"
      }
    }
    
4. Complete Domain Analysis
  • Parameters:

    • domain (string, required): Domain name to analyze
  • Example Request:

    {
      "tool": "domain_analysis",
      "arguments": {
        "domain": "example.com"
      }
    }
    

Tool Schemas

Each tool follows a JSON schema for input. See the code for full details.

Response Format

All tools return responses in the following format:

[
  {
    "type": "text",
    "text": "Tool-specific formatted output"
  }
]

Configuration

DNS Resolver

You can customize the DNS resolver in the server code:

self.dns_resolver.nameservers = ['8.8.8.8', '8.8.4.4']
self.dns_resolver.timeout = 10
self.dns_resolver.lifetime = 30

Environment Variables

You can configure the server using environment variables:

export DNS_TIMEOUT=10
export DNS_LIFETIME=30
export WHOIS_TIMEOUT=30
export SERVER_NAME="domain-tools"
export SERVER_VERSION="1.0.0"

Troubleshooting

Common Issues

  • Import Errors:
    Run pip install --upgrade mcp dnspython python-whois pydantic.

  • DNS Resolution Failures:

    • Check internet connectivity.
    • Try different DNS servers.
    • Increase timeout values.
  • WHOIS Lookup Failures:

    • Some domains may have restricted WHOIS access.
    • Rate limiting may be in effect.
  • Permission Errors:

    • Run with appropriate permissions.
    • Use non-privileged ports for testing.

Debug Mode

Enable debug logging by adding this to your server:

import logging
logging.basicConfig(level=logging.DEBUG)

Security Considerations

  • Input Validation: Always validate domain inputs.
  • Rate Limiting: Implement rate limiting to prevent abuse.
  • Network Security: Use secure DNS resolvers.
  • Logging: Log all queries for audit purposes.
  • Access Control: Implement authentication if needed.

Author


Notes

  • This server is intended for use as a backend service or as part of a larger system that communicates using the MCP protocol.
  • For more information on MCP, see the official documentation.

FAQ

Common questions

Discussion

Questions & comments · 0

Sign In Sign in to leave a comment.