Scryfall Service - Gnome-Lackey/mtglm-docs GitHub Wiki
Contracts
GET All Cards GET Card GET Random Card GET Set
[GET] /cards
Get cards from scryfall API
Query Parameters
For more information on how to use queries with this endpoint, see our service query FAQ page in the wiki.
| Parameter | Data type | Examples |
|---|---|---|
| colors | string OR string[] | ?colors=u ?colors=[]u,b,r |
| format | string | ?format=modern |
| subtype | string | ?subtype=legendary |
| language | string | ?language=en |
| border | string | ?border=black |
| type | string OR string[] | ?type=creature ?type=[]creature,zombie,donkey |
Request Headers
{
Authorization: Bearer Identity Token;
}
Response Body
{
status: number;
data: [
{
colors: string[];
costs: {
mana: string;
converted: number;
};
id: string;
identity: string[];
image: string;
language: string;
name: string;
rarity: string;
releasedOn: string;
set: {
code: string;
name: string;
};
subtype: string;
type: string;
}
],
...
}
[GET] /cards/{card id}
Get an existing card from scryfall API
Request Headers
{
Authorization: Bearer Identity Token;
}
Response Body
{
status: number;
data: {
colors: string[];
costs: {
mana: string;
converted: number;
};
id: string;
identity: string[];
image: string;
language: string;
name: string;
rarity: string;
releasedOn: string;
set: {
code: string;
name: string;
};
subtype: string;
type: string;
}
}
[GET] /cards/random
Get random existing card from scryfall API
Query Parameters
For more information on how to use queries with this endpoint, see our service query FAQ page in the wiki.
| Parameter | Data type | Examples |
|---|---|---|
| colors | string OR string[] | ?colors=u ?colors=[]u,b,r |
| format | string | ?format=modern |
| subtype | string | ?subtype=legendary |
| language | string | ?language=en |
| border | string | ?border=black |
| type | string OR string[] | ?type=creature ?type=[]creature,zombie,donkey |
Request Headers
{
Authorization: Bearer Identity Token;
}
Response Body
{
status: number;
data: {
colors: string[];
costs: {
mana: string;
converted: number;
};
id: string;
identity: string[];
image: string;
language: string;
name: string;
rarity: string;
releasedOn: string;
set: {
code: string;
name: string;
};
subtype: string;
type: string;
}
}
[GET] /sets/{set code}
Get an existing set from scryfall API
Request Headers
{
Authorization: Bearer Identity Token;
}
Response Body
{
status: number;
data: {
cardCount: number;
code: string;
id: string;
name: string;
releasedOn: string;
}
}