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

    Function carouselInViewOf

    • The carousel of a post in view: the answer's children, and the slide swiped to past the first. The feed's answer names a child by its pk; every other surface holds a child by its container id (<childPk>_<authorPk>, the form of MediaCarousel), so the child is spelled as its post is: the post's id carries the author after its _, and the child's id takes the same author.

      Parameters

      • entry: {
            key: string;
            media: {
                carousel_media?: readonly { pk: string }[];
                code: string;
                id: string;
                injected?: { ad_id?: string } | null;
                inventory_source?: string;
                logging_info_token?: string;
                media_type: number;
                mezql_token?: string;
                pk?: string;
                product_type?: string;
                taken_at?: number;
                user?: { pk: string; username: string };
            };
            position: number;
            slide?: number;
            type: "post";
        }
        • Readonlykey: string
        • Readonlymedia: {
              carousel_media?: readonly { pk: string }[];
              code: string;
              id: string;
              injected?: { ad_id?: string } | null;
              inventory_source?: string;
              logging_info_token?: string;
              media_type: number;
              mezql_token?: string;
              pk?: string;
              product_type?: string;
              taken_at?: number;
              user?: { pk: string; username: string };
          }
          • Optional Readonlycarousel_media?: readonly { pk: string }[]

            The children of a carousel media, in the order the app swipes them: each child's pk is the carousel_media_id its like names. Absent on a media that is not a carousel.

          • Readonlycode: string
          • Readonlyid: string

            The media's container id (<pk>_<authorPk>), the id every media request addresses (media/<id>/info/, like/, comment/). Organic media carry it; a promoted one carries an ad id here and is marked by injected, so it is no media a post action can address.

          • Optional Readonlyinjected?: { ad_id?: string } | null

            Present on a promoted media (media_or_ad of an ad): its presence is what tells the ad apart from an organic post. Its other fields are not modelled.

          • Optional Readonlyinventory_source?: string

            The inventory the feed served the media from (media_or_ad on the Following feed's organic media): the value the item's like and unlike echo as inventory_source.

          • Optional Readonlylogging_info_token?: string

            The feed-issued logging token the item's like echoes as logging_info_token and its repost note as ranking_info_token. Organic media in the answers carry it (one value for the page's items); a promoted media carries none.

          • Readonlymedia_type: number
          • Optional Readonlymezql_token?: string

            The feed item's mezql_token — "" on every organic media of the Android 451 timeline, and the value the item's like echoes as its mezql_token.

          • Optional Readonlypk?: string
          • Optional Readonlyproduct_type?: string

            What kind of media the entry is, as the answer names it: the screen reads clips — a reel — and nothing else (the 451 warm-launch timeline answer carries it). An ad is not a product_type: the answer marks it injected. Absent on older answers.

          • Optional Readonlytaken_at?: number
          • Optional Readonlyuser?: { pk: string; username: string }
        • Readonlyposition: number
        • Optional Readonlyslide?: number

          The slide the person swiped the post's carousel to (zero-based, in carousel_media), absent until they swipe: the first slide is in front. The row's, replaced in the feed's frame by swipeToSlide; it dies with the frame.

        • Readonlytype: "post"

      Returns { children: readonly string[]; size?: number; slide?: number } | undefined