Event tracking REST API (1 problem + 1 suggestion)


I try to do that with Piwik from a desktop application. I developed a module making the Webrequest and (beside of overwriting and one other thing) everything works…

So, my problems:
I send always one thing at once --> index could always be 1. The problem is, that this (obviously) gets overwritten… I think, that the problem could be solved by changing the scope to (THIS-VERY-REQUEST-ONLY)…

The other thing is, that the Measurement Protocoll allows for the event the following thing:
Category --> Action --> Label --> Value
It would very nice to allow something like this (changed example from documentation)[Maybe also without Limit of # of entries] :
{“1″:[“OS”,“iOS”,“iPhone 5”]}

I am writing this from a tablet PC, I am really sorry for the formatting. Please do not hesitate to ask any further question…


Florian R.

I think you are describing to add “Event Tracking” in Piwik, see: Custom Events analytics, event tracking · Issue #472 · matomo-org/matomo · GitHub

Hi matt,

I have read that, but I am quite sure, that “event tracking” is possible right now, or quite easy to implement as 80% is a wrapper about existing things). I have seen, that in JS it is possible to set a scope for custom variables (page or view). I simply thought, that this part is not docuented with the REST API, but possible…

And yes, that is event tracking, but an infinity of subcategories should be easy to do. Example use case
Mobile,iOS,iOS 6,iPad,de-at
Desktop,Windows,Windows 7,Chrome,de-at

Questions you should be able to answer with these custom variables:
[li] % Mobile
[/li][li] %iOS user on iPad
[/li][li] %iPad users (whole userbase)
[/li][li] % of e.g. fr-fr

Piwik is frustating close to event tracking.
IMHO 2 major steps are needed
1)Allow tracking an infinite number of key/values (Please refer to example above. Expect of the first and the last one they are both, key and value)
2)A scope ONCE which makes overwriting of custom variables impossible

The third step is optional: Creating a wrapper for custom variable, which specifies the following (%abc% <-- This is a parameter, using REST API)

_cvar={“1″:[“event”,"%abc%","%def%",…,"%ghi%"]} Custom variables with the key (first item) “event” should not be shown in custom variables report, but in a new event report (in a perfect world)…


Florian R.