Class NewsItem


  • public final class NewsItem
    extends java.lang.Object
    • Method Detail

      • getType

        public java.util.Optional<java.lang.String> getType()
        Returns:
        The type of object.
      • getId

        public java.util.Optional<java.lang.String> getId()
        Returns:
        The unique identifier for the news item which is given by Intercom.
      • getWorkspaceId

        public java.util.Optional<java.lang.String> getWorkspaceId()
        Returns:
        The id of the workspace which the news item belongs to.
      • getTitle

        public java.util.Optional<java.lang.String> getTitle()
        Returns:
        The title of the news item.
      • getBody

        public java.util.Optional<java.lang.String> getBody()
        Returns:
        The news item body, which may contain HTML.
      • getSenderId

        public java.util.Optional<java.lang.Integer> getSenderId()
        Returns:
        The id of the sender of the news item. Must be a teammate on the workspace.
      • getState

        public java.util.Optional<NewsItem.State> getState()
        Returns:
        News items will not be visible to your users in the assigned newsfeeds until they are set live.
      • getNewsfeedAssignments

        public java.util.Optional<java.util.List<NewsfeedAssignment>> getNewsfeedAssignments()
        Returns:
        A list of newsfeed_assignments to assign to the specified newsfeed.
      • getLabels

        public java.util.Optional<java.util.List<java.util.Optional<java.lang.String>>> getLabels()
        Returns:
        Label names displayed to users to categorize the news item.
      • getCoverImageUrl

        public java.util.Optional<java.lang.String> getCoverImageUrl()
        Returns:
        URL of the image used as cover. Must have .jpg or .png extension.
      • getReactions

        public java.util.Optional<java.util.List<java.util.Optional<java.lang.String>>> getReactions()
        Returns:
        Ordered list of emoji reactions to the news item. When empty, reactions are disabled.
      • getDeliverSilently

        public java.util.Optional<java.lang.Boolean> getDeliverSilently()
        Returns:
        When set to true, the news item will appear in the messenger newsfeed without showing a notification badge.
      • getCreatedAt

        public java.util.Optional<java.lang.Integer> getCreatedAt()
        Returns:
        Timestamp for when the news item was created.
      • getUpdatedAt

        public java.util.Optional<java.lang.Integer> getUpdatedAt()
        Returns:
        Timestamp for when the news item was last updated.
      • equals

        public boolean equals​(java.lang.Object other)
        Overrides:
        equals in class java.lang.Object
      • getAdditionalProperties

        public java.util.Map<java.lang.String,​java.lang.Object> getAdditionalProperties()
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object