Skip to main content
Glama
Michaelzag

Migadu MCP Server

by Michaelzag

activate_domain

Idempotent

Activate domains after DNS configuration. Validates DNS records and fails with error if validation fails.

Instructions

Activate domain(s) once DNS records are configured. Fails with 422 if DNS validation fails. List of dicts with: name.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
itemsYes

Implementation Reference

  • The activate_domain tool handler. It is decorated with @migadu_bulk_tool (accepts list of dicts), validates each using DomainActivateRequest, calls domain_service().activate_domain(item.name), and returns a bulk-result envelope.
    @migadu_bulk_tool(mcp, DomainActivateRequest, entity="domain activation")
    async def activate_domain(
        item: DomainActivateRequest, ctx: Context
    ) -> dict[str, Any]:
        """Activate domain(s) once DNS records are configured. Fails with 422 if DNS validation fails. List of dicts with: name."""
        await ctx.info(f"📋 Activating domain {item.name}")
        result = await get_service_factory().domain_service().activate_domain(item.name)
        return {"domain": result, "name": item.name, "success": True}
  • DomainService.activate_domain method. Makes a GET request to /domains/{name}/activate on the Migadu API. Raises MigaduAPIError(422) if DNS validation fails.
    async def activate_domain(self, name: str) -> dict[str, Any]:
        """Activate a domain once DNS records are correctly configured.
    
        Raises MigaduAPIError(422, ...) if DNS validation fails.
        """
        return await self.client.get(f"/domains/{name}/activate")
  • Pydantic schema DomainActivateRequest with a single required 'name' field (str) used to validate input for the activate_domain tool.
    class DomainActivateRequest(BaseModel):
        name: str = Field(..., description="Domain name")
  • The activate_domain tool is registered indirectly via register_domain_tools(mcp) called in initialize_server().
    def initialize_server() -> None:
        register_domain_tools(mcp)
  • register_domain_tools function that registers all domain tools (including activate_domain) on the FastMCP instance. The decorator @migadu_bulk_tool internally calls mcp.tool() to register.
    def register_domain_tools(mcp: FastMCP) -> None:
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already cover idempotency and non-destructiveness; description adds validation behavior (422 failure) and input structure (list of dicts with name). No contradictions.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Two sentences, front-loaded with key info. Could group related details but overall efficient.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Covers purpose, prerequisite, failure mode, and param structure. Lacks success response details but adequate for typical activation tool.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema has 0% coverage for items array; description clarifies each dict must have a 'name' field, adding essential meaning beyond schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Description clearly states verb 'Activate' and resource 'domain(s)', with prerequisite 'once DNS records are configured'. Distinguishes from siblings like create_domain and update_domain.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Specifies when to use (after DNS configuration) and failure condition (422 if DNS validation fails). While not exhaustive on alternatives, it provides sufficient usage context.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Michaelzag/migadu-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server