This is a skeletal task for implementing a network client for the new search Desktop Improvements Project / FAWG search experience. The interface approach taken by [[ https://gerrit.wikimedia.org/r/plugins/gitiles/mediawiki/extensions/Popups/+/master/src/gateway/rest.js | Popups ]] seems to have worked well and allows the underlying service to be swapped between the Action API, RESTBase, and mocked data so it should probably be considered for this task.
=== Questions
- Are the client responses [[ https://he.wikipedia.org/wiki/%D7%9E%D7%93%D7%99%D7%94_%D7%95%D7%99%D7%A7%D7%99:Gadget-Dwim.js | DWIM ]] compatible?
- Can we get thumbnails? How large are they?
- How many results per response?
- Is the caching sensible? For example, if a user types "f", "o", "o", <backspace>, can the browser served cached results for "fo"?
=== Docs and examples
https://www.mediawiki.org/wiki/API:REST_API/Search
https://en.wikipedia.org/w/rest.php/coredev/v0/search/page?q=foo
https://en.wikipedia.org/w/api.php?action=query&format=json&generator=prefixsearch&prop=pageprops%7Cpageimages%7Cdescription&redirects=&ppprop=displaytitle&piprop=thumbnail&pithumbsize=160&pilimit=6&gpssearch=foo&gpsnamespace=0&gpslimit=6&callback=callbackStack.queue%5B0%5D