When I try to retrieve a poker game info from the /battles/{battleId} endpoint in the Thunderdome API, I currently receive a 403 response if I have the game open in a browser window. The JSON response returned is
This is a bit annoying, especially if I just participated in a poker game and want to get the data via the API.
How To Reproduce
Create a new poker game in Thunderdome
Join the game in your browser and leave the tab open
Make an API request to the GET /battles/{battleId} endpoint with battleId set to the ID of the created game, e.g. via the Swagger UI
Possible Causes
I think this might be linked to the internal session management, since you can't join the same game twice with the same account in your browser too. However, from an REST API I would expect different behavior, i.e. that the API request is not linked to any session.
I suspect that the API request triggers a game join at some point, which fails because the browser session already exists. This then leads to the error USER_MUST_JOIN_BATTLE when the data is accessed.
Self Hosted?
No
Version
Latest
What browsers are you seeing the problem on?
No response
Relevant log output
No response
Code of Conduct
[X] I agree to follow this project's Code of Conduct
Contact Details
No response
What happened?
When I try to retrieve a poker game info from the
/battles/{battleId}
endpoint in the Thunderdome API, I currently receive a 403 response if I have the game open in a browser window. The JSON response returned isThis is a bit annoying, especially if I just participated in a poker game and want to get the data via the API.
How To Reproduce
GET /battles/{battleId}
endpoint withbattleId
set to the ID of the created game, e.g. via the Swagger UIPossible Causes
I think this might be linked to the internal session management, since you can't join the same game twice with the same account in your browser too. However, from an REST API I would expect different behavior, i.e. that the API request is not linked to any session.
I suspect that the API request triggers a game join at some point, which fails because the browser session already exists. This then leads to the error
USER_MUST_JOIN_BATTLE
when the data is accessed.Self Hosted?
No
Version
Latest
What browsers are you seeing the problem on?
No response
Relevant log output
No response
Code of Conduct