These forums have been archived and are now read-only.

The new forums are live and can be found at https://forums.eveonline.com/

EVE Technology Lab

 
  • Topic is locked indefinitely.
 

Where do you fetch your market data from?

Author
Moryg H'qarr
The Scope
Gallente Federation
#1 - 2016-12-12 17:43:13 UTC
I'm currently using CREST, wanted to switch everything to ESI.

Turns out, the ESI regional market data (all orders, no type filter) return just an array, so there's really no way of figuring how many pages there are in advance. Is there an ingame channel / slack where ccp & 3rd party devs hang out?
Avrora Primogenitor
Pator Tech School
Minmatar Republic
#2 - 2016-12-13 10:06:01 UTC  |  Edited by: Avrora Primogenitor
I chose for the Eve-central API. Why? Because then I don't have to bother doing calculations and keeping historical data about market orders myself. Saves storage since historical data builds up quite quick.

EDIT: Register for #DevFleet slack: https://www.fuzzwork.co.uk/tweetfleet-slack-invites/
Moryg H'qarr
The Scope
Gallente Federation
#3 - 2016-12-13 11:24:38 UTC
Thanks.

I don't mind doing the calculations and currently have no plans to store history, just the current state (and that works just fine). I swapped back to CREST for now and will implement ESI for market at a later stage.
Blacksmoke16
Imperial Academy
#4 - 2016-12-13 14:38:59 UTC
I use https://market.fuzzwork.co.uk/api/

However if you wanted to get the data from ESI you could just have it start on page 1, get data move onto page two and repeat. When you reach the final page it would be an empty array. So you could do something like this

Pseudo code:

url = https://esi.tech.ccp.is/latest/markets/10000002/orders/?page=1

response = HTTP_GET(url)

if response.data.length > 0
for each obj in response
// parse the array of objs here
Moryg H'qarr
The Scope
Gallente Federation
#5 - 2016-12-13 16:05:12 UTC
Yeah, I did just that. But it takes more requests - CREST returns in batches of 30k, ESI in batches of 10k and you tend to do it sequentially. With CREST, I make the request for the first page, then queue up the rest at once. With ESI I could queue up requests for several pages at once and keep doing that until one of them came back empty to speed it up. But that seems inefficient.

I'll leave it on CREST for now, my ESI code is working so I can swap at any time, I just find the market request more awkward to work with at the moment.