$ curl https://api.tcgpricelookup.com/v1/search

最快的
TCG 价格 API
专为开发者打造

支持 Pokemon、Magic: The Gathering、游戏王、Lorcana、航海王等 8 款游戏的实时卡牌价格 API。30 万余张卡牌,5 个官方 SDK,含免费套餐。

300,000+ 张卡牌
8 款游戏
5 个 SDK
2 个市场
Free 免费套餐
24/7 实时更新
快速开始 JavaScript
// Search for any card across all 8 games
import { TCGLookup } from 'tcglookup';

const tcg = new TCGLookup({ apiKey: 'your-key' });
const cards = await tcg.search('charizard');
// 47 results, real-time prices from TCGPlayer + eBay

const card = await tcg.getCard('pokemon-sv4-charizard-ex-006');
// Market price, per-condition, PSA/BGS/CGC graded values

TCG API工作原理

从零开始到获取卡牌价格数据,5分钟内完成。三步搞定,无需复杂配置。

01

获取免费API密钥

在tcgpricelookup.com注册 — 无需信用卡。API密钥立即生成,适用于所有支持的8款游戏。免费计划提供每日200次请求,立即开始开发。

API key: tpl_live_xxxxxxxxxxxx
02

安装SDK

选择您偏好的编程语言。官方SDK支持JavaScript、Python、Go、Rust和PHP。所有SDK均由TCG Price Lookup团队维护,附带完整类型定义。

$ npm install tcglookup
03

获取卡牌价格

按卡牌名称、套牌或ID搜索。通过单一API获取TCGPlayer和eBay实时价格、按品相分类的价格、评级价格及价格历史。

search GET /v1/search?q=charizard
card GET /v1/cards/:id
history GET /v1/cards/:id/prices
batch POST /v1/cards/batch

可以构建什么

TCG卡牌价格API被广泛应用于从个人脚本到生产级交易应用的各类场景。

💰

价格比较工具

并排展示TCGPlayer市场价格和eBay成交价格。买家可找到最低价,卖家可设置有竞争力的定价。

📊

收藏品追踪器

让收藏家录入卡牌并随时间追踪收藏价值。通过价格历史端点绘制盈亏图表。

🤖

Discord机器人

为TCG Discord服务器添加斜杠命令,让成员无需离开聊天即可查询卡牌价格。支持所有8款游戏的开源Discord机器人可在数分钟内部署。

🔄

交易应用

用实时价格数据支持买卖与交换界面。支持显示合理交换价格、检测低价卡牌以及批量获取整套卡组的价格。

🔔

价格提醒

监控特定卡牌,当价格超过阈值时通知用户。可使用定时轮询或付费计划的Webhook通知。

📈

分析仪表盘

构建价格历史图表、全套牌趋势分析和套牌总市值估算。价格历史端点提供按月的每日快照数据。

一个TCG API覆盖所有游戏

一个API密钥支持8款游戏。Pokemon TCG API、MTG API、游戏王API、Lorcana、One Piece等,通过统一界面全部访问。

Pokemon

30,000+ cards

Access real-time pricing for over 30,000 Pokemon TCG cards. Search by name, set, or card number. Get per-condition pricing from Near Mint to Damaged, plus PSA, BGS, and CGC graded values.

查看Pokemon API文档 →
Pokemon API example JavaScript
const results = await tcg.search('charizard', { game: 'pokemon' });
// Returns: prices for all Charizard cards across all sets

Magic: The Gathering

100,000+ cards

Access real-time pricing for over 100,000 Magic: The Gathering cards. Complete coverage of all sets from Alpha to the latest release. Per-condition and graded pricing.

查看Magic: The Gathering API文档 →
Magic: The Gathering API example JavaScript
const results = await tcg.search('black lotus', { game: 'mtg' });
// Returns: prices for Black Lotus across all editions

Yu-Gi-Oh!

40,000+ cards

Access real-time pricing for over 40,000 Yu-Gi-Oh! cards. Coverage spans all sets and rarities with per-condition and graded card values.

查看Yu-Gi-Oh! API文档 →
Yu-Gi-Oh! API example JavaScript
const results = await tcg.search('blue-eyes white dragon', { game: 'yugioh' });
// Returns: prices for Blue-Eyes White Dragon across all sets

