Chess a player's games with PGN API

Use the Chess a player's games with PGN API to retrieve match records, chess positions and move notation, record identities and titles and source-page links as structured JSON from Chess. Supply public username in the query; optionally select source site, calendar period and performance category to set the requested scope. Use these results to assemble a score display and connect the reported event status with the relevant competitors. Chess.com date-range lookup reads at most 3 months per call; continuation uses the returned next_to date. The detail page includes parameter definitions, paired request and response examples, and usage pricing for this operation.

Selected price
$0.002 / billing creditPublished pricing
Sellers / implementations
1 / 1
Requests · 30d
—Loading...
Success rate · 30d
—Loading...

Run sends a real API request. Charges follow the published API contract.

Request parameters
Username.
Optional parameters (25)
chesscom or lichess.
YYYY-MM: games of that month.
Games to return (chess.com 1-500, lichess 1-100; default 50).
lichess only: bullet, blitz, rapid, classical, correspondence, chess960 ...
lichess only: true rated games only, false casual only.
lichess only: `next_until` from the previous page.
Only games of this time class: bullet, blitz, rapid, daily (lichess: correspondence) or classical (lichess). On lichess it stands in for `perf` when `perf` is not given.
Only games the player had this colour in.
Only games the player won, lost or drew. On lichess it is applied to the page of games fetched, so a page can hold fewer than `limit` games; keep paging with `next_until`.
Only games against this username.
Games played from this date (YYYY-MM-DD or epoch milliseconds). Same as `from`.
lichess only: true for games with computer analysis, false for games without.
Games played from this date (YYYY-MM-DD or epoch milliseconds).
Games played up to this date, inclusive (YYYY-MM-DD or epoch milliseconds). chess.com pages with `next_to`.
Only games whose opening name contains this text (e.g. sicilian defense, queens gambit declined).
Only games whose ECO code starts with this (e.g. B90, B9 or B).
lichess only: newest first (default) or oldest first (page with `next_after` as `after`).
lichess only, with sort=oldest: `next_after` from the previous page.
lichess only: true also returns games still being played.
lichess only: true adds the clock after every move (`clocks_centiseconds`).
0 leaves out the bulky `raw` source blocks (often 10-30x smaller).
Comma-separated fields to return, e.g. `posts.id,posts.title`. Call metadata is always included.
1 skips the 24-hour cache and fetches live.
JSON only for this OpenAny product. Omit output or use json; CSV and NDJSON are not supported.
With output=csv|ndjson: the top-level list to turn into rows (e.g. `reviews`), or `.` for the whole object as one row.

Sample response

