lichess.org
Donate

Lichess Developer API - opening book?

Can the Lichess API interact with the opening book? I'm interested in programmatic access to the information, without the many clicks required on the UI.

Happy to clarify this question further if I'm unclear, but I should be to the intended audience.

Wow, thanks @revoof so much for your quick reply. This is generally what I was looking for. I've been busy with other things, but I'll follow up personally when I have a good chance to look into this further.

One question, am I correct to assume there is no online version of this already available for immediate queries? It seems I would have to build/install this on my own server/etc, in order to have access to the functionality.
Great, I tried this out last night and it worked great! (I also used chess.js to apply the "san" move to the FEN and was happy that all worked correctly too.)

Observation: The opening explorer itself (UI, not API) will only list at most the default number of moves (12), even if there are more available. For instance, White's first move f3 is not shown in the opening book, even though it is returned by the endpoint if 'moves' is greater than 12. @revoof, bug that slipped through the cracks or by design?

Follow up question: How can the name of the position be determined? (such as mapping an FEN to "A57: Benko Gambit")

Thanks!

This topic has been archived and can no longer be replied to.