Disney Lorcana

3,000+ cards

Access real-time pricing for over 3,000 Disney Lorcana cards. Full coverage since launch with per-condition pricing and graded values.

查看Disney Lorcana API文档 →
Disney Lorcana API example JavaScript
const results = await tcg.search('elsa', { game: 'lorcana' });
// Returns: prices for all Elsa cards

One Piece

6,000+ cards

Access real-time pricing for over 6,000 One Piece TCG cards. Complete set coverage with per-condition pricing and graded values.

查看One Piece API文档 →
One Piece API example JavaScript
const results = await tcg.search('luffy', { game: 'onepiece' });
// Returns: prices for all Luffy cards

Pokemon Japan

20,000+ cards

Access real-time pricing for over 20,000 Japanese Pokemon TCG cards. Covers Japanese-exclusive sets, promos, and special releases.

查看Pokemon Japan API文档 →
Pokemon Japan API example JavaScript
const results = await tcg.search('pikachu', { game: 'pokemonjp' });
// Returns: prices for Japanese Pikachu cards

Star Wars: Unlimited

2,500+ cards

Access real-time pricing for over 2,500 Star Wars: Unlimited cards. Full coverage with per-condition pricing and graded values.

查看Star Wars: Unlimited API文档 →
Star Wars: Unlimited API example JavaScript
const results = await tcg.search('darth vader', { game: 'swu' });
// Returns: prices for all Darth Vader cards

Flesh and Blood

8,000+ cards

Access real-time pricing for over 8,000 Flesh and Blood cards. Complete coverage with per-condition pricing and graded values.

查看Flesh and Blood API文档 →
Flesh and Blood API example JavaScript
const results = await tcg.search('bravo', { game: 'fab' });
// Returns: prices for all Bravo cards

TCG API 对比

TCG Price Lookup与Scryfall、pokemontcg.io、TCGPlayer API及自建爬虫的对比。

功能 TCG Price Lookup Scryfall API pokemontcg.io TCGPlayer API 自建爬虫
支持游戏数量 8款 仅MTG 仅Pokemon 多款(变动中) 自定义
实时价格 部分(TCGP) ✓(仅TCGP) 视情况而定
按品相分类价格 手动
评级卡价格(PSA/BGS/CGC) 手动
官方SDK 5种语言 仅社区版 1个(JS)
免费计划 ✓ 200次请求/天 无价格数据 无价格数据 需要申请 ✓(自行承担)
价格历史 有限 自建

开发者生态系统

除REST API外,还提供5种语言的官方SDK、开箱即用的工具以及完善的开发者文档。

官方SDK — 6种语言

CLI Tool

GitHub →

Live trading card prices in your terminal. Search, lookup, price history, JSON output for scripting. Also installable via npm.

$ brew tap TCG-Price-Lookup/tcg && brew install tcglookup
  • Search cards from terminal
  • Price history lookups
  • JSON output for scripting

Go SDK

GitHub →

Official Go SDK for the TCG Price Lookup API. Idiomatic Go, stdlib net/http, zero third-party deps, functional options, typed errors.

$ go get github.com/TCG-Price-Lookup/tcglookup-go
  • Zero third-party dependencies
  • Idiomatic Go design
  • Functional options pattern

JavaScript / TypeScript SDK

GitHub →

Official JavaScript/TypeScript SDK for the TCG Price Lookup API. Zero deps, ESM + CJS, works in Node 18+, browsers, Bun, Deno, Cloudflare Workers.

$ npm install tcglookup
  • Zero dependencies
  • ESM and CommonJS support
  • Full TypeScript types

PHP SDK

GitHub →

Official PHP SDK for the TCG Price Lookup API. PHP 8.1+, Guzzle, PSR-4, typed exception hierarchy.

$ composer require tcg-price-lookup/tcglookup
  • PHP 8.1+ support
  • Guzzle HTTP client
  • PSR-4 autoloading

Python SDK

GitHub →

Official Python SDK for the TCG Price Lookup API. Python 3.9+, built on httpx, typed exception hierarchy, context manager support.

