Skip to main content
Glama
@alltcgapi/mcp

@alltcgapi/mcp

Official

@alltcgapi/mcp

An MCP server for alltcgapi, the trading card game API. It gives an agent seven tools over one catalogue of 19 games: cards, sets, sealed products and the current Cardmarket (EUR) and TCGplayer (USD) quotes of each, every quote with its source and the date it was observed.

Games: Pokémon, Yu-Gi-Oh!, One Piece, Disney Lorcana, Digimon, Dragon Ball Super Fusion World, Flesh and Blood, Star Wars: Unlimited, Weiss Schwarz, Cardfight!! Vanguard, Riftbound, Gundam, Final Fantasy, Force of Will, Dragon Ball Super Masters, Battle Spirits Saga, Cyberpunk, Star Wars: Destiny and Dragoborne. Which of them the API serves today, and which have quotes from which source, is what atcg_get_coverage answers from a live call.

Unofficial. Not produced, endorsed, supported by or affiliated with any of the publishers of the games above. All game names and marks are trademarks of their respective owners.

Get a key

Sign up at alltcgapi.com/free-api-key: the page creates the account and shows the key. A key starts with atcg_live_ and is shown once.

Related MCP server: satorntcg-mcp-server

Install

Claude Code:

claude mcp add alltcgapi --env ALLTCG_API_KEY=your-key -- npx -y @alltcgapi/mcp

Claude Desktop, claude_desktop_config.json:

{
  "mcpServers": {
    "alltcgapi": {
      "command": "npx",
      "args": ["-y", "@alltcgapi/mcp"],
      "env": { "ALLTCG_API_KEY": "your-key" }
    }
  }
}

Cursor, .cursor/mcp.json:

{
  "mcpServers": {
    "alltcgapi": {
      "command": "npx",
      "args": ["-y", "@alltcgapi/mcp"],
      "env": { "ALLTCG_API_KEY": "${env:ALLTCG_API_KEY}" }
    }
  }
}

VS Code, .vscode/mcp.json. The top-level key is servers, and inputs keeps the key out of the committed file:

{
  "inputs": [
    { "id": "alltcg-key", "type": "promptString", "description": "alltcgapi key", "password": true }
  ],
  "servers": {
    "alltcgapi": {
      "command": "npx",
      "args": ["-y", "@alltcgapi/mcp"],
      "env": { "ALLTCG_API_KEY": "${input:alltcg-key}" }
    }
  }
}

