Skip to main content
Glama

Apply DNS template

apply_dns_template
Destructive

Preview and apply a backend-defined DNS template to a native forward zone, showing records before writing and optionally replacing conflicting records.

Instructions

Apply a backend-defined DNS template to a native forward zone. The written records can change public DNS answers; overwrite=true replaces conflicting records. Records still pass the same API validation, quotas and conflict rules as manual record writes. Prefer preview=true first to show the user exactly which records a template would write before changing the zone. Requires dns:write when using an API key.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "zone_id": "<zone_id>",
      "template": "<template>"
    },
    "name": "apply_dns_template"
  }
}

Input Schema

NameRequiredDescriptionDefault
previewNotrue to dry-run the template and return the records it would write without changing the zone
zone_idYesDNS zone ID
templateYesTemplate ID returned by list_dns_templates, e.g. web_service, null_mx, google_workspace, microsoft_365, mail_security, caa_letsencrypt
overwriteNotrue to replace existing records that conflict with the template. Destructive: confirm the exact conflicts with the user first, ideally from a preview run.
parametersNoTemplate parameters, e.g. { ipv4, ipv6, www, mx_target, ttl } depending on the template

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv2.3.21
    • addedInput schema / properties / parameters / propertyNames
      Added value: +{
      +  "type": "string"
      +}
  2. First observedv2.3.16

TDQS

A4.3/5.0
Behavior5/5

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

Goes well beyond the annotations (destructiveHint=true, openWorldHint=true): it warns that written records can change public DNS answers, that records pass through the same API validation, quotas and conflict rules as manual writes, and that dns:write is required for API-key auth. That is exactly the operational context an agent needs for a destructive mutation.

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?

Front-loads the action and effect, then the safety workflow, then the auth requirement. Slightly repetitive between 'overwrite=true replaces conflicting records' and the later preview/conflict-confirmation sentence, but no sentence is wasted.

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?

A destructive, non-idempotent mutation with a nested open-ended parameters object and no output schema is well covered: effect, safety workflow, validation/quotas, and auth scope are all stated. Only minor gap is the description itself not pointing to list_dns_templates as the source of valid template IDs and expected parameters (the schema does).

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

Parameters3/5

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

Schema coverage is 100% and the schema already documents preview as a dry-run, overwrite as destructive, and the template ID source (list_dns_templates). The description reinforces the preview-then-overwrite workflow but adds little syntax or meaning not already in the schema, so the baseline of 3 applies.

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?

States a specific verb and resource ('Apply a backend-defined DNS template to a native forward zone') and scopes the effect to public DNS answers, so an agent can distinguish this from sibling record-level writers like upsert_dns_record or import_dns_zone.

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?

Gives an explicit recommended workflow: run with preview=true first and show the user the prospective records, and confirm exact conflicts with the user before using overwrite=true. It does not name alternatives for manual record writes, but the when-to-use guidance is concrete.

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

Deploy Server

Other Tools