# alltcgapi: full text > A REST API for trading card games. Pokémon, Yu-Gi-Oh!, One Piece, Lorcana, Digimon, Flesh and Blood, Star Wars: Unlimited and twelve more: cards, sets, sealed products and current prices through one contract, one key and one response shape. Base URL: https://api.alltcgapi.com Status: open for sign-up. Keys are self-service: a free account gets one at once, with no card. Trial: 800 credits, granted once, at most 200 a day. Price history: one point per series per day on /v1/cards/{id}/prices/history and /v1/sealed/{id}/prices/history. How far back a key reads depends on its plan. Not served: graded prices, recognition of a card from a photo, currency conversion. Integrations: Not published yet, as of 2026-11-19: the MCP server (@alltcgapi/mcp on npm, hosted at https://mcp.alltcgapi.com/mcp) and the SDKs (@alltcgapi/sdk, alltcgapi on PyPI, github.com/alltcgapi/sdk-go). Their install commands fail today. Use the REST API directly, or generate a client from https://alltcgapi.com/openapi.json. Machine-readable files: - OpenAPI: https://alltcgapi.com/openapi.json - Coverage, read from the API with its date: https://alltcgapi.com/coverage.json - Short index: https://alltcgapi.com/llms.txt - Changelog feed (Atom): https://alltcgapi.com/changelog.xml - Blog feed (Atom): https://alltcgapi.com/blog.xml ## Games Counts below are the snapshot of 2026-11-19 in the site source, not a live reading. ### Pokémon TCG (game=pokemon) Page: https://alltcgapi.com/pokemon-tcg-api Snapshot 2026-11-19: 653 sets, 58,481 cards, 2,098 sealed products. Every Pokémon card with its set, number, rarity and artwork. Western releases and the Asian print lines sit in the same catalogue, told apart by region. - Two print regions: Use region=WEST or region=EAST on /v1/sets. An Asian set is its own set, not a translation of the English one. - The printing, not the species: A card is one printing: set, collector number and rarity. Keep the returned id; it never changes. - Game attributes: HP, types and subtypes arrive in attributes, the same field every game uses for its own rules data. ### Yu-Gi-Oh! Trading Card Game (game=yugioh) Page: https://alltcgapi.com/yugioh-tcg-api Snapshot 2026-11-19: 125 sets, 16,150 cards, 0 sealed products. Monsters, spells and traps from the English-language TCG, one record per printing. A card printed at Ultra, Starlight and Grand Master Rare is three cards, each with its own id and image. - Set codes as printed: MAMS-EN001 is the code in the corner of the card and the number in the API. Another rarity of the same card adds a letter: MAMS-EN001a, MAMS-EN001b. - The frame in supertype: Effect Monster, Xyz Monster, Field Spell or Counter Trap arrives in supertype. The attribute, LIGHT or DARK, arrives in attributes.types. - Stats in attributes: attack, defense and monsterType arrive in attributes, next to the fields every game shares. ### One Piece Card Game (game=onepiece) Page: https://alltcgapi.com/one-piece-tcg-api Snapshot 2026-11-19: 111 sets, 9,639 cards, 168 sealed products. Leaders, characters, events and stages from every booster set and starter deck, with the card number collectors actually search for. - Card numbers as printed: OP01-001 is the number on the card and the number in the API. Filter with number= to find a printing. - Sets and decks alike: Booster sets, starter decks and promo sets are all sets: one list, one shape. - Colours in attributes: Card colours arrive in attributes.types, the same field Pokémon uses for its types. ### Disney Lorcana (game=lorcana) Page: https://alltcgapi.com/lorcana-tcg-api Snapshot 2026-11-19: 19 sets, 3,261 cards, 56 sealed products. Characters, actions, items and locations from The First Chapter onward, with set codes, collector numbers, rarities and artwork. - Chapters as sets: Each chapter is a set with its own code, release date and card total. - Collector numbers: Cards come back in collector-number order within a set, special printings included. - Rules data in attributes: Game-specific data arrives in attributes, alongside the fields every game shares. ### Digimon Card Game (game=digimon) Page: https://alltcgapi.com/digimon-card-game-api Snapshot 2026-11-19: 104 sets, 9,539 cards, 0 sealed products. Digi-Eggs, Digimon, Tamers and Options from booster sets, starter decks and limited packs, with the number, colour, level and form a deck builder needs. - Card numbers as printed: BT27-002 is the number on the card and in the API. Filter with number= to find every printing of it. - The card kind in supertype: Digi-Egg, Digimon, Tamer or Option arrives in supertype; the colour arrives in attributes.types. - Level and form: level, form (In-Training, Rookie and up) and digimonTypes arrive in attributes when the card has them. ### Dragon Ball Super Card Game Fusion World (game=dragonball-fw) Page: https://alltcgapi.com/dragon-ball-fusion-world-api Snapshot 2026-11-19: 51 sets, 4,373 cards, 0 sealed products. Leaders, Battle and Extra cards from the Fusion World boosters and starter decks, with power, traits and colour on each printing. - Card numbers as printed: FB11-001 is the number on the card and in the API. Its alternate art adds a letter: FB11-001a. - Leader, Battle or Extra: The card type arrives in supertype and the colour in attributes.types. - Power and traits: A leader carries both sides of its power (15000/20000) and its traits, such as Saiyan, in attributes. ### Flesh and Blood (game=fab) Page: https://alltcgapi.com/flesh-and-blood-tcg-api Snapshot 2026-11-19: 110 sets, 10,809 cards, 0 sealed products. Heroes, weapons, equipment, actions and reactions from booster sets, armory decks and mastery packs, one record per printing. - Collector numbers: MPB001 is the collector number in the API. A Marvel or alternate printing adds a letter: MPB002a. - Heroes and their kit: Hero, Weapon, Equipment, Action, Instant or Defense Reaction: the card type arrives in supertype. - Decks are sets too: Armory decks and mastery packs have their own codes (FAB-AMO, FAB-MPA) and their own card lists. ### Star Wars: Unlimited (game=swu) Page: https://alltcgapi.com/star-wars-unlimited-api Snapshot 2026-11-19: 32 sets, 9,743 cards, 0 sealed products. Leaders, bases, units, events and upgrades from every set, with weekly play, convention and partner promos kept in sets of their own. - Numbers with the set size: Card numbers carry the printed total: 1/194, 100/194. - The card type in supertype: Leader, Base, Unit, Event, Upgrade or Token arrives in supertype. - Promos as sets: Weekly play and convention promos are their own sets, such as SWU-HMWP next to Homeworlds. ### Weiss Schwarz (game=weissschwarz) Page: https://alltcgapi.com/weiss-schwarz-api Snapshot 2026-11-19: 171 sets, 31,639 cards, 0 sealed products. English Weiss Schwarz boosters, premium boosters and trial decks, one set per release: characters, climaxes and events, each printing with its own number and image. - Card numbers as printed: UMA/W119-E001 is the code on the card and in the API. SP and SR printings keep their suffix: UMA/W119-E001SP. - Character, Climax, Event: The card type arrives in supertype and the colour in attributes.types. - A set per release: Each booster or premium booster is a set, named after its title and volume. ### Cardfight!! Vanguard (game=vanguard) Page: https://alltcgapi.com/cardfight-vanguard-api Snapshot 2026-11-19: 269 sets, 26,709 cards, 0 sealed products. English Vanguard releases, booster sets, start decks and title boosters, with the number and rarity printed on each card. - Card numbers as printed: DZ-BT17/001EN is the number on the card and in the API, language suffix included. - Rarity as printed: RRR, RR, R and the special rarities arrive in rarity exactly as the card shows them. - Start decks are sets: Start decks and title boosters have their own codes, like the booster sets. ### Riftbound (game=riftbound) Page: https://alltcgapi.com/riftbound-tcg-api Snapshot 2026-11-19: 8 sets, 1,201 cards, 13 sealed products. Legends, champion units, spells, gear, runes and battlefields from Origins onward, with set codes, collector numbers, rarities and artwork. - Domains in attributes: The domains of a card arrive in attributes.types. A dual-domain card carries both. - Card type as supertype: Legend, Champion Unit, Unit, Spell, Gear, Rune or Battlefield: one field, on every card. - Promos are sets too: Organized play, judge and promotional cards have their own sets, apart from the main releases. ### Gundam Card Game (game=gundam) Page: https://alltcgapi.com/gundam-card-game-api Snapshot 2026-11-19: 27 sets, 2,201 cards, 0 sealed products. Units, pilots, commands, bases and resources from every booster and starter deck, with colour and rarity on each printing. - Numbers as printed, reprints included: GD05-123 is the number on the card. A card reprinted in a later set keeps its original number, so GD06 can hold a GD02 card. - Plus rarities: Parallel printings carry the plus rarity printed on them: R+, U+, C+. - The card type in supertype: Unit, Pilot, Command, Base, Resource and the EX cards arrive in supertype, the colour in attributes.types. ### Final Fantasy Trading Card Game (game=fftcg) Page: https://alltcgapi.com/final-fantasy-tcg-api Snapshot 2026-11-19: 38 sets, 5,703 cards, 0 sealed products. Forwards, Backups, Summons and Monsters from the opus sets, starter sets and championship decks, with the card number that carries its rarity. - Numbers with the rarity: 1-018L is the number on the card: opus, card and rarity letter. The API keeps it whole. - The card type in supertype: Forward, Backup, Summon or Monster arrives in supertype. - Reprints stay apart: A card reprinted in a deck or a later set is a separate printing with its own id. ### Force of Will (game=fow) Page: https://alltcgapi.com/force-of-will-tcg-api Snapshot 2026-11-19: 103 sets, 13,733 cards, 0 sealed products. Rulers, resonators, spells, additions, regalia and magic stones from booster sets and collections, with the attribute of each card. - Card numbers as printed: CPB-001 is the number on the card and in the API. - The card type in supertype: Ruler, Resonator, Magic Stone, Regalia, Rune and the other types arrive in supertype. - Attribute in types: Light, Fire, Water, Wind and Darkness arrive in attributes.types. ### Dragon Ball Super Card Game Masters (game=dragonball-masters) Page: https://alltcgapi.com/dragon-ball-super-masters-api Snapshot 2026-11-19: 100 sets, 11,591 cards, 0 sealed products. The original Dragon Ball Super Card Game, now called Masters: booster sets up to Impact Beyond Dimensions, with release event, judge and tournament cards kept in sets of their own. - Leader, Battle, Extra, Unison: The card type arrives in supertype, Z- types included: Z-Leader, Z-Battle, Z-Extra. - Promos apart: Release event, judge and tournament cards have their own sets (DBM-BT31-PR, DBM-JPR, DBM-TPR). - Merit and championship cards: Tournament prize cards are in the catalogue with their own ids, next to the playable cards. ### Battle Spirits Saga (game=battlespirits) Page: https://alltcgapi.com/battle-spirits-saga-api Snapshot 2026-11-19: 20 sets, 1,841 cards, 0 sealed products. Spirits, nexuses and magic cards from the English Battle Spirits Saga boosters, starter decks and collaboration boosters, up to Generational Link. - Card numbers as printed: BSS06-001 is the number on the card and in the API. SAGA and special rare printings add a letter: BSS06-001a. - Spirit, Nexus or Magic: The card type arrives in supertype and the colour in attributes.types. - Pre-release cards apart: Pre-release cards sit in sets of their own, next to the booster they introduced. ### Cyberpunk TCG (game=cyberpunk) Page: https://alltcgapi.com/cyberpunk-tcg-api Snapshot 2026-11-19: 14 sets, 527 cards, 0 sealed products. Legends, units, gear and programs from the retail release and its starter decks, with pre-release, judge and box topper cards in sets of their own. - The card type in supertype: Legend, Unit, Gear or Program arrives in supertype, the colour in attributes.types. - Numbers within the product: Card numbers count within each product: 001 in a starter deck and 001 in the booster are two cards with two ids. - Promos as sets: Pre-release, judge and box topper cards have their own sets. ### Star Wars: Destiny (game=swdestiny) Page: https://alltcgapi.com/star-wars-destiny-api Snapshot 2026-11-19: 13 sets, 2,238 cards, 0 sealed products. Characters, upgrades, supports, events, battlefields and plots from the Star Wars: Destiny expansions, with the promotional cards and their variants. - The card type in supertype: Character, Upgrade, Support, Event, Battlefield, Plot or Downgrade arrives in supertype, the colour in attributes.types. - Promo variants: Alternate full arts and Aurebesh printings are separate cards in the promo set, each with its own id. - Cards, not dice: Die faces are not part of the card record today. ### Dragoborne: Rise to Supremacy (game=dragoborne) Page: https://alltcgapi.com/dragoborne-api Snapshot 2026-11-19: 11 sets, 671 cards, 0 sealed products. Creatures, spells and banners from the English booster packs and trial decks released between 2017 and 2018. - Card numbers as printed: DB-BT05/001 is the number on the card and in the API. - Creature, Spell or Banner: The card type arrives in supertype and the colour in attributes.types. - Trial decks are sets: Each trial deck has its own code and card list, like the booster packs. # Documentation ## Quickstart From a key to a page of cards in three requests. Every route lives under /v1 and returns JSON. You need one key, and the same key reads every game. ### 1. List the games The id of a game is what you pass as game= everywhere else. ``` curl "https://api.alltcgapi.com/v1/games" \ -H "X-Api-Key: $ALLTCG_KEY" ``` ``` { "data": [ { "id": "battlespirits", "name": "Battle Spirits Saga", "sets": 20, "cards": 1841, "sealed": 0 }, { "id": "cyberpunk", "name": "Cyberpunk TCG", "sets": 14, "cards": 527, "sealed": 0 }, … { "id": "pokemon", "name": "Pokémon TCG", "sets": 653, "cards": 58481, "sealed": 2098 }, … ] } ``` ### 2. Pick a set Sets come newest first. Keep the code: it is the handle for the next call. ``` curl "https://api.alltcgapi.com/v1/sets?game=onepiece&limit=3" \ -H "X-Api-Key: $ALLTCG_KEY" ``` ### 3. Read its cards Cards of a set come back in collector-number order. Follow links.next until it is null. ``` curl "https://api.alltcgapi.com/v1/sets/OP01/cards?limit=50" \ -H "X-Api-Key: $ALLTCG_KEY" ``` ### What to keep - Store the id of every card you show. Ids never change and are never reused. - Do not match cards by name: two printings can share one. - Read X-Quota-Remaining on any response to know what is left. ## Authentication One key, sent as a header, for every game. Send your key on every request to a non-public route, in either of two headers. ``` X-Api-Key: atcg_live_… Authorization: Bearer atcg_live_… ``` A key starts with atcg_live_ and is shown once, when it is issued. Only a keyed hash of it is stored, so a lost key cannot be recovered: it is replaced. ### Keys and accounts Credits and rate limits belong to the account, not to the key. Several keys on one account share one allowance, so a key per environment costs nothing extra. ### Manage keys Create, rotate and revoke keys from your account page, or with the /v1/me/keys routes. Rotating gives a key a new secret and keeps the old one working for a short grace period, so you can switch without downtime. ### Never in a browser A key in client-side code is a key anyone can copy. Call the API from your server and send your own response to the browser. ### Check a key ``` curl "https://api.alltcgapi.com/v1/me" -H "X-Api-Key: $ALLTCG_KEY" ``` /v1/me costs no credits and returns your plan, your scopes and what is left. ## Prices The current price of a card or a sealed product by source, and its history day by day. A price is a quote: one source, one variant, one language, one amount in one currency, and the day it was observed. A card usually has several. The API returns them all and does not blend them into a single number. ### Read the quotes of a card ``` curl "https://api.alltcgapi.com/v1/cards/{id}/prices" \ -H "X-Api-Key: $ALLTCG_KEY" ``` ``` { "data": [ { "source": "CARDMARKET", "variant": "LOWEST_NEAR_MINT", "language": "en", "condition": "NEAR_MINT", "printing": null, "region": "EU", "eu_only": false, "price": { "amount": 12.5, "currency": "EUR" }, "as_of": "2026-11-17" }, { "source": "TCGPLAYER", "variant": "MARKET", "language": "en", "condition": null, "printing": "NORMAL", "region": null, "eu_only": false, "price": { "amount": 14.2, "currency": "USD" }, "as_of": "2026-11-17" } ] } ``` Sealed products work the same way on /v1/sealed/{id}/prices. Both routes cost 2 credits and return every quote of the item in one response. ### Several items in one request GET /v1/prices/current takes up to 25 ids in ids=, separated by commas. Cards and sealed products can be mixed. It costs 4 credits whatever the number of ids, and accepts the same filters. ``` curl "https://api.alltcgapi.com/v1/prices/current?ids={id},{id}&source=CARDMARKET" \ -H "X-Api-Key: $ALLTCG_KEY" ``` ``` { "data": [ { "id": "01d3a5f3-…", "kind": "card", "quotes": [ … ] }, { "id": "7c0e9b1a-…", "kind": "sealed", "quotes": [ … ] } ], "meta": { "requested": 3, "found": 2 } } ``` Items come back in the order you asked for them. An id that is not in the catalogue is left out, and meta.found tells you how many were found. More than 25 ids, or an id that is not a valid id, is a 400. ### Fields Field | Meaning source | Where the number comes from: CARDMARKET or TCGPLAYER. /v1/prices/sources lists what is served. variant | What the number measures. See the table below. language | The language of the copy that was quoted. condition | The condition the quote refers to, when the source states one. Otherwise null. printing | NORMAL, HOLOFOIL and so on, when the source prices finishes apart. Otherwise null. region | The market the quote was read in, when the source is regional. Otherwise null. eu_only | true when the source counted sellers in the European Union only. Otherwise false. price.amount, price.currency | The amount and its currency, always together. Amounts are never converted. as_of | The last day, in UTC, the source published this quote. A date, not a time. ### Variants Variant | Meaning LOWEST_NEAR_MINT | The lowest asking price for a near mint copy. LOWEST | The lowest asking price, any condition. Used for sealed products. MARKET | The market price published by the source, based on recent sales. TREND | The trend price published by the source. AVG_7D · AVG_30D | The average sale price over 7 or 30 days. ### Filters - source= keeps one source. An unknown source is a 400 that lists the available ones. - language= keeps one language, such as en or ja. - variant= keeps one variant, such as MARKET. - A card with no quote returns an empty list with status 200. A card that does not exist returns 404. ### History GET /v1/cards/{id}/prices/history returns the past quotes of a card, and /v1/sealed/{id}/prices/history those of a sealed product. Each costs 5 credits. A series is one combination of source, variant, language, condition, printing, region and eu_only: the response has one point per series per day, oldest first. ``` curl "https://api.alltcgapi.com/v1/cards/{id}/prices/history?source=TCGPLAYER&variant=MARKET&from=2026-08-01&to=2026-10-31" \ -H "X-Api-Key: $ALLTCG_KEY" ``` ``` { "data": [ { "date": "2026-08-01", "source": "TCGPLAYER", "variant": "MARKET", "language": "en", "condition": null, "printing": "NORMAL", "region": null, "eu_only": false, "price": { "amount": 13.9, "currency": "USD" } }, … ], "meta": { "id": "01d3a5f3-18df-4520-ac0b-4449c077f179", "kind": "card", "from": "2026-08-01", "to": "2026-10-31", "bucket": "day", "count": 92, "truncated": false, "capped": false, "plan_window_days": null } } ``` Parameter | Meaning from, to | The first and the last day, as YYYY-MM-DD in UTC. Without them: the last 90 days. bucket | day (the default), week or month. A week starts on Monday. A week or a month is one point per series, dated on its first day, with the median of its days. source, language, variant | The same filters as the current quotes. Use them: a card with many series returns many points. - Each plan reads back a number of days: plan_window_days in the response, history_days in /v1/billing/plans. A request that starts earlier is not refused: it is cut to the window, and meta.truncated is true. meta.from is the day the response really starts. - A response holds at most 3,000 points. When there were more, meta.capped is true: narrow the dates or the filters, or ask for bucket=week. - When a source skips a few days and returns with the same price, the days in between carry that price. A day with no point is a day the source published nothing for that series. - History starts on the first day the source was read for that item, and does not expire. ### Delay and age GET /v1/prices/sources lists each source with delay_hours and max_age_days. A day can be read delay_hours after it began: with 24, once it is over in UTC. Days are loaded once each morning, so the newest day is yesterday, or the day before in the first hours of the UTC day. A quote the source has not published for more than max_age_days is no longer returned as current; it stays in the history. ### What is not here - Graded prices. - Currency conversion. A euro quote stays in euro and a dollar quote stays in dollars. - Individual listings, sellers or stock counts. - An index or an average across sources. ### Coverage Not every game has quotes from every source. GET /v1/prices/coverage is public and returns, per game and source, how many cards and sealed products have a current quote and the day of the newest one. ## Pagination Cursor-based: ask for a page, follow links.next. Lists are paged with a cursor. Send limit (default 50, maximum 250) and follow links.next from each response until it is null. ``` { "data": [ … ], "meta": { "limit": 50, "count": 50, "has_more": true }, "links": { "next": "https://api.alltcgapi.com/v1/cards?cursor=eyJr…" } } ``` ### Rules - links.next is a complete URL. Request it as it is; do not build or edit cursors. - A cursor belongs to the list that issued it. Used on a different list it returns 400 INVALID_CURSOR. - limit above 250 returns 400 LIMIT_EXCEEDED. It is never silently reduced. - A list costs 1 credit per 50 rows requested: limit=250 costs 5. ### Why not page numbers With page numbers, a card added while you are reading shifts every later page and you see one row twice or not at all. A cursor resumes after the last row you read, whatever changed in between. ## Rate limits & credits What a request costs, how fast you can go, and what the headers say. Two things are counted for an account: how fast it calls, and how many credits it spends. ### Credits Request | Cost A card, set or sealed product by id | 1 The prices of a card or a sealed product | 2 The prices of up to 25 items in one request | 4 The price history of a card or a sealed product | 5 A list of games or sets | 1 A list of cards or sealed products | 1 per 50 rows requested /v1/me and the public routes | 0 Any 4xx, 5xx or 304 | refunded The cost is charged before the request runs and given back if the response carries no data. An error never costs a credit. ### Headers on every response Header | Meaning X-Credits-Cost | What this request cost. X-Quota-Limit | Credits in your period. X-Quota-Remaining | Credits left after this request. X-Quota-Reset | When a paid period renews. Absent on the trial. RateLimit-Limit | Requests per second on your plan. RateLimit-Remaining | Requests left in the current second. Retry-After | On a 429: seconds to wait. ### Rate Each plan has a limit per second, per minute, and on requests in flight at once. Going over returns 429 with Retry-After. A refused request is not counted against you. ### The trial The trial is 800 credits in total, with at most 200 a day. When it is used up the API returns 403 TRIAL_EXPIRED. There is no Retry-After on that response, because the credits do not come back. ## Errors One error shape, a stable code, and what to do about each. Every error has the same shape. Branch on error.code, which is stable; the message is written for a person and may change. ``` { "error": { "code": "INVALID_PARAMETER", "message": "Unknown game \"one-piece\". Available: battlespirits, cyberpunk, digimon, dragoborne, dragonball-fw, dragonball-masters, fab, fftcg, fow, gundam, lorcana, onepiece, pokemon, riftbound, swdestiny, swu, vanguard, weissschwarz, yugioh.", "details": { "param": "game", "allowed": ["battlespirits", "cyberpunk", "digimon", …, "yugioh"] }, "request_id": "6e1237ead44557646331e2c99fb3c3be" } } ``` Quote request_id when you ask for help: it identifies the request in our logs. ### Codes Status | Code | Meaning 400 | INVALID_PARAMETER | An unknown parameter, a repeated one, or a value outside its vocabulary. details.param names it. 400 | LIMIT_EXCEEDED | limit is above 250. The request is refused, never truncated. 400 | INVALID_CURSOR | The cursor is malformed or was issued for a different list. 401 | MISSING_API_KEY | No key was sent. 401 | INVALID_API_KEY | The key is unknown or has been revoked. 401 | INVALID_CREDENTIALS | Sign-in with an email and password that do not match. 403 | TRIAL_EXPIRED | Trial credits are used up. They do not renew: choose a plan. 403 | IMAGE_URL_INVALID | An image URL with no signature, a wrong one, or one past its expiry. Read the object again for a fresh image_url. 403 | INSUFFICIENT_SCOPE | The key lacks the scope the route needs, such as account:write. 404 | KEY_NOT_FOUND | No key with that id on your account. 404 | CARD_NOT_FOUND · SET_NOT_FOUND · SEALED_NOT_FOUND | No object with that id. Refunded. 404 | ROUTE_NOT_FOUND | No such route. details.did_you_mean suggests the closest one. 409 | ACCOUNT_EXISTS | An account already uses that email. Sign in or recover access. 409 | IDEMPOTENCY_CONFLICT | The Idempotency-Key was already used with a different request body. 429 | RATE_LIMITED | Too many requests in the current second or minute. Wait Retry-After seconds. 429 | CONCURRENCY_LIMIT | Too many requests in flight at once. 429 | QUOTA_EXCEEDED | Not enough credits left in the period, or the daily cap is reached. 503 | METER_UNAVAILABLE | Usage metering is briefly unreachable. Retry in a few seconds. 503 | FEATURE_NOT_CONFIGURED | A part of the service, such as payments, is not switched on yet. ### Unknown parameters are errors A misspelled filter is refused, not ignored. Ignored, it would return the whole catalogue as if it were filtered, and you would find out after paying for the pages. ## API reference Every route, its parameters and what it costs. Base URL: https://api.alltcgapi.com. Every data route is a GET and returns JSON. Route | Credits | Parameters | Returns GET /v1/games | 1 | — | The games in the catalogue, with set, card and sealed counts. GET /v1/sets | 1 | game, region, limit, cursor | Sets, newest first. GET /v1/sets/{id} | 1 | — | One set by id or by code, with its names per language. GET /v1/sets/{id}/cards | 1 per 50 rows | limit, cursor | The cards of a set, in collector-number order. GET /v1/cards | 1 per 50 rows | game, set, name, number, limit, cursor | Cards across the catalogue. GET /v1/cards/{id} | 1 | — | One card, with its names per language. GET /v1/sealed | 1 per 50 rows | game, set, kind, limit, cursor | Sealed products. GET /v1/sealed/{id} | 1 | — | One sealed product. GET /v1/cards/{id}/prices | 2 | source, language, variant | The current quotes of a card. GET /v1/cards/{id}/prices/history | 5 | from, to, bucket, source, language, variant | The price history of a card: one point per series per day. GET /v1/sealed/{id}/prices | 2 | source, language, variant | The current quotes of a sealed product. GET /v1/sealed/{id}/prices/history | 5 | from, to, bucket, source, language, variant | The price history of a sealed product. GET /v1/prices/current | 4 | ids, source, language, variant | The current quotes of up to 25 cards and sealed products in one request. GET /v1/prices/sources | public | — | The price sources the API serves, with the delay of each. GET /v1/prices/coverage | public | — | Per game and source: how many items have a quote. GET /v1/me | 0 | — | Your plan, scopes and remaining credits. GET /v1/billing/plans | public | — | The price list. GET /v1/reference | public | — | The closed vocabularies in one call. GET /v1/status | public | — | When the catalogue and the prices were last refreshed. GET /v1/health | public | — | Process and database health. ### Account and billing These routes take and return JSON and cost no credits. The ones that change the account need the account:write scope, which the key issued at signup has. The account page on this site uses the same routes. Route | Credits | Body | Returns POST /v1/accounts/register | public | email, password, label | An account with its first key. The key is shown once, in this response. POST /v1/accounts/free | public | email | A trial key for an email address, without a password. POST /v1/accounts/verify | public | token | Confirms the email address with the token from the verification link. POST /v1/accounts/recover | public | email | Sends a recovery link. The answer is the same whether or not the account exists. POST /v1/accounts/recover/confirm | public | token, password, label | A new key for the account, and a new password if you send one. GET /v1/me/usage | 0 | days | Requests and credits per day. GET /v1/me/keys | 0 | — | The keys of the account, masked. POST /v1/me/keys | 0 | label | A new key. Send an Idempotency-Key header. POST /v1/me/keys/{id}/rotate | 0 | — | A new secret for a key. The old one keeps working for a grace period. DELETE /v1/me/keys/{id} | 0 | — | Revokes a key at once. POST /v1/me/verification/resend | 0 | — | Sends a new verification link. POST /v1/billing/checkout | 0 | plan, interval, success_to, cancel_to | A Stripe Checkout address for a paid plan. POST /v1/billing/portal | 0 | return_to | A Stripe billing portal address: card, plan, cancellation. GET /v1/billing/invoices | 0 | — | The invoices of the account. ### Parameters Parameter | On | Meaning game | sets, cards, sealed | A game id from /v1/games. An unknown value is a 400. region | sets | WEST or EAST: the print line of the set. set | cards, sealed | A set id or code. name | cards | Matches the start of the card name. number | cards | The collector number, exactly as printed. kind | sealed | A product kind, such as BOOSTER_BOX. source | prices | CARDMARKET or TCGPLAYER. language | prices | A language code, such as en or ja. variant | prices | A variant, such as MARKET or LOWEST_NEAR_MINT. ids | prices/current | Up to 25 card or sealed product ids, separated by commas. from, to | price history | Days as YYYY-MM-DD, in UTC. Default: the last 90 days. bucket | price history | day, week or month. Default day. limit | lists | 1 to 250. Default 50. cursor | lists | From links.next. Never built by hand. ### A card ``` { "data": { "id": "01d3a5f3-18df-4520-ac0b-4449c077f179", "game": "onepiece", "set": { "id": "95435c34-…", "code": "OP11", "name": "A Fist of Divine Speed" }, "number": "OP11-095", "name": "Monkey.D.Garp", "rarity": "SUPER RARE", "supertype": null, "attributes": { "types": ["Black"] }, "image_url": "https://media.alltcgapi.com/cards/…/OP11-095-normal.webp?e=…&s=…", "languages": ["en"], "external_ids": { "cardmarket": 827230, "tcgplayer": … }, "version": 1, "updated_at": "2026-11-18T22:21:15.182Z" } } ``` ### Images image_url on cards, sets and sealed products is a signed URL on media.alltcgapi.com: e is its expiry, s its signature. It needs no API key and costs no credits, so it can go straight into an img tag. A signed URL stays the same for a whole week and is valid for at least 7 days. Store the object id, not the URL, and read the object again when you need the image: an expired or altered URL answers 403 IMAGE_URL_INVALID. A few image_url still point to the original host of the image and are served from there as they are. ### Stability - An id never changes and is never reused. - version moves only when the data of the object changes. - New fields may be added to an object. Fields are not renamed or removed within /v1. ## What a price in this API is. Where the numbers come from, what each one measures, and what the API deliberately does not do with them. ### A quote, not a valuation Every price the API returns is a quote observed at a named source. It is the number that source published for that item, in that source's currency, on the date in as_of. The API does not compute a fair value, an average across sources or a recommended price. ### Sources Source | Currency | What it reflects CARDMARKET | EUR | The European marketplace: asking prices and the trend and average figures it publishes. TCGPLAYER | USD | The United States marketplace: its market price, based on recent sales, and its lowest asking price. GET /v1/prices/sources returns the sources the API serves at any moment. A source can be withdrawn; when it is, its quotes stop being returned at once. ### Series, and their history A series is the combination of item, source, variant, language, condition, printing, region and eu_only. The prices routes return the newest quote of each series. The history routes return the series itself: one point for each day, in UTC, the source published the quote. The API keeps a series as stretches of days at the same price and gives them back one point per day. When a source skips up to a week and returns with the same price, the days in between carry that price. After a longer silence, or when the price is different on return, the missing days have no point: the API does not draw a line between two observations. With bucket=week or bucket=month a point is the median of the days in that week or month, not their average: one odd day barely moves a median. History starts on the first day the source was read for the item, in November 2024 at the earliest, and how far back a key reads depends on its plan. ### Variants Variant | Measures | Use it for LOWEST_NEAR_MINT | The lowest asking price for a near mint copy. | What a buyer would pay today for a clean copy. LOWEST | The lowest asking price in any condition. | Sealed products, where condition is not graded. MARKET | A price based on recent completed sales. | A steadier number for a collection value. TREND | The trend figure the source publishes. | Smoothing out a single cheap listing. AVG_7D · AVG_30D | The average sale price over the window. | Comparing today with the recent past. ### Asking prices are not sale prices A lowest asking price can be one mispriced listing, a damaged copy described as near mint, or a seller who does not ship to your buyer. It moves faster and further than a sale-based figure. If your product shows a collection value, prefer MARKET, TREND or an average where the source offers one. ### Language, condition and printing - language is the language of the copy that was quoted. Copies in different languages are different quotes and often different prices. - condition is set only when the source states it. A null condition means the source did not say, not that the card is mint. - printing tells a foil from a non-foil where the source prices them apart. A null printing means the source has one price for the card. ### Currency Amounts are returned in the currency of the source and are never converted. Do not add or compare amounts with different currencies without converting them yourself, at a rate you choose and can explain to your users. ### Freshness as_of is the last day the source published the quote, not the time of your request. A day is loaded once it is over, so the newest as_of is yesterday. GET https://api.alltcgapi.com/v1/prices/sources states the delay of each source, and after how many days without an observation a quote stops being returned as current. The status page and GET https://api.alltcgapi.com/v1/status show when prices were last refreshed. A quote can be days old for a card that rarely trades: check as_of before presenting a number as current. ### What is not served - Graded prices. - Individual listings, sellers, stock counts. - An index, an average across sources or a currency conversion. - Quotes from sources other than the ones listed above. ### Gaps A card with no quote returns an empty list. That means no quote is held, not that the card is worth nothing. Coverage by game and source is public at /v1/prices/coverage. ## What changed in the API. ### 2026-11-23 - Added price history: GET /v1/cards/{id}/prices/history and GET /v1/sealed/{id}/prices/history, 5 credits each, with from=, to= and bucket=day|week|month. How far back a key reads depends on its plan. - Added GET /v1/prices/current: the current quotes of up to 25 cards and sealed products in one request, 4 credits. - Quotes now carry eu_only, and the prices routes accept variant=. - as_of is now a day (YYYY-MM-DD), no longer a timestamp: a quote is dated by the day the source published it. - GET /v1/prices/sources now returns delay_hours and max_age_days for each source. - Added fifteen games to the catalogue. GET /v1/games lists all nineteen. ### 2026-11-19 - Added current prices: GET /v1/cards/{id}/prices and GET /v1/sealed/{id}/prices, 2 credits each, with source= and language= filters. - Added GET /v1/prices/sources and GET /v1/prices/coverage, both public. - Added Riftbound to the catalogue as game=riftbound. - /v1/status now reports a prices lane next to the catalogue lane. ### 2026-11-18 - First version of /v1: games, sets, cards and sealed products for Pokémon TCG, One Piece Card Game and Disney Lorcana. - Credits and rate limits per account, with the cost of every request in X-Credits-Cost. - An unknown game= now returns 400 with the list of valid games instead of an empty page. # Articles ## What “one response shape” means across every game https://alltcgapi.com/blog/one-response-shape-across-games · published 2026-11-19 What stays identical in every game of the API (envelope, card fields, errors, pagination, credits), what varies inside attributes, and how to render it. The home page of this site says "one response shape". This article spells out what that covers and where it stops, so you can decide what to hard-code and what to read at run time. ### What is identical in every game - The envelope. A list is { data, meta, links }, one object is { data }, an error is { error: { code, message, details, request_id } }. - The fields of a card: id, game, set, number, name, rarity, supertype, attributes, image_url, languages, external_ids, version and updated_at. Same names and same types, whatever the game. - Sets and sealed products, likewise: one set of fields each, listed on the coverage page. - Pagination: limit up to 250, then links.next until it is null. - Credits and headers: the same cost per route and the same X-Credits-Cost and X-Quota-Remaining on every response. - Prices: one quote object, with source, variant, language, condition, printing, region, eu_only, price and as_of. ### What varies: supertype supertype holds the card type in the words of the game: Effect Monster or Counter Trap in Yu-Gi-Oh!, Digi-Egg, Digimon, Tamer or Option in Digimon, Leader, Base, Unit, Event or Upgrade in Star Wars: Unlimited. They are the game’s own categories, not a vocabulary shared across games, and supertype can be null. ### What varies: attributes attributes holds the rules data of the card. The keys depend on the game: Game | Keys | Notes Pokémon | hp, types, subtypes | types are the Pokémon types. Yu-Gi-Oh! | attack, defense, monsterType, types | types holds the attribute, such as LIGHT or DARK. One Piece | types | The colours of the card. Digimon | level, form, digimonTypes, types | form runs from In-Training and Rookie up. Riftbound | types | The domains. A dual-domain card carries both. Force of Will | types | The attribute: Light, Fire, Water, Wind or Darkness. types is the one key several games share, and it means something different in each. Do not build a cross-game filter on it without the game next to it. Two rules hold everywhere. A key the card does not have is left out, not sent as null. A card with no rules data at all has attributes set to null. Some games carry little rules data today: Cardfight!! Vanguard cards, for example, carry number, name, rarity and image. ### Rendering it without a case per game Render the shared fields the same way for every game. For attributes, keep a small table of renderers for the games your product cares about, and a fallback for every other game, including the ones the API has not added yet. ``` interface Card { id: string; game: string; set: { id: string; code: string; name: string }; number: string; name: string; rarity: string | null; supertype: string | null; attributes: Record | null; image_url: string | null; external_ids: { cardmarket: number | null; tcgplayer: number | null }; version: number; } type Row = [label: string, value: string]; const text = (v: unknown): string => (Array.isArray(v) ? v.join(', ') : v == null ? '' : String(v)); const RENDERERS: Record) => Row[]> = { pokemon: (a) => [['HP', text(a.hp)], ['Types', text(a.types)]], yugioh: (a) => [['ATK', text(a.attack)], ['DEF', text(a.defense)], ['Type', text(a.monsterType)]], digimon: (a) => [['Level', text(a.level)], ['Form', text(a.form)]], }; // Any other game: print what is there, key by key. const fallback = (a: Record): Row[] => Object.entries(a).map(([k, v]) => [k, text(v)]); export function details(card: Card): Row[] { if (!card.attributes) return []; const render = RENDERERS[card.game] ?? fallback; return render(card.attributes).filter(([, value]) => value !== ''); } ``` The filter at the end matters because keys are left out when a card does not have them: a Spell Card has no ATK, and the row should disappear rather than show an empty value. ### What is not uniform, and where to read it - Sealed products exist for some games only. GET /v1/games returns the sealed count of each game: read it instead of showing an empty tab. - Price coverage differs by game and by source. GET /v1/prices/coverage is public and says, per game and source, how many items have a quote. - Cardmarket ids are partial in games where TCGplayer and Cardmarket split finishes differently. - Print regions: Pokémon has WEST and EAST sets. For another game, check /v1/sets?region=EAST before relying on it. - Depth of rules data: some games carry the full set of fields above, others only number, name, rarity, type and image. ### A game you have never seen Game ids come from /v1/games, and an unknown game= is answered with a 400 that lists the valid ids. If your app loads that list at start-up, renders the shared fields and falls back to printing attributes, a game added to the API shows up in your product with no code change. That is the practical meaning of one response shape. ## Card numbers across card games, and why they are strings https://alltcgapi.com/blog/card-numbers-across-games · published 2026-11-19 OP01-001, MAMS-EN001a, DZ-BT17/001EN, 1/194, 1-018L: how each game numbers its cards, and five rules for storing, sorting and searching them. The collector number is the field users type into a search box, and the field with the least in common between games. Below is what the catalogue holds, game by game, and what it means for your code. ### What a number looks like Game | Example | What it contains One Piece | OP01-001 | Set and position, as printed on the card. Yu-Gi-Oh! | MAMS-EN001 · MAMS-EN001a | Set code, language and position. Each further rarity of the same card adds a letter. Digimon | BT27-002 | Set and position, as printed. Fusion World | FB11-001 · FB11-001a | Set and position. The alternate art adds a letter. Flesh and Blood | MPB001 · MPB002a | Collector number. A Marvel or alternate printing adds a letter. Star Wars: Unlimited | 1/194 | Position and the printed size of the set. Weiss Schwarz | UMA/W119-E001 · UMA/W119-E001SP | Title, set and position, with the SP or SR suffix kept. Cardfight!! Vanguard | DZ-BT17/001EN | Set, position and a language suffix. The slash is part of it. Gundam | GD05-123 | The set the card was first printed in. Reprints keep it. Final Fantasy | 1-018L | Opus, position and a rarity letter. Force of Will | CPB-001 | Set and position. Battle Spirits Saga | BSS06-001 · BSS06-001a | Set and position. SAGA and special rare printings add a letter. Dragoborne | DB-BT05/001 | Set and position, with a slash. Cyberpunk TCG | 001 | Position within its own product only. The table lists the games whose number format is described on their page of this site. The rules below hold for every game in the API. ### 1. A number is a string Leading zeros (001), letters (a, SP, L, EN) and slashes (1/194) are all part of the number. Parsed as an integer, OP01-001 fails and 001 becomes 1, which no user has ever typed. Store numbers as text and compare them as text. ### 2. number= matches exactly GET /v1/cards?game=onepiece&number=OP01-001 returns the cards whose number is exactly OP01-001. Exact means exact: in Yu-Gi-Oh! number=MAMS-EN001 returns the first rarity and not MAMS-EN001a. To show every rarity of a card, list the set or search by the start of the name, and group the results yourself. ``` curl "https://api.alltcgapi.com/v1/cards?game=yugioh&number=MAMS-EN001" \ -H "X-Api-Key: $ALLTCG_KEY" ``` ### 3. Encode the slash Send the number URL-encoded. In Vanguard DZ-BT17/001EN becomes DZ-BT17%2F001EN; the same applies to 1/194, UMA/W119-E001 and DB-BT05/001, and to anything else your users type. Use the encoder of your language rather than replacing characters by hand. ``` const number = 'DZ-BT17/001EN'; const url = `https://api.alltcgapi.com/v1/cards?game=vanguard&number=${encodeURIComponent(number)}`; // …/v1/cards?game=vanguard&number=DZ-BT17%2F001EN ``` ### 4. Sort in the order the API returns The cards of a set come back in collector-number order. Sorting the strings yourself puts 10 before 2. A natural sort fixes that and still has to know that 001a follows 001, that SP follows the base card and that L is a rarity, not a position. Store the position in which /v1/sets/{code}/cards returned each card and sort on that. ### 5. The number does not identify the card - Gundam reprints keep their first number, so a GD06 card can be numbered GD02-…. - Cyberpunk TCG numbers restart in every product. - Final Fantasy puts the rarity inside the number. So the number alone tells you neither the set nor the card. Use it to search and to display; store the id. ### Showing numbers to users Show the number as the API returns it. It is what the user reads on the card in their hand, and any reformatting (dropping the zeros, splitting the slash, moving the suffix) is one more step between your screen and the card. When a search by number returns more than one card, show them all with set and image, and let the user pick. ## Modelling a multi-game card collection with stable ids https://alltcgapi.com/blog/multi-game-collection-stable-ids · published 2026-11-19 How to store cards from several card games in one schema: which id to key on, what to keep from the API, and where copies and prices belong. A collection app built for one game usually keys its cards on something the game prints: a set code and a number, or a name. That holds until the second game arrives. This article describes a schema that keeps working when the second game is added, and the nineteenth. ### Key on the id, not on what is printed Every card the API returns has an id. It never changes and is never reused. Make it the primary key of your card table and the foreign key everywhere else. Printed fields are good for search and bad as keys. A few cases from the catalogue: - A Yu-Gi-Oh! card printed at three rarities is three cards with three ids. The number of the first is MAMS-EN001; the others add a letter, MAMS-EN001a and MAMS-EN001b. - A Gundam Card Game card reprinted in a later set keeps the number it was first printed with, so the set GD06 can hold a card numbered GD02. The number does not tell you the set. - Cyberpunk TCG numbers count within each product: 001 in a starter deck and 001 in the booster are two different cards. - Names repeat in every game: alternate arts, parallels and reprints share the name of the base card. The id is the only identity the API promises. Use set and number to find a card, then store what you found by its id. ### Three tables, three speeds A collection holds three kinds of fact: what exists (the catalogue), what a user owns (copies), and what a marketplace asked or sold for on a given day (quotes). They change at different speeds and come from different places, so they belong in different tables. ``` -- What exists. Filled from the API, never edited by users. create table card ( id uuid primary key, -- data.id: never changes, never reused game text not null, -- data.game: pokemon, onepiece, yugioh… set_code text not null, -- data.set.code number text not null, -- data.number, exactly as returned name text not null, rarity text, supertype text, attributes jsonb, -- game-specific rules data image_url text, cardmarket_id integer, -- data.external_ids.cardmarket, may be null tcgplayer_id integer, -- data.external_ids.tcgplayer, may be null version integer not null -- data.version: moves when the card changes ); create index on card (game, set_code, number); -- for lookups, not unique -- What a user owns. create table copy ( id bigserial primary key, user_id bigint not null, card_id uuid not null references card (id), language text not null, -- the language this copy is printed in printing text not null default '', -- a finish, where the game prices it apart condition text, quantity integer not null default 1 ); -- What a source quoted, kept with its date. The API serves the latest only. create table quote ( card_id uuid not null references card (id), source text not null, -- CARDMARKET, TCGPLAYER variant text not null, -- LOWEST_NEAR_MINT, MARKET, TREND… language text not null, condition text not null default '', printing text not null default '', region text not null default '', amount numeric not null, currency text not null, -- EUR or USD: never summed together as_of timestamptz not null, primary key (card_id, source, variant, language, condition, printing, region, as_of) ); ``` One card table holds every game. The objects have the same fields whatever the game, and the rules data that differs sits in attributes, so a new game is new rows, not a new table and a migration. The index on game, set and number is a plain index, not a unique constraint. The API does not promise that pair is unique, and a constraint that holds for most games but not for one becomes a failed import. ### A copy is not a card A copy has properties the catalogue does not: the language it was printed in, its condition, how many the user has. Two users who own the same card own two copies of one card row. Two cases need care, and both are decided by the catalogue, not by your schema: - Asian Pokémon print lines are sets of their own, with region EAST, their own codes, numbers and images. A Japanese printing is a different card with a different id, not a copy of the English card with language set to ja. - Finishes are a separate card in some games and a property of the copy in others. In Yu-Gi-Oh! each rarity has its own id. In Riftbound foil and non-foil are one card, and their prices are told apart by the printing field of each quote. Where a finish has its own id, it is a card; where it does not, store it on the copy and match it to printing. ### Keeping the catalogue current - For each set your users hold, read /v1/sets/{code}/cards page by page and compare version with the value you stored. Update only the rows whose version moved. - To find new sets, list /v1/sets?game=… newest first and add the codes you do not have. Read the whole list again from time to time: a set can be added with a release date older than your newest one. - A list costs 1 credit for every 50 rows requested, so re-reading a set with limit=250 costs 5 credits a page. A detail request costs 1. - Load the list of games from /v1/games at start-up instead of hard-coding it. A game the API adds later then appears without a release of your app. ### Joining with marketplace data external_ids carries the Cardmarket and TCGplayer product ids. Treat both as optional. In some games TCGplayer lists each finish as a product of its own while Cardmarket groups them under one card, so the Cardmarket id is missing wherever the two catalogues do not agree on the printing. Quotes come from /v1/cards/{id}/prices at 2 credits a card. For many cards at once, /v1/prices/current takes up to 25 ids for 4 credits. You do not have to build a history yourself: /v1/cards/{id}/prices/history returns each series day by day. If you keep your own copy of the quotes, store each one with its as_of and insert a row only when as_of is newer than the last one you hold. ``` curl "https://api.alltcgapi.com/v1/cards/{id}/prices?source=CARDMARKET" \ -H "X-Api-Key: $ALLTCG_KEY" ``` ### Checklist - Primary key: the API id. Never a name, never set plus number. - One card table for every game, with game as a column and attributes as JSON. - Copies in their own table, with language, condition and, where needed, printing. - Quotes in their own table, with source, currency and as_of on every row. - Sync by version; discover games and sets from the API, not from a list in your code.