Closed Sagi44 closed 6 years ago
I think you misunderstood the parameter.
The "?days" query string can be specified to limit the number of days of data to return. That does not mean doing ?days=2
will return 2 results. One day can have multiple results as your clan is tracked every 4 hours.
E.g: https://api.royaleapi.com/Clan/PPYJ0V/history?days=3 - will return data recorded during 6/30 to 7/2 + today's data.
Thanks. So can I count on 6 records per day ?
No, you should not. API can go offline or game can have maintenance which can lead to your clan not being tracked at the scheduled time. Making it possible not to have 6 records of history per day. You should not rely on counting but should check the timestamp in your application.
I suspect that the history endpoint is not respecting the "days" parameter as described in :
https://docs.royaleapi.com/#/endpoints/clan_history
Request Details:
GET https://api.royaleapi.com/Clan/PPYJ0V/history?10 Should return last 10 ClanHistoryRecords. Instead Returns ALL ClanHistoryRecords ever since tracking enabled..