Hi All,
We are putting together a simple report web page for our users, just showing the last 3 months’ trend for Page Views and Time Spent on Page.
I’m having a problem with the following API string:
http://servernamehere/stats/piwik/index.php?module=API&method=Actions.getPageTitles&filter_pattern=ProdOps&idSite=2&period=range&date=2014-05-01,2014-05-31&format=JSON&token_auth=tokenhere
I was getting valid responses until last Thursday for May, June, and July’s API requests. Thursday morning, we started getting an empty (invalid) response for the May statistics requests. I could change the end date from May 31 to the 30th, 29th, etc. and get a valid JSON in response. Friday night, this May 1-31 range started working and giving me a valid response again.
I thought that was the end of the mystery. However, now that it’s September and the last 3 months are June, July, and August. The July 1-31 API request is getting an empty response, when it had been working fine previously. Even plugging the API request into a browser, we see an empty response. Here’s our July query:
And once again, if I change the date range even a little bit, we get a valid response.
We are on Piwik 1.12 - and we can’t upgrade just yet because another application on the server has a dependency on the older PHP version currently running. [Also - the reason we are using a date range is because period=month&date=previousn (I could be wrong about the specific syntax - I’m going from memory) doesn’t work on our version of Piwik, but I have found a report that it is fixed in a newer version. Using a date range is our workaround for now.]
Any idea what could be causing my issue with the intermittent blank response or any suggestions on what to try as a workaround?
Thank you very much,
Amy