Nice work on the API!
I wrote a basic consumer of this API at
http://codepen.io/Krinkle/full/wKOMMN#wikimdia-pageviews
The only hurdle I found is that the 'articles' property is itself
nested/double encoded JSON, instead of a plain object. This was somewhat
unexpected and makes the API harder to use.
Code at
http://codepen.io/Krinkle/pen/wKOMMN?editors=001.
(Supported in Chrome, Firefox, Safari and IE10+)
On Wed, Nov 18, 2015 at 3:09 AM, MZMcBride <z(a)mzmcbride.com> wrote:
Dan Andreescu wrote:
The API can tell you how many times a wiki article
or project is viewed
over a certain period. You can break that down by views from web crawlers
or humans, and by desktop, mobile site, or mobile app. And you can find
the 1000 most viewed articles
<
https://wikimedia.org/api/rest_v1/metrics/pageviews/top/es.wikipedia/all-
access/2015/11/11>
on any project, on any given day or month that we have data for. We
currently have data back through October and we will be able to go back to
May 2015 when the loading jobs are all done.
This looks very promising. Congratulations to all on getting this launched!
I hit a bug involving gzip compression and HTTP headers that was quickly
fixed (<https://phabricator.wikimedia.org/T118817>). Now that I'm
lightly poking at the API's data, the "Paul_Elio" article on the English
Wikipedia allegedly received 4,832,338 views on 2015-11-16, according to
<https://phabricator.wikimedia.org/P2325>. This anomaly and a few others
make me a bit wary about the accuracy of this data. That said, a lot of
the results look about right and are easily explained ("Charlie_Sheen" and
"November_2015_Paris_attacks" are easy examples).
MZMcBride
_______________________________________________
Wikitech-l mailing list
Wikitech-l(a)lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikitech-l