Skip to contents

Scryfall provides daily exports of our card data in bulk files. Each of these files is represented as a bulk_data object via the API. See details.

Usage

scry_bulk_files()

scry_bulk_file(name)

Arguments

name

A string with file to be downloaded. Can be any one of Oracle Cards, Unique Artwork, Default Cards, All Cards or Rulings. See details.

Value

A data frame with 1 or more rows and the following columns:

  • id [chr]: A unique ID for this bulk item.

  • name [chr]: A human-readable name for this file. See details.

  • type [chr]: A computer-readable string for the kind of bulk item.

  • updated_at [dttm]: The time when this file was last updated.

  • uri [chr]: The Scryfall API URI for this file.

  • description [chr]: A human-readable description for this file.

  • compressed_size [int]: The size of this file in integer bytes.

  • download_uri [chr]: The URI that hosts this bulk file for fetching.

  • content_type [chr]: The MIME type of this file.

  • content_encoding [chr]: The Content-Encoding encoding that will be used to transmit this file when you download it.

Details

URLs for files change their timestamp each day, and can be fetched programmatically. The currently available files are the following:

  • Oracle Cards: A JSON file containing one Scryfall card for each Oracle ID on Scryfall. The chosen sets for the cards are an attempt to return the most up-to-date recognizable version of the card.

  • Unique Artwork: A JSON file of Scryfall cards that together contain all unique artworks. The chosen cards promote the best image scans.

  • Default Cards: A JSON file containing every card on Scryfall in English or the printed language if the card is only available in one language.

  • All Cards: A JSON file containing every card on Scryfall in every language.

  • Rulings: A JSON file containing all Rulings on Scryfall. Each ruling refers to cards via an oracle_id.

Please note:

  • Cards in bulk data include price information, but prices should be considered dangerously stale after 24 hours. Only use bulk price information to track trends or provide a general estimate of card value. Prices are not updated frequently enough to power a storefront or sales system. You consume price information at your own risk.

  • Updates to gameplay data (such as card names, Oracle text, mana costs, etc) are much less frequent. If you only need gameplay information, downloading card data once per week or right after set releases would most likely be sufficient.

  • Every card type in every product is included, including planar cards, schemes, Vanguard cards, tokens, emblems, and funny cards.

Bulk data is only collected once every 12 hours. You can use scry_cards() to retrieve fresh objects instead.

Examples

# \donttest{
# Get information about bulk data files
scry_bulk_files()
#> # A tibble: 5 × 10
#>   name           id      type  updated_at          uri     description  
#>   <chr>          <chr>   <chr> <dttm>              <chr>   <chr>        
#> 1 Oracle Cards   27bf32… orac… 2022-01-07 10:03:51 https:… A JSON file …
#> 2 Unique Artwork 6bbcf9… uniq… 2022-01-07 10:13:04 https:… A JSON file …
#> 3 Default Cards  e2ef41… defa… 2022-01-07 10:02:39 https:… A JSON file …
#> 4 All Cards      922288… all_… 2022-01-07 10:11:49 https:… A JSON file …
#> 5 Rulings        06f54c… ruli… 2022-01-07 10:04:02 https:… A JSON file …
#> # … with 4 more variables: compressed_size <int>, download_uri <chr>,
#> #   content_type <chr>, content_encoding <chr>

# Download a bulk data file
scry_bulk_file("Rulings")
#> # A tibble: 44,486 × 4
#>    oracle_id                            source published_at comment     
#>    <chr>                                <chr>  <date>       <chr>       
#>  1 0004ebd0-dfd6-4276-b4a6-de0003e94237 wotc   2004-10-04   If there ar…
#>  2 0007c283-5b7a-4c00-9ca1-b455c8dff8c3 wotc   2019-08-23   The “comman…
#>  3 0007c283-5b7a-4c00-9ca1-b455c8dff8c3 wotc   2019-08-23   Certain car…
#>  4 0007c283-5b7a-4c00-9ca1-b455c8dff8c3 wotc   2019-08-23   If your com…
#>  5 000e5d65-96c3-498b-bd01-72b1a1991850 wotc   2004-10-04   The target …
#>  6 0012bc78-e69d-4a67-a302-e5fe0dfd4407 wotc   2019-05-03   A land norm…
#>  7 00187de2-bc48-4137-97d8-a9a0fafc76c1 wotc   2019-01-25   You can alw…
#>  8 00187de2-bc48-4137-97d8-a9a0fafc76c1 wotc   2019-01-25   Pteramander…
#>  9 00187de2-bc48-4137-97d8-a9a0fafc76c1 wotc   2019-01-25   If a creatu…
#> 10 001c6369-df13-427d-89df-718d5c09f382 wotc   2009-05-01   Vedalken He…
#> # … with 44,476 more rows
# }