# Drawstep engine · Costs · `revealCards` > Reveal cards — Reveal this many matching cards from your hand as a cost; they remain in hand (CR 701.20a, 118.11, 601.2h). "Reveal X blue cards from your hand" (count X); "Reveal two cards from your hand that share a color" (sharesColor). Engine: Magic: The Gathering (`mtg`). This is one primitive of the Drawstep card vocabulary; field names and the discriminator are exact. Wiki page: https://drawstep.xyz/wiki/mtg/costs#revealCards ## Where it goes One part of a `cost` object (an activated ability's cost, `mayPay`, `unlessPays`, an `additionalCost`): `{ "revealCards": … }`; parts combine freely. ## Fields | Field | Type | Required | Description | |---|---|---|---| | `revealCards` | `{ filter?: ObjectFilter; count: ValueDef; sharesColor?: boolean }` | no | Reveal this many matching cards from your hand as a cost; they remain in hand (CR 701.20a, 118.11, 601.2h). "Reveal X blue cards from your hand" (count X); "Reveal two cards from your hand that share a color" (sharesColor) | ## Stock examples - **Martyr of Ashes** — “{2}, Reveal X red cards from your hand, Sacrifice this creature: This creature deals X damage to each creature without flying.” ```json {"chooseX":{"min":0},"mana":"{2}","sacrificeSelf":true,"revealCards":{"filter":{"colors":["R"]},"count":{"kind":"var","name":"X"}}} ``` ## Related - [Costs](https://drawstep.xyz/wiki/mtg/costs.md) — the whole topic - [Filters & targets](https://drawstep.xyz/wiki/mtg/targets.md) — how `target` / `filter` select objects and players (selection algebra) - [Values](https://drawstep.xyz/wiki/mtg/values.md) — every number kind an `amount` accepts - [Start here](https://drawstep.xyz/wiki/mtg/start.md) — the rules, the output contract and the index of every primitive