Skip to content

Commit

Permalink
Merge pull request #12 from rubenrangel/add-catalog
Browse files Browse the repository at this point in the history
feat: add `IScryfallCatalog` interface
  • Loading branch information
rubenrangel committed May 21, 2023
2 parents b5b0633 + 86b32af commit 2f69cc1
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 0 deletions.
29 changes: 29 additions & 0 deletions src/IScryfallCatalog.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
import { IScryfallObject } from "./IScryfallObject";

/**
* A Catalog object contains an array of Magic datapoints (words, card values, etc). Catalog objects are provided by the
* API as aids for building other Magic software and understanding possible values for a field on Card objects.
*
* @see https://scryfall.com/docs/api/catalogs
*/
export interface IScryfallCatalog extends IScryfallObject {
/**
* @inheritDoc
*/
object: "catalog";

/**
* A link to the current catalog on Scryfall’s API.
*/
uri: string;

/**
* The number of items in the `data` array.
*/
total_values: number;

/**
* An array of datapoints.
*/
data: string[];
}
1 change: 1 addition & 0 deletions src/index.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
export * from "./IScryfallBulkData";
export * from "./IScryfallCardSymbol";
export * from "./IScryfallCatalog";
export * from "./IScryfallColor";
export * from "./IScryfallError";
export * from "./IScryfallList";
Expand Down

0 comments on commit 2f69cc1

Please sign in to comment.