igpapi — Instagram private API Simulator for Node.js (API reference) 4.19.0
    Preparing search index...

    Interface SearchInputActions

    The actions of SearchInputScreen: the methods you call on its handle while the screen is open.

    interface SearchInputActions {
        change: <Self extends ScreenHandle>(
            this: Self,
            ...args: [query: string],
        ) => Effect<
            Self,
            ScreenDataActionFailure<
                | IgApiError
                | HttpRequestError
                | SchemaError
                | GraphqlRootFieldMissingError
                | GraphqlServerError,
            >,
            never,
        >;
        clear: <Self extends ScreenHandle>(
            this: Self,
            ...args: [],
        ) => Effect<Self, ScreenDataActionFailure<never>, never>;
        openRecentAccount: (
            ...args: readonly [string],
        ) => Effect<
            AssembledHandle<
                "UserProfile",
                "screen",
                {
                    backgroundFailures: readonly {
                        message?: string;
                        request: | "story"
                        | "chaining"
                        | "recentSearchClick"
                        | "friendship"
                        | "highlights"
                        | "avatar"
                        | "inboxTray"
                        | "schoolBadge"
                        | "quickPromotion"
                        | "noteCtas"
                        | "selfProfileChaining"
                        | "creatorsTrial"
                        | "onboardingChecklist"
                        | "creatorDestinationType"
                        | "paymentsAccountDisabledRisk"
                        | "fbPayExperience"
                        | "donationsEligibility"
                        | "metaOneBenefitEligibility"
                        | "ringCreatorMetadata"
                        | "proHomeBadge"
                        | "proDashboard"
                        | "activityCount";
                        tag: string;
                    }[];
                    following?: boolean;
                    followRequested?: boolean;
                    gridCursor?: { gridItemsCursor: string; maxId: string };
                    isPrivate: boolean;
                    media: readonly {
                        authorId?: string;
                        carousel?: { children: readonly string[]; size?: number };
                        dashManifest?: string;
                        mediaId: string;
                        mediaType?: number;
                        position: number;
                        takenAt?: number;
                        trackingToken?: string;
                        videoDuration?: number;
                    }[];
                    profileSessionId: string;
                    stories: readonly {
                        id: string;
                        media_type: number;
                        pk: string;
                        taken_at?: number;
                    }[];
                    suggested: readonly {
                        followRankingToken?: string;
                        fullName: string;
                        userId: string;
                        username: string;
                    }[];
                    userId: string;
                    username: string;
                },
                ProfileActions,
                ProfileItems,
                ScreenHandle,
                "required",
                true,
                "userId",
                AndroidScreens,
            >,
            | ScreenEnterConcurrentError
            | ScreenDataError
            | ScreenEdgeInputError
            | ProfileEnterError,
            never,
        >;
        search: (
            ...args: readonly [string],
        ) => Effect<
            AssembledHandle<
                "SearchResultsTopTab",
                "screen",
                {
                    query: string;
                    session: {
                        clientUuidRankToken?: string;
                        searchSessionId: string;
                        serpSessionId: string;
                        typeaheadSessionId?: string;
                    };
                },
                SearchResultsTopTabActions,
                Record<never, never>,
                ScreenHandle,
                "required",
                true,
                never,
                AndroidScreens,
            >,

                | IgApiError
                | HttpRequestError
                | ScreenEnterConcurrentError
                | ScreenDataError
                | ScreenEdgeInputError,
            never,
        >;
    }
    Index

    Properties

    change: <Self extends ScreenHandle>(
        this: Self,
        ...args: [query: string],
    ) => Effect<
        Self,
        ScreenDataActionFailure<
            | IgApiError
            | HttpRequestError
            | SchemaError
            | GraphqlRootFieldMissingError
            | GraphqlServerError,
        >,
        never,
    >

    Types in the search field (query): looks the text up. Answers the field shown again over the fresh data (the query, its results and the rank token); continue from it for the next keystroke, which carries on the same typing session. A text this typing session already answered shows that answer and sends nothing.

    clear: <Self extends ScreenHandle>(
        this: Self,
        ...args: [],
    ) => Effect<Self, ScreenDataActionFailure<never>, never>

    Clears the field's text: the person tapped its clear (X). Sends no request and answers the field's live handle — the same typing session, an empty text, no suggestions, no rank token ('', the empty open's own value) and the recent accounts the field holds from its open, which an empty field shows again — so the next change starts from an empty field and carries only the new text.

    Recorded: android-451/follow-two-from-search — after the first follow the person returned to the field still holding the first name, tapped its clear once, and no request went out between the follow (#122) and the second typing (#124); the second typing's requests carry the same typeahead session id as the first's. The app registers a client event for the tap (ig_search_clear_query_x_icon_tap), not a request, and the library logs it (search.telemetry.ts); the library emits no search_viewport_view (null_state_recent) after it, because the recording logs none there.

    Observed by screenshot, not recorded: on our emulator (app 451, 2026-10-30) the field is empty right after the tap and the Recent accounts list is back with the keyboard open, and it stays so 3 s later. The packet recording carries no screen for it.

    openRecentAccount: (
        ...args: readonly [string],
    ) => Effect<
        AssembledHandle<
            "UserProfile",
            "screen",
            {
                backgroundFailures: readonly {
                    message?: string;
                    request: | "story"
                    | "chaining"
                    | "recentSearchClick"
                    | "friendship"
                    | "highlights"
                    | "avatar"
                    | "inboxTray"
                    | "schoolBadge"
                    | "quickPromotion"
                    | "noteCtas"
                    | "selfProfileChaining"
                    | "creatorsTrial"
                    | "onboardingChecklist"
                    | "creatorDestinationType"
                    | "paymentsAccountDisabledRisk"
                    | "fbPayExperience"
                    | "donationsEligibility"
                    | "metaOneBenefitEligibility"
                    | "ringCreatorMetadata"
                    | "proHomeBadge"
                    | "proDashboard"
                    | "activityCount";
                    tag: string;
                }[];
                following?: boolean;
                followRequested?: boolean;
                gridCursor?: { gridItemsCursor: string; maxId: string };
                isPrivate: boolean;
                media: readonly {
                    authorId?: string;
                    carousel?: { children: readonly string[]; size?: number };
                    dashManifest?: string;
                    mediaId: string;
                    mediaType?: number;
                    position: number;
                    takenAt?: number;
                    trackingToken?: string;
                    videoDuration?: number;
                }[];
                profileSessionId: string;
                stories: readonly {
                    id: string;
                    media_type: number;
                    pk: string;
                    taken_at?: number;
                }[];
                suggested: readonly {
                    followRankingToken?: string;
                    fullName: string;
                    userId: string;
                    username: string;
                }[];
                userId: string;
                username: string;
            },
            ProfileActions,
            ProfileItems,
            ScreenHandle,
            "required",
            true,
            "userId",
            AndroidScreens,
        >,
        | ScreenEnterConcurrentError
        | ScreenDataError
        | ScreenEdgeInputError
        | ProfileEnterError,
        never,
    >

    Opening an account of the field's Recent list by its user id, without a submit: the same walk a Recent row's openProfile takes (the account is cached, the click registers, the info stream is the bare entry_point=profile form). A scene whose person returns to the field and taps a Recent row continues from here (android-451/follow-from-search). Answers the profile handle.

    search: (
        ...args: readonly [string],
    ) => Effect<
        AssembledHandle<
            "SearchResultsTopTab",
            "screen",
            {
                query: string;
                session: {
                    clientUuidRankToken?: string;
                    searchSessionId: string;
                    serpSessionId: string;
                    typeaheadSessionId?: string;
                };
            },
            SearchResultsTopTabActions,
            Record<never, never>,
            ScreenHandle,
            "required",
            true,
            never,
            AndroidScreens,
        >,

            | IgApiError
            | HttpRequestError
            | ScreenEnterConcurrentError
            | ScreenDataError
            | ScreenEdgeInputError,
        never,
    >

    Taps the keyboard's search key with query: opens the Top results of the search. Answers its handle.