Open LukeS28 opened 1 year ago
Hello, I looked into this as I am also using this python module for a personal 2nd Division project and it seems that this is an issue of the underlying kickbase API. It also happens with a lot of Hertha BSC players and more. If I see correctly these are values from when the players maybe used to be in the 1st Division, which is why the lowest value is 500k and not 250k. The endpoint also seems to mix the actual values with the wrong one, so I would recommend not using the .team_players() method to receive market values.
Temp Fix: for the correct Market Values I currently use a manual request to the API described in https://kevinskyba.github.io/kickbase-api-doc/index.html#request-player-player-stats . This gives the correct values for each player, even in the 2nd Division. I'm planning to also create a Pull Request for this endpoint, but I am currently not sure if the owner is still active to review them.
Best Regards Toubeyas
Hey Toubeyas,
thank you for your reply! I've tried using the regular API (HTTP) to fetch Marketvalues with 'Player Stats'. However I'm having trouble with authentication. Every HTTP Request I've tried returns either Status 403 (Forbidden) when trying a GET request or Status 401 (Unauthorized) when trying to POST a login. Do you know how authentication works?
Thank you & Best Regards LukeS28
Hey LukeS28,
I just used the method _do_get() from this package, as it already correctly implements the authentication via cookie. If you want to write your own api method, I would recommend looking into the code of the _do_get() and login() methods.
Best Regards Toubeyas
Hey Toubeyas,
thank you! I managed to get it to work with player_stats. However the_do_get() function doesn't automatically recognize the token after login(), as I presume it is intended. I'm now manually retrieving the token with auth_cookie() and using it in the header of the request function and this works perfectly. I can now retrieve the complete market value history for any player!
Thank you so much for helping me with the solution!
Thanks & Best Regards LukeS28
Hi,
I know this issue is quite old, but I'm experiencing a similar problem. I used the team_players endpoint to retrieve a list of all players per team (along with their player IDs) and then used the player_stats endpoint for individual market values. However, it seems that the team_players endpoint now only returns teams from the first division instead of the second division.
Is there another way to get a list of all relevant player IDs from the second division?
Thanks in advance, Flex
Hey,
I’m currently using the Kickbase-API for my own little programming project creating a webapp, that delivers insights about market value development for the 2. German Bundesliga. However, I noticed that for a few weeks now, the market values seem to be incorrect.
For example, almost all HSV players return a market value of 500.000: This is what my code looks like:
And this is the output:![image](https://github.com/kevinskyba/kickbase-api-python/assets/29575783/6be923a6-ba76-4a4b-ad03-b8def57e5c20)
Do you have any idea what could be the reason for this?
Thank you & Best Regards LukeS28