Environment: ALLTCG_API_KEY, and ALLTCG_BASE_URL (defaults to https://api.alltcgapi.com). Node 20 or newer. Without a key the server starts and lists its tools; the calls then come back saying what is missing, except atcg_get_coverage, which still reports price coverage and refresh times from public routes.

The tools

Seven tools, not one per route. tools/list sits in the model's context on every turn, and each tool is shaped like a question, so the model does not chain four calls to answer one thing.

Tool

Answers

Credits

atcg_search_cards

Cards by name or collector number, in one game or across all of them

1

atcg_get_card

One card in full: names per language, attributes, image, Cardmarket and TCGplayer ids; optionally its quotes

1, +2 with prices

atcg_list_sets

"Every One Piece set released in 2025", by game, print line, name or release window

1 per page

atcg_list_set_cards

The cards of one set, in collector-number order

1

atcg_search_sealed

Booster boxes, packs and decks by game, set, kind, name or language

1 per 50 rows

atcg_get_prices

Every current quote of a card or a sealed product, one summary line per currency

2

atcg_get_coverage

What the API holds per game, which games have quotes from which source, and what it does not hold at all

1

Every tool is annotated readOnlyHint: true and destructiveHint: false. Nothing here writes.

Parameters are enumerated where the API would refuse a wrong value: game takes one of the 19 ids, region is WEST or EAST, source is CARDMARKET or TCGPLAYER. An id that is not a UUID is refused before any call is spent, with the name of the tool that finds one.

Reading prices correctly

A quote is one source, one variant, one language, one amount in one currency, and the day it was observed. An item usually has several, and the API returns them all rather than blending them into a single number. The tool keeps it that way:

  • Two currencies, never one figure. Cardmarket quotes are in EUR and TCGplayer quotes in USD. Nothing is converted. The result opens with one line per currency (how many quotes, from which source, how recent) and, when both are present, a line telling the model to report them apart.

  • Dates. Every quote carries as_of, a day in UTC: the API serves each source about a day behind. When the newest quote in a currency is more than seven days old, the summary line says so, so an old number is not passed off as today's.

  • Variants. LOWEST_NEAR_MINT (lowest asking price for a near mint copy) and LOWEST (lowest asking price, sealed products) are offers; MARKET (TCGplayer), AVG_7D and AVG_30D come from sales; TREND is the source's trend price.

  • Rows. language is the language of the copy that was quoted; printing separates Normal and Holofoil on TCGplayer; condition and region are set when the source states them.

  • Empty is not missing. An item with no quote returns an empty list. The catalogue has it, and no source quotes it today.

What these tools do not have

atcg_get_coverage returns these from the server rather than leaving a model to infer them:

  • No price history through these tools: they return only the latest quote of each series. The REST API serves the history of a card or a sealed product; this server has no tool for it yet.

  • No graded prices.

  • No currency conversion.

  • No individual listings, sellers or stock counts.

  • No photo recognition.

  • No rules text search and no deck legality.

  • Card name search is a prefix match on the start of the name, ignoring case, not full text.

Context discipline

Results are capped at 50 rows whatever the API allows, sent as aligned tables rather than JSON. The exact objects travel in structuredContent for clients that read it. Truncation is always announced, with the cursor to continue. Price rows are never truncated.

When a tool filters locally (a set name, a release window, a sealed product's name or language), it reads pages and keeps the matching rows, up to eight pages, and says when it stopped before the end.

Over HTTP

The package carries a second entry, dist/http-main.js, that serves the same seven tools over streamable HTTP. It is what runs behind the hosted server at https://mcp.alltcgapi.com/mcp; the stdio entry above is unchanged.

Over HTTP the server holds no key of its own. Each request carries an OAuth Bearer token. The server checks it against the API's token introspection endpoint (RFC 7662), refuses a token issued for another resource, and calls the API with it, so usage lands on the account of whoever is calling. A request without a token gets a 401 whose WWW-Authenticate header points at /.well-known/oauth-protected-resource, which names the authorization server. On this transport the tool descriptions and refusals do not mention credits or plans.

To try it from a clone, with an API key in place of an OAuth token:

npm ci && npm run build
ALLTCG_MCP_ACCEPT_API_KEYS=1 ALLTCG_MCP_PUBLIC_URL=http://localhost:8080/mcp node dist/http-main.js
claude mcp add --transport http alltcgapi-http http://localhost:8080/mcp --header "Authorization: Bearer your-key"

It is not a second bin: with two, npx -y @alltcgapi/mcp could no longer tell which one to run. ALLTCG_MCP_ACCEPT_API_KEYS is for local testing only. The other settings are PORT, ALLTCG_MCP_PUBLIC_URL, ALLTCG_OAUTH_ISSUER, ALLTCG_BASE_URL, ALLTCG_MCP_INTROSPECTION_URL, ALLTCG_MCP_PROXY_SECRET and ALLTCG_MCP_ALLOWED_HOSTS; src/http-main.ts lists their defaults.

Protocol

Built on @modelcontextprotocol/server v2. The protocol revisions it negotiates are the library's, not a claim of our own.

Build from source

npm ci
npm run typecheck
npm test

Node 20 or newer. npm test builds and runs the unit tests in tests/ against a stubbed API.

Licence

MIT. Data served by the API carries per-source terms: see alltcgapi.com/legal/attribution.

Available Tools

7 tools
atcg_get_cardGet one cardA
Read-onlyIdempotent

One card by id: game, set, number, rarity, names in every language the catalogue holds, the game attributes it carries, the image URL and its Cardmarket and TCGplayer product ids. With include_prices it also returns every current quote in the same call. 1 credit, plus 2 with include_prices. attributes are whatever the game publishes, unevenly filled: a missing attribute means we do not hold it, never that the card lacks it. If a call is refused with TRIAL_EXPIRED or QUOTA_EXCEEDED, tell the user as written and do not retry; RATE_LIMITED says how many seconds to wait.

Inputs: id (required), include_prices.

atcg_get_coverageWhat the API coversA
Read-onlyIdempotent

What the API covers, measured live: each game with its id and its set, card and sealed counts, how many cards and sealed products have a current quote from each source and how recent the newest is, when the catalogue was last refreshed, and what the API does not hold at all. Call this before telling a user what the API can or cannot answer, or which games have prices. 1 credit for the game counts; price coverage and refresh times are public and answer even without a key. If a call is refused with TRIAL_EXPIRED or QUOTA_EXCEEDED, tell the user as written and do not retry; RATE_LIMITED says how many seconds to wait.

Inputs: game.

atcg_get_pricesGet current pricesA
Read-onlyIdempotent

Every current quote for one card or one sealed product, by the id a search returned: source, variant, language of the copy, condition, printing, region, amount with its currency, and the as_of date. The result opens with one line per currency saying how many quotes and how recent. Cardmarket quotes are in EUR and TCGplayer quotes in USD. Nothing is converted: never add, average or compare a EUR figure with a USD figure as if they were one number. Report each market separately, with its currency. Every quote carries as_of, the day (UTC) the source last quoted it. Quotes are current, not live: the API serves each source about a day behind, some quotes are older, and the result says how old the newest one is. Never quote a price without its source and its as_of date. variant says what the number measures: LOWEST_NEAR_MINT is the lowest asking price for a near mint copy, LOWEST the lowest asking price in any condition (sealed products), TREND the trend price published by the source, AVG_7D and AVG_30D the average sale price over 7 or 30 days, MARKET the TCGplayer market price based on recent sales. An asking price is an offer, not a sale: say which one you quote. One item usually has several quotes: per source, per variant, per language of the copy, and on TCGplayer per printing (NORMAL, HOLOFOIL, …). Read language, condition and printing on the row you quote rather than taking the first number, and say which row it is. An empty list means no source quotes the item today, not that it does not exist. Only the latest quote of each series: this tool has no price history, and the API has no graded prices. 2 credits per call. If a call is refused with TRIAL_EXPIRED or QUOTA_EXCEEDED, tell the user as written and do not retry; RATE_LIMITED says how many seconds to wait.

Inputs: id (required), type (required), source, currency, +1 more.

atcg_list_set_cardsList the cards of a setA
Read-onlyIdempotent

The cards of one set in collector-number order, by set id or code from atcg_list_sets. A set code can exist in more than one game: pass the set id to be exact, and check the game on the first line of the result. name (start of the card name) and number narrow the list. 1 credit per call (up to 50 rows). If a call is refused with TRIAL_EXPIRED or QUOTA_EXCEEDED, tell the user as written and do not retry; RATE_LIMITED says how many seconds to wait.

Inputs: set (required), name, limit, cursor, +1 more.

atcg_list_setsList setsA
Read-onlyIdempotent

Sets newest first, with code, name, game, print line, release date, card count and id. One call answers "every One Piece set released in 2025" or "which Lorcana set is called Azurite Sea". The print line is WEST (international) or EAST (Asian prints: Japanese, Chinese, Korean); an Asian set is its own row, not a translation of a Western one. name keeps sets whose name or code contains the text. 1 credit per page: a name or date filter reads pages of 250 and keeps the matching sets, up to 8 pages. If a call is refused with TRIAL_EXPIRED or QUOTA_EXCEEDED, tell the user as written and do not retry; RATE_LIMITED says how many seconds to wait.

Inputs: game, name, limit, cursor, +3 more.

atcg_search_cardsSearch cardsA
Read-onlyIdempotent

Search trading cards by name or collector number, in one game or across every game the API serves. Returns one row per card with its id, game, set, number and rarity; pass the id to atcg_get_card or atcg_get_prices. name matches the START of the card name, ignoring case: "charizard" finds "Charizard ex" but not "Dark Charizard", and spelling, accents and punctuation must match the printed name. If nothing comes back, retry with a shorter prefix (the first word) before concluding the card is missing. Rows come back in id order, not by release date or relevance: narrow with game, set or number rather than paging through a common name. 1 credit per call (up to 50 rows). If a call is refused with TRIAL_EXPIRED or QUOTA_EXCEEDED, tell the user as written and do not retry; RATE_LIMITED says how many seconds to wait.

Inputs: set, game, name, limit, +2 more.

atcg_search_sealedSearch sealed productsA
Read-onlyIdempotent

Sealed products (booster boxes, booster packs, starter decks, tins, collections) of a game or a set, with kind, set, release date, pack count and the languages each product exists in. kind is the product kind as the catalogue writes it, e.g. BOOSTER_BOX, BOOSTER_PACK, ETB: read the values off a search rather than guessing, an unknown kind returns no rows. name keeps products whose name contains the text. 1 credit per 50 rows; a name or language filter reads pages of 100 (2 credits each) and keeps the matches, up to 8 pages. Quotes are a separate call: atcg_get_prices with type "sealed" and the id returned here. If a call is refused with TRIAL_EXPIRED or QUOTA_EXCEEDED, tell the user as written and do not retry; RATE_LIMITED says how many seconds to wait.

Inputs: set, game, kind, name, +3 more.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A4.5/5.0

    Scored across 7 tools

    Disambiguation4/5

    Each tool has a clear resource+action target (search vs. get card vs. prices vs. sets vs. sealed vs. coverage). Minor overlap: atcg_list_set_cards also accepts a name prefix like atcg_search_cards, and atcg_get_card's include_prices duplicates atcg_get_prices, but the descriptions explicitly steer agents between them.

    Naming Consistency5/5

    Every tool follows the same atcg_verb_noun pattern (get_prices, search_cards, get_card, list_sets, list_set_cards, search_sealed, get_coverage) with verbs chosen consistently by action type. No camelCase/snake_case mixing or synonym drift.

    Tool Count5/5

    Seven tools map cleanly onto the domain's distinct operations: card search/lookup, set browsing, sealed browsing, pricing, and capability discovery. Nothing appears redundant or ornamental for a read-only catalogue API.

    Completeness4/5

    The catalogue+quote lifecycle is well covered for a read-only API (search, detail, sets, sealed, prices, coverage). Gaps: atcg_get_prices handles only one id per call so bulk portfolio pricing requires many calls, and there is no get-sealed-product-by-id detail tool (only search + a priced lookup). Price history and graded prices are deliberately absent and documented.

    Maintenance

    ActivityMaintained
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • F
      license
      Not graded
      quality
      D
      maintenance
      Provides access to TCGplayer trading card data, including search, product details, pricing, and market information, enabling natural language queries for card analysis.
      1
      -
    • A
      license
      A
      quality
      B
      maintenance
      Enables LLM clients to query live TCG inventory, pricing, alerts, profit and loss, and eBay listings directly through natural language tool calls.
      11
      MIT
    • F
      license
      Not graded
      quality
      Not graded
      maintenance
      Enables AI assistants to look up trading-card market values across Pokémon, Magic, sports and other TCG catalogs, including raw prices by condition, graded ladders, price history, trending movers and set checklists. It also calculates grading ROI — gem premiums, net profit after fees, expected value and break-even gem rates — so collectors can decide whether a card is worth submitting.
      -