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

 
 

ESI as a replacement for Eve-Central API for market data?

Author
Mia Markaya
Unlimited Blade Works.
#1 - 2017-06-02 02:31:27 UTC
I'm currently using the Eve-Central API to pull price data from market hubs to use on all my spreadsheets ( Excel 2016 ).

Today I started reworking and reorganizing most of them and decided to take a closer look to see if switching from Eve-Central API to ESI was possible, specially since I want to start pulling Citadel data and as far as I know that's not possible with the current Eve-C API.

I have close to zero programming knowledge so I rely on guides to do all the data import, and found this one for CREST but used with ESI instead and it worked fine.

I started with "/markets/prices/" and while it was very straight forward to pull the price data, I noticed after comparing with my current spreadsheets and evepraisal that the prices were inaccurate.

Then I tried "/markets/{region_id}/orders/" and after pulling all the information from The Forge, I tried filtering so I only got the results from Jita 4-4 ( station_id: 60003760 ) but that was also unsuccessful for a bunch of items and inaccurate for the rest.

So how do I get the data I'm looking for out of ESI? Is it even possible without some advanced programming knowledge? Any good up to date alternatives that have Citadel market data?
Althalus Stenory
Flying Blacksmiths
#2 - 2017-06-02 06:38:49 UTC
/market/prices are not the actual prices from market, they are only the average and adjusted prices used for industry taxes, insurances, killmails.

If you want prices, you'll have to use this endpoint "/markets/{region_id}/orders/" which only gives you buy orders from everywhere, but only NPC stations sell orders.

About citadels, they are available, but not as a public data because of upwell ACL. To get them, you need to log in SSO, loops over the structures list endpoint, and test all structure to see if you have access and get its market data.

EsiPy - Python 2.7 / 3.3+ Swagger Client based on pyswagger for ESI

Mia Markaya
Unlimited Blade Works.
#3 - 2017-06-02 15:03:06 UTC
Althalus Stenory wrote:
If you want prices, you'll have to use this endpoint "/markets/{region_id}/orders/" which only gives you buy orders from everywhere, but only NPC stations sell orders.


So not of any of to me.

Out of curiosity then, how does a site like Eve-Central get the accurate price then if ESI only shows NPC Sell orders?
Areta Kalgor
School of Applied Knowledge
Caldari State
#4 - 2017-06-02 20:00:34 UTC
hey all, just to quickly jump in on this topic - anybody knows at what time does this API fetch current day data https://esi.tech.ccp.is/latest/markets/10000067/history/?datasource=tranquility&type_id=3687 ?
Althalus Stenory
Flying Blacksmiths
#5 - 2017-06-02 21:11:01 UTC
every hour the cache is updated. See the headers:
date:Fri, 02 Jun 2017 20:16:32 GMT
expires:Fri, 02 Jun 2017 21:16:32 GMT


But the data itself is updated at the same time it's done in the client, so probably downtime or somewhere in the night

@Mia Markaya: they probably fetch public citadels using one of the eve-central dev eve account if they have citadel prices

EsiPy - Python 2.7 / 3.3+ Swagger Client based on pyswagger for ESI

Areta Kalgor
School of Applied Knowledge
Caldari State
#6 - 2017-06-02 21:40:36 UTC
Althalus Stenory wrote:
every hour the cache is updated. See the headers:
date:Fri, 02 Jun 2017 20:16:32 GMT
expires:Fri, 02 Jun 2017 21:16:32 GMT


But the data itself is updated at the same time it's done in the client, so probably downtime or somewhere in the night

@Mia Markaya: they probably fetch public citadels using one of the eve-central dev eve account if they have citadel prices



thx for prompt reply! :D so, there is no way to get the data upon cache expiry? what is the best way to get the data ASAP? thank you very much :D
Althalus Stenory
Flying Blacksmiths
#7 - 2017-06-03 00:04:55 UTC
I'd say, save the "expires" date from the header of your last request and call the endpoint again as soon as it's outdated ?
I don't know really, especially for the history... you'll get 24 calls for only one real update somewhere in the day.

After that's the same for all endpoints : if you want to have the "latest" data available in the endpoint, just keep the "expires" from your last call, and do another one as soon as your data is outdated.

But you can't force the cache refresh, so you'll have to wait for it anyway :)

EsiPy - Python 2.7 / 3.3+ Swagger Client based on pyswagger for ESI

Areta Kalgor
School of Applied Knowledge
Caldari State
#8 - 2017-07-15 22:07:58 UTC
Hello,

JSON is being returned for that location https://esi.tech.ccp.is/latest/universe/stations/60003790/?datasource=tranquility, however error message is being returned for this location https://esi.tech.ccp.is/latest/universe/stations/1021701589215/?datasource=tranquility ({"error": "'station_id' is required, failed to coerce value '1021701589215' into type integer (format: int32)"})

anyone else having this problem?

thx
Blacksmoke16
Resilience.
#9 - 2017-07-16 00:52:26 UTC
Areta Kalgor wrote:
Hello,

JSON is being returned for that location https://esi.tech.ccp.is/latest/universe/stations/60003790/?datasource=tranquility, however error message is being returned for this location https://esi.tech.ccp.is/latest/universe/stations/1021701589215/?datasource=tranquility ({"error": "'station_id' is required, failed to coerce value '1021701589215' into type integer (format: int32)"})

anyone else having this problem?

thx


You are trying to use the stations endpoint to get information on a structure.

You will have to use THISinstead, which requires token auth.
Areta Kalgor
School of Applied Knowledge
Caldari State
#10 - 2017-07-16 07:15:22 UTC
Blacksmoke16 wrote:
Areta Kalgor wrote:
Hello,

JSON is being returned for that location https://esi.tech.ccp.is/latest/universe/stations/60003790/?datasource=tranquility, however error message is being returned for this location https://esi.tech.ccp.is/latest/universe/stations/1021701589215/?datasource=tranquility ({"error": "'station_id' is required, failed to coerce value '1021701589215' into type integer (format: int32)"})

anyone else having this problem?

thx


You are trying to use the stations endpoint to get information on a structure.

You will have to use THISinstead, which requires token auth.


ah, thx ;)