# Magic: The Gathering API

Oracle text, mana costs, colour identity, every frame variant and all twenty-plus format legalities.

- Slug: `magic-the-gathering`
- GraphQL enum: `MAGIC_THE_GATHERING`
- Publisher: Wizards of the Coast, released 1993
- Coverage: 37,952 cards, 108,302 printings, 973 sets
- Languages: English, German, French, Italian, Spanish, Portuguese, Japanese, Korean, Russian, Simplified Chinese and Traditional Chinese (English rows by default; `?language=<code>` for one language, `?language=all` for every printing)
- Formats: Standard, Pioneer, Modern, Legacy, Vintage, Commander, Pauper, Brawl, Alchemy, Historic
- Price sources: Cardmarket, TCGplayer, Card Kingdom, Mana Pool
- Daily price history: Cardmarket from 8 September 2026, TCGplayer from 1 August 2026, Card Kingdom from 1 August 2026 and Mana Pool from 1 August 2026. A card that joined the catalogue later starts later. Cardmarket sales by day: 99,596 English printings, half of the series beginning by July 2026 and nine in ten by September 2026; the oldest reaches August 2007.
- Every set: https://tcggraph.com/games/magic-the-gathering/sets (plain text at https://tcggraph.com/games/magic-the-gathering/sets.md)
- How it is modelled: Every finish, frame effect and promo treatment is an addressable printing with its own price series, so a Showcase foil and its regular printing never share a number.

## Overview

Magic: The Gathering invented the trading card game and still leads the market by total dollar value. TCGGraph exposes canonical Oracle text, mana value, colour identity, type lines, keyword abilities and legality across Standard, Pioneer, Modern, Legacy, Vintage, Commander and Pauper — plus every finish, frame effect and promo treatment as an addressable printing with its own price series.

## Request

```bash
curl "https://api.tcggraph.com/v1/cards?game=magic-the-gathering&limit=5" \
  -H "Authorization: Bearer $TCGGRAPH_KEY"
```

## Magic-specific fields

These live under `gameData`.

- `manaCost` (String) — Mana cost in symbol notation, e.g. {2}{U}{U}.
- `manaValue` (Float) — Converted mana cost.
- `colors` ([String]) — Colours in the mana cost.
- `colorIdentity` ([String]) — Commander-legal colour identity.
- `typeLine` (String) — Full type line including supertypes and subtypes.
- `power` (String) — Creature power. May be a character such as *.
- `toughness` (String) — Creature toughness. May be a character such as *.
- `loyalty` (String) — Starting loyalty for planeswalkers.
- `keywords` ([String]) — Parsed keyword abilities.
- `layout` (Enum) — normal, transform, modal_dfc, split, adventure, saga…
- `finishes` ([String]) — nonfoil, foil or etched: the finishes the printing was made in.

## Core fields on every card

- `id` (string) — Stable identifier, unique across every game. If a set is re-keyed the old id keeps resolving on every by-id endpoint, and the response carries `meta.movedFrom`.
- `game` (string) — The game's slug.
- `name` (string) — The English name, on every language's printing. `?name=` searches this and `printedName`.
- `language` (string) — The language this printing is in, as a code: `en`, `ja`, `de`, `zhs` and so on. The list endpoints return `en` unless `?language=` asks otherwise.
- `printedName` (string | null) — The name as printed, in the card's language (`Glurak-ex`). Null on English printings and where the source list carries no name. `?name=` searches this too.
- `englishId` (string | null) — The English printing this one corresponds to: the same set and number for a translated printing, the same illustration for a card in a set of its own (Japanese Pokémon). Null on English printings and where none has been found.
- `sameArtwork` (string[]) — The printings of this card's illustration in the other catalogue, where a language is numbered on its own and the link is by artwork (Japanese Pokémon). On a Japanese card, every English printing of the picture, nearest first, so `englishId` is the first: the expansion's, and each reprint of it in a World Championship deck, a Prize Pack, a Trainer Kit or as a Jumbo. On an English card, the Japanese printings of it. Empty where none has been found, and on games whose languages share set and number, where `englishId` is the link.
- `baseCardId` (string | null) — The card this record reprints, for a Pokémon card sold as a product of its own outside the expansions: a stamped store exclusive (`GameStop Exclusive`), a Prize Pack, Trick or Trade or World Championship deck copy. The stamped and holo ones are also listed in the base card's `printings`. Null elsewhere, and where TCGplayer lists more than one card the reprint could be.
- `pricesFrom` (string) — `own` when `prices`, `gradedPrices` and `priceStatus` are this printing's. `englishTwin` when they are the English printing's, because the marketplace sells one product across languages. `localizedTwin` on an English printing no marketplace sells in English (a Japan-only One Piece promo): they are the printing `pricesTwin` names, in its language.
- `pricesTwin` (object | null) — With `localizedTwin`, the printing quoted: its `id` and the `language` its copies are in. Null otherwise.
- `set` (CardSet) — The set the card was printed in.
- `collectorNumber` (string) — The number printed on the card, as printed (`6`, `TG12`, `OP16-077`), without the `/total`. Where several printings share one printed number (One Piece and Dragon Ball Super parallels and reprints) each carries a suffix after `_` that tells them apart: `OP05-119_p2`, `BT15-033_SPR`.
- `rarity` (string) — The publisher's rarity, as each game spells it (`Double Rare`, `uncommon`, `SR`).
- `artist` (string | null) — The illustrator credit.
- `text` (string | null) — Rules text. Null on a card with none, and on a Pokémon whose attacks and abilities are structured under `gameData` instead.
- `images` (Images) — The card's picture in three widths. On our CDN (`cards.tcggraph.io`) the URLs end in `.webp`; the same path ending in `.avif` serves AVIF. A CDN URL always serves the same picture and may be cached for good: a picture we replace goes out under a new URL, which the card's `images` then carry. Before a card is mirrored all three are the source's original URL. Image requests cost no credits.
- `imageFrom` (string) — Whose picture `images` is. `own` for the printing's scan. `englishTwin` for a localized printing in an English set its source has no scan of (older French, German, Spanish and Italian Pokémon; Magic printings Scryfall shows in English only), or that no card list carries and Cardmarket sells copies of in its language (French Prize Pack and World Championship deck cards, gold DON!! cards): the English twin's picture, so the card can be listed and priced without a scan of its own. Such a card has no `hashes` and recognition never answers it. A card in an own-language set (Japanese Pokémon) with no scan has null `images` instead.
- `hashes` (object | null) — Perceptual hashes of the artwork, for matching a photo to a printing yourself. Null until the image has been processed.
- `prices` (Price[]) — Every current quote, one per source, list type and finish. Every quote is always returned; `?source=` changes which one filters and sorts read, not what comes back.
- `gradedPrices` (GradedPrice[]) — What graded copies sell for, one entry per grader and grade the index quotes. Empty when there are none; `priceStatus.graded` says why.
- `languagePrices` (LanguagePrice[]) — Cardmarket's live listings split by language and finish, with the cheapest copy per condition. Empty until we have read the card's product page, which is not the same as nothing for sale.
- `printings` (Printing[]) — `prices` regrouped by finish: one entry per physical printing, the plain card first, each with its own picture where a marketplace shows one.
- `priceStatus` (PriceStatus) — Why each source does or does not quote this card.
- `legalities` (map<string, string>) — Format to status. Formats are each game's own (`standard`, `commander`, `tcg`, `core`). Statuses are `legal`, `not_legal`, `banned` and `restricted`, except on Yu-Gi-Oh!, which uses its Forbidden & Limited list: `unlimited`, `semi_limited`, `limited`, `forbidden`. A format the card has never been legal in may be absent rather than `not_legal`. Empty on One Piece, Star Wars: Unlimited, Digimon, Grand Archive and Dragon Ball Super, whose catalogue sources publish none. Read it, don't filter on it: `/v1/cards` has no legality filter, except Yu-Gi-Oh!'s `banlist.tcg` and `banlist.ocg` game fields.
- `gameData` (object) — The game-specific fields: HP and attacks on Pokémon, mana cost and colours on Magic, ATK and DEF on Yu-Gi-Oh!. Each game's fields are listed on its game page and returned by `GET /v1/games/{slug}` as `schema`, and each one is a filter on `/v1/cards`.
- `externalIds` (ExternalIds) — The marketplace products this printing is sold as, for joining to their data.

