dndbeyond-mcp
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@dndbeyond-mcpRoll 2d20 for initiative."
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
D&D Beyond MCP
A local Model Context Protocol server that gives Claude access to D&D Beyond character sheets, an SRD content search, a dice roller, and (optionally) your campaigns.
Heads up: D&D Beyond has no official public API. The character and campaign tools use undocumented internal endpoints that Wizards of the Coast can change or remove without notice. The spell/monster/item search uses the open-licensed Open5e SRD API, which is stable. Keep usage personal and within D&D Beyond's terms of service.
Tools
Tool | What it does | Needs auth? |
| Fetch a public character sheet by ID (stats, HP, inventory, spells) | No |
| Roll standard notation: | No |
| Search SRD spells | No |
| Search SRD monster statblocks | No |
| Search SRD magic items | No |
| List campaigns on your account | Yes (cobalt cookie) |
| Details for one campaign | Yes (cobalt cookie) |
The character tool only works if the sheet's privacy is set to Public (or Campaign Only) on
D&D Beyond. Find the character ID in the sheet URL: dndbeyond.com/characters/<ID>.
Related MCP server: dnd-oracle
Setup
Install Python 3.10+ and the dependencies:
cd dndbeyond-mcp python3 -m pip install -r requirements.txtTest that it starts (Ctrl+C to stop — it waits for a client over stdio):
python3 server.py
Testing
A smoke test verifies tool registration, the dice roller (offline), the SRD search (live), and optionally a real character sheet:
python tests/test_smoke.pyTo also test a public character sheet, pass its ID (from a
dndbeyond.com/characters/<ID> URL):
python tests/test_smoke.py --character 24998307Offline checks always run; the live SRD search is reported as SKIP (not a
failure) if you have no network. A clean run ends with smoke test passed.
Connect to Claude Desktop
Edit your Claude Desktop config file:
macOS:
~/Library/Application Support/Claude/claude_desktop_config.jsonWindows:
%APPDATA%\Claude\claude_desktop_config.json
Add this server (use the absolute path to server.py, and your real python3 path if needed):
{
"mcpServers": {
"dndbeyond": {
"command": "python3",
"args": ["/Users/seansanve/dndbeyond-mcp/server.py"],
"env": {
"DDB_COBALT_COOKIE": ""
}
}
}
}Replace the path above with wherever this folder lives on your machine. If you use a virtualenv, point
commandat that venv's python (e.g./Users/seansanve/dndbeyond-mcp/.venv/bin/python) so themcpandhttpxdependencies are available.
Restart Claude Desktop. You should see the dndbeyond tools appear. Try:
"Roll
adv d20+7for me.""Look up the fireball spell."
"Fetch D&D Beyond character 12345678."
Enabling the campaign tools (optional)
list_campaigns and get_campaign need your login session:
Log in to dndbeyond.com in your browser.
Open DevTools (F12) → Application → Cookies →
https://www.dndbeyond.com.Copy the value of the
CobaltSessioncookie.Paste it as
DDB_COBALT_COOKIEin the configenvabove (or in a local.envfile — see.env.example).
This cookie is a login secret — keep it private. It expires periodically; when the campaign tools start failing with auth errors, refresh it.
Notes & limitations
Undocumented endpoints break sometimes. If
get_characteror the campaign tools return unexpected errors, the endpoints may have changed — check D&D Beyond's network traffic in DevTools to find the current URL and updateserver.py.get_characterreturns a readable summary by default; passraw=truefor the full JSON.The campaign endpoints (
/api/campaign/stt/...) are best-effort and the least stable part of this server; they may need adjusting for your account.SRD search only covers open-licensed content, not paid D&D Beyond sourcebooks.
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/seansanve-robot/dndbeyond-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server