# YGOPRODeck API

> Returns Yu-Gi-Oh! cards by name, id, archetype or set with text and stats, plus the list of archetype names.

Category: Sports & Gaming. Region: global. 8 endpoints at `https://api.hoshime.com/v1/ygoprodeck/<endpoint>`, `GET` with query parameters, answering `{data, meta}` (see https://hoshime.com/docs/responses.md). Reference: https://hoshime.com/docs/platforms/ygoprodeck
## GET /v1/ygoprodeck/card

One card by its exact English name, with its text and stats.

Scope: `social:read` · Units: 1 · Cached: 1440 min

| Parameter | Type | Required | Description |
|---|---|---|---|
| `name` | string | yes | Exact card name, such as Dark Magician. (e.g. Dark Magician) |
| `tunnel` | string | no | Id or name of one of your tunnels: the call reads the source from the machine that runs `hoshime tunnel`, through its own connection. Fails with 409 tunnel_unavailable when no machine is connected. Cannot be combined with proxy. |
| `proxy` | string | no | Your own http:// or https:// proxy, such as http://user:pass@proxy.example.com:8080, on a public address. The call reads the source only through it. |
| `profileId` | string | no | Browser profile whose login the call sends (its cookies), so the source answers as that account. Without tunnel or proxy it leaves through the profile's own residential IP. Needs the browser:read scope. Data read logged in is for your account only. |

Response data fields: `archetype` (string), `attack` (integer (int64)), `attribute` (string), `defense` (integer (int64)), `description` (string), `frameType` (string), `id` (string), `image` (string), `level` (integer (int64)), `name` (string), `race` (string), `type` (string), `url` (string)

```bash
curl "https://api.hoshime.com/v1/ygoprodeck/card?name=Dark+Magician" -H "Authorization: Bearer $HOSHIME_TOKEN"
```

## GET /v1/ygoprodeck/search

Cards whose name contains a text, up to a limit.

Scope: `social:read` · Units: 1 · Cached: 360 min · Paginated: cursor

| Parameter | Type | Required | Description |
|---|---|---|---|
| `name` | string | yes | Text the card name contains, such as dark magi. (e.g. dark magi) |
| `limit` | integer | no | Items per page, 1 to 50. (default 10) |
| `tunnel` | string | no | Id or name of one of your tunnels: the call reads the source from the machine that runs `hoshime tunnel`, through its own connection. Fails with 409 tunnel_unavailable when no machine is connected. Cannot be combined with proxy. |
| `proxy` | string | no | Your own http:// or https:// proxy, such as http://user:pass@proxy.example.com:8080, on a public address. The call reads the source only through it. |
| `profileId` | string | no | Browser profile whose login the call sends (its cookies), so the source answers as that account. Without tunnel or proxy it leaves through the profile's own residential IP. Needs the browser:read scope. Data read logged in is for your account only. |

Response data fields: `archetype` (string), `attack` (integer (int64)), `attribute` (string), `defense` (integer (int64)), `description` (string), `frameType` (string), `id` (string), `image` (string), `level` (integer (int64)), `name` (string), `race` (string), `type` (string), `url` (string)

```bash
curl "https://api.hoshime.com/v1/ygoprodeck/search?name=dark+magi" -H "Authorization: Bearer $HOSHIME_TOKEN"
```

## GET /v1/ygoprodeck/cardById

One card by its YGOPRODeck id, with its text and stats.

Scope: `social:read` · Units: 1 · Cached: 1440 min

| Parameter | Type | Required | Description |
|---|---|---|---|
| `id` | integer | yes | Card id, such as 46986414 for Dark Magician. (e.g. 46986414) |
| `tunnel` | string | no | Id or name of one of your tunnels: the call reads the source from the machine that runs `hoshime tunnel`, through its own connection. Fails with 409 tunnel_unavailable when no machine is connected. Cannot be combined with proxy. |
| `proxy` | string | no | Your own http:// or https:// proxy, such as http://user:pass@proxy.example.com:8080, on a public address. The call reads the source only through it. |
| `profileId` | string | no | Browser profile whose login the call sends (its cookies), so the source answers as that account. Without tunnel or proxy it leaves through the profile's own residential IP. Needs the browser:read scope. Data read logged in is for your account only. |

Response data fields: `archetype` (string), `attack` (integer (int64)), `attribute` (string), `defense` (integer (int64)), `description` (string), `frameType` (string), `id` (string), `image` (string), `level` (integer (int64)), `name` (string), `race` (string), `type` (string), `url` (string)

```bash
curl "https://api.hoshime.com/v1/ygoprodeck/cardById?id=46986414" -H "Authorization: Bearer $HOSHIME_TOKEN"
```

## GET /v1/ygoprodeck/archetypeCards

Cards of one archetype, such as Blue-Eyes, paged.

Scope: `social:read` · Units: 1 · Cached: 1440 min · Paginated: cursor

| Parameter | Type | Required | Description |
|---|---|---|---|
| `archetype` | string | yes | Archetype name as YGOPRODeck writes it, such as Blue-Eyes. (e.g. Blue-Eyes) |
| `limit` | integer | no | Cards per page, from 1 to 100. (default 20; e.g. 2) |
| `cursor` | string | no | meta.pagination.nextCursor of the previous page. Omit it for the first page. |
| `tunnel` | string | no | Id or name of one of your tunnels: the call reads the source from the machine that runs `hoshime tunnel`, through its own connection. Fails with 409 tunnel_unavailable when no machine is connected. Cannot be combined with proxy. |
| `proxy` | string | no | Your own http:// or https:// proxy, such as http://user:pass@proxy.example.com:8080, on a public address. The call reads the source only through it. |
| `profileId` | string | no | Browser profile whose login the call sends (its cookies), so the source answers as that account. Without tunnel or proxy it leaves through the profile's own residential IP. Needs the browser:read scope. Data read logged in is for your account only. |

Response data fields: `archetype` (string), `attack` (integer (int64)), `attribute` (string), `defense` (integer (int64)), `description` (string), `frameType` (string), `id` (string), `image` (string), `level` (integer (int64)), `name` (string), `race` (string), `type` (string), `url` (string)

```bash
curl "https://api.hoshime.com/v1/ygoprodeck/archetypeCards?archetype=Blue-Eyes&limit=2" -H "Authorization: Bearer $HOSHIME_TOKEN"
```

## GET /v1/ygoprodeck/setCards

Cards of one set, by its exact set name, paged.

Scope: `social:read` · Units: 1 · Cached: 1440 min · Paginated: cursor

| Parameter | Type | Required | Description |
|---|---|---|---|
| `set` | string | yes | Exact set name, such as Legend of Blue Eyes White Dragon. (e.g. Legend of Blue Eyes White Dragon) |
| `limit` | integer | no | Cards per page, from 1 to 100. (default 20; e.g. 2) |
| `cursor` | string | no | meta.pagination.nextCursor of the previous page. Omit it for the first page. |
| `tunnel` | string | no | Id or name of one of your tunnels: the call reads the source from the machine that runs `hoshime tunnel`, through its own connection. Fails with 409 tunnel_unavailable when no machine is connected. Cannot be combined with proxy. |
| `proxy` | string | no | Your own http:// or https:// proxy, such as http://user:pass@proxy.example.com:8080, on a public address. The call reads the source only through it. |
| `profileId` | string | no | Browser profile whose login the call sends (its cookies), so the source answers as that account. Without tunnel or proxy it leaves through the profile's own residential IP. Needs the browser:read scope. Data read logged in is for your account only. |

Response data fields: `archetype` (string), `attack` (integer (int64)), `attribute` (string), `defense` (integer (int64)), `description` (string), `frameType` (string), `id` (string), `image` (string), `level` (integer (int64)), `name` (string), `race` (string), `type` (string), `url` (string)

```bash
curl "https://api.hoshime.com/v1/ygoprodeck/setCards?set=Legend+of+Blue+Eyes+White+Dragon&limit=2" -H "Authorization: Bearer $HOSHIME_TOKEN"
```

## GET /v1/ygoprodeck/archetypes

The archetype names of the card database, paged in alphabetical order of the database.

Scope: `social:read` · Units: 1 · Cached: 1440 min · Paginated: cursor

| Parameter | Type | Required | Description |
|---|---|---|---|
| `limit` | integer | no | Archetypes per page, from 1 to 500. (default 100; e.g. 5) |
| `cursor` | string | no | meta.pagination.nextCursor of the previous page. Omit it for the first page. |
| `tunnel` | string | no | Id or name of one of your tunnels: the call reads the source from the machine that runs `hoshime tunnel`, through its own connection. Fails with 409 tunnel_unavailable when no machine is connected. Cannot be combined with proxy. |
| `proxy` | string | no | Your own http:// or https:// proxy, such as http://user:pass@proxy.example.com:8080, on a public address. The call reads the source only through it. |
| `profileId` | string | no | Browser profile whose login the call sends (its cookies), so the source answers as that account. Without tunnel or proxy it leaves through the profile's own residential IP. Needs the browser:read scope. Data read logged in is for your account only. |

Response data fields: `name` (string)

```bash
curl "https://api.hoshime.com/v1/ygoprodeck/archetypes?limit=5" -H "Authorization: Bearer $HOSHIME_TOKEN"
```

## GET /v1/ygoprodeck/cardSets

The booster sets and products of the card database, with their codes and release dates, paged.

Scope: `social:read` · Units: 1 · Cached: 1440 min · Paginated: cursor

| Parameter | Type | Required | Description |
|---|---|---|---|
| `limit` | integer | no | Sets per page, from 1 to 500. (default 50; e.g. 5) |
| `cursor` | string | no | meta.pagination.nextCursor of the previous page. Omit it for the first page. |
| `tunnel` | string | no | Id or name of one of your tunnels: the call reads the source from the machine that runs `hoshime tunnel`, through its own connection. Fails with 409 tunnel_unavailable when no machine is connected. Cannot be combined with proxy. |
| `proxy` | string | no | Your own http:// or https:// proxy, such as http://user:pass@proxy.example.com:8080, on a public address. The call reads the source only through it. |
| `profileId` | string | no | Browser profile whose login the call sends (its cookies), so the source answers as that account. Without tunnel or proxy it leaves through the profile's own residential IP. Needs the browser:read scope. Data read logged in is for your account only. |

Response data fields: `cardCount` (integer (int64)), `code` (string), `image` (string), `name` (string), `releaseDate` (string)

```bash
curl "https://api.hoshime.com/v1/ygoprodeck/cardSets?limit=5" -H "Authorization: Bearer $HOSHIME_TOKEN"
```

## GET /v1/ygoprodeck/databaseVersion

The version of the card database and when it was last updated.

Scope: `social:read` · Units: 1 · Cached: 10 min

| Parameter | Type | Required | Description |
|---|---|---|---|
| `tunnel` | string | no | Id or name of one of your tunnels: the call reads the source from the machine that runs `hoshime tunnel`, through its own connection. Fails with 409 tunnel_unavailable when no machine is connected. Cannot be combined with proxy. |
| `proxy` | string | no | Your own http:// or https:// proxy, such as http://user:pass@proxy.example.com:8080, on a public address. The call reads the source only through it. |
| `profileId` | string | no | Browser profile whose login the call sends (its cookies), so the source answers as that account. Without tunnel or proxy it leaves through the profile's own residential IP. Needs the browser:read scope. Data read logged in is for your account only. |

Response data fields: `lastUpdate` (string), `version` (string)

```bash
curl "https://api.hoshime.com/v1/ygoprodeck/databaseVersion" -H "Authorization: Bearer $HOSHIME_TOKEN"
```
