Variable SearchInputSchemaConst
SearchInputSchema: Union<
readonly [
Struct<
{
lastSeenMedia: optionalKey<
$Array<
Struct<
{
mediaIds: $Array<String>;
surfaceType: String;
timestamp: Number;
},
>,
>,
>;
query: String;
session: optionalKey<
Struct<
{
clientUuidRankToken: optionalKey<String>;
searchSessionId: String;
serpSessionId: optionalKey<String>;
typeaheadSessionId: optionalKey<String>;
},
>,
>;
},
>,
Struct<
{
recent: $Array<
Struct<{ fullName: String; userId: String; username: String }>,
>;
},
>,
],
> = ...
The search field as the person uses it:
SingleSearchTypeaheadTabFragmentshowing thesearch_typeaheadmodule.The screen opens in one of two ways:
{ recent }): the person tapped the search field on the Explore tab. The app sends nothing then; the field shows the recent accounts the tab fetched when it opened, and those travel here from the tab's handle (ExploreScreen.openSearchInput). Typing is thechangeaction, from a fresh search session.{ query, session?, lastSeenMedia? }): the caller opens the field with a query; the enter sends TypeaheadSearch for it.The screen's data is what it shows: the typed text, the typeahead's result stream (keyword, user and hashtag suggestions) and the search session the results screen continues — or, when it was opened empty, the recent accounts and no session (the first keystroke starts one). Its state keeps that session and the feed views the caller brought with the input (the SERP's Top query sends them when known), so every action continues the same search. A keystroke answers the screen's live handle over its fresh data, so the session the typing started travels with the handle a caller continues from.
Wire: entering the screen brings it to front (one
NavigateTo) and, for a typed opening, sends TypeaheadSearch for the first typed text; each further keystroke is achangeand one more request in the same session;searchregisters the recent-search click and opens the results' Top tab through SearchResultsTopTabScreen; a recent account of the empty field opens its profile from the account's ownopenProfile, with the sourcesearch_result. Both app versions (450 and 451) sendlat/lngasnullhere (the device's position belongs to the SERP's Accounts request, not to the typeahead). The one-time Meta AI consent write (MAIUnifiedUserMutation, entrypointIG__SEARCH__NULLSTATE) goes out after the keystroke's request while the session holds the notice from the launch's status query and has not acknowledged it (launch.meta-ai-consent.ts).Confirmed on Android 451: the field opened empty from the Explore tab with no request, the recent row tapped into a profile, and the field typed into, its query submitted and the results opened.
Screenshot:
screenshots/typeahead-account-result.webpbeside this file.