Dagins.5163:

Hello, I would like to query all ids of items at once for market prices, but there is a limit of 200 per query. I tried to use ‘ids=all’, but it doesn’t work. I can do it sequentially, but it takes too long for my taste. I am thinking about doing it with threads, where each thread would query pack of 200 ids.

What is the best way to do this?

PS: I use Python.

Eearslya.6309:

I’m using PHP in my implementation, but the logic behind my answer is about the same. Simply use /v2/items?page=0&page_size=200 to fetch 200 items at once. You can read the X-Page-Total HTTP header to know how many other pages there are. Then you can fetch all 206 (currently) pages of items with threads and do what you need with them there. /v2/items?page=1&page_size=200 and so on.

smiley.1438:

See this thread: https://forum-en.guildwars2.com/forum/community/api/PHP-SQL-script-takes-9hrs-to-complete-db/4472325

I think there was also a Python implementation around, but i can’t find it anymore.

€:

There it is: https://forum-en.guildwars2.com/forum/community/api/v2-item-details-and-recipe-details/4436181