# Drawstep engine wiki — Card anatomy > Every top-level field of a card definition: type, whether it is required, what it means and the values it accepts. Engine: Magic: The Gathering (`mtg`). Page: https://drawstep.xyz/wiki/mtg/anatomy · Raw Markdown: https://drawstep.xyz/wiki/mtg/anatomy.md · Complete AI pack (every topic in one document, with the output contract and worked examples): https://drawstep.xyz/wiki/drawstep-mtg-ai-pack.md. This page is generated from Drawstep's card schema; field names and discriminators are exact. A card definition is one JSON object; anything the vocabulary cannot express goes verbatim into `unparsed` instead of being approximated. ## Card anatomy — top-level fields | Field | Type | Required | Description | |---|---|---|---| | `schemaVersion` | `1` | no | Always 1 (default `1`) | | `id` | `string` | yes | Unique id (stock: oracle slug; custom: any unique string) | | `oracleId` | `string` | no | Scryfall oracle id of the printed card (corpus cards only) | | `name` | `string` | yes | The card's name; used for "~" in rules text and for name filters | | `game` | `string` | no | Engine id ("magic") (default `"magic"`) | | `source` | `"stock" \| "custom"` | no | "stock" for shipped cards, "custom" for player-made ones (default `"stock"`) | | `layout` | `"normal" \| "transform" \| "modal_dfc" \| "adventure" \| "split" \| "flip" \| "saga" \| "token" \| "class" \| "leveler" \| "meld" \| "emblem" \| "prepare" \| "dungeon" \| "host" \| "augment" \| "stickers"` | no | Single-faced "normal" unless the card has faces, chapters, levels, rooms, … (default `"normal"`) | | `supertypes` | `string[]` | no | Legendary, Basic, Snow, World, Ongoing (default `[]`) | | `types` | `string[]` | no | Card types: Creature, Instant, Sorcery, Artifact, Enchantment, Planeswalker, Land, Battle, Kindred (default `[]`) | | `subtypes` | `string[]` | no | Creature types, land types, Aura / Equipment / Saga / Class, spell subtypes (default `[]`) | | `manaCost` | `string` | no | Mana symbols as text: "{2}{W}{U}", hybrid "{W/U}", Phyrexian "{B/P}", "{X}" | | `colors` | `string[]` | no | W, U, B, R, G — normally derived from the mana cost; set explicitly for colorless-cost colored cards and color indicators (default `[]`) | | `power` | `number \| string` | no | Creature power; a string for "*" (then a static setPT with cda provides the value) | | `toughness` | `number \| string` | no | Creature toughness; a string for "*" | | `loyalty` | `number \| "X"` | no | Starting loyalty of a planeswalker; the letter "X" for one that enters with X loyalty counters, X being the value chosen as it was cast | | `keywords` | `string[]` | no | Rule-flag keywords, including Arena Double team: a nontoken attacker conjures its original into hand; both cards perpetually lose double team (default `[]`) | | `keywordAbilities` | `KeywordAbilityDef[]` | no | Keywords with parameters: cycling, kicker, ward, enchant, protection, … (default `[]`) | | `text` | `string` | no | The printed rules text. Display only — the engine reads `abilities`, never this (default `""`) | | `abilities` | `AbilityDef[]` | no | The card's behaviour: spell / triggered / activated / loyalty / static / replacement abilities, in printed order (default `[]`) | | `tableAdjudicated` | `boolean` | no | Full text coverage includes table-adjudicated rules (CR 100.7); report separately from fully automated cards | | `additionalCost` | `CostDef` | no | What must be paid. Amounts may be values: X in a non-mana cost is announced as the spell is cast / the ability activated (CR 601.2b) | | `chooseAsEnters` | `({ who?: "eachPlayer"; opponentsOnly?: boolean; kind: "option" \| "creatureType" \| "color" \| "cardName" \| "basicLandType" \| "landType" \| "cardType" \| "landNonland" \| "oddEven" \| "number" \| "player"; from?: ObjectFilter; zone?: "battlefield" \| "hand" \| "graveyard" \| "library" \| "exile" \| "stack" \| "command"; excludePreviouslyChosen?: boolean; options?: string[]; exclude?: string[]; filter?: object; key?: string; secret?: boolean; beforeGame?: "commander"; label?: string; min?: number; max?: number })[]` | no | Choices made as the card enters ("choose a creature type"); later effects read them via chosen* filters (default `[]`) | | `manaFromSource` | `{ types?: string[]; subtypes?: string[]; supertypes?: string[] }` | no | CR 106.3, 106.6: the producing source must have every listed type, subtype and supertype ("basic lands": supertypes [Basic], types [Land]; "creatures": types [Creature]; "Treasures": subtypes [Treasure]) | | `faces` | `({ name: string; manaCost?: string; supertypes?: string[]; types?: string[]; subtypes?: string[]; colors?: string[]; power?: number \| string; toughness?: number \| string; loyalty?: number \| "X"; keywords?: string[]; keywordAbilities?: KeywordAbilityDef[]; text?: string; abilities?: AbilityDef[]; additionalCost?: CostDef; chooseAsEnters?: object[]; manaFromSource?: object })[]` | no | Extra faces for transform/modal/adventure/split cards; face 0 is the front | | `classLevels` | `ClassLevelDef[]` | no | Class enchantments: levels 2..N (level 1 is the card's own abilities) | | `levels` | `LevelBandDef[]` | no | Leveler creatures: P/T and abilities per level-counter band | | `meld` | `MeldDef` | no | Meld front cards: partner name and melded result id | | `stationLevels` | `LevelBandDef[]` | no | Spacecraft: bands keyed to charge counters ("STATION 9+: 4/4 artifact creature") | | `rooms` | `DungeonRoomDef[]` | no | Dungeon cards: rooms in order; room 0 is the entrance | | `defense` | `number` | no | Battles: the defense counters it enters with | | `solveCondition` | `ConditionDef` | no | Cases: the "To solve —" condition, checked at the beginning of your end step while unsolved | | `attractionLights` | `number[]` | no | Attractions: the lit lights (2–6) | | `prize` | `EffectDef[]` | no | Attractions: the "Prize —" effects run by claimPrize | | `augment` | `AugmentDef` | no | Augment (Unstable): combine with a host | | `stickers` | `StickerSheetDef` | no | A sticker sheet (Unfinity, CR 123) | | `spellbook` | `string[]` | no | Arena spellbook card names supplied by external data; draft samples three entries without replacement | | `specializations` | `{ W?: string; U?: string; B?: string; R?: string; G?: string }` | no | Specialized card names keyed by discarded color/basic land type, linked from the corpus | | `unspecialized` | `string` | no | Original card name for unspecialize (Lukamina forms) | | `startingIntensity` | `number` | no | Starting intensity. Initialized once on the card object; increases survive all zone changes | | `image` | `{ normal?: string; art?: string }` | no | Image URLs for rendering; never read by the engine | | `appearance` | `{ frame?: object; flavor?: string; artist?: string; collector?: string; faces?: object[] }` | no | How the card is drawn (frame, flavor text, credits). Display only | | `pokemon` | `{ category: "Pokemon" \| "Trainer" \| "Energy"; set?: string; setName?: string; number?: string; series?: string; released?: string; rarity?: string; regulationMark?: string; legal?: string[]; illustrator?: string; dexIds?: number[]; stage?: "Basic" \| "Stage1" \| "Stage2" \| "BREAK" \| "LEVEL-UP" \| "MEGA" \| "VMAX" \| "VSTAR" \| "V-UNION" \| "Baby" \| "Restored" \| "LEGEND"; hp?: number; types?: ("Grass" \| "Fire" \| "Water" \| "Lightning" \| "Psychic" \| "Fighting" \| "Darkness" \| "Metal" \| "Fairy" \| "Dragon" \| "Colorless")[]; evolvesFrom?: string; level?: string; tags?: string[]; ruleBox?: boolean; prizes?: number; attacks?: object[]; abilities?: object[]; weaknesses?: object[]; resistances?: object[]; retreat?: number; trainerKind?: "Item" \| "Supporter" \| "Stadium" \| "Tool" \| "Technical Machine" \| "Rocket's Secret Machine" \| "Goldenrod Game Corner"; energyKind?: "Basic" \| "Special"; provides?: ("Grass" \| "Fire" \| "Water" \| "Lightning" \| "Psychic" \| "Fighting" \| "Darkness" \| "Metal" \| "Fairy" \| "Dragon" \| "Colorless")[]; text?: string; playCond?: any; cost?: any[]; effects?: any[]; statics?: any[]; triggers?: object[]; grantsAttacks?: object[]; stadiumAbility?: object; attachFilter?: object; unparsed?: string[] }` | no | Pokémon TCG cards (game "pokemon"): printed structure (stage, HP, types, Weakness / Resistance, Retreat, attacks, Trainer / Energy kind) and the rules steps the Pokémon engine runs | | `tcg` | `{ category: string; cost?: number; stats?: object; attributes?: string[]; traits?: string[]; keywords?: string[]; flags?: string[]; set?: string; number?: string; rarity?: string; legal?: string[]; limits?: object; extra?: object }` | no | Cards of the other games (game "yugioh", "onepiece", "fab", "gundam", "lorcana", "unionarena"): category, cost, printed stats, attributes, traits, legality. Plain data the game's ruleset reads; card text is resolved by the players | | `unparsed` | `string[]` | no | Rules-text lines not yet expressed in the vocabulary, kept verbatim. Any entry flags the card "partially enforced" (manual at a free table, surfaced at an enforced one) instead of approximating it; the engine ignores them | | `unparsed` | `string[]` | no | Printed lines that are not expressed in `abilities` yet — the last rung of the honesty ladder (see Custom mechanics). The table flags the card as partially enforced while this is non-empty. | Multi-face cards (`layout`: transform / modal_dfc / adventure / split / flip / prepare) put each face in `faces[]` (face 0 is the front; the card's own characteristics mirror face 0). Face fields: `name`, `manaCost`, `supertypes`, `types`, `subtypes`, `colors`, `power`, `toughness`, `loyalty`, `keywords`, `keywordAbilities`, `text`, `abilities`, `additionalCost`, `chooseAsEnters`, `manaFromSource`.