{
  "cached": false,
  "count": 1,
  "credits_used": 1,
  "fetched_at": "2026-11-19T12:20:22.790Z",
  "games": [
    {
      "accuracies": {
        "black": 68.59,
        "white": 66.72
      },
      "black": {
        "rating": 3080,
        "result": "resigned",
        "username": "Carnivoras"
      },
      "eco": "A01",
      "end_time": "2026-11-19T01:35:02.000Z",
      "fen": "1Q2k3/2Rb2q1/3p3r/3P1p2/4p2p/PP2PpP1/5P2/6K1 b - - 1 39",
      "id": "9dd53891-e3b8-11f1-baf4-33d19f01000f",
      "opening": "Nimzowitsch Larsen Attack Modern Variation 2.Bb2 Nc6 3.c4 g6",
      "pgn": "[Event \"Live Chess\"]\n[Site \"Chess.com\"]\n[Date \"2026.11.19\"]\n[Round \"-\"]\n[White \"Hikaru\"]\n[Black \"Carnivoras\"]\n[Result \"1-0\"]\n[CurrentPosition \"1Q2k3/2Rb2q1/3p3r/3P1p2/4p2p/PP2PpP1/5P2/6K1 b - - 1 39\"]\n[Timezone \"UTC\"]\n[ECO \"A01\"]\n[ECOUrl \"https://www.chess.com/openings/Nimzowitsch-Larsen-Attack-Modern-Variation-2.Bb2-Nc6-3.c4-g6\"]\n[UTCDate \"2026.11.19\"]\n[UTCTime \"01:29:08\"]\n[WhiteElo \"3465\"]\n[BlackElo \"3080\"]\n[TimeControl \"180\"]\n[Termination \"Hikaru won by resignation\"]\n[StartTime \"01:29:08\"]\n[EndDate \"2026.11.19\"]\n[EndTime \"01:35:02\"]\n[Link \"https://www.chess.com/game/live/187517802954\"]\n\n1. b3 {[%clk 0:03:00]} 1... e5 {[%clk 0:03:00]} 2. Bb2 {[%clk 0:02:59.1]} 2... Nc6 {[%clk 0:02:59.7]} 3. c4 {[%clk 0:02:58.3]} 3... g6 {[%clk 0:02:57.1]} 4. g3 {[%clk 0:02:57.2]} 4... Bg7 {[%clk 0:02:56.5]} 5. Bg2 {[%clk 0:02:56.9]} 5... f5 {[%clk 0:02:49.9]} 6. e3 {[%clk 0:02:55.3]} 6... d6 {[%clk 0:02:49.6]} 7. Ne2 {[%clk 0:02:54.4]} 7... Nf6 {[%clk 0:02:49]} 8. d4 {[%clk 0:02:53.8]} 8... e4 {[%clk 0:02:47.7]} 9. O-O {[%clk 0:02:51.8]} 9... O-O {[%clk 0:02:46.9]} 10. a3 {[%clk 0:02:49.6]} 10... Ne7 {[%clk 0:02:45.5]} 11. d5 {[%clk 0:02:48.7]} 11... g5 {[%clk 0:02:43.4]} 12. Nbc3 {[%clk 0:02:36]} 12... Ng6 {[%clk 0:02:40.2]} 13. Qc2 {[%clk 0:02:34.2]} 13... Ne5 {[%clk 0:02:33]} 14. Rad1 {[%clk 0:02:33.2]} 14... Qe8 {[%clk 0:02:28.6]} 15. Nd4 {[%clk 0:02:30.2]} 15... g4 {[%clk 0:02:23.4]} 16. Nce2 {[%clk 0:02:25.8]} 16... Nf3+ {[%clk 0:02:21.2]} 17. Bxf3 {[%clk 0:02:23.6]} 17... gxf3 {[%clk 0:02:09]} 18. Nf4 {[%clk 0:02:23]} 18... Bh6 {[%clk 0:01:57.6]} 19. Kh1 {[%clk 0:01:46.6]} 19... Ng4 {[%clk 0:01:47.2]} 20. Qc3 {[%clk 0:01:43.9]} 20... Bg7 {[%clk 0:01:38.6]} 21. h3 {[%clk 0:01:40.8]} 21... Ne5 {[%clk 0:01:37.4]} 22. c5 {[%clk 0:01:19.4]} 22... Bd7 {[%clk 0:01:24.1]} 23. cxd6 {[%clk 0:01:14.2]} 23... cxd6 {[%clk 0:01:23]} 24. Qc7 {[%clk 0:01:13.9]} 24... Rc8 {[%clk 0:01:08.8]} 25. Qxb7 {[%clk 0:01:12.9]} 25... Rf6 {[%clk 0:00:55.6]} 26. Nde6 {[%clk 0:01:09.7]} 26... Rh6 {[%clk 0:00:38]} 27. Nxg7 {[%clk 0:01:07.6]} 27... Kxg7 {[%clk 0:00:37.9]} 28. Rc1 {[%clk 0:00:59.2]} 28... Kf8 {[%clk 0:00:31.6]} 29. Rxc8 {[%clk 0:00:57.1]} 29... Bxc8 {[%clk 0:00:31.5]} 30. Qc7 {[%clk 0:00:56.1]} 30... Bd7 {[%clk 0:00:29]} 31. Kg1 {[%clk 0:00:46.8]} 31... Qe7 {[%clk 0:00:22.5]} 32. Rc1 {[%clk 0:00:42]} 32... Ng6 {[%clk 0:00:21.4]} 33. Nxg6+ {[%clk 0:00:25.8]} 33... hxg6 {[%clk 0:00:20.5]} 34. h4 {[%clk 0:00:25.5]} 34... g5 {[%clk 0:00:19.9]} 35. Qb8+ {[%clk 0:00:23.6]} 35... Kf7 {[%clk 0:00:18.8]} 36. Rc7 {[%clk 0:00:23.3]} 36... gxh4 {[%clk 0:00:17.8]} 37. Qxa7 {[%clk 0:00:23.1]} 37... Ke8 {[%clk 0:00:09.2]} 38. Bg7 {[%clk 0:00:21.1]} 38... Qxg7 {[%clk 0:00:07.7]} 39. Qb8+ {[%clk 0:00:20.3]} 1-0\n",
      "rated": true,
      "result": "1-0",
      "rules": "chess",
      "start_time": "2026-11-19T01:29:08Z",
      "termination": "Hikaru won by resignation",
      "time_class": "blitz",
      "time_control": "180",
      "url": "https://www.chess.com/game/live/187517802954",
      "white": {
        "rating": 3465,
        "result": "win",
        "username": "Hikaru"
      }
    }
  ],
  "month": "2026-11",
  "months": [
    "2026-11",
    "2026-10",
    "2026-09",
    "2026-08",
    "2026-07",
    "2026-06",
    "2026-05",
    "2026-04",
    "2026-03",
    "2026-02",
    "2026-01",
    "2025-12",
    "2025-11",
    "2025-10",
    "2025-09",
    "2025-08",
    "2025-07",
    "2025-06",
    "2025-05",
    "2025-04",
    "2025-03",
    "2025-02",
    "2025-01",
    "2024-12",
    "2024-11",
    "2024-10",
    "2024-09",
    "2024-08",
    "2024-07",
    "2024-06",
    "2024-05",
    "2024-04",
    "2024-03",
    "2024-02",
    "2024-01",
    "2023-12",
    "2023-11",
    "2023-10",
    "2023-09",
    "2023-08",
    "2023-07",
    "2023-06",
    "2023-05",
    "2023-04",
    "2023-03",
    "2023-02",
    "2023-01",
    "2022-12",
    "2022-11",
    "2022-10",
    "2022-09",
    "2022-08",
    "2022-07",
    "2022-06",
    "2022-05",
    "2022-04",
    "2022-03",
    "2022-02",
    "2022-01",
    "2021-12",
    "2021-11",
    "2021-10",
    "2021-09",
    "2021-08",
    "2021-07",
    "2021-06",
    "2021-05",
    "2021-04",
    "2021-03",
    "2021-02",
    "2021-01",
    "2020-12",
    "2020-11",
    "2020-10",
    "2020-09",
    "2020-08",
    "2020-07",
    "2020-06",
    "2020-05",
    "2020-04",
    "2020-03",
    "2020-02",
    "2020-01",
    "2019-12",
    "2019-11",
    "2019-10",
    "2019-09",
    "2019-08",
    "2019-07",
    "2019-06",
    "2019-05",
    "2019-04",
    "2019-03",
    "2019-02",
    "2019-01",
    "2018-12",
    "2018-11",
    "2018-10",
    "2018-09",
    "2018-08",
    "2018-07",
    "2018-06",
    "2018-05",
    "2018-04",
    "2018-03",
    "2018-02",
    "2018-01",
    "2017-12",
    "2017-11",
    "2017-10",
    "2017-09",
    "2017-08",
    "2017-07",
    "2017-06",
    "2017-05",
    "2017-04",
    "2017-03",
    "2017-02",
    "2017-01",
    "2016-12",
    "2016-11",
    "2016-10",
    "2016-09",
    "2016-08",
    "2016-07",
    "2016-06",
    "2016-05",
    "2016-04",
    "2016-03",
    "2016-02",
    "2016-01",
    "2015-12",
    "2015-11",
    "2015-10",
    "2015-09",
    "2015-08",
    "2015-07",
    "2015-06",
    "2015-05",
    "2015-04",
    "2015-03",
    "2015-02",
    "2015-01",
    "2014-12",
    "2014-11",
    "2014-10",
    "2014-09",
    "2014-08",
    "2014-07",
    "2014-06",
    "2014-05",
    "2014-04",
    "2014-03",
    "2014-02",
    "2014-01"
  ],
  "previous_month": "2026-10",
  "site": "chesscom",
  "username": "hikaru"
}

Response result

Response structure

Inferred from examples
  • cachedboolean
  • countinteger
  • credits_usedinteger
  • fetched_atstring
  • gamesobject[]
    • accuraciesobject
      • blacknumber
      • whitenumber
    • blackobject
      • ratinginteger
      • resultstring
      • usernamestring
    • ecostring
    • end_timestring
    • fenstring
    • idstring
    • openingstring
    • pgnstring
    • ratedboolean
    • resultstring
    • rulesstring
    • start_timestring
    • terminationstring
    • time_classstring
    • time_controlstring
    • urlstring
    • whiteobject
      • ratinginteger
      • resultstring
      • usernamestring
  • monthstring
  • monthsstring[]
  • previous_monthstring
  • sitestring
  • usernamestring

Loading related APIs…

Common questions

Do I need a separate key for every provider?

Use your OpenAny API key for standard API access. Read it from OPENANY_API_KEY in your environment and keep it out of prompts, source code and logs.

Are these providers interchangeable?

No. Each offering has its own inputs, pricing and response contract. Selecting a catalog offering does not establish automatic routing or fallback. Confirm the service contract before calling.

How is this API billed?

API-key calls use your shared balance at the selected implementation's published rate. Check the billing unit and request-specific pricing rules before making a paid call. Recorded usage determines the final charge under that contract.

Where do the price and contract come from?

The selected implementation publishes its provider, request contract, revision and billing rules through OpenAny's public API catalog. A revision number identifies a contract version, not a price update date. A price update timestamp is not supplied; do not treat a page date as one.

How do OpenAny Balance and x402 differ?

OpenAny Balance uses an API key and one shared balance. Card, USDC and x402 top-ups, card auto top-up and USDC subscriptions fund that balance; available routes appear on the Credits page. Direct x402 is a separate pay-per-request flow, available only on listings that show it and requiring an authorized payment client.

Does Playground send a paid request?

Yes. After you sign in, Run sends a real API request using an active OpenAny API key. Charges follow the published API contract and use your shared balance. Selecting an implementation, editing inputs and viewing sample responses do not send requests.

Use Chess a player's games with PGN API with your agent

Inspect endpoint contracts and confirm availability and pricing before a paid call.