Page MenuHomePhabricator

Count the number of video plays
Open, LowPublic


We currently don't have any way to track the number of times our videos are viewed. This was done by so far, but it appears that tool is malfunctioning. This is a child task of the greater effort to collect and report these metrics from mediawiki. Once that is underway, this task can use those metrics to produce a standard dataset and maybe expose it via the pageview api.

Event Timeline is an alternative tool using @Harej's mediaviews API, which is populated from I think the commons-video-clicks tool probably just isn't using the new API endpoint, which was changed only a week or so ago.

It would be awesome to have this data exposed in the pageviews API. One thing that is possible with harej's API is to query by category (though I still haven't added support for this in Mediaviews). You may wish to consider something like this for the Pageviews API, too.

Milimetric moved this task from Incoming to Analytics Query Service on the Analytics board.

Yes, how would this new standard dataset differ from ?

(Or if this is about work to remedy the shortcomings listed at and get a more precise estimate of how many videos are actually being played / viewed by users, then yes, that would surely be worth a separate task.)

I think the difference is that this current dataset is strictly media downloads, which can happen any number of ways (clicking play on a video widget, submitting an HTTP request directly to the server). This is a superset of a more precise click metric which would capture clicking "play" as an event. Is this correct?

Yes, almost. Clicking "play" and also deciding what it means that someone "viewed" the video. Like, does watching 1/2 of it count? What about skipping through it? Those questions have standard answers on sites like youtube but our purposes may be different so our answers may be different.