$ pip install tcglookup
  • Python 3.9+ support
  • Built on httpx (async ready)
  • Typed exception hierarchy

Rust SDK

GitHub →

Official Rust SDK for the TCG Price Lookup API. Async with reqwest + tokio, typed Error enum, builder pattern.

$ cargo add tcglookup
  • Async with reqwest + tokio
  • Typed Error enum
  • Builder pattern

工具与资源 — 5个工具

Awesome TCG

list

Curated list of the TCG Price Lookup ecosystem — REST API, 5 SDKs, CLI, code examples in 8 languages, blog tutorials.

github.com/TCG-Price-Lookup/awesome-tcg#readme →

Discord Bot

bot

Self-hosted Discord bot for live trading card prices. Slash commands powered by the TCG Price Lookup API. Supports all 8 games.

github.com/TCG-Price-Lookup/tcg-discord-bot#readme →

Next.js Starter

starter

One-click deployable Next.js 16 starter for the TCG Price Lookup API. Search live trading card prices across 8 games out of the box.

$ npx create-next-app -e https://github.com/TCG-Price-Lookup/nextjs-tcg-starter

OpenAPI Specification

spec

OpenAPI 3.1 specification for the TCG Price Lookup API. Use with Swagger UI, Redoc, Postman, or any OpenAPI-compatible tool.

github.com/TCG-Price-Lookup/tcg-api-openapi#readme →

Postman Collection

collection

Ready-to-use Postman collection and environment for the TCG Price Lookup API. Import, set your API key, and start testing.

github.com/TCG-Price-Lookup/tcg-api-postman#readme →

常见问题

从TCG Price Lookup API入门到请求限制、评级卡价格的常见问题解答。

什么是TCG API?

+

TCG API(集换式卡牌游戏API)是一种提供卡牌数据编程访问的Web服务,可获取卡牌详情、套牌信息和实时市场价格等数据。开发者使用TCG API构建价格追踪工具、收藏管理工具、Discord机器人等应用。

TCG Price Lookup API是免费的吗?

+

是的,TCG Price Lookup为爱好项目和原型提供每日200次请求的免费计划(仅限非商业用途)。付费计划提供更高的请求限制、价格历史端点、eBay价格、评级卡价格以及商业使用权。无需信用卡即可开始使用。

支持哪些集换式卡牌游戏?

+

目前支持8款游戏:Pokemon TCG(英文版)、Pokemon日文版、Magic: The Gathering、游戏王、Disney Lorcana、One Piece卡牌游戏、Star Wars: Unlimited以及Flesh and Blood。所有游戏使用相同的统一搜索和卡牌端点。

如何获取Pokemon TCG API密钥?

+

在tcgpricelookup.com注册并验证邮箱后,API密钥将立即生成。无需审批流程,即可立即向Pokemon TCG API(以及所有其他游戏)发送请求。

支持评级卡价格(PSA、BGS、CGC)吗?

+

是的。可获取PSA(1-10级)、Beckett(BGS 7-10,包含9.5和10黑标)以及CGC(1-10级)的评级卡价格。评级价格来源于eBay销售数据。需要Trader计划或更高级别。

API的请求限制是怎样的?

+

免费计划每日最多200次请求(突发:每3秒1次请求)。Trader计划(月费$14.99)每日10,000次请求(突发:每秒1次请求)。Business计划(月费$89.99)每日100,000次请求(突发:每秒3次请求)。每日限制在UTC午夜重置。

有哪些可用的SDK?

+

提供5个官方SDK:JavaScript/TypeScript(npm install tcglookup)、Python(pip install tcglookup)、Go(go get github.com/TCG-Price-Lookup/tcglookup-go)、Rust(cargo add tcglookup)、PHP(composer require tcg-price-lookup/tcglookup)。还提供CLI工具供终端访问。

卡牌价格多久更新一次?

+

卡牌价格持续更新。TCGPlayer市场价格在有新销售数据时每隔数小时更新一次。eBay成交记录每天更新。对于时效性要求较高的应用,可使用价格历史端点跟踪趋势。

立即使用TCG API开始开发

含免费计划。无需信用卡。立即访问8款游戏的30万余张卡牌。