Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

API Feature Request: Send full FEN on all /api/stream/game/{id} events #12357

Closed
trevorbayless opened this issue Feb 11, 2023 · 0 comments · Fixed by #12405
Closed

API Feature Request: Send full FEN on all /api/stream/game/{id} events #12357

trevorbayless opened this issue Feb 11, 2023 · 0 comments · Fixed by #12405

Comments

@trevorbayless
Copy link
Member

trevorbayless commented Feb 11, 2023

This is an API feature request to send the full FEN on all /api/stream/game/{id} events. This would be beneficial specifically for Crazyhouse and Three-Check as the FEN contains unique parts (such as the crazyhouse pocket and check counter).

Currently, the full FEN is only sent in the first message. Follow up messages only contain the board FEN.

Example:

{"id":"TQUh1YtP","variant":{"key":"threeCheck","name":"Three-check","short":"3check"},"speed":"bullet","perf":"threeCheck","rated":true,"fen":"2k3r1/p1pq1p1N/1p2p2P/3pP2R/3P1Q2/2P4K/P1P2P1r/5R2 w - - 3 27 +0+3","player":"white","turns":52,"startedAtTurn":0,"source":"friend","status":{"id":60,"name":"variantEnd"},"createdAt":1676145078042,"winner":"black","lastMove":"g2h2","check":"h3","drawOffers":[52],"players":{"white":{"user":{"name":"Frido1802","id":"frido1802"},"rating":1856,"ratingDiff":-44,"provisional":true},"black":{"user":{"name":"Professor_Eisenstahl","id":"professor_eisenstahl"},"rating":1890,"ratingDiff":26}}}
...
{"fen":"2k3r1/p1pq1p1N/1p2p2P/3pP2R/3P1Q2/2P5/P1P2PrK/5R2 w","lm":"g6g2","wc":2,"bc":14}
{"fen":"2k3r1/p1pq1p1N/1p2p2P/3pP2R/3P1Q2/2P4K/P1P2Pr1/5R2 b","lm":"h2h3","wc":1,"bc":14}
{"fen":"2k3r1/p1pq1p1N/1p2p2P/3pP2R/3P1Q2/2P4K/P1P2P1r/5R2 w","lm":"g2h2","wc":1,"bc":11}

I'm using the endpoint above in an application I'm working on which has the ability to watch TV games. Providing the full FEN would allow for showing the Crazyhouse pocket and check count.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant