A .NET MCP server for MTG deckbuilding with Scryfall data and Archidekt writeback.
Copy the AI prompt to install this server into Claude Code, Cursor, or another agent β or use 1-click editor setup below.
π‘ Paste the JSON block into your client's configuration file under mcpServers, then restart the application.
mtg-mcp gives an LLM grounded Magic: The Gathering card, deck, provider, and
statistical evidence. The LLM makes deckbuilding decisions.
The clean-break 0.9.0 server uses stdio. It exposes 96 tools, one
capability resource, and no prompts. It does not migrate 0.8.x data or tool
schemas.
The evidence-first rewrite is complete. 0.9.0 is the first stable release of
the new surface.
| Capability | Tools | Default | Storage or writes |
|---|---|---|---|
| Local decks and interchange | 28 | Yes | Local |
| Scryfall evidence | 18 | Yes | Local cache and card data |
| Exact statistics | 8 | Yes | No |
| Archidekt | 23 | No | Remote |
| Playgroup | 16 | No | Remote |
| Commander Spellbook evidence | 3 | No | Local cache only |
The packaged acceptance run before the Spellbook addition passed 88 tool calls. Two Scryfall card-data download operations are fixture-backed, Scryfall rollback awaits a second provider generation, and two Playgroup writes remain fixture-only because the public API has no cleanup. Commander Spellbook has its own bounded, read-only live check. See live acceptance.
Bootstrap the repository, then run the MCP smoke test:
On Linux or macOS:
Bootstrap installs Mise when needed. Mise installs Task and PowerShell from
mise.toml and the .NET SDK from global.json in an isolated tool directory.
After bootstrap, run task <command> normally. The Taskfile invokes Mise for
.NET; if a fresh shell cannot find Task, activate Mise or temporarily use
mise exec -- task <command>.
Committed Mise and NuGet lock files keep setup repeatable. Version pins live in
mise.toml, global.json, Directory.Packages.props, and dotnet-tools.json.
Use task deps:check to inspect available updates. Use task deps:update only
when you intend to review the related pin and lock-file changes.
Use mtg-mcp as the MCP command. The default invocation is equivalent to:
Use --smoke for a one-shot configuration check. It does not start an MCP
session.
Modes control authority.
| Mode | Reads | Local writes | Remote writes |
|---|---|---|---|
read-only | Yes | No | No |
local | Yes | Yes | No |
remote | Yes | Yes | Yes |
local is the default. Scryfall cache misses can require a local write for
pacing and evidence persistence. In read-only, those misses return
local-write-required before HTTP.
Commander Spellbook reads are available in all three modes. They never change a deck or make a write request to the source. Successful responses use a short-lived local cache so repeated exact requests do not create needless provider traffic.
Toolsets control relevance. They do not grant authority.
| Value | Result |
|---|---|
default or omitted | Enable decks, scryfall, and stats |
all | Enable every implemented toolset |
none | Expose no tools |
| Comma-separated list | Enable the exact named toolsets |
Available toolsets are decks, scryfall, stats, archidekt, playgroup,
and spellbook. Selection is fixed for the MCP session.
| Profile | read-only | local | remote |
|---|---|---|---|
default | 32 | 54 | 54 |
all | 60 | 83 | 96 |
none | 0 | 0 | 0 |
Read mtg://server/capabilities to inspect the active mode, toolsets, counts,
credential state, package version, and data-store state. Reading the resource
does not contact a provider.
Pass configuration on the command line, in environment variables, or in an
optional mtg-mcp.json in the working directory. Command-line values win over
environment values. Environment values win over JSON.
| Setting | Command line | Environment | JSON key |
|---|---|---|---|
| Operation mode | --mode | MTGMCP__MODE | MODE |
| Toolsets | --toolsets | MTGMCP__TOOLSETS | TOOLSETS |
| Data root | --data-dir | MTGMCP__DATA_DIR | DATA_DIR |
| Scryfall TTL | --scryfall-ttl-hours | MTGMCP__SCRYFALL_TTL_HOURS | SCRYFALL_TTL_HOURS |
| Commander Spellbook TTL | --spellbook-ttl-minutes | MTGMCP__SPELLBOOK__TTL_MINUTES | SPELLBOOK_TTL_MINUTES |
The default data root is the platform application-data directory under
mtg-mcp/v0.9. All MCP processes that use the same root reuse decks.db and
scryfall.db. Reads do not create the root.
Use MTGMCP__ARCHIDEKT__USERNAME and MTGMCP__ARCHIDEKT__PASSWORD, or create:
The provider origin is fixed. Authentication output never contains credentials, account identity, or a credential path.
Use MTGMCP__PLAYGROUP__API_KEY, or create:
The file contains one apiKey property. The provider origin is fixed to the
official public API.
The decks toolset supports:
Every existing-deck mutation requires expectedRevision. The store is
format-neutral. Validation checks structure, not Commander legality, card
quality, or strategic fit.
Use deck_identity_reconcile_preview before apply. Resolution uses printing ID,
set and collector number, Oracle ID, then exact name. It never uses fuzzy
matching or selects an arbitrary printing.
Use deck_category_rules_validate, deck_category_rules_preview, and
deck_category_rules_apply to evaluate caller-owned tag rules. Rules can be
inline or use the transparent common-v1 preset. The MCP does not decide what a
category means.
Use deck_interchange_formats to inspect preservation limits.
| Format | Notes |
|---|---|
mtg-mcp-json-v1 | Lossless native format |
generic-text-v1 | Quantity, name, zone headings, and printing hints |
archidekt-text-v1 | Manual import plus native/category companions |
moxfield-bulk-edit-v1 | Bulk Edit text plus native/tag companions |
Provider artifacts do not perform network automation. Excluded entries remain in the native companion and are omitted from provider text.
The scryfall toolset supports search, exact card lookup, collection lookup,
prints, rulings, sets, catalogs, autocomplete, bulk metadata, tag evidence,
immutable snapshots, and explicit card-data download operations.
The local card-data store contains All Cards, Rulings, Oracle Tags, and Art Tags. Card-data downloads are explicit. They never run at startup or in the background.
Freshness policies are default, cache-only, and refresh. The default TTL
is 24 hours. Immutable snapshots do not expire.
scryfall_card_collection accepts 150 ordered lookup rows. It uses local card-data
hits first, deduplicates provider misses, and sends provider batches of at most
75. Results use stable cursor pagination.
Arbitrary Scryfall queries remain provider-authoritative. The cache reuses only the exact same request. Card facts and community tags remain separate evidence classes.
Enable the spellbook toolset for three source-evidence tools:
spellbook_variant_search returns one bounded page for an exact Commander
Spellbook query.spellbook_variant_get returns one exact source variant by ID.spellbook_deck_combos_find sends only the commander and main entries
from one exact saved deck revision, then reports the entries it skipped.The tools preserve Commander Spellbook JSON and name the source, request, retrieval time, cache state, checksum, and limits. They do not rank results, infer card roles, or recommend a combo or card change. The cache lasts 15 minutes by default; configure it with a whole number from 1 through 1,440 minutes.
The stats toolset provides eight read-only tools for:
Every probability returns an exact reduced fraction and a stable decimal. The caller supplies the population, groups, turn draws, mana capabilities, and keep rules. The MCP does not infer legality, roles, or whether a result is good.
Deck-backed statistics can select entries by entry ID, zone name, or category ID. This lets an LLM use existing Archidekt groups or deterministic categories without hiding the selected cards.
Enable the archidekt toolset. Use remote mode for remote writes.
The adapter supports owned deck list/get/create/delete, pull, push, diff, folders, and named snapshots. Apply operations require current revisions, fingerprints, and preview evidence. The MCP never chooses a conflict winner.
Requests start at least two seconds apart per configured account. The adapter
allows at most 30 starts in 60 seconds and 150 requests per tool invocation.
It stops on 403 and 429. Ambiguous mutations are not retried.
Archidekt may renumber category positions. Content equality therefore compares category identity, membership, flags, and primary assignment, not the provider-controlled numeric rank.
Enable the playgroup toolset. It exposes the pinned Public API 1.0.0 surface.
All modes include 14 safe read tools. remote adds two write tools.
No reviews yet β be the first to share how this listing worked for you.
Showcase your server listing on GitHub or your project documentation. Embed this dynamic SVG badge to highlight official listing status and live engagement.
[](https://allmcps.com/mcp/mtg-mcp)<a href="https://allmcps.com/mcp/mtg-mcp"><img src="https://allmcps.com/api/badge/mtg-mcp?style=directory" alt="MTG MCP on AllMCPs" /></a>