## Notable sets

- Limited Edition Alpha (`LEA`) — 295 cards, 1993-08-05
- Urza's Saga (`USG`) — 350 cards, 1998-10-12
- Modern Horizons 3 (`MH3`) — 303 cards, 2024-06-14
- Final Fantasy (`FIN`) — 309 cards, 2025-06-13
- Marvel's Spider-Man (`SPM`) — 286 cards, 2025-09-26

Every Magic set the catalogue holds, with its code, release date and card count: https://tcggraph.com/games/magic-the-gathering/sets.md

## FAQ

**Is Oracle text kept up to date with rules updates?**

Oracle text, the card's text field, is re-read from Scryfall's bulk data on every ingest, so an errata lands with the next run. A change fires a card.updated webhook whose changed array names the fields that moved. The previous wording is not kept: store it on your side if you need to diff.

**Can I query a specific printing rather than the card?**

A card record is a printing: each set, collector number and language is its own id, with its own artist, image and prices, and finishes of that printing are separate quotes under prices and printings. There is no id grouping every printing of a card; search by name to gather them.

**Are double-faced cards handled properly?**

They are one record per printing, with the faces joined by " // " in name, gameData.typeLine and text ("Invasion of Tarkir // Defiant Thundermaw"), and gameData.layout saying which kind it is: transform, modal_dfc, split, adventure and so on. There is no per-face array; manaCost, power and toughness are the front face's.

**How far back does Magic price history go?**

Daily price history: Cardmarket from 8 September 2026, TCGplayer from 1 August 2026, Card Kingdom from 1 August 2026 and Mana Pool from 1 August 2026. A card that joined the catalogue later starts later. Cardmarket sales by day: 99,596 English printings, half of the series beginning by July 2026 and nine in ten by September 2026; the oldest reaches August 2007. Measured on 15 November 2026; every series grows by a day, every day.

## Related

- [Every Magic: The Gathering set in the API](https://tcggraph.com/games/magic-the-gathering/sets)
- [Most valuable Magic: The Gathering cards and their prices](https://tcggraph.com/games/magic-the-gathering/cards)
- [Magic: The Gathering card scanner API](https://tcggraph.com/recognition/magic-the-gathering)
- [Pokémon TCG API](https://tcggraph.com/games/pokemon)
- [One Piece TCG API](https://tcggraph.com/games/one-piece)
- [Yu-Gi-Oh! API](https://tcggraph.com/games/yugioh)
- [Disney Lorcana API](https://tcggraph.com/games/disney-lorcana)
- [Star Wars: Unlimited API](https://tcggraph.com/games/star-wars-unlimited)
- [Digimon Card Game API](https://tcggraph.com/games/digimon)
- [Grand Archive TCG API](https://tcggraph.com/games/grand-archive)
- [Dragon Ball Super Card Game API](https://tcggraph.com/games/dragon-ball-super)

---

Canonical page: https://tcggraph.com/games/magic-the-gathering
Full machine-readable reference: https://tcggraph.com/llms-full.txt
