"As a Reader, I want to see a thumbnail image of each page in a search result set, so I can visually identify the topic of the page."
To do this, we can add a thumbnail element to the pages in the search results, using the FileRepresentation object schema (see https://www.mediawiki.org/wiki/Core_Platform_Team/Initiatives/Core_REST_API_in_MediaWiki/Schema for object types in the REST API so far).
MediaWiki core doesn't have a representation of a thumbnail image. The default implementation should return null for the thumbnail, but allow for extensions to add a thumbnail (for example, using a hook).
The thumbnail size should be the biggest thumbnail that can fit in a 200x200px square.
The PageImages extension us using the ApiOpenSearchSuggest hook to attach thumbnails to search results returned by ApiOpenSearch.