API · POST /v1/search

Search

One player’s games, newest first, from over two million games. Find them by FIDE ID or by name, then filter by colour, date, opening, result and opponent. Or send a position for every move played from it.

Try it in the Playground

Signed out? You’ll sign up first. Your own account gets $10 of Trial credits once, never expiring, no card. Only successful responses carry usage and cost_usd.

Hand-written answers on real public games 1 of 2
Search A FIDE ID: his newest games. POST /v1/search
a8b7c6d5e4f3g2h1
Caruana, Fabiano 2776 v Carlsen, Magnus 2837
Norway Chess Armageddon 13th · 31 May 2025 · C57 · 0–1
Player FIDE ID 1503014
200
{
  "id": "req_01M818JNWVJPHKHPX36F59WCV9",
  "match": "fide",
  "player": {
    "birth_year": 1990,
    "federation": "NOR",
    "fide_id": 1503014,
    "name": "Carlsen, Magnus",
    "ratings": {
      "blitz": 2860,
      "rapid": 2801,
      "standard": 2823
    },
    "title": "GM"
  },
  "candidates": [],
  "games": [
    {
      "color": "black",
      "game": {
        "black": {
          "fide_id": 1503014,
          "name": "Carlsen, Magnus",
          "rating": 2837,
          "title": null
        },
        "date": "2025-05-31",
        "eco": "C57",
        "event": "Norway Chess Armageddon 13th",
        "id": "11540354",
        "opening": null,
        "pgn": "[Event \"Norway Chess Armageddon 13th\"]\n[Site \"St…",
        "platform": null,
        "rated": null,
        "result": "0-1",
        "speed": null,
        "speed_basis": null,
        "time_control": null,
        "url": null,
        "venue": null,
        "white": {
          "fide_id": null,
          "name": "Caruana, Fabiano",
          "rating": 2776,
          "title": null
        }
      }
    },
    { "color": "black", "game": {…} },
    { "color": "white", "game": {…} }
  ],
  "next_cursor": "g1.eyJjIjoiZXlKaUlqb2lNakF5TmkweE1TMHdPU0lzSW1naU9pSmpaVEptWW1ObE0yVm1NR1kwT1ROaUlpd2lheUk2TlRrME1EQjkifQ",
  "usage": { "games": 3 },
  "cost_usd": "0.015000"
}
1.6 s Real games · no API call

What it takes

A player: a fide_id or a name as FIDE’s list writes it. An optional limit (default 50, 1 to 200), cursor, pgn and filters, all optional and combined: date, eco, result, color and opponent. Or a position, for its moves.

What it returns

The player, with their ratings, and games, newest first: each the color they had and the game, with its players, ratings, event, date, opening and result, and its PGN if you ask. next_cursor is the next page. A position returns its moves, most played first, each with how its games ended.

Price and limits

Price on Search
$5
per 1K games
Typical call
≈ $0.25
drawn from your Balance
Streaming
No
one JSON response
Games
200
at most a call, then the next page
  • Billed per game returned, at least one a call. A position’s moves are one query.
  • An ambiguous name returns up to 5 candidates and no games, free: call again with one’s fide_id.
  • A cursor stops working when the games are rebuilt: cursor_expired means start again without it.

Similar momentsComing soon

Find the moments in real games nearest a position or a question, filtered by rating, speed, date, player, opening and result. It isn’t open yet: a call with query returns 501 coming_soon, unbilled.

Search A text query: games where a queen is given up to force mate. POST /v1/search lichess-2026-09
a8b7c6d5e4f3g2h1
31… Qxg2+ · ANMessi 1803 v Sergey_Shachnev 2099 Open move 31… Qxg2+ on Lichess
Blitz 5+0 · 31 Oct 2024 · Sicilian Defense: Closed (B23) · 0–1
Text “a queen sacrifice that ends in mate”
200
{
  "id": "req_0120T2BC95NRRXC8RH20K48FYW",
  "model": "chessdrive-embed-1",
  "corpus": "lichess-2026-09",
  "hits": [
    {
      "score": 0.91,
      "moment": {
        "game": {…},
        "ply": 62,
        "fen": "5r1k/1b4p1/p5pp/8/2B5/P2P4/4Q1qP/5R1K w - - 0 32",
        "move": { "san": "Qxg2+", "uci": "c6g2" }
      }
    },
    { "score": 0.88, "moment": {…} },
    { "score": 0.84, "moment": {…} }
  ],
  "usage": { "queries": 1 },
  "cost_usd": "0.005000"
}
2.2 s Recorded hits · no API call
curl https://api.chessdrive.io/v1/search \
  -H "Authorization: Bearer $CHESSDRIVE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "player": {"fide_id": 1503014},
    "filters": {"date": {"from": "2025-05", "to": "2025-05"}},
    "limit": 3,
    "pgn": true
  }'

The sample calls Search for the Magnus Carlsen Specimen, reading the key from the environment.

Try it in the Playground

Signed out? You’ll sign up first. Your own account gets $10 of Trial credits once, never expiring, no card. Only successful responses carry usage and cost_usd.