I’ve developed a module for Indico software which interfaces with Piwik for statistics tracking. I am currently attempting to link a download listener on the serverside to accomplish this, it is working fine however I wish to obtain ‘top 5’ downloads for any given day and, specifically, a segment.
I am using custom variables when generating the request which logs the download via the cvar parameter as follows:
This returns the following, and registers as a successful hit on the downloads when getDownload() is triggered against it:
Page level Custom Variables: array ( 'custom_var_k1' => 'DownloadConferenceID', 'custom_var_v1' => '137976', ) array ( 'idvisit' => '73', 'idsite' => 1, 'idvisitor' => 'ÁCÃø`Ç ', 'server_time' => '2012-06-13 14:10:10', 'idaction_url' => 55, 'idaction_url_ref' => '55', 'idaction_name_ref' => '0', 'time_spent_ref_action' => 576, 'custom_var_k1' => 'DownloadConferenceID', 'custom_var_v1' => '137976', )
The issue is, using Action.getDownloads() I can’t find the correct combination of customVariablePageName1 & value etc to retrieve all the downloads where the value of the name and number match those which I sent over, I am attempting to get only that subset of data.
My only conclusion is that the action of a download isn’t bound to custom variables in the same manner in which page views are, unless there is something which I am missing.
If you can see the solution for this, I’d be most grateful for any assistance offered.
Note: Piwik IP & token_auth in URLs are within local scope only.