Wikifeeds/ja
Wikifeeds is a Node.js service that provides content used in the featured content feeds of the ウィキメディア アプリ .
It was originally written as part of the Mobile Content Service, and later split out into a separate service.
コード リポジトリ: https://gerrit.wikimedia.org/g/mediawiki/services/wikifeeds
Deployment steps: Wikifeeds/Deployment Process
Endpoints
.../feed/announcements
Stability: 実験的
This endpoint is meant to provide information about surveys and fundraising announcements for the iOS and Android apps only. It is experimental to the extent that it might significantly change or even go away in the future, more likely than other experimental endpoints. Client should code very defensively about the structure and the existence of this endpoint. If a client gets 404s, an exponential backoff strategy may be advisable.
例: Prod | ベータ クラスター | Labs | Local RB | ローカル ウィキフィード
See the announcement config spec: Wikimedia Apps/Team/RESTBase services for apps/Feed announcement config spec
.../feed/featured/{yyyy}/{mm}/{dd}
Stability: 不安定
This endpoint provides an aggregation of feed related microservices for one specific day. Note that year has to be exactly four digits, and month and day have to be two digits. Pad with 0 if needed. Earliest year supported is 2016. Example: 2016/07/01.
The response contains the following properties:
tfa
: featured article (WP languages supported: bg, bn, bs, cs, de, el, en, fa, he, hu, ja, la, no, sco, sd, sv, ur, vi, zh) Latest list and implementationimage
: featured image of the day (from Wikimedia Commons)mostread
: a list of the previous day's top read articlesnews
: current news, irrespective of day requested. This item is only available for a few wikis right now: da, de, el, en, es, fi, fr, he, ko, no, pl, pt, ru, sv, vi. Latest list and implementation if you want to help us expand it to more languages.
While the other feed microservices are implemented in Wikifeeds they are not exposed via RESTBase at this time. Some example URIs to just invoke the microservices locally is in the README.md of the source repo.
例: Prod | ベータ クラスター | Labs | Local RB | Local Wikifeeds (Aggregated feed for Febuary 6th, 2017)
For debugging: Local Wikifeeds routes of microservices: tfa | image | mostread | news (news in Wikifeeds directly is always current, not easy to get to historic content, recent versions of the aggregated RESTBase endpoint try to preserve historical news as much as possible)
Note: Not all feed content may be supported for all languages.
.../feed/onthisday/{type}/{mm}/{dd}
Stability: experimental
This endpoint provides information about what event which happened on a specific day and month of the year. Note that month and day have to be two digits. Pad with 0 if needed. Example: selected/07/01. Supported types of events and some examples:
- all: all of the following. 例: Prod | ベータ クラスター | Labs | Local RB | ローカル ウィキフィード
- selected: a list of a few selected anniversaries which happen on the provided day and month; often the entries are curated for the current year. 例: Prod | ベータ クラスター | Labs | Local RB | ローカル ウィキフィード
- births: a list of birthdays which happened on the provided day and month. 例: Prod | ベータ クラスター | Labs | Local RB | ローカル ウィキフィード
- deaths: a list of deaths which happened on the provided day and month. 例: Prod | ベータ クラスター | Labs | Local RB | ローカル ウィキフィード
- holidays: a list of fixed holidays celebrated on the provided day and month. 例: Prod | ベータ クラスター | Labs | Local RB | ローカル ウィキフィード
- events: a list of significant events which happened on the provided day and month and which are not covered by the other types yet. 例: Prod | ベータ クラスター | Labs | Local RB | ローカル ウィキフィード
Note: May not be supported for all languages.
.../page/random/{format}
Stability: unstable
Wikifeeds provides the title
format. All other formats (summary
and mobile-sections-lead
) are provided by RESTBase. See T132597 (Agree on feed endpoints).
This endpoint tries to provide more interesting pages in its result than a straight random MW API query. It prefers pages with a lead image, WD description, and longer text extract.
例:
title
- Prod | ベータ クラスター | Labs | Local RB | ローカル ウィキフィードsummary
- Prod | ベータ クラスター | Labs | Local RB | ローカル ウィキフィードmobile-sections-lead
- Prod | ベータ クラスター | Labs | Local RB | ローカル ウィキフィード