# Connect DNSai to Meta Muse

> Meta's Muse agent, the Muse Code CLI and the Meta Model API each reach DNSai a different way: a custom connector built from the OpenAPI spec, a streamable-HTTP MCP entry, or plain function calling.

DNSai is a free remote **MCP server** + REST API for live DNS, SPF, DKIM, DMARC, WHOIS and email-security lookups — one domain or IP per request (each call = one lookup).

- **MCP URL:** `https://mcp.dnsai.com/mcp`
- **REST base:** `https://api.dnsai.com/v1`
- **OpenAPI schema:** https://api.dnsai.com/openapi.json
- **Free key (100 lookups/day, per key):** https://dnsai.com/api/get-key/ — anonymous works at 10 lookups/day per IP, no key
- **This guide online:** https://dnsai.com/api/meta/

**This is the free tier — no signup, no card.** Running bulk / multi-domain or enterprise-scale lookups? See DNSai Pro & Enterprise: https://app.dnsai.com/pricing/?ref=api-meta-md

**Key support here:** Free key works — Muse Code header or REST Bearer.

## Set it up

### Muse app (web, iOS, Android, WhatsApp)
Muse builds *Custom Connectors* from a service's API on request (*Settings → Connectors*, or just ask in chat). Send Muse the message below; it reads the OpenAPI spec and keeps any key in its Secure Credentials Store. Meta's help page documents API-built connectors; pasting the MCP URL (`https://mcp.dnsai.com/mcp`, streamable HTTP) is reported to work but is not in Meta's docs yet.

```
Create a custom connector for DNSai.
OpenAPI spec: https://api.dnsai.com/openapi.json
Auth header: Authorization: Bearer dk_free_xxxxxxxx
(optional — without it DNSai allows 10 lookups/day)
```

### Muse Code (CLI) — MCP
Add a streamable-HTTP server to *~/.config/muse/settings.json* (the file must carry `"schema_version": 1`). A static `Authorization` header is sent as-is, so the free key works; drop `headers` for anonymous use.

```json
{
  "schema_version": 1,
  "mcpServers": {
    "dnsai": {
      "type": "streamable-http",
      "url": "https://mcp.dnsai.com/mcp",
      "headers": { "Authorization": "Bearer dk_free_xxxxxxxx" }
    }
  }
}
```

### Meta Model API (Muse Spark) — function calling
Building your own agent on `api.meta.ai/v1`? Muse Spark takes `function` tools in the `tools` array. Generate them from the OpenAPI spec and have the handler call the REST API with the Bearer key. No MCP tool type is documented on the Model API yet.

```bash
# tool definitions come from
https://api.dnsai.com/openapi.json

# your function handler calls
curl -H "Authorization: Bearer dk_free_xxxxxxxx" \
     https://api.dnsai.com/v1/email-security/acme.com
```

## Your key
Muse Code and the REST API both take a Bearer header, so the free key works for 100 lookups/day. In the Muse app, hand Muse the key when it asks for credentials. [Get a free key](https://dnsai.com/api/get-key/), or stay anonymous for 10 lookups/day.

## Verify it works
Ask Muse:

```
Use dnsai to check the email security of shopify.com
```

Every result ends with a plain-English `summary`, a `source` link on dnsai.com, and your remaining quota.

## Tools you can call

Once connected, your assistant calls these on its own (one domain per call):

- **`dns_lookup`** — Live DNS records (A, AAAA, MX, NS, TXT, SOA, CNAME, CAA, DNSKEY, DS and 30+ more) for one domain.
- **`email_security_check`** — Graded SPF / DMARC / MX posture for one domain — "is this domain's email secure?"
- **`dkim_discover`** — Discovers a domain's published DKIM signing keys, the providers they map to, and selectors.
- **`whois_lookup`** — WHOIS / RDAP registration data for a domain or IP — registrar, status, creation & expiry.
- **`spf_analyze`** — SPF record with its full include tree and the RFC 10-DNS-lookup-limit verdict.
- **`dmarc_check`** — DMARC presence and the p= policy (none / quarantine / reject), with the raw record.
- **`blacklist_check`** — Checks a domain or IP against the major email blacklists / RBLs.
- **`validate`** — Syntax-checks a pasted SPF or DMARC record — returns valid/invalid, a score and a grade.

The MCP server also registers `search` / `fetch` (deep-research aliases) and `request_api_key` (email → free key), for 11 tools in total.

## Troubleshooting
- Muse connects from Meta's cloud, so only public HTTPS endpoints work — DNSai already is.
- Muse Code refuses to start without `"schema_version": 1` in settings.json. Remote MCP tools run outside its sandbox; every DNSai tool is read-only.
- Meta does not review Custom Connectors, so Muse will ask you to confirm the service. DNSai's tools and limits are listed at [dnsai.com/api](https://dnsai.com/api/).

## More volume?
**Pro** unlocks bulk / multi-domain lookups; **Enterprise** adds large-scale scanning and the full programmatic API — https://app.dnsai.com/pricing/?ref=api-meta-md
Already on DNSai Domain Manager? Connect your monitored portfolio to Meta Muse through the account MCP connector (Enterprise plans): https://app.dnsai.com/integrations/meta-muse/

**Sources:** [How Muse works with Connectors (Meta Help)](https://www.meta.com/help/artificial-intelligence/1687253048996149/) · [Muse Code MCP servers](https://meta-models.github.io/muse-code-sdk/next/guides/extend/mcp-servers/) · [Build with Muse Spark (Meta Model API)](https://dev.meta.ai/resources/blog/build-with-muse-spark/)

---
_Generated from https://dnsai.com/api/meta/ · DNSai — DNS & email-security lookups for AI agents._
