Bitcoin Forum

Economy => Services => Topic started by: lockepi on January 26, 2016, 04:07:04 PM



Title: worldcoinindex api
Post by: lockepi on January 26, 2016, 04:07:04 PM
i am using worldcoinindex.com api i get the prices but am struggling to get the correct percentage change for each currency the same as world coin index.

any help appreciated will pay for solution with working example


Title: Re: worldcoinindex api
Post by: EngiNerd on January 26, 2016, 04:12:43 PM
The percentage change depends on the time period you're viewing it over. It's not included in the API response, but all you'd need to do is just store the last price you retrieved and then compare :) If you just want the daily % change, you could just fetch all the prices once at the start of the day and compare all future requests to those.

Another (dirtier) option would be manually scrapping it from the main page.


Title: Re: worldcoinindex api
Post by: Patatas on January 26, 2016, 08:52:20 PM
There might be a problem with your parser.Open your Console (preferably Google Chrome) and check the GET requests with the time delays.If you could send me the code or post it here I would have the clear idea of the bug.