# Ygoprodeck — Wrapped API

> **You are on:** `https://api.beta.paywithlocus.com/api` | [llms.txt](https://beta.paywithlocus.com/llms.txt) | [docs](https://docs.paywithlocus.com)
>
> Locus runs on multiple environments -- make sure every URL you call matches your expected environment.
> | Environment | Landing | API | Docs |
> |---|---|---|---|
> | Production | paywithlocus.com | api.paywithlocus.com | docs.paywithlocus.com |
> | Beta | beta.paywithlocus.com | api.beta.paywithlocus.com | docs.paywithlocus.com |
> | Stage | stage.paywithlocus.com | api.stage.paywithlocus.com | docs.paywithlocus.com |
>
> If the API URL above doesn't match your expected environment, re-fetch this file from the correct domain.

> Search and retrieve detailed Yu-Gi-Oh! card information including attributes, effects, and images from the comprehensive YGOProDeck database. Browse the complete card catalog or look up specific cards to find everything you need about their stats and abilities.

**Category:** Entertainment | **Website:** [ygoprodeck.com/](https://ygoprodeck.com/) | **Docs:** [parse.bot/marketplace/788e9356-c857-4d32-bff3-22ba452c5da0/ygoprodeck-com-api](https://parse.bot/marketplace/788e9356-c857-4d32-bff3-22ba452c5da0/ygoprodeck-com-api)

Pay-per-use API proxy for Locus Pro. Each call burns credits from your workspace balance.

## Access

**Base URL:** `https://api.beta.paywithlocus.com/api/wrapped/credits/ygoprodeck/`
**Auth:** `Authorization: Bearer <LOCUS_CREDITS_SECRET_KEY>` (an `lcr_` secret key or a scoped `lcac_` agent credential)
**Required header:** `Idempotency-Key: <fresh UUID per call>`. A retry with the same key replays the stored result without a new charge.
**Response:** the provider response after any endpoint-specific normalization. `X-Locus-Credits-Charged` carries the charge and `X-Locus-Credits-Balance` the remaining balance. Insufficient credits return `402` before the provider is called.
**Pricing:** estimated costs below are USD. Locus debits the credit equivalent at your workspace rate.

Full call contract: https://docs.paywithlocus.com/api-reference/introduction

> Using a Pay With Locus wallet key (`claw_` prefix)? Wallet routes are documented separately: https://docs.paywithlocus.com/wrapped-apis/for-agents

## Endpoints

### Get card details

Retrieve comprehensive details for a specific Yu-Gi-Oh! card by ID or exact name. Returns a single card object with full information including pricing, set appearances, and images. At least one of id or name must be provided.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `id` | string | No | Card ID (e.g. '89631139'). At least one of id or name is required. |
| `name` | string | No | Exact card name (e.g. 'Blue-Eyes White Dragon'). At least one of id or name is required. |

```bash
curl -X POST https://api.beta.paywithlocus.com/api/wrapped/credits/ygoprodeck/get-card-details \
  -H "Authorization: Bearer $LOCUS_CREDITS_SECRET_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{"id":"<string>","name":"<string>"}'
```

### Get cards

Search for Yu-Gi-Oh! cards using various filters. Supports fuzzy name search, exact name, type, attribute, level, atk, def, archetype, and race. Returns paginated results with metadata. When using num or offset, both must be provided together.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `archetype` | string | No | Card archetype (e.g. 'Blue-Eyes', 'Dark Magician'). |
| `atk` | integer | No | Attack value. |
| `attribute` | string | No | Card attribute. |
| `def` | integer | No | Defense value. |
| `fname` | string | No | Fuzzy name search keyword (e.g. 'Blue-Eyes'). |
| `level` | integer | No | Card level or rank. |
| `name` | string | No | Exact name of the card. |
| `num` | integer | No | Number of results per page. Must be used together with offset. |
| `offset` | integer | No | Pagination offset. Must be used together with num. |
| `race` | string | No | Card race or spell/trap type (e.g. 'Dragon', 'Spellcaster', 'Continuous', 'Quick-Play'). |
| `type` | string | No | Card type (e.g. 'Normal Monster', 'Spell Card', 'Effect Monster', 'Fusion Monster'). |

```bash
curl -X POST https://api.beta.paywithlocus.com/api/wrapped/credits/ygoprodeck/get-cards \
  -H "Authorization: Bearer $LOCUS_CREDITS_SECRET_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{"archetype":"<string>","atk":"<integer>","attribute":"<string>","def":"<integer>","fname":"<string>","level":"<integer>","name":"<string>","num":"<integer>","offset":"<integer>","race":"<string>","type":"<string>"}'
```

### List all cards

List all cards available in the YGOProDeck database with pagination. Returns cards in alphabetical order with full card data and pagination metadata.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `limit` | integer | No | Number of cards to return per page. |
| `offset` | integer | No | Pagination offset. |

```bash
curl -X POST https://api.beta.paywithlocus.com/api/wrapped/credits/ygoprodeck/list-all-cards \
  -H "Authorization: Bearer $LOCUS_CREDITS_SECRET_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{"limit":"<integer>","offset":"<integer>"}'
```

## Next steps

- [All wrapped API providers](https://beta.paywithlocus.com/wapi/index.md): pick another provider.
- [Find and call tools](https://beta.paywithlocus.com/agent/tools.md): price ceilings, async results, and errors.
- [Credits and billing](https://beta.paywithlocus.com/agent/billing.md): what a call costs and how to add credits.
- [Agent docs index](https://beta.paywithlocus.com/agent/index.md): every Locus agent page.