4,500+ servers built on MCP Fusion
Vinkius
AdGuard Home logo
Vinkius
LangChain logo

How to Use the AdGuard Home MCP in LangChain

Build LangChain agents that analyze query logs and rewrite DNS rules in real time to stop network threats.

See Vinkius in Action

Works with every AI agent you already use

…and any MCP-compatible client

AdGuard Home MCP on Cursor AI Code Editor MCP Client AdGuard Home MCP on Claude Desktop App MCP Integration AdGuard Home MCP on OpenAI Agents SDK MCP Compatible AdGuard Home MCP on Visual Studio Code MCP Extension Client AdGuard Home MCP on GitHub Copilot AI Agent MCP Integration AdGuard Home MCP on Google Gemini AI MCP Integration AdGuard Home MCP on Lovable AI Development MCP Client AdGuard Home MCP on Mistral AI Agents MCP Compatible AdGuard Home MCP on Amazon AWS Bedrock MCP Support
MCP Servers - Free for Subscribers
LangChain

Connect AdGuard Home MCP to LangChain

Create your Vinkius account to connect AdGuard Home to LangChain and route execution through our secure gateway. The platform manages server hosting, runtime updates, and security layers. Configuration requires no manual server provisioning.

GDPR Free for Subscribers

Automate DNS Threat Response with LangChain

The `get_query_log` tool lets your LangChain agents trace bad traffic patterns and immediately block them. Inspect the domains and pass them to your decision chain. If the chain flags a domain, it triggers `add_filter_url` or `set_user_rules` instantly. This setup turns passive logging into active defense. Your agent evaluates the logs, runs its reasoning loop, and updates your network blocklist without you writing custom glue code.

Dynamic DHCP and Client Provisioning via MCP Server

Using `get_dhcp_status` allows you to keep your network database updated during automated deployment workflows. When a new device connects, your LangChain chain calls the tool to find empty slots. It then uses `add_static_lease` and `add_client` to register the hardware. LangSmith traces every step of this configuration process, showing you the exact payload sent to your AdGuard Home instance. You see exactly how the agent mapped the MAC address to the static IP.

Smart Service Blocking Schedules

The `update_blocked_services` tool lets you schedule parental or focus controls without rigid cron jobs. With this MCP Server, your agent reads your calendar or team status, then invokes the tool to toggle access to distracting platforms. The agent checks current network load with `get_stats` before changing rules. If it detects heavy traffic, it waits or alerts you before running `set_protection` to toggle global filters.

Setup guide

Set up AdGuard Home MCP in LangChain

Prerequisites

  • Python 3.10+ installed
  • langchain-mcp-adapters + langgraph packages
  • Active Vinkius subscription with a valid endpoint token
  1. 1

    Install dependencies

    Run pip install langchain-mcp-adapters langgraph langchain-openai. The MCP adapters package converts MCP tools into native LangChain BaseTool objects.

  2. 2

    Connect via HTTP transport

    Use MultiServerMCPClient with "transport": "http" pointing to your Vinkius endpoint. Replace [YOUR_TOKEN_HERE] with your token from cloud.vinkius.com.

  3. 3

    Create a ReAct agent

    Pass the discovered tools to create_react_agent() from LangGraph. The agent automatically routes AdGuard Home tool calls through the MCP protocol.

  4. 4

    Run with any LLM

    Swap ChatOpenAI for ChatAnthropic, ChatGoogleGenerativeAI, or any LangChain-compatible model. The MCP tools work identically across all providers.

agent.py
from langchain_mcp_adapters.client import MultiServerMCPClient
from langgraph.prebuilt import create_react_agent
from langchain_openai import ChatOpenAI

async with MultiServerMCPClient({
    "adguard-home-mcp": {
        "transport": "http",
        "url": "https://edge.vinkius.com/[YOUR_TOKEN_HERE]/mcp",
    }
}) as client:
    tools = client.get_tools()

    agent = create_react_agent(
        ChatOpenAI(model="gpt-4o"),
        tools,
    )
    result = await agent.ainvoke({
        "messages": "List recent AdGuard Home transactions"
    })
    print(result["messages"][-1].content)

Independent Platform Disclaimer: Vinkius is an independent platform and is not affiliated with, endorsed by, sponsored by, verified by, or otherwise authorized by AdGuard Home. All third-party trademarks, logos, and brand names are the property of their respective owners. Their use on this website is strictly for informational purposes to identify service compatibility and interoperability.

Why Choose Vinkius

Vinkius connects your tools to AI with real-time monitoring and automatic cost savings — all from one dashboard.

Real-time monitoring

Live

visibility into every interaction

Connect your favorite tools to your AI and see exactly what's happening — every request, every response, in real time.

Built-in savings

60%

lower AI costs

Vinkius compresses data between your apps and your AI automatically. Lower bills every month — no configuration required.

Single dashboard

One

place for every integration

Every tool your AI connects to, managed from a single screen. One account, complete control.

Common questions about AdGuard Home MCP in LangChain

Install the MCP adapters via pip. Initialize the MultiServerMCPClient with the Vinkius endpoint, retrieve the tools, and pass them to your agent constructor.
Yes, by using `add_rewrite` and `list_rewrites` in its tool loop. The agent inspects existing rules first to prevent duplicate entries or circular routing.
LangSmith logs every DNS tool execution, such as `check_host` or `get_dns_info`. You can inspect the precise parameters passed by the LLM and the raw JSON response from your router.
Yes, LangChain's multi-server client aggregates tools from different endpoints. You can run `get_status` across multiple networks and sync their blocklists simultaneously.
The MCP Server reads DNS query logs, client IP addresses, and MAC addresses. Since Vinkius runs in a secure sandbox, this sensitive network traffic data stays isolated and never leaks to public training sets.

Start using the AdGuard Home MCP today

We host it, we monitor it, we maintain it. You just paste one token.

Built & Managed by Vinkius 30s setup 23 tools

We've already built the connector for AdGuard Home. Just plug in your AI agents and start using Vinkius.

No hosting. No infrastructure. No complex setup.
All 23 tools are live and waiting. You're up and running in seconds.

Claude Claude
ChatGPT ChatGPT
Cursor Cursor
Gemini Gemini
Windsurf Windsurf
VS Code VS Code
JetBrains JetBrains
Vercel Vercel
+ other MCP clients

Vinkius gives your AI agents access to the full catalog of app connectors, all fully managed, secure, and enterprise-ready. One subscription, every tool you need.

Zero hosting required Full MCP catalog included Enterprise-grade security Auto-updated by Vinkius

Built, hosted, and secured by Vinkius. You just connect and go.