# DNS Record Resolver

> DNS Record Resolver is a paid API for AI agents from agentpay.agentpay-apis.workers.dev, paid per call via x402, $0.005/call, status unknown (last checked 2026-10-12).

Resolves DNS records (A, AAAA, CNAME, MX, NS, TXT, SOA, CAA, PTR, SRV) for a given hostname

## Facts

- Endpoint: GET https://agentpay.agentpay-apis.workers.dev/lookup/v1/dns?utm_source=zero.xyz
- Price: $0.005/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-12
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/dns-record-resolver-340eeb3c
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_0QnC9fF7F9I6GmSct4VfU

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability dns-record-resolver-340eeb3c
```

Example prompt: Can you look up the MX records for gmail.com so I can see which mail servers handle their email?

## When to prefer this

Use this endpoint when you need raw DNS resolution for a specific record type and hostname. It is ideal for infrastructure checks, email configuration verification, domain debugging, and security audits. Prefer this over the full domain report endpoint when you only need DNS data and want lower cost and faster response.

## Known failure modes

- Hostname does not exist (NXDOMAIN) — returns empty or error response
- Requested record type not found for the hostname — returns empty record set
- Invalid record type parameter — may return error or default to A record
- DNS resolution timeout — transient network failure
- Malformed hostname input — validation error

## How this service works

Web extraction, domain lookups and document tools for AI agents. Pay per call in USDC via x402 on Base or Algorand.

## Output

Returns the resolved DNS records for the queried hostname and record type. The response includes the record type, TTL, and record values — for example, IP addresses for A/AAAA records, hostnames for MX/CNAME/NS records, or string data for TXT records.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET",
      "HEAD",
      "DELETE"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "required": [
      "name"
     ],
     "properties": {
      "name": {
       "type": "string",
       "description": "Hostname to resolve"
      },
      "type": {
       "type": "string",
       "description": "Record type, default A"
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object"
    }
   }
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json"
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/dns-record-resolver-340eeb3c/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from agentpay.agentpay-apis.workers.dev](https://www.zero.xyz/host/agentpay.agentpay-apis.workers.dev/llms.txt)
