Closed jesusthatsgreat closed 4 years ago
Thank you for reporting this issue. Api was updated to be in sync with documentation.
I will leave this issue open for better granulation clarification (or api changes?).
Latest update improved upon granulation, where you now have option to select what granulation you want.
Query params as per documentation don't work when trying to get price history for portfolios. For example according to docs the following should work:
https://api.iconomi.com/v1/daa/BLX/pricehistory?from=1530615303&to=1533207303
But that doesn't work and the default response is returned. The following does work:
https://api.iconomi.com/v1/daa/BLX/pricehistory/1530615303/1533207303
However this isn't documented anywhere. On a side note, there's also no documentation on how the granulation is arrived at. If it can't be controlled by the user by entering a query param, I feel like the user needs to understand how it is determined and under what circumstances is HOURLY, THREE_HOURLY, DAILY granulation triggered i.e. whether it's based on a set number of results returned or duration between dates etc...
Small example: if i want daily pricing for a portfolio for the month of January, I have no choice but to accept hourly granulation as things stand, meaning more client side processing for me / more data being sent from server and it just seems inefficient all round. So in order to get daily granulation I might just request the price starting a year ago because I know that will return daily prices and will be easier for me to filter client side but it's still inefficient.