Hi all,

Thanks for all the help and advice with this issue, especially with the
wmflabs tool with the redirect view tool. We'll try using that tool to
download the pageview data we need and manually filter by dates to map
redirects to the page. We'll also look into the REST API that Wiki has to
see if it can help us as well.

Thanks again,

Jackie, James, Junyi, Kirby


On Sun, Feb 23, 2020 at 10:58 PM Gergo Tisza <gti...@wikimedia.org> wrote:

> On Sun, Feb 23, 2020 at 4:17 PM James Gardner via Wikitech-l <
> wikitech-l@lists.wikimedia.org> wrote:
>
>> We attempted to use the wmflabs.org tool, but it only shows data from a
>> certain date. (Example link:
>>
>> https://tools.wmflabs.org/pageviews/?project=en.wikipedia.org&platform=all-access&agent=user&start=2019-07-01&end=2020-01-25&pages=2019%E2%80%9320_Hong_Kong_protests|China
>> <https://tools.wmflabs.org/pageviews/?project=en.wikipedia.org&platform=all-access&agent=user&start=2019-07-01&end=2020-01-25&pages=2019%E2%80%9320_Hong_Kong_protests%7CChina>
>> <
>> https://tools.wmflabs.org/pageviews/?project=en.wikipedia.org&platform=all-access&agent=user&start=2019-07-01&end=2020-01-25&pages=2019%E2%80%9320_Hong_Kong_protests%7CChina
>> >
>> )
>>
>
> There's a redirectview tool (see the "redirects" links at the bottom of
> the page you linked) but it can't be filtered by date so it probably can't
> help you.
>
>
>> Then we attempted to use the redirects of a page and using the old page
>> ids
>> to grab the pageview data, but there was no data returned. When we
>> attempted to grab data for a page that we knew would have a long past, but
>> the parameter of "pvipcontinue" did not appear (
>> https://www.mediawiki.org/w/api.php?action=help&modules=query%2Bpageviews
>> ).
>> (Example:
>>
>> https://www.mediawiki.org/wiki/Special:ApiSandbox#action=query&format=json&prop=pageviews&titles=MediaWiki&pvipmetric=pageviews&pvipdays=60&pvipcontinue=
>> )
>>
>
> That API displays a limited set of metrics and is focused on caching and
> being backend-agnostic. There is no way to get old data, pvicontinue is for
> fetching data about more pages. If you need something more specific, you
> should use the Analytics Query Service (which the other APIs rely on)
> directly: https://wikitech.wikimedia.org/wiki/Analytics/AQS/Pageviews
>
> I think you'll have to piece the data together using the MediaWiki
> redirects API and AQS.
>
_______________________________________________
Wikitech-l mailing list
Wikitech-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikitech-l

Reply via email to