Skip to content
LangChain

mtg oracle for LangChain

io.github.gregario/mtg-oracle

Magic: The Gathering MCP server — cards, rules, combos, and Commander intelligence

client:LangChain transport:stdio runtime:npm

Install mtg oracle in LangChain

pip install langchain-mcp-adapters

from langchain_mcp_adapters.client import MultiServerMCPClient

client = MultiServerMCPClient({
        "mtg-oracle": {
            "transport": "stdio",
            "command": "npx",
            "args": ["-y", "mtg-oracle"],
        }
})

tools = await client.get_tools()

get_tools() returns the server's tools as LangChain tools, ready for an agent. LangChain docs

mtg oracle in other clients