API doesn't return the list of players for US

Sort:
czopluoglu

Hi,

Does anyone know why API doesn't return the players in the US?

https://api.chess.com/pub/country/US/players

This returns an error 

{"status":"error","message":"Internal Server Error"}

It works fine for all other countries. 

Thank you.

Olympiad

Now that's interesting. I'll forward this for you and hope to be able to update you on it, but I can't promise anything!

czopluoglu

Thank you.

CaMiBellman

Any updates on this issue? Still returns the error message.

Martin_Stahl
CMBellman wrote:

Any updates on this issue? Still returns the error message.

 

I believe is has to do with the size of the results.

CaMiBellman
Martin_Stahl wrote:

I believe is has to do with the size of the results.

Would it be possible to circumvent the problem by for example split up the result over many queries?

Martin_Stahl

I'm not terribly familiar with the API, just have seen similar posts in the developers club about it with the same situation with other countries with a lot of players.

io_kloud

https://api.chess.com/pub/country/US/players

Tried it and this is now working.

czopluoglu

Yes, it seems like they limited the returned list to 10,000 players. Not an ideal solution. You cannot get the list of all players.

Martin_Stahl
czopluoglu wrote:

Yes, it seems like they limited the returned list to 10,000 players. Not an ideal solution. You cannot get the list of all players.

It's due to the size of those datasets and resources.

czopluoglu

Yes, I get it. They can still allow downloading the list of all players by giving the option to request the list 10,000 by 10,000. Something like the following

https://api.chess.com/pub/country/US/players/1-10000

https://api.chess.com/pub/country/US/players/10001-20000

...

It probably requires just another line of code in their codebase.

Martin_Stahl
czopluoglu wrote:

Yes, I get it. They can still allow downloading the list of all players by giving the option to request the list 10,000 by 10,000. Something like the following

https://api.chess.com/pub/country/US/players/1-10000

https://api.chess.com/pub/country/US/players/10001-20000

...

It probably requires just another line of code in their codebase.

It requires pagination of the API results and It's been suggested before. My understanding is that it likely isn't going to be implemented.