Get Community-Specific Feed Elements from a Feed

Display a user profile feed that contains only feed elements that are scoped to a specific community. Feed elements that have a User or a Group parent record are scoped to communities. Feed elements whose parents are record types other than User or Group are always visible in all communities. Other parent record types could be scoped to communities in the future.

Example

This example gets the specified page of feed elements that includes only community-specific feed elements.
ConnectApi.FeedElementPage fep = ConnectApi.ChatterFeeds.getFeedElementsFromFeed(Network.getNetworkId(), ConnectApi.FeedType.UserProfile, 'me', 3, ConnectApi.FeedDensity.FewerUpdates, null, null, ConnectApi.FeedSortOrder.LastModifiedDateDesc, ConnectApi.FeedFilter.CommunityScoped);
Previous
Next