NextDNS MCP server for AI agents

Live

API KEY

DNS SECURITY

Analytics

NextDNS gives your agent DNS filtering control in your NextDNS account: manage profiles, allowlists, denylists, blocklists, and parental controls, adjust security and privacy settings, and read query logs and analytics.

  • Per-user credentials: each call uses the actual user's API key, never a shared bot.
  • Encrypted per-tenant vault: AES-256, resolved at request time, never in LLM context.
  • Scoped before every call: pre-call scope check, 90-day SIEM-exportable audit chain.
NextDNS
agent · Acme Q3
Run
Which domains were queried most on my home profile this week?
S
nextdns_analytics_domains_get
690ms
DNS security agent
Listed the top queried domains on the home profile for the last 7 days with their query counts.
Sources: NextDNS analytics, 1 profile
nextdns
1 report
18:29
Message Claude...

Tools your dns security agent reaches for on NextDNS, scoped per user.

CALL ANY TOOL
59 tools for DNS security in NextDNS: manage profiles, allowlists, denylists, blocklists, and parental controls, change security and privacy settings, and read logs and analytics.
nextdns_allowlist_add
Add allowlist
Add an entry to a profile's always-allowed domains by domain. Returns data, meta. Use nextdns_allowlist_remove to remove it.
Parameters
Name
Type
Required
Description
id
string
Required
The domain to add, e.g. goodwebsite.com. Example: goodwebsite.com
profile
string
Required
NextDNS profile ID (the 6-character ID in the dashboard URL, e.g. abc123). List profiles with nextdns_profiles_list. Example: abc123
active
boolean
Optional
Whether the entry is active. Example: true
nextdns_allowlist_list
List allowlist
nextdns_allowlist_remove
Remove allowlist
nextdns_allowlist_toggle
Allowlist toggle
nextdns_analytics_destinations_get
Get analytics destinations
nextdns_analytics_dnssec_get
Get analytics dnssec
nextdns_analytics_ip_versions_get
Get analytics ip versions
nextdns_analytics_protocols_get
Get analytics protocols
nextdns_analytics_series_get
Get analytics series
nextdns_block_page_settings_update
Update block page settings
nextdns_blocked_tlds_add
Add blocked tlds
nextdns_blocked_tlds_list
List blocked tlds
nextdns_blocked_tlds_remove
Remove blocked tlds
nextdns_denylist_add
Add denylist
nextdns_denylist_list
List denylist
nextdns_denylist_remove
Remove denylist
nextdns_denylist_toggle
Denylist toggle
nextdns_logs_download_get
Get logs download
nextdns_native_tracking_list
List native tracking
nextdns_parental_categories_add
Add parental categories
nextdns_parental_categories_remove
Remove parental categories
nextdns_parental_categories_toggle
Parental categories toggle
nextdns_parental_control_get
Get parental control
nextdns_parental_control_update
Update parental control
nextdns_parental_services_list
List parental services
nextdns_privacy_update
Update privacy
nextdns_profile_create
Create profile
nextdns_profile_delete
Delete profile
nextdns_profile_get
Get profile
nextdns_security_update
Update security

For more tools, view docs.

Build your Agent
Same auth pattern across LangChain, OpenAI, Anthropic, and Google ADK.
Python · LlamaIndex
import { ScalekitClient } from "@scalekit-sdk/node";
import { createReactAgent } from "@langchain/langgraph/prebuilt";

const sk = new ScalekitClient(env.SCALEKIT_ENV_URL, env.SCALEKIT_CLIENT_ID, env.SCALEKIT_CLIENT_SECRET);

// NextDNS tools scoped to this user
const { tools } = await sk.tools.listScopedTools("user_123", {
  filter: { connectionNames: ["nextdns"], toolNames: [
    "nextdns_profiles_list",
    "nextdns_denylist_add",
    "nextdns_analytics_domains_get"] },
  pageSize: 100,
});

const agent = createReactAgent({ llm, tools });
await agent.invoke({ messages: [{ role: "user", content: "List my profiles, add ads.example.com to the denylist on my home profile, and show its top queried domains" }] });
import OpenAI from "openai";
import { ScalekitClient } from "@scalekit-sdk/node";

const sk = new ScalekitClient(env.SCALEKIT_ENV_URL, env.SCALEKIT_CLIENT_ID, env.SCALEKIT_CLIENT_SECRET);
const openai = new OpenAI();

const { tools } = await sk.tools.listScopedTools("user_123", {
  filter: { connectionNames: ["nextdns"] }, pageSize: 100,
});

const res = await openai.chat.completions.create({
  model: "gpt-5",
  messages: [{ role: "user", content: "List my profiles, add ads.example.com to the denylist on my home profile, and show its top queried domains" }],
  tools,
});

// Execute the tool call with the user's vaulted NextDNS API key
await sk.tools.executeTool(res.choices[0].message.tool_calls[0], "user_123");
import Anthropic from "@anthropic-ai/sdk";
import { ScalekitClient } from "@scalekit-sdk/node";

const sk = new ScalekitClient(env.SCALEKIT_ENV_URL, env.SCALEKIT_CLIENT_ID, env.SCALEKIT_CLIENT_SECRET);
const anthropic = new Anthropic();

const { tools } = await sk.tools.listScopedTools("user_123", {
  filter: { connectionNames: ["nextdns"] }, pageSize: 100,
});

const msg = await anthropic.messages.create({
  model: "claude-sonnet-5",
  max_tokens: 1024,
  messages: [{ role: "user", content: "List my profiles, add ads.example.com to the denylist on my home profile, and show its top queried domains" }],
  tools,
});

// Tool call runs with the user's vaulted NextDNS API key
await sk.tools.executeTool(msg.content, "user_123");
import { Agent } from "@google/adk/agents";
import { ScalekitClient } from "@scalekit-sdk/node";

const sk = new ScalekitClient(env.SCALEKIT_ENV_URL, env.SCALEKIT_CLIENT_ID, env.SCALEKIT_CLIENT_SECRET);

const { tools } = await sk.tools.listScopedTools("user_123", {
  filter: { connectionNames: ["nextdns"] }, pageSize: 100,
});

const agent = new Agent({
  name: "dns_security_agent",
  model: "gemini-2.5-pro",
  instruction: "NextDNS tools scoped to this user",
  tools,
});

await agent.run("List my profiles, add ads.example.com to the denylist on my home profile, and show its top queried domains");
Try these prompts
Copy any prompt into your agent. Each maps directly to a NextDNS tool. Click to copy, paste into your agent, done.
Profiles and lists
Copy the prompt
Copied
List my NextDNS profiles.
Copy the prompt
Copied
Add ads.example.com to the denylist on my home profile.
Copy the prompt
Copied
Add a blocklist to my work profile.
Security and parental controls
Copy the prompt
Copied
Show the security settings on my home profile.
Copy the prompt
Copied
Block social networks on my kids profile.
Copy the prompt
Copied
Turn on the TLD blocking for the .zip domain.
Logs and analytics
Copy the prompt
Copied
Show the last 20 blocked queries on my home profile.
Copy the prompt
Copied
Which devices made the most queries this week?
Copy the prompt
Copied
Show query counts by destination country.
SEE HOW AUTH WORKS
Each user connects their own NextDNS API key once, and Scalekit sends it with every call. Keys stay vaulted, every call is scope checked, and every action is logged.
1
Authorize
Your user connects
NextDNS
once. We tie it to their identity and the access they approved, with no shared bot account and no org-wide access
Who:
user ‘A’
when:
Once per user
access:
Limited to user
2
Store
Their
NextDNS
credential lives in a vault scoped to them. User A's data is never reachable by an agent acting for user B, even on the same connection
vault:
encrypted
scope:
per-user
tenants:
isolated
3
Resolve
When your agent calls a
NextDNS
tool, we fetch the right credential server-side. It never touches your agent, never appears in the LLM context, never shows up in your logs
speed:
~40ms
check:
before every call
seen by:
nobody
4
Audit
Every
NextDNS
tool call is logged: who triggered it, which tool ran, what came back. 90 days of history, tied to the user who authorized it
history:
90 days
export:
SIEM-ready
logged:
every call
Test other agents
See the same per-user auth pattern across other monitoring connectors.
Engineering Teams
DevOps assistant agent
Polls GitHub for failing checks and stale PRs, opens Linear issues for the ones that need work, and posts a daily digest to Slack. It acts as the engineer, not a shared service account.
Test other agents
See the same per-user auth pattern across other monitoring connectors.
ENGINEERING
DevOps assistant agent
Poll GitHub for failing checks and stale pull requests, open Linear issues for the ones that need work, and digest to Slack.
Why Scalekit
Secure your agent's access. Connectors ship in minutes
01.
Shared tokens break per-user analytics
A shared NextDNS API key looks fine in a demo. In production every filter change looks like one service account, and you cannot tell which user triggered it. Scalekit resolves the credential of the actual user who triggered the agent, never a shared bot.
// shared key
audit → bot_service_account

// scalekit
audit → user_abc ✓
02.
Authentication is not authorization
03.
Multi-tenancy is architectural
04.
NextDNS today. Ten connectors tomorrow.
“Our agents act across Salesforce, Gong, Google Drive, and more, on behalf of every customer. Scalekit behind the scenes meant we can keep adding tools without ever rebuilding how credentials or tool calling work.”
Venu Madhav Kattagoni
Head of Engineering / Von
FAQs
Frequently Asked Questions
Does the agent access NextDNS as the user or through a shared key?
As the user. Each user connects their own NextDNS API key once, and Scalekit sends it with every call. Audit logs attribute every list and settings change to that user, not a shared service account.
Where is the NextDNS API key stored?
In Scalekit's managed AES-256 token vault, namespaced per tenant. To rotate it, the user reconnects with a new API key. Revocation is a single dashboard action. Credentials never appear in prompts, logs, or LLM context.
Can I limit what the agent does in NextDNS?
Yes. Filter by tool name in listScopedTools to expose only what you want, for example the analytics and list tools without nextdns_logs_clear, which deletes all of a profile's query logs, or nextdns_profile_delete, which deletes a profile and its logs. Scalekit also enforces scope checks before every API call.
What happens when a user revokes NextDNS access?
The connection is invalidated on the next tool call. Subsequent requests for that user fail closed with a clear error. Other users in the tenant remain unaffected. The event is logged for audit.
Can the agent read DNS query logs?
Yes. nextdns_logs_list returns a profile's DNS query logs, newest first, filtered by date, device, and status. nextdns_logs_download_get downloads them, and nextdns_logs_settings_get shows how logging is configured. nextdns_logs_clear deletes all of a profile's logs and cannot be undone.
Start in your coding agent
Up and running in one command
Install the Scalekit skill in your editor of choice. Connector, auth, tools, prompt, all wired up
Claude Code REPL
/plugin marketplace add scalekit-inc/claude-code-authstack
/plugin install agentkit@scalekit-auth-stack
Cursor Code REPL
# ~/.cursor/mcp.json
{
""mcpServers"": {
""nextdns"": {
""url"": ""https://mcp.scalekit.com/nextdns"",
""headers"": { ""Authorization"": ""Bearer $SCALEKIT_TOKEN"" }
}
}
}
Codex Code REPL
# ~/.codex/config.toml
[mcp_servers.nextdns]
url = ""https://mcp.scalekit.com/nextdns""
auth_env = ""SCALEKIT_TOKEN""
Copilot Code REPL
# .vscode/mcp.json
{
""servers"": {
""nextdns"": {
""url"": ""https://mcp.scalekit.com/nextdns"",
""type"": ""http""
}
}
}