Class IgMedia

    • Constructor Detail

    • Method Detail

      • getChildren

        public List<IgMediaChildgetChildren()
        returns the list of child media objects, only available if the media_type is a carousal
        Returns:
        the list of children as unmodifiable list
      • addChild

        public boolean addChild​(IgMediaChild child)
        adds a new child to the children list
        Parameters:
        child - the child that is added
        Returns:
        true if adding the child works
      • removeChild

        public boolean removeChild​(IgMediaChild child)
        removes a new child from the children list
        Parameters:
        child - the child that is removed
        Returns:
        true if removing the child works
      • getComments

        public List<IgCommentgetComments()
        returns the comments of this media
        Returns:
        the comments of this media
      • setBoostEligibilityInfo

        public void setBoostEligibilityInfo​(IgBoostEligibilityInfo boostEligibilityInfo)
        The field provides information about boosting eligibility of a IG instagram media as an ad and additional details if not eligible.
      • getCaption

        public String getCaption()
        Caption. Excludes album children. The @ symbol is excluded, unless the app user can perform admin-equivalent tasks on the Facebook Page connected to the Instagram account used to create the caption.
      • setCaption

        public void setCaption​(String caption)
        Caption. Excludes album children. The @ symbol is excluded, unless the app user can perform admin-equivalent tasks on the Facebook Page connected to the Instagram account used to create the caption.
      • getCommentsCount

        public Long getCommentsCount()
        Count of comments on the media.

        Excludes comments on album child media and the media's caption. Includes replies on comments.

      • setCommentsCount

        public void setCommentsCount​(Long commentsCount)
        Count of comments on the media.

        Excludes comments on album child media and the media's caption. Includes replies on comments.

      • getIsCommentEnabled

        public Boolean getIsCommentEnabled()
        Indicates if comments are enabled or disabled. Excludes album children.
      • setIsCommentEnabled

        public void setIsCommentEnabled​(Boolean isCommentEnabled)
        Indicates if comments are enabled or disabled. Excludes album children.
      • getIsSharedToFeed

        public Boolean getIsSharedToFeed()
        Reels only. If true, indicates the reel can appear in both the Feed and Reels tabs.

        If false, indicates the reel can only appear in the Reels tab.

      • setIsSharedToFeed

        public void setIsSharedToFeed​(Boolean isSharedToFeed)
        Reels only. If true, indicates the reel can appear in both the Feed and Reels tabs.

        If false, indicates the reel can only appear in the Reels tab.

      • getLikeCount

        public Long getLikeCount()
        Count of likes on the media.

        Excludes likes on album child media and likes on promoted posts created from the media. Includes replies on comments.

        • v10.0 and older calls: value will be 0 if the media owner has hidden like counts it.
        • v11.0+ calls: field will be omitted if media owner has hidden like counts on it.
      • setLikeCount

        public void setLikeCount​(Long likeCount)
        Count of likes on the media.

        Excludes likes on album child media and likes on promoted posts created from the media. Includes replies on comments.

        • v10.0 and older calls: value will be 0 if the media owner has hidden like counts it.
        • v11.0+ calls: field will be omitted if media owner has hidden like counts on it.