After an offline discussion we decided to
- remove the summary end point for wiktionaries, as it is not actually returning useful extracts, and
- add a definition end point exposing the new definition functionality in the mobile app content service.
After an offline discussion we decided to
Status | Subtype | Assigned | Task | ||
---|---|---|---|---|---|
Resolved | Dbrant | T115484 Display definitions of highlighted words from Wiktionary | |||
Resolved | • Mholloway | T119235 Add route to provide Wiktionary definition of requested word or phrase. | |||
Resolved | • Mholloway | T123142 Expose definition end point in public REST API on Wiktionary |
I've made a PR for RESTBase to expose the definition endpoint. It also does some refactoring internal for RESTBase, relevant endpoint spec is located here
I've came up with a response schema by looking at several api responses, but it needs to be verified as I might have missed some optional fields.
Another thing we should settle on is what's returned by the service in case of an unsupported language. Now it just returns 500 error, which's passed back to the user. This should be changed in the service to 404, or may be 501.
The definitions endpoint in RESTBase is life in production: https://en.wiktionary.org/api/rest_v1/?doc#!/Page_content/get_page_definition_term
So, I'm closing this task.
Is there still no wiki page on this service and its expected usage? What am I supposed to link if I want to tell people that it exists, how to use it and where it's heading?
Hi all -- Nemo's asking for some documentation on this service. Any chance we can get this scheduled? Happy to help find the appropriate resources.
-Toby
A PR to improve the definition API end point documentation is available at https://github.com/wikimedia/restbase/pull/519. It includes a link to https://www.mediawiki.org/wiki/Wikimedia_Apps/Wiktionary_definition_popups_in_the_Android_Wikipedia_Beta_app.