PHPackages                             ypho/scryfall - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [API Development](/categories/api)
4. /
5. ypho/scryfall

ActiveLibrary[API Development](/categories/api)

ypho/scryfall
=============

A wrapper around the API from Scryfall (scryfall.com)

2.0(2y ago)11.9k3Apache-2.0PHPPHP ^8.1

Since Aug 30Pushed 2y ago2 watchersCompare

[ Source](https://github.com/Ypho/Scryfall)[ Packagist](https://packagist.org/packages/ypho/scryfall)[ Docs](https://ypho.nl)[ RSS](/packages/ypho-scryfall/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (5)Dependencies (2)Versions (6)Used By (0)

Scryfall Api Wrapper
====================

[](#scryfall-api-wrapper)

This wrapper connects with the Scryfall API.

Installation
------------

[](#installation)

You can use composer to require the package, it will automatically install the latest version.

> composer require ypho/scryfall

### Testing the package

[](#testing-the-package)

In this package there are several tests. The responses are mocked, so it won't actually spam the Scryfall API.

> vendor/bin/phpunit

How to use the package
----------------------

[](#how-to-use-the-package)

In the examples folder, there are some example scripts you can use. Otherwise, you can use the snippets below.

### Initialize new client

[](#initialize-new-client)

```
require 'vendor/autoload.php';
$client = new Ypho\Scryfall\Client();
```

### Sets

[](#sets)

```
// Get the Endpoint
$setEndpoint = $client->sets();

$setEndpoint->all(); // Returns an array with Set-objects
$setEndpoint->get('mmq'); // Returns a single Set-object of the Mercadian Masques set
```

### Cards

[](#cards)

```
$cardEndpoint = $client->cards();

$cardEndpoint->get('0038ea4d-d0a6-44a4-bee6-24c03313d2bc'); // Returns a Card-object of Sphinx's Revelation (MM3 version)
$cardEndpoint->allCardsInSet('mm3'); // Returns an array with Card-objects for all cards in MM3
```

### Symbols

[](#symbols)

```
$symbologyEndpoint = $client->symbology();

$symbologyEndpoint->all(); // Returns an array with all Symbol-objects
$symbologyEndpoint->parseMana('RG'); // Returns a ManaCost-object
```

###  Health Score

37

—

LowBetter than 83% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity24

Limited adoption so far

Community12

Small or concentrated contributor base

Maturity75

Established project with proven stability

 Bus Factor1

Top contributor holds 92.3% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~458 days

Total

5

Last Release

987d ago

Major Versions

v1.0.3 → 2.02023-09-05

PHP version history (2 changes)1.0PHP &gt;=7.1

2.0PHP ^8.1

### Community

Maintainers

![](https://www.gravatar.com/avatar/1beed62e171411d8d12ed81f47a1c71b056a4748e39ec012bd8a6775419017d7?d=identicon)[Ypho](/maintainers/Ypho)

---

Top Contributors

[![ypho](https://avatars.githubusercontent.com/u/7271977?v=4)](https://github.com/ypho "ypho (12 commits)")[![silasary](https://avatars.githubusercontent.com/u/194254?v=4)](https://github.com/silasary "silasary (1 commits)")

---

Tags

Api Wrappermagicscryfall.commagic the gatheringscryfall

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/ypho-scryfall/health.svg)

```
[![Health](https://phpackages.com/badges/ypho-scryfall/health.svg)](https://phpackages.com/packages/ypho-scryfall)
```

###  Alternatives

[tencentcloud/tencentcloud-sdk-php

TencentCloudApi php sdk

3731.2M42](/packages/tencentcloud-tencentcloud-sdk-php)[fiveam-code/laravel-notion-api

Laravel Wrapper for the Notion API

435224.4k1](/packages/fiveam-code-laravel-notion-api)[marcreichel/igdb-laravel

A Laravel wrapper for version 4 of the IGDB API (Apicalypse) including webhook handling

115146.6k1](/packages/marcreichel-igdb-laravel)[otherguy/php-currency-api

A PHP API Wrapper to offer a unified programming interface for popular Currency Rate APIs.

2526.2k](/packages/otherguy-php-currency-api)[grok-php/client

Grok PHP Client is a robust and community-driven PHP client library for seamless integration with Grok AI API, offering efficient access to advanced AI and data processing capabilities.

325.9k4](/packages/grok-php-client)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
