No Results
Search Tips:
- Please consider misspellings
- Try different search keywords
Newer Version Available
ChatterFeeds Class
Namespace
Usage
Feeds are made up of feed items. A feed item is a piece of information posted by a user (for example, a poll) or by an automated process (for example, when a tracked field is updated on a record). Because feeds and feed items are the core of Chatter, understanding them is crucial to developing applications with Chatter REST API and Chatter in Apex. For detailed information about the composition of feeds and feed items, see Working with Feeds and Feed Items.
Message segments in a feed item are typed as ConnectApi.MessageSegment. Feed item attachments are typed as ConnectApi.FeedItemAttachment. Record fields are typed as ConnectApi.AbstractRecordField. These classes are all abstract and have several concrete subclasses. At runtime you can use instanceof to check the concrete types of these objects and then safely proceed with the corresponding downcast. When you downcast, you must have a default case that handles unknown subclasses.
ChatterFeeds Methods
The following are methods for ChatterFeeds. All methods are static.
deleteComment(String, String)
API Version
28.0
Signature
public static Void deleteComment(String communityId, String commentId)
Parameters
Return Value
Type: Void
deleteLike(String, String)
API Version
28.0
Signature
public static Void deleteLike(String communityId, String likeId)
Parameters
Return Value
Type: Void
getComment(String, String)
API Version
28.0
Signature
public static ConnectApi.Comment getComment(String communityId, String commentId)
Parameters
Return Value
getCommentsForFeedItem(String, String)
API Version
28.0
Signature
public static ConnectApi.CommentPage getCommentsForFeedItem(String communityId, String feedItemId)
Parameters
Return Value
getCommentsForFeedItem(String, String, String, Integer)
API Version
28.0
Signature
public static ConnectApi.CommentPage getCommentsForFeedItem(String communityId, String feedItemId, String pageParam, Integer pageSize)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedItemId
- Type: String
- The ID for a feed item.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
Return Value
getFeed(String, ConnectApi.FeedType)
API Version
28.0
Signature
public static ConnectApi.Feed getFeed(String communityId, ConnectApi.FeedType feedType)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- The type of feed. The only valid value is Company.
Return Value
Type: ConnectApi.Feed Class
getFeed(String, ConnectApi.FeedType, ConnectApi.FeedSortOrder)
API Version
28.0
Signature
public static ConnectApi.Feed getFeed(String communityId, ConnectApi.FeedType feedType, ConnectApi.FeedSortOrder sortParam)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- The type of feed. The only valid value is Company.
- sortParam
- Type: ConnectApi.FeedSortOrder
- Values are:
- CreatedDateDesc—Sorts the feed items by most recent post date.
- LastModifiedDateDesc—Sorts the feed items by most recent activity, which includes new feed items and comments.
Return Value
Type: ConnectApi.Feed Class
getFeed(String, ConnectApi.FeedType, String)
API Version
28.0
Signature
public static ConnectApi.Feed getFeed(String communityId, ConnectApi.FeedType feedType, String subjectId)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- The type of feed. Valid values include every ConnectApi.FeedType except Company and Filter.
- subjectId
- Type: String
- If feedType is Record, subjectId can be any record ID, including a group ID. If feedType is Topics, subjectId must be a topic ID. If feedType is UserProfile, subjectId can be any user ID. If the feedType is any other value, subjectId must be the ID of the context user or the alias me.
Return Value
Type: ConnectApi.Feed Class
getFeed(String, ConnectApi.FeedType, String, ConnectApi.FeedSortOrder)
API Version
28.0
Signature
public static ConnectApi.Feed getFeed(String communityId, ConnectApi.FeedType feedType, String subjectId, ConnectApi.FeedSortOrder sortParam)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- The type of feed. Valid values include every ConnectApi.FeedType except Company and Filter.
- subjectId
- Type: String
- If feedType is Record, subjectId can be any record ID, including a group ID. If feedType is Topics, subjectId must be a topic ID. If feedType is UserProfile, subjectId can be any user ID. If the feedType is any other value, subjectId must be the ID of the context user or the alias me.
- sortParam
- Type: ConnectApi.FeedSortOrder
- Values are:
- CreatedDateDesc—Sorts the feed items by most recent post date.
- LastModifiedDateDesc—Sorts the feed items by most recent activity, which includes new feed items and comments.
Return Value
Type: ConnectApi.Feed Class
getFeedDirectory(String)
API Version
30.0
Signature
public static ConnectApi.FeedDirectory getFeedDirectory(String communityId)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
Return Value
Type: ConnectApi.FeedDirectory
getFeedItem(String, String)
API Version
28.0
Signature
public static ConnectApi.FeedItem getFeedItem(String communityId, String feedItemId)
Parameters
Return Value
getFeedItemsFromFeed(String, ConnectApi.FeedType)
API Version
28.0
Signature
public static ConnectApi.FeedItemPage getFeedItemsFromFeed(String communityId, ConnectApi.FeedType feedType)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- The type of feed. The only valid value is Company.
Return Value
Usage
getFeedItemsFromFeed(String, ConnectApi.FeedType, String, Integer, ConnectApi.FeedSortOrder)
API Version
28.0
Signature
public static ConnectApi.FeedItemPage getFeedItemsFromFeed(String communityId, ConnectApi.FeedType feedType, String pageParam, Integer pageSize, ConnectApi.FeedSortOrder sortParam)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- The type of feed. The only valid value is Company.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- sortParam
- Type: ConnectApi.FeedSortOrder
- Values are:
- CreatedDateDesc—Sorts the feed items by most recent post date.
- LastModifiedDateDesc—Sorts the feed items by most recent activity, which includes new feed items and comments.
Return Value
Usage
getFeedItemsFromFeed(String, ConnectApi.FeedType, Integer, ConnectApi.FeedDensity, String, Integer, ConnectApi.FeedSortOrder)
API Version
29.0
Signature
public static ConnectApi.FeedItemPage getFeedItemsFromFeed(String communityId, ConnectApi.FeedType feedType, Integer recentCommentCount, ConnectApi.FeedDensity density, String pageParam, Integer pageSize, ConnectApi.FeedSortOrder sortParam)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- The type of feed. The only valid value is Company.
- recentCommentCount
- Type: Integer
- The maximum number of comments to return with each feed item. The default value is 3.
- density
- Type: ConnectApi.FeedDensity
- Specify the amount of content in a feed.
- AllUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of.
- FewerUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of, but hides system-generated posts from records that nobody commented on.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- sortParam
- Type: ConnectApi.FeedSortOrder
- Values are:
- CreatedDateDesc—Sorts the feed items by most recent post date.
- LastModifiedDateDesc—Sorts the feed items by most recent activity, which includes new feed items and comments.
Return Value
Usage
getFeedItemsFromFeed(String, ConnectApi.FeedType, String)
API Version
28.0
Signature
public static ConnectApi.FeedItemPage getFeedItemsFromFeed(String communityId, ConnectApi.FeedType feedType, String subjectId)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- The type of feed. Valid values include every ConnectApi.FeedType except Company and Filter.
- subjectId
- Type: String
- If feedType is Record, subjectId can be any record ID, including a group ID. If feedType is Topics, subjectId must be a topic ID. If feedType is UserProfile, subjectId can be any user ID. If the feedType is any other value, subjectId must be the ID of the context user or the alias me.
Return Value
Usage
getFeedItemsFromFeed(String, ConnectApi.FeedType, String, String, Integer, ConnectApi.FeedSortOrder)
API Version
28.0
Signature
public static ConnectApi.FeedItemPage getFeedItemsFromFeed(String communityId, ConnectApi.FeedType feedType, String subjectId, String pageParam, Integer pageSize, ConnectApi.FeedSortOrder sortParam)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- The type of feed. Valid values include every ConnectApi.FeedType except Company and Filter.
- subjectId
- Type: String
- If feedType is Record, subjectId can be any record ID, including a group ID. If feedType is Topics, subjectId must be a topic ID. If feedType is UserProfile, subjectId can be any user ID. If the feedType is any other value, subjectId must be the ID of the context user or the alias me.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- The page contains the default number of items.
- sortParam
- Type: ConnectApi.FeedSortOrder
- Values are:
- CreatedDateDesc—Sorts the feed items by most recent post date.
- LastModifiedDateDesc—Sorts the feed items by most recent activity, which includes new feed items and comments.
Return Value
Usage
getFeedItemsFromFeed(String, ConnectApi.FeedType, String, Integer, ConnectApi.FeedDensity, String, Integer, ConnectApi.FeedSortOrder)
API Version
29.0
Signature
public static ConnectApi.FeedItemPage getFeedItemsFromFeed(String communityId, ConnectApi.FeedType feedType, String subjectId, Integer recentCommentCount, ConnectApi.FeedDensity density, String pageParam, Integer pageSize, ConnectApi.FeedSortOrder sortParam)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- The type of feed. Valid values include every ConnectApi.FeedType except Company and Filter.
- subjectId
- Type: String
- If feedType is Record, subjectId can be any record ID, including a group ID. If feedType is Topics, subjectId must be a topic ID. If feedType is UserProfile, subjectId can be any user ID. If the feedType is any other value, subjectId must be the ID of the context user or the alias me.
- recentCommentCount
- Type: Integer
- The maximum number of comments to return with each feed item. The default value is 3.
- density
- Type: ConnectApi.FeedDensity
- Specify the amount of content in a feed.
- AllUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of.
- FewerUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of, but hides system-generated posts from records that nobody commented on.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- sortParam
- Type: ConnectApi.FeedSortOrder
- Values are:
- CreatedDateDesc—Sorts the feed items by most recent post date.
- LastModifiedDateDesc—Sorts the feed items by most recent activity, which includes new feed items and comments.
Return Value
Usage
getFeedItemsFromFeed(String, ConnectApi.FeedType, String, Integer, ConnectApi.FeedDensity, String, Integer, ConnectApi.FeedSortOrder, Boolean)
API Version
30.0
Signature
public static ConnectApi.FeedItemPage getFeedItemsFromFeed(String communityId, ConnectApi.FeedType feedType, String subjectId, Integer recentCommentCount, ConnectApi.FeedDensity density, String pageParam, Integer pageSize, ConnectApi.FeedSortOrder sortParam, Boolean showInternalOnly)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- Value must be ConnectApi.FeedType.Record.
- subjectId
- Type: String
- Any record ID, including a group ID.
- recentCommentCount
- Type: Integer
- The maximum number of comments to return with each feed item. The default value is 3.
- density
- Type: ConnectApi.FeedDensity
- Specify the amount of content in a feed.
- AllUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of.
- FewerUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of, but hides system-generated posts from records that nobody commented on.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- sortParam
- Type: ConnectApi.FeedSortOrder
- Values are:
- CreatedDateDesc—Sorts the feed items by most recent post date.
- LastModifiedDateDesc—Sorts the feed items by most recent activity, which includes new feed items and comments.
- showInternalOnly
- Type: Boolean
- Specifies whether to show only feed items from internal (non-community) users (true), or not (false). The default value is false.
Return Value
Usage
getFeedItemsFromFilterFeed(String, String, String)
API Version
28.0
Signature
public static ConnectApi.FeedItemPage getFeedItemsFromFilterFeed(String communityId, String subjectId, String keyPrefix)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- subjectId
- Type: String
- The ID of the context user or the alias me.
- keyPrefix
- Type: String
- A key prefix that specifies record type. A key prefix is the first three characters in the object ID, which specifies the object type. For example, User objects have a prefix of 005 and Group objects have a prefix of 0F9.
Return Value
Usage
getFeedItemsFromFilterFeed(String, String, String, String, Integer, ConnectApi.FeedSortOrder)
API Version
28.0
Signature
public static ConnectApi.FeedItemPage getFeedItemsFromFilterFeed(String communityId, String subjectId, String keyPrefix, String pageParam, Integer pageSize, ConnectApi.FeedSortOrder sortParam)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- subjectId
- Type: String
- The ID of the context user or the alias me.
- keyPrefix
- Type: String
- A key prefix that specifies record type. A key prefix is the first three characters in the object ID, which specifies the object type. For example, User objects have a prefix of 005 and Group objects have a prefix of 0F9.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- sortParam
- Type: ConnectApi.FeedSortOrder
- Values are:
- CreatedDateDesc—Sorts the feed items by most recent post date.
- LastModifiedDateDesc—Sorts the feed items by most recent activity, which includes new feed items and comments.
Return Value
Usage
getFeedItemsFromFilterFeed(String, String, String, Integer, ConnectApi.FeedDensity, String, Integer, ConnectApi.FeedSortOrder)
API Version
29.0
Signature
public static ConnectApi.FeedItemPage getFeedItemsFromFilterFeed(String communityId, String subjectId, String keyPrefix, Integer recentCommentCount, ConnectApi.FeedDensity density, String pageParam, Integer pageSize, ConnectApi.FeedSortOrder sortParam)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- subjectId
- Type: String
- The ID of the context user or the alias me.
- keyPrefix
- Type: String
- A key prefix that specifies record type. A key prefix is the first three characters in the object ID, which specifies the object type. For example, User objects have a prefix of 005 and Group objects have a prefix of 0F9.
- recentCommentCount
- Type: Integer
- The maximum number of comments to return with each feed item. The default value is 3.
- density
- Type: ConnectApi.FeedDensity
- Specify the amount of content in a feed.
- AllUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of.
- FewerUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of, but hides system-generated posts from records that nobody commented on.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- sortParam
- Type: ConnectApi.FeedSortOrder
- Values are:
- CreatedDateDesc—Sorts the feed items by most recent post date.
- LastModifiedDateDesc—Sorts the feed items by most recent activity, which includes new feed items and comments.
Return Value
Usage
getFeedItemsFromFilterFeedUpdatedSince(String, String, String, Integer, ConnectApi.FeedDensity, String, Integer, String)
API Version
30.0
Signature
public static ConnectApi.FeedItemPage getFeedItemsFromFilterFeedUpdatedSince(String communityId, String subjectId, String keyPrefix, Integer recentCommentCount, ConnectApi.FeedDensity density, String pageParam, Integer pageSize, String updatedSince)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- subjectId
- Type: String
- The ID of the context user or the alias me.
- keyPrefix
- Type: String
- A key prefix that specifies record type. A key prefix is the first three characters in the object ID, which specifies the object type. For example, User objects have a prefix of 005 and Group objects have a prefix of 0F9.
- recentCommentCount
- Type: Integer
- The maximum number of comments to return with each feed item. The default value is 3.
- density
- Type: ConnectApi.FeedDensity
- Specify the amount of content in a feed.
- AllUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of.
- FewerUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of, but hides system-generated posts from records that nobody commented on.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- updatedSince
- Type: String
- An opaque token containing information about the last modified date of the feed. Do not construct this token. To retrieve this token, call getFeedItemsFromFilterFeed and take the value from the updatesToken property of the ConnectApi.FeedItemPage response body.
Usage
This method returns only feed items that have been updated since the time specified in the updatedSince argument. A feed item is considered to be updated if it was created since the last feed request, or if sort=LastModifiedDateDesc and a comment was added to the feed item since the last feed request. Adding likes and topics doesn’t update a feed item.
To test this method, use the matching set test method. When invoked during a test with the matching set test method, returns the feed item page that was passed in with that method, filtered by the key prefix: only the feed items associated with the specified type are returned. You must use the test method with the exact same parameters, or you receive an exception.
getFeedItemsUpdatedSince(String, ConnectApi.FeedType, Integer, ConnectApi.FeedDensity, String, Integer, String)
API Version
30.0
Signature
public static ConnectApi.FeedItemPage getFeedItemsUpdatedSince(String communityId, ConnectApi.FeedType feedType, Integer recentCommentCount, ConnectApi.FeedDensity density, String pageParam, Integer pageSize, String updatedSince)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- The type of feed. The only valid value is Company.
- recentCommentCount
- Type: Integer
- The maximum number of comments to return with each feed item. The default value is 3.
- density
- Type: ConnectApi.FeedDensity
- Specify the amount of content in a feed.
- AllUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of.
- FewerUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of, but hides system-generated posts from records that nobody commented on.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- updatedSince
- Type: String
- An opaque token containing information about the last modified date of the feed. Do not construct this token. Retrieve this token from the updatesToken property of the ConnectApi.FeedItemPage response body.
Return Value
Type: ConnectApi.FeedItemPage Class
A paged collection of ConnectApi.FeedItem objects.
Usage
This method returns only feed items that have been updated since the time specified in the updatedSince argument. A feed item is considered to be updated if it was created since the last feed request, or if sort=LastModifiedDateDesc and a comment was added to the feed item since the last feed request. Adding likes and topics doesn’t update a feed item.
To test code that uses this method, use the matching set test method.
Example
getFeedItemsUpdatedSince(String, ConnectApi.FeedType, String, Integer, ConnectApi.FeedDensity, String, Integer, String)
API Version
30.0
Signature
public static ConnectApi.FeedItemPage getFeedItemsUpdatedSince(String communityId, ConnectApi.FeedType feedType, String subjectId, Integer recentCommentCount, ConnectApi.FeedDensity density, String pageParam, Integer pageSize, String updatedSince)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- One of these values:
- Files
- Groups
- News
- People
- Record
- subjectId
- Type: String
- If feedType is ConnectApi.Record, subjectId can be any record ID, including a group ID. Otherwise, it must be the context user or the alias me.
- recentCommentCount
- Type: Integer
- The maximum number of comments to return with each feed item. The default value is 3.
- density
- Type: ConnectApi.FeedDensity
- Specify the amount of content in a feed.
- AllUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of.
- FewerUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of, but hides system-generated posts from records that nobody commented on.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- updatedSince
- Type: String
- An opaque token containing information about the last modified date of the feed. Do not construct this token. Retrieve this token from the updatesToken property of the ConnectApi.FeedItemPage response body.
Return Value
Type: ConnectApi.FeedItemPage Class
A paged collection of ConnectApi.FeedItem objects.
Usage
This method returns only feed items that have been updated since the time specified in the updatedSince argument. A feed item is considered to be updated if it was created since the last feed request, or if sort=LastModifiedDateDesc and a comment was added to the feed item since the last feed request. Adding likes and topics doesn’t update a feed item.
To test code that uses this method, use the matching set test method.
Example
getFeedItemsUpdatedSince(String, ConnectApi.FeedType, String, Integer, ConnectApi.FeedDensity, String, Integer, String, Boolean)
API Version
30.0
Signature
public static ConnectApi.FeedItemPage getFeedItemsUpdatedSince(String communityId, ConnectApi.FeedType feedType, String subjectId, Integer recentCommentCount, ConnectApi.FeedDensity density, String pageParam, Integer pageSize, String updatedSince, Boolean showInternalOnly)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- Value must be ConnectApi.FeedType.Record.
- subjectId
- Type: String
- Any record ID, including a group ID.
- recentCommentCount
- Type: Integer
- The maximum number of comments to return with each feed item. The default value is 3.
- density
- Type: ConnectApi.FeedDensity
- Specify the amount of content in a feed.
- AllUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of.
- FewerUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of, but hides system-generated posts from records that nobody commented on.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- updatedSince
- Type: String
- An opaque token containing information about the last modified date of the feed. Do not construct this token. Retrieve this token from the updatesToken property of the ConnectApi.FeedItemPage response body.
- showInternalOnly
- Type: Boolean
- Specifies whether to show only feed items from internal (non-community) users (true), or not (false). The default value is false.
Return Value
Type: ConnectApi.FeedItemPage Class
A paged collection of ConnectApi.FeedItem objects.
Usage
This method returns only feed items that have been updated since the time specified in the updatedSince argument. A feed item is considered to be updated if it was created since the last feed request, or if sort=LastModifiedDateDesc and a comment was added to the feed item since the last feed request. Adding likes and topics doesn’t update a feed item.
If showInternalOnly is true and Communities is enabled, feed items from communities are included. Otherwise, only feed items from the internal community are included.
To test code that uses this method, use the matching set test method.
Example
getFeedPoll(String, String)
API Version
28.0
Signature
public static ConnectApi.FeedPoll getFeedPoll(String communityId, String feedItemId)
Parameters
Return Value
getFilterFeed(String, String, String)
API Version
28.0
Signature
public static ConnectApi.Feed getFilterFeed(String communityId, String subjectId, String keyPrefix)
Parameters
Return Value
Type: ConnectApi.Feed Class
getFilterFeed(String, String, String, ConnectApi.FeedType)
API Version
28.0
Signature
public static ConnectApi.Feed getFilterFeed(String communityId, String subjectId, String keyPrefix, ConnectApi.FeedType sortParam)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- subjectId
- Type: String
- The ID of the context user or the alias me.
- keyPrefix
- Type: String
- A key prefix that specifies record type. A key prefix is the first three characters in the object ID, which specifies the object type. For example, User objects have a prefix of 005 and Group objects have a prefix of 0F9.
- sortParam
- Type: ConnectApi.FeedType
- Values are:
- CreatedDateDesc—Sorts the feed items by most recent post date.
- LastModifiedDateDesc—Sorts the feed items by most recent activity, which includes new feed items and comments.
Return Value
Type: ConnectApi.Feed Class
getFilterFeedDirectory(String, String)
API Version
30.0
Signature
public static ConnectApi.FeedDirectory getFilterFeedDirectory(String communityId, String subjectId)
Parameters
Usage
Call this method to return a directory containing a list of ConnectApi.FeedDirectoryItem objects. Each object contains a key prefix associated with an entity type the logged-in user is following. A key prefix is the first three characters of a record ID, which specifies the entity type.
Use the key prefixes to filter the news feed so that it contains only feed items whose parent is the entity type associated with the key prefix, for example, get all the feed items whose parent is an Account. To get the feed items, pass a key prefix to the ConnectApi.getFeedItemsFromFilterFeed method.
The information about filter feeds never contains the key prefixes for the User (005) or Group (0F9) entity types, but all users can use those key prefixes as filters.
The ConnectApi.FeedDirectory.favorites property is always empty when returned by a call to getFilterFeedDirectory because you can’t filter a news feed by favorites.
Example
This example calls getFilterFeedDirectory and loops through the returned FeedDirectoryItem objects to find the key prefixes the logged-in user can use to filter their news feed. It then copies each keyPrefix value to a list. Finally, it passes one of the key prefixes from the list to the getFeedItemsFromFilterFeed method. The returned feed items include every feed item from the news feed whose parent is the entity type specified by the passed key prefix.
getLike(String, String)
API Version
28.0
Signature
public static ConnectApi.ChatterLike getLike(String communityId, String likeId)
Parameters
Return Value
getLikesForComment(String, String)
API Version
28.0
Signature
public static ConnectApi.ChatterLikePage getLikesForComment(String communityId, String commentId)
Parameters
Return Value
getLikesForComment(String, String, Integer, Integer)
API Version
28.0
Signature
public static ConnectApi.ChatterLikePage getLikesForComment(String communityId, String commentId, Integer pageParam, Integer pageSize)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- commentId
- Type: String
- The ID for a comment.
- pageParam
- Type: Integer
- Specifies the number of the page you want returned. Starts at 0. If you pass in null or 0, the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
Return Value
getLikesForFeedItem(String, String)
API Version
28.0
Signature
public static ConnectApi.ChatterLikePage getLikesForFeedItem(String communityId, String feedItemId)
Parameters
Return Value
getLikesForFeedItem(String, String, Integer, Integer)
API Version
28.0
Signature
public static ConnectApi.ChatterLikePage getLikesForFeedItem(String communityId, String feedItemId, Integer pageParam, Integer pageSize)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedItemId
- Type: String
- The ID for a feed item.
- pageParam
- Type: Integer
- Specifies the number of the page you want returned. Starts at 0. If you pass in null or 0, the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
Return Value
isModified(String, ConnectApi.FeedType, String, String)
API Version
28.0
Signature
public static ConnectApi.FeedModifiedInfo isModified(String communityId, ConnectApi.FeedType feedType, String subjectId, String since)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- Specifies the type of feed. The only supported type is News
- subjectId
- Type: String
- The ID of the context user or the alias me.
- since
- Type: String
- an opaque token containing information about the last modified date of the feed. Retrieve this token from Feed.isModifiedToken or FeedItemPage.isModifiedToken.
Return Value
Usage
likeComment(String, String)
API Version
28.0
Signature
public static ConnectApi.ChatterLike likeComment(String communityId, String commentId)
Parameters
Return Value
likeFeedItem(String, String)
API Version
28.0
Signature
public static ConnectApi.ChatterLike likeFeedItem(String communityId, String feedItemId)
Parameters
Return Value
postComment(String, String, String)
API Version
28.0
Signature
public static ConnectApi.Comment postComment(String communityId, String feedItemId, String text)
Parameters
Return Value
Usage
Feed items and comments can contain up to 5000 characters.
postComment(String, String, ConnectApi.CommentInput, ConnectApi.BinaryInput)
API Version
28.0
Signature
public static ConnectApi.Comment postComment(String communityId, String feedItemId, ConnectApi.CommentInput comment, ConnectApi.BinaryInput feedItemFileUpload)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedItemId
- Type: String
- The ID for a feed item.
- comment
- Type: ConnectApi.CommentInput Class
- In the CommentInput object, specify rich text, including @mentions. Optionally, in the CommentInput.attachment property, specify an existing file or a new file
- feedItemFileUpload
- Type: ConnectApi.BinaryInput Class
- If you specify a NewFileAttachmentInput object in the CommentInput.attachment property, specify the new binary file to attach in this argument. Otherwise, do not specify a value.
Return Value
Usage
Feed items and comments can contain up to 5000 characters.
postFeedItem(String, ConnectApi.FeedType, String, String)
API Version
28.0
Signature
public static ConnectApi.FeedItem postFeedItem(String communityId, ConnectApi.FeedType feedType, String subjectId, String text)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- One of the following:
- News
- Record
- UserProfile
- subjectId
- Type: String
- The value depends on the feedType:
- News—subjectId must be the ID of the context user or the keyword me.
- Record—The ID of any record with a feed, including groups.
- UserProfile—The ID of any user.
- text
- Type: String
- The text of the comment. Mentions and hashtags are removed.
Return Value
postFeedItem(String, ConnectApi.FeedType, String, ConnectApi.FeedItemInput, ConnectApi.BinaryInput)
API Version
28.0
Signature
public static ConnectApi.FeedItem postFeedItem(String communityId, ConnectApi.FeedType feedType, String subjectId, ConnectApi.FeedItemInput feedItemInput, ConnectApi.BinaryInput feedItemFileUpload)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- One of the following:
- News
- Record
- UserProfile
- subjectId
- Type: String
- If feedType is Record, subjectId can be any record ID, including a group ID. If feedType is Topics, subjectId must be a topic ID. If feedType is UserProfile, subjectId can be any user ID. If the feedType is any other value, subjectId must be the ID of the context user or the alias me.
- feedItemInput
- Type: ConnectApi.FeedItemInput Class
- In the FeedItemInput object, specify rich text. Optionally, in the FeedItemInput.attachment property, specify a link, a poll, an existing file, or a new file.
- feedItemFileUpload
- Type: ConnectApi.BinaryInput Class
- If you specify a NewFileAttachmentInput object in the FeedItemInput.attachment property, specify the new binary file to attach in this argument. Otherwise, do not specify a value.
Return Value
Usage
searchFeedItems(String, String)
API Version
28.0
Signature
public static ConnectApi.FeedItemPage searchFeedItems(String communityId, String q)
Parameters
Return Value
searchFeedItems(String, String, ConnectApi.FeedSortOrder)
API Version
28.0
Signature
public static ConnectApi.FeedItemPage searchFeedItems(String communityId, String q, ConnectApi.FeedSortOrder sortParam)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- q
- Type: String
- Required and cannot be null. Specifies the string to search. The search string must contain at least two characters, not including wildcards. See Wildcards.
- sortParam
- Type: ConnectApi.FeedSortOrder
- Values are:
- CreatedDateDesc—Sorts the feed items by most recent post date.
- LastModifiedDateDesc—Sorts the feed items by most recent activity, which includes new feed items and comments.
Return Value
searchFeedItems(String, String, String, Integer)
API Version
28.0
Signature
public static ConnectApi.FeedItemPage searchFeedItems(String communityId, String q, String pageParam, Integer pageSize)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- q
- Type: String
- Required and cannot be null. Specifies the string to search. The search string must contain at least two characters, not including wildcards. See Wildcards.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
Return Value
searchFeedItems(String, String, String, Integer, ConnectApi.FeedSortOrder)
API Version
28.0
Signature
public static ConnectApi.FeedItemPage searchFeedItems(String communityId, String q, String pageParam, Integer pageSize, ConnectApi.FeedSortOrder sortParam)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- q
- Type: String
- Required and cannot be null. Specifies the string to search. The search string must contain at least two characters, not including wildcards. See Wildcards.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- sortParam
- Type: ConnectApi.FeedSortOrder
- Values are:
- CreatedDateDesc—Sorts the feed items by most recent post date.
- LastModifiedDateDesc—Sorts the feed items by most recent activity, which includes new feed items and comments.
Return Value
searchFeedItems(String, String, Integer, String, Integer, ConnectApi.FeedSortOrder)
API Version
29.0
Signature
public static ConnectApi.FeedItemPage searchFeedItems(String communityId, String q, Integer recentCommentCount, String pageParam, Integer pageSize, ConnectApi.FeedSortOrder sortParam)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- q
- Type: String
- Required and cannot be null. Specifies the string to search. The search string must contain at least two characters, not including wildcards. See Wildcards.
- recentCommentCount
- Type: Integer
- The maximum number of comments to return with each feed item. The default value is 3.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- sortParam
- Type: ConnectApi.FeedSortOrder
- Values are:
- CreatedDateDesc—Sorts the feed items by most recent post date.
- LastModifiedDateDesc—Sorts the feed items by most recent activity, which includes new feed items and comments.
Return Value
searchFeedItemsInFeed(String, ConnectApi.FeedType, String)
API Version
28.0
Signature
public static ConnectApi.FeedItemPage searchFeedItemsInFeed(String communityId, ConnectApi.FeedType feedType, String q)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- The type of feed. The only valid value is Company.
- q
- Type: String
- Required and cannot be null. Specifies the string to search. The search string must contain at least two characters, not including wildcards. See Wildcards.
Return Value
Usage
searchFeedItemsInFeed(String, ConnectApi.FeedType, String, Integer, ConnectApi.FeedSortOrder, String)
API Version
28.0
Signature
public static ConnectApi.FeedItemPage searchFeedItemsInFeed(String communityId, ConnectApi.FeedType feedType, String pageParam, Integer pageSize, ConnectApi.FeedSortOrder sortParam, String q)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- The type of feed. The only valid value is Company.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- sortParam
- Type: ConnectApi.FeedSortOrder
- Values are:
- CreatedDateDesc—Sorts the feed items by most recent post date.
- LastModifiedDateDesc—Sorts the feed items by most recent activity, which includes new feed items and comments.
- q
- Type: String
- Required and cannot be null. Specifies the string to search. The search string must contain at least two characters, not including wildcards. See Wildcards.
Return Value
Usage
searchFeedItemsInFeed(String, ConnectApi.FeedType, Integer, ConnectApi.FeedDensity, String, Integer, ConnectApi.FeedSortOrder, String)
API Version
29.0
Signature
public static ConnectApi.FeedItemPage searchFeedItemsInFeed(String communityId, ConnectApi.FeedType feedType, Integer recentCommentCount, ConnectApi.FeedDensity density, String pageParam, Integer pageSize, ConnectApi.FeedSortOrder sortParam, String q)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- The type of feed. The only valid value is Company.
- recentCommentCount
- Type: Integer
- The maximum number of comments to return with each feed item. The default value is 3.
- density
- Type: ConnectApi.FeedDensity
- Specify the amount of content in a feed.
- AllUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of.
- FewerUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of, but hides system-generated posts from records that nobody commented on.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- sortParam
- Type: ConnectApi.FeedSortOrder
- Values are:
- CreatedDateDesc—Sorts the feed items by most recent post date.
- LastModifiedDateDesc—Sorts the feed items by most recent activity, which includes new feed items and comments.
- q
- Type: String
- Required and cannot be null. Specifies the string to search. The search string must contain at least two characters, not including wildcards. See Wildcards.
Return Value
Usage
searchFeedItemsInFeed(String, ConnectApi.FeedType, String, String)
API Version
28.0
Signature
public static ConnectApi.FeedItemPage searchFeedItemsInFeed(String communityId, ConnectApi.FeedType feedType, String subjectId, String q)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- The type of the feed. Valid values include every ConnectApi.FeedType except Company, Filter, and Topics.
- subjectId
- Type: String
- If feedType is Record, subjectId can be any record ID, including a group ID. If feed type is UserProfile, subjectId can be any user ID. If feedType is any other value, subjectId must be the ID of the context user or the alias me.
- q
- Type: String
- Required and cannot be null. Specifies the string to search. The search string must contain at least two characters, not including wildcards. See Wildcards.
Return Value
Usage
searchFeedItemsInFeed(String, ConnectApi.FeedType, String, String, Integer, ConnectApi.FeedSortOrder, String)
API Version
28.0
Signature
public static ConnectApi.FeedItemPage searchFeedItemsInFeed(String communityId, ConnectApi.FeedType feedType, String subjectId, String pageParam, Integer pageSize, ConnectApi.FeedSortOrder sortParam, String q)
Parameters
- communityId
- Type: String
- The type of the feed. Valid values include every ConnectApi.FeedType except Company, Filter, and Topics.
- feedType
- Type: ConnectApi.FeedType
- If feedType is Record, subjectId can be any record ID, including a group ID. If feedType is UserProfile, subjectId can be any user ID. If feedType is any other value, subjectId must be the ID of the context user or the alias me.
- subjectId
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageParam
- Type: String
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- pageSize
- Type: Integer
- Values are:
- CreatedDateDesc—Sorts the feed items by most recent post date.
- LastModifiedDateDesc—Sorts the feed items by most recent activity, which includes new feed items and comments.
- sortParam
- Type: ConnectApi.FeedSortOrder
- Required and cannot be null. Specifies the string to search. The search string must contain at least two characters, not including wildcards. See Wildcards.
- q
- Type: String
- Search term. Searches keywords in the user or group name. A minimum of 1 character is required. This parameter does not support wildcards. This parameter is required.
Return Value
Usage
searchFeedItemsInFeed(String, ConnectApi.FeedType, String, Integer, ConnectApi.FeedDensity, String, Integer, ConnectApi.FeedSortOrder, String)
API Version
29.0
Signature
public static ConnectApi.FeedItemPage searchFeedItemsInFeed(String communityId, ConnectApi.FeedType feedType, String subjectId, Integer recentCommentCount, ConnectApi.FeedDensity density, String pageParam, Integer pageSize, ConnectApi.FeedSortOrder sortParam, String q)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- The type of the feed. Valid values include every ConnectApi.FeedType except Company, Filter, and Topics.
- subjectId
- Type: String
- If feedType is Record, subjectId can be any record ID, including a group ID. If feedType is UserProfile, subjectId can be any user ID. If feedType is any other value, subjectId must be the ID of the context user or the alias me.
- recentCommentCount
- Type: Integer
- Specify the amount of content in a feed.
- AllUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of.
- FewerUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of, but hides system-generated posts from records that nobody commented on.
- density
- Type: ConnectApi.FeedDensity
- Specify the amount of content in a feed.
- AllUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of.
- FewerUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of, but hides system-generated posts from records that nobody commented on.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- sortParam
- Type: ConnectApi.FeedSortOrder
- Values are:
- CreatedDateDesc—Sorts the feed items by most recent post date.
- LastModifiedDateDesc—Sorts the feed items by most recent activity, which includes new feed items and comments.
- q
- Type: String
- Required and cannot be null. Specifies the string to search. The search string must contain at least two characters, not including wildcards. See Wildcards.
Return Value
Usage
searchFeedItemsInFeed(String, ConnectApi.FeedType, String, Integer, ConnectApi.FeedDensity, String, Integer, ConnectApi.FeedSortOrder, String, Boolean)
API Version
30.0
Signature
public static ConnectApi.FeedItemPage searchFeedItemsInFeed(String communityId, ConnectApi.FeedType feedType, String subjectId, Integer recentCommentCount, ConnectApi.FeedDensity density, String pageParam, Integer pageSize, ConnectApi.FeedSortOrder sortParam, String q, Boolean showInternalOnly)
Parameters
- communityId
- Type: String
- The type of the feed. Valid values include every ConnectApi.FeedType except Company, Filter, and Topics.
- feedType
- Type: ConnectApi.FeedType
- Value must be ConnectApi.FeedType.Record.
- subjectId
- Type: String
- Any record ID, including a group ID.
- recentCommentCount
- Type: Integer
- The maximum number of comments to return with each feed item. The default value is 3.
- density
- Type: ConnectApi.FeedDensity
- Specify the amount of content in a feed.
- AllUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of.
- FewerUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of, but hides system-generated posts from records that nobody commented on.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- sortParam
- Type: ConnectApi.FeedSortOrder
- Values are:
- CreatedDateDesc—Sorts the feed items by most recent post date.
- LastModifiedDateDesc—Sorts the feed items by most recent activity, which includes new feed items and comments.
- q
- Type: String
- Required and cannot be null. Specifies the string to search. The search string must contain at least two characters, not including wildcards. See Wildcards.
- showInternalOnly
- Type: Boolean
- Specifies whether to show only feed items from internal (non-community) users (true), or not (false). The default value is false.
Return Value
Usage
To test code that uses this method, use the matching set test method.
searchFeedItemsInFilterFeed(String, String, String, String)
API Version
28.0
Signature
public static ConnectApi.FeedItemPage searchFeedItemsInFilterFeed(String communityId, String subjectId, String keyPrefix, String q)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- subjectId
- Type: String
- The ID of the context user or the alias me.
- keyPrefix
- Type: String
- A key prefix that specifies record type. A key prefix is the first three characters in the object ID, which specifies the object type. For example, User objects have a prefix of 005 and Group objects have a prefix of 0F9.
- q
- Type: String
- Required and cannot be null. Specifies the string to search. The search string must contain at least two characters, not including wildcards. See Wildcards.
Return Value
Usage
searchFeedItemsInFilterFeed(String, String, String, String, Integer, ConnectApi.FeedSortOrder, String)
API Version
28.0
Signature
public static ConnectApi.FeedItemPage searchFeedItemsInFilterFeed(String communityId, String subjectId, String keyPrefix, String pageParam, Integer pageSize, ConnectApi.FeedSortOrder sortParam, String q)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- subjectId
- Type: String
- The ID of the context user or the alias me.
- keyPrefix
- Type: String
- A key prefix that specifies record type. A key prefix is the first three characters in the object ID, which specifies the object type. For example, User objects have a prefix of 005 and Group objects have a prefix of 0F9.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- sortParam
- Type: ConnectApi.FeedSortOrder
- Values are:
- CreatedDateDesc—Sorts the feed items by most recent post date.
- LastModifiedDateDesc—Sorts the feed items by most recent activity, which includes new feed items and comments.
- q
- Type: String
- Required and cannot be null. Specifies the string to search. The search string must contain at least two characters, not including wildcards. See Wildcards.
Return Value
Usage
searchFeedItemsInFilterFeed(String, String, String, Integer, ConnectApi.FeedDensity, String, Integer, ConnectApi.FeedSortOrder, String)
API Version
29.0
Signature
public static ConnectApi.FeedItemPage searchFeedItemsInFilterFeed(String communityId, String subjectId, String keyPrefix, Integer recentCommentCount, ConnectApi.FeedDensity density, String pageParam, Integer pageSize, ConnectApi.FeedSortOrder sortParam, String q)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- subjectId
- Type: String
- The ID of the context user or the alias me.
- keyPrefix
- Type: String
- A key prefix that specifies record type. A key prefix is the first three characters in the object ID, which specifies the object type. For example, User objects have a prefix of 005 and Group objects have a prefix of 0F9.
- recentCommentCount
- Type: Integer
- The maximum number of comments to return with each feed item. The default value is 3.
- density
- Type: ConnectApi.FeedDensity
- Specify the amount of content in a feed.
- AllUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of.
- FewerUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of, but hides system-generated posts from records that nobody commented on.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- sortParam
- Type: ConnectApi.FeedSortOrder
- Values are:
- CreatedDateDesc—Sorts the feed items by most recent post date.
- LastModifiedDateDesc—Sorts the feed items by most recent activity, which includes new feed items and comments.
- q
- Type: String
- Required and cannot be null. Specifies the string to search. The search string must contain at least two characters, not including wildcards. See Wildcards.
Return Value
Usage
setTestGetFeedItemsFromFeed(String, ConnectApi.FeedType, ConnectApi.FeedItemPage)
API Version
28.0
Signature
public static Void setTestGetFeedItemsFromFeed(String communityId, ConnectApi.FeedType feedType, ConnectApi.FeedItemPage result)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- The type of feed. The only valid value is Company.
- result
- Type: ConnectApi.FeedItemPage Class
- The object containing test data.
Return Value
Type: Void
setTestGetFeedItemsFromFeed(String, ConnectApi.FeedType, String, Integer, ConnectApi.FeedSortOrder, ConnectApi.FeedItemPage)
API Version
28.0
Signature
public static Void setTestGetFeedItemsFromFeed(String communityId, ConnectApi.FeedType feedType, String pageParam, Integer pageSize, ConnectApi.FeedSortOrder sortParam, ConnectApi.FeedItemPage result)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- The type of feed. The only valid value is Company.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- sortParam
- Type: ConnectApi.FeedSortOrder
- Values are:
- CreatedDateDesc—Sorts the feed items by most recent post date.
- LastModifiedDateDesc—Sorts the feed items by most recent activity, which includes new feed items and comments.
- result
- Type: ConnectApi.FeedItemPage Class
- The object containing test data.
Return Value
Type: Void
setTestGetFeedItemsFromFeed(String, ConnectApi.FeedType, Integer, ConnectApi.FeedDensity, String, Integer, ConnectApi.FeedSortOrder, ConnectApi.FeedItemPage)
API Version
29.0
Signature
public static Void setTestGetFeedItemsFromFeed(String communityId, ConnectApi.FeedType feedType, Integer recentCommentCount, ConnectApi.FeedDensity density, String pageParam, Integer pageSize, ConnectApi.FeedSortOrder sortParam, ConnectApi.FeedItemPage result)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- The type of feed. The only valid value is Company.
- recentCommentCount
- Type: Integer
- The maximum number of comments to return with each feed item. The default value is 3.
- density
- Type: ConnectApi.FeedDensity
- Specify the amount of content in a feed.
- AllUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of.
- FewerUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of, but hides system-generated posts from records that nobody commented on.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- sortParam
- Type: ConnectApi.FeedSortOrder
- Values are:
- CreatedDateDesc—Sorts the feed items by most recent post date.
- LastModifiedDateDesc—Sorts the feed items by most recent activity, which includes new feed items and comments.
- result
- Type: ConnectApi.FeedItemPage Class
- The object containing test data.
Return Value
Type: Void
setTestGetFeedItemsFromFeed(String, ConnectApi.FeedType, String, ConnectApi.FeedItemPage)
API Version
28.0
Signature
public static Void setTestGetFeedItemsFromFeed(String communityId, ConnectApi.FeedType feedType, String subjectId, ConnectApi.FeedItemPage result)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- The type of feed. Valid values include every ConnectApi.FeedType except Company and Filter.
- subjectId
- Type: String
- If feedType is Record, subjectId can be any record ID, including a group ID. If feedType is Topics, subjectId must be a topic ID. If feedType is UserProfile, subjectId can be any user ID. If the feedType is any other value, subjectId must be the ID of the context user or the alias me.
- result
- Type: ConnectApi.FeedItemPage Class
- The object containing test data.
Return Value
Type: Void
setTestGetFeedItemsFromFeed(String, ConnectApi.FeedType, String, String, Integer, ConnectApi.FeedSortOrder, ConnectApi.FeedItemPage)
API Version
28.0
Signature
public static Void setTestGetFeedItemsFromFeed(String communityId, ConnectApi.FeedType feedType, String subjectId, String pageParam, Integer pageSize, ConnectApi.FeedSortOrder sortParam, ConnectApi.FeedItemPage result)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- The type of feed. Valid values include every ConnectApi.FeedType except Company and Filter.
- subjectId
- Type: String
- If feedType is Record, subjectId can be any record ID, including a group ID. If feedType is Topics, subjectId must be a topic ID. If feedType is UserProfile, subjectId can be any user ID. If the feedType is any other value, subjectId must be the ID of the context user or the alias me.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- sortParam
- Type: ConnectApi.FeedSortOrder
- Values are:
- CreatedDateDesc—Sorts the feed items by most recent post date.
- LastModifiedDateDesc—Sorts the feed items by most recent activity, which includes new feed items and comments.
- result
- Type: ConnectApi.FeedItemPage Class
- The object containing test data.
Return Value
Type: Void
setTestGetFeedItemsFromFeed(String, ConnectApi.FeedType, String, Integer, ConnectApi.FeedDensity, String, Integer, ConnectApi.FeedSortOrder, ConnectApi.FeedItemPage)
API Version
29.0
Signature
public static Void setTestGetFeedItemsFromFeed(String communityId, ConnectApi.FeedType feedType, String subjectId, Integer recentCommentCount, ConnectApi.FeedDensity density, String pageParam, Integer pageSize, ConnectApi.FeedSortOrder sortParam, ConnectApi.FeedItemPage result)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- The type of feed. Valid values include every ConnectApi.FeedType except Company and Filter.
- subjectId
- Type: String
- If feedType is Record, subjectId can be any record ID, including a group ID. If feedType is Topics, subjectId must be a topic ID. If feedType is UserProfile, subjectId can be any user ID. If the feedType is any other value, subjectId must be the ID of the context user or the alias me.
- recentCommentCount
- Type: Integer
- The maximum number of comments to return with each feed item. The default value is 3.
- density
- Type: ConnectApi.FeedDensity
- Specify the amount of content in a feed.
- AllUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of.
- FewerUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of, but hides system-generated posts from records that nobody commented on.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- sortParam
- Type: ConnectApi.FeedSortOrder
- Values are:
- CreatedDateDesc—Sorts the feed items by most recent post date.
- LastModifiedDateDesc—Sorts the feed items by most recent activity, which includes new feed items and comments.
- result
- Type: ConnectApi.FeedItemPage Class
- The object containing test data.
Return Value
Type: Void
setTestGetFeedItemsFromFeed(String, ConnectApi.FeedType, String, Integer, ConnectApi.FeedDensity, String, Integer, ConnectApi.FeedSortOrder, Boolean, ConnectApi.FeedItemPage)
API Version
30.0
Signature
public static Void setTestGetFeedItemsFromFeed(String communityId, ConnectApi.FeedType feedType, String subjectId, Integer recentCommentCount, ConnectApi.FeedDensity density, String pageParam, Integer pageSize, ConnectApi.FeedSortOrder sortParam, Boolean, showInternalOnly, ConnectApi.FeedItemPage result)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- The type of feed. Valid values include every ConnectApi.FeedType except Company and Filter.
- subjectId
- Type: String
- If feedType is Record, subjectId can be any record ID, including a group ID. If feedType is Topics, subjectId must be a topic ID. If feedType is UserProfile, subjectId can be any user ID. If the feedType is any other value, subjectId must be the ID of the context user or the alias me.
- recentCommentCount
- Type: Integer
- The maximum number of comments to return with each feed item. The default value is 3.
- density
- Type: ConnectApi.FeedDensity
- Specify the amount of content in a feed.
- AllUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of.
- FewerUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of, but hides system-generated posts from records that nobody commented on.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- sortParam
- Type: ConnectApi.FeedSortOrder
- Values are:
- CreatedDateDesc—Sorts the feed items by most recent post date.
- LastModifiedDateDesc—Sorts the feed items by most recent activity, which includes new feed items and comments.
- showInternalOnly
- Type: Boolean
- Specifies whether to show only feed items from internal (non-community) users (true), or not (false). The default value is false.
- result
- Type: ConnectApi.FeedItemPage Class
- The object containing test data.
Return Value
Type: Void
setTestGetFeedItemsFromFilterFeed(String, String, String, ConnectApi.FeedItemPage)
API Version
28.0
Signature
public static Void setTestGetFeedItemsFromFilterFeed(String communityId, String subjectId, String keyPrefix, ConnectApi.FeedItemPage result)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- subjectId
- Type: String
- The ID of the context user or the alias me.
- keyPrefix
- Type: String
- A key prefix that specifies record type. A key prefix is the first three characters in the object ID, which specifies the object type. For example, User objects have a prefix of 005 and Group objects have a prefix of 0F9.
- result
- Type: ConnectApi.FeedItemPage Class
- The object containing test data.
Return Value
Type: Void
setTestGetFeedItemsFromFilterFeed(String, String, String, String, Integer, ConnectApi.FeedSortOrder, ConnectApi.FeedItemPage)
API Version
28.0
Signature
public static Void setTestGetFeedItemsFromFilterFeed(String communityId, String subjectId, String keyPrefix, String pageParam, Integer pageSize, ConnectApi.FeedSortOrder sortParam, ConnectApi.FeedItemPage result)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- subjectId
- Type: String
- The ID of the context user or the alias me.
- keyPrefix
- Type: String
- A key prefix that specifies record type. A key prefix is the first three characters in the object ID, which specifies the object type. For example, User objects have a prefix of 005 and Group objects have a prefix of 0F9.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- sortParam
- Type: ConnectApi.FeedSortOrder
- Values are:
- CreatedDateDesc—Sorts the feed items by most recent post date.
- LastModifiedDateDesc—Sorts the feed items by most recent activity, which includes new feed items and comments.
- result
- Type: ConnectApi.FeedItemPage Class
- The object containing test data.
Return Value
Type: Void
setTestGetFeedItemsFromFilterFeed(String, String, String, Integer, ConnectApi.FeedDensity, String, Integer, ConnectApi.FeedSortOrder, ConnectApi.FeedItemPage)
API Version
29.0
Signature
public static Void setTestGetFeedItemsFromFilterFeed(String communityId, String subjectId, String keyPrefix, Integer recentCommentCount, ConnectApi.FeedDensity density, String pageParam, Integer pageSize, ConnectApi.FeedSortOrder sortParam, ConnectApi.FeedItemPage result)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- subjectId
- Type: String
- The ID of the context user or the alias me.
- keyPrefix
- Type: String
- A key prefix that specifies record type. A key prefix is the first three characters in the object ID, which specifies the object type. For example, User objects have a prefix of 005 and Group objects have a prefix of 0F9.
- recentCommentCount
- Type: Integer
- The maximum number of comments to return with each feed item. The default value is 3.
- density
- Type: ConnectApi.FeedDensity
- Specify the amount of content in a feed.
- AllUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of.
- FewerUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of, but hides system-generated posts from records that nobody commented on.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- sortParam
- Type: ConnectApi.FeedSortOrder
- Values are:
- CreatedDateDesc—Sorts the feed items by most recent post date.
- LastModifiedDateDesc—Sorts the feed items by most recent activity, which includes new feed items and comments.
- result
- Type: ConnectApi.FeedItemPage Class
- The object containing test data.
Return Value
Type: Void
setTestGetFeedItemsFromFilterFeedUpdatedSince(String, String, String, Integer, ConnectApi.FeedDensity, String, Integer, String, ConnectApi.FeedItemPage)
API Version
30.0
Signature
public static Void setTestGetFeedItemsFromFilterFeedUpdatedSince(String communityId, String subjectId, String keyPrefix, Integer recentCommentCount, ConnectApi.FeedDensity density, String pageParam, Integer pageSize, ConnectApi.FeedSortOrder sortParam, String updatedSince, ConnectApi.FeedItemPage result)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- subjectId
- Type: String
- The ID of the context user or the alias me.
- keyPrefix
- Type: String
- A key prefix that specifies record type. A key prefix is the first three characters in the object ID, which specifies the object type. For example, User objects have a prefix of 005 and Group objects have a prefix of 0F9.
- recentCommentCount
- Type: Integer
- The maximum number of comments to return with each feed item. The default value is 3.
- density
- Type: ConnectApi.FeedDensity
- Specify the amount of content in a feed.
- AllUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of.
- FewerUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of, but hides system-generated posts from records that nobody commented on.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- sortParam
- Type: ConnectApi.FeedSortOrder
- Values are:
- CreatedDateDesc—Sorts the feed items by most recent post date.
- LastModifiedDateDesc—Sorts the feed items by most recent activity, which includes new feed items and comments.
- updatedSince
- Type: String
- An opaque token containing information about the last modified date of the feed. Do not construct this token. To retrieve this token, call getFeedItemsFromFilterFeed and take the value from the updatesToken property of the ConnectApi.FeedItemPage response body.
- result
- Type: ConnectApi.FeedItemPage Class
- The object containing test data.
Return Value
Type: Void
setTestGetFeedItemsUpdatedSince(String, ConnectApi.FeedType, Integer, ConnectApi.FeedDensity, String, Integer, String, ConnectApi.FeedItemPage)
API Version
30.0
Signature
public static Void setTestGetFeedItemsUpdatedSince(String communityId, ConnectApi.FeedType feedType, Integer recentCommentCount, ConnectApi.FeedDensity density, String pageParam, Integer pageSize, String updatedSince)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- The type of feed. The only valid value is Company.
- recentCommentCount
- Type: Integer
- The maximum number of comments to return with each feed item. The default value is 3.
- density
- Type: ConnectApi.FeedDensity
- Specify the amount of content in a feed.
- AllUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of.
- FewerUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of, but hides system-generated posts from records that nobody commented on.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- updatedSince
- Type: String
- An opaque token containing information about the last modified date of the feed. Do not construct this token. Retrieve this token from the updatesToken property of the ConnectApi.FeedItemPage response body.
- result
- Type: ConnectApi.FeedItemPage Class
- The object containing test data.
Return Value
Type: Void
setTestGetFeedItemsUpdatedSince(String, ConnectApi.FeedType, String, Integer, ConnectApi.FeedDensity, String, Integer, String, ConnectApi.FeedItemPage)
API Version
30.0
Signature
public static Void setTestGetFeedItemsUpdatedSince(String communityId, ConnectApi.FeedType feedType, String subjectId, Integer recentCommentCount, ConnectApi.FeedDensity density, String pageParam, Integer pageSize, String updatedSince, ConnectApi.FeedItemPage result)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- One of these values:
- Files
- Groups
- News
- People
- Record
- subjectId
- Type: String
- If feedType is ConnectApi.Record, subjectId can be any record ID, including a group ID. Otherwise, it must be the context user or the alias me.
- recentCommentCount
- Type: Integer
- The maximum number of comments to return with each feed item. The default value is 3.
- density
- Type: ConnectApi.FeedDensity
- Specify the amount of content in a feed.
- AllUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of.
- FewerUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of, but hides system-generated posts from records that nobody commented on.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- updatedSince
- Type: String
- An opaque token containing information about the last modified date of the feed. Do not construct this token. Retrieve this token from the updatesToken property of the ConnectApi.FeedItemPage response body.
- result
- Type: ConnectApi.FeedItemPage Class
- The object containing test data.
Return Value
Type: Void
setTestGetFeedItemsUpdatedSince(String, ConnectApi.FeedType, String, Integer, ConnectApi.FeedDensity, String, Integer, String, Boolean, ConnectApi.FeedItemPage)
API Version
30.0
Signature
public static Void setTestGetFeedItemsUpdatedSince(String communityId, ConnectApi.FeedType feedType, String subjectId, Integer recentCommentCount, ConnectApi.FeedDensity density, String pageParam, Integer pageSize, String updatedSince, Boolean, showInternalOnly, ConnectApi.FeedItemPage result)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- One of these values:
- Files
- Groups
- News
- People
- Record
- subjectId
- Type: String
- If feedType is ConnectApi.Record, subjectId can be any record ID, including a group ID. Otherwise, it must be the context user or the alias me.
- recentCommentCount
- Type: Integer
- The maximum number of comments to return with each feed item. The default value is 3.
- density
- Type: ConnectApi.FeedDensity
- Specify the amount of content in a feed.
- AllUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of.
- FewerUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of, but hides system-generated posts from records that nobody commented on.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- updatedSince
- Type: String
- An opaque token containing information about the last modified date of the feed. Do not construct this token. Retrieve this token from the updatesToken property of the ConnectApi.FeedItemPage response body.
- showInternalOnly
- Type: Boolean
- Specifies whether to show only feed items from internal (non-community) users (true), or not (false). The default value is false.
- result
- Type: ConnectApi.FeedItemPage Class
- The object containing test data.
Return Value
Type: Void
setTestSearchFeedItems(String, String, ConnectApi.FeedItemPage)
API Version
28.0
Signature
public static Void searchFeedItems(String communityId, String q, ConnectApi.FeedItemPage result)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- q
- Type: String
- Required and cannot be null. Specifies the string to search. The search string must contain at least two characters, not including wildcards. See Wildcards.
- result
- Type: ConnectApi.FeedItemPage
- The object containing test data.
Return Value
Type: Void
setTestSearchFeedItems(String, String, ConnectApi.FeedSortOrder, ConnectApi.FeedItemPage)
API Version
28.0
Signature
public static Void setTestSearchFeedItems(String communityId, String q, ConnectApi.FeedSortOrder sortParam, ConnectApi.FeedItemPage result)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- q
- Type: String
- Required and cannot be null. Specifies the string to search. The search string must contain at least two characters, not including wildcards. See Wildcards.
- sortParam
- Type: ConnectApi.FeedSortOrder
- Values are:
- CreatedDateDesc—Sorts the feed items by most recent post date.
- LastModifiedDateDesc—Sorts the feed items by most recent activity, which includes new feed items and comments.
- result
- Type: ConnectApi.FeedItemPage
- The feed item test page.
Return Value
Type: Void
setTestSearchFeedItems(String, String, String, Integer, ConnectApi.FeedItemPage)
API Version
28.0
Signature
public static Void setTestSearchFeedItems(String communityId, String q, String pageParam, Integer pageSize, ConnectApi.FeedItemPage result)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- q
- Type: String
- Required and cannot be null. Specifies the string to search. The search string must contain at least two characters, not including wildcards. See Wildcards.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- result
- Type: ConnectApi.FeedItemPage Class
- The test feed item page.
Return Value
Type: Void
setTestSearchFeedItems(String, String, String, Integer, ConnectApi.FeedSortOrder, ConnectApi.FeedItemPage)
API Version
28.0
Signature
public static Void setTestSearchFeedItems(String communityId, String q, String pageParam, Integer pageSize, ConnectApi.FeedSortOrder sortParam, ConnectApi.FeedItemPage result)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- q
- Type: String
- Required and cannot be null. Specifies the string to search. The search string must contain at least two characters, not including wildcards. See Wildcards.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- sortParam
- Type: ConnectApi.FeedSortOrder
- Values are:
- CreatedDateDesc—Sorts the feed items by most recent post date.
- LastModifiedDateDesc—Sorts the feed items by most recent activity, which includes new feed items and comments.
- result
- Type: ConnectApi.FeedItemPage
- The test feed item page.
Return Value
Type: Void
setTestSearchFeedItems(String, String, Integer, String, Integer, ConnectApi.FeedSortOrder, ConnectApi.FeedItemPage)
API Version
29.0
Signature
public static Void setTestSearchFeedItems(String communityId, String q, Integer recentCommentCount, String pageParam, Integer pageSize, ConnectApi.FeedSortOrder sortParam, ConnectApi.FeedItemPage result)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- q
- Type: String
- Required and cannot be null. Specifies the string to search. The search string must contain at least two characters, not including wildcards. See Wildcards.
- recentCommentCount
- Type: Integer
- The maximum number of comments to return with each feed item. The default value is 3.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- sortParam
- Type: ConnectApi.FeedSortOrder
- Values are:
- CreatedDateDesc—Sorts the feed items by most recent post date.
- LastModifiedDateDesc—Sorts the feed items by most recent activity, which includes new feed items and comments.
- result
- Type: ConnectApi.FeedItemPage
- The test feed item page.
Return Value
Type: Void
setTestSearchFeedItemsInFeed(String, ConnectApi.FeedType, String, ConnectApi.FeedItemPage)
API Version
28.0
Signature
public static Void setTestSearchFeedItemsInFeed(String communityId, ConnectApi.FeedType feedType, String q, ConnectApi.FeedItemPage result)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- The type of feed. The only valid value is Company.
- q
- Type: String
- Required and cannot be null. Specifies the string to search. The search string must contain at least two characters, not including wildcards. See Wildcards.
- result
- Type: ConnectApi.FeedItemPage Class
- The object containing test data.
Return Value
Type: Void
setTestSearchFeedItemsInFeed(String, ConnectApi.FeedType, String, Integer, ConnectApi.FeedSortOrder, String, ConnectApi.FeedItemPage)
API Version
28.0
Signature
public static Void setTestSearchFeedItemsInFeed(String communityId, ConnectApi.FeedType feedType, String pageParam, Integer pageSize, ConnectApi.FeedSortOrder sortParam, String q, ConnectApi.FeedItemPage result)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- The type of feed. Valid values include every ConnectApi.FeedType except Company and Filter.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- sortParam
- Type: ConnectApi.FeedSortOrder
- Values are:
- CreatedDateDesc—Sorts the feed items by most recent post date.
- LastModifiedDateDesc—Sorts the feed items by most recent activity, which includes new feed items and comments.
- q
- Type: String
- Required and cannot be null. Specifies the string to search. The search string must contain at least two characters, not including wildcards. See Wildcards.
- result
- Type: ConnectApi.FeedItemPage Class
- The object containing test data.
Return Value
Type: Void
setTestSearchFeedItemsInFeed(String, ConnectApi.FeedType, Integer, ConnectApi.FeedDensity, String, Integer, ConnectApi.FeedSortOrder, String, ConnectApi.FeedItemPage)
API Version
29.0
Signature
public static Void setTestSearchFeedItemsInFeed(String communityId, ConnectApi.FeedType feedType, Integer recentCommentCount, ConnectApi.FeedDensity density, String pageParam, Integer pageSize, ConnectApi.FeedSortOrder sortParam, String q, ConnectApi.FeedItemPage result)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- The type of feed. Valid values include every ConnectApi.FeedType except Company and Filter.
- recentCommentCount
- Type: Integer
- The maximum number of comments to return with each feed item. The default value is 3.
- density
- Type: ConnectApi.FeedDensity
- Specify the amount of content in a feed.
- AllUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of.
- FewerUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of, but hides system-generated posts from records that nobody commented on.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- sortParam
- Type: ConnectApi.FeedSortOrder
- Values are:
- CreatedDateDesc—Sorts the feed items by most recent post date.
- LastModifiedDateDesc—Sorts the feed items by most recent activity, which includes new feed items and comments.
- q
- Type: String
- Required and cannot be null. Specifies the string to search. The search string must contain at least two characters, not including wildcards. See Wildcards.
- result
- Type: ConnectApi.FeedItemPage Class
- The object containing test data.
Return Value
Type: Void
setTestSearchFeedItemsInFeed(String, ConnectApi.FeedType, String, String, ConnectApi.FeedItemPage)
API Version
28.0
Signature
public static Void setTestSearchFeedItemsInFeed(String communityId, ConnectApi.FeedType feedType, String subjectId, String q, ConnectApi.FeedItemPage result)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- The type of the feed. Valid values include every ConnectApi.FeedType except Company, Filter, and Topics.
- subjectId
- Type: String
- If feedType is Record, subjectId can be any record ID, including a group ID. If feedType is UserProfile, subjectId can be any user ID. If feedType is any other value, subjectId must be the ID of the context user or the alias me.
- q
- Type: String
- Required and cannot be null. Specifies the string to search. The search string must contain at least two characters, not including wildcards. See Wildcards.
- result
- Type: ConnectApi.FeedItemPage Class
- The object containing test data.
Return Value
Type: Void
setTestSearchFeedItemsInFeed(String, ConnectApi.FeedType, String, String, Integer, ConnectApi.FeedSortOrder, String, ConnectApi.FeedItemPage)
API Version
28.0
Signature
public static Void setTestSearchFeedItemsInFeed(String communityId, ConnectApi.FeedType feedType, String subjectId, String pageParam, Integer pageSize, ConnectApi.FeedSortOrder sortParam, String q, ConnectApi.FeedItemPage result)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- The type of the feed. Valid values include every ConnectApi.FeedType except Company, Filter, and Topics.
- subjectId
- Type: String
- If feedType is Record, subjectId can be any record ID, including a group ID. If feedType is UserProfile, subjectId can be any user ID. If feedType is any other value, subjectId must be the ID of the context user or the alias me.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- sortParam
- Type: ConnectApi.FeedSortOrder
- Values are:
- CreatedDateDesc—Sorts the feed items by most recent post date.
- LastModifiedDateDesc—Sorts the feed items by most recent activity, which includes new feed items and comments.
- q
- Type: String
- Required and cannot be null. Specifies the string to search. The search string must contain at least two characters, not including wildcards. See Wildcards.
- result
- Type: ConnectApi.FeedItemPage Class
- The object containing test data.
Return Value
Type: Void
setTestSearchFeedItemsInFeed(String, ConnectApi.FeedType, String, Integer, ConnectApi.FeedDensity, String, Integer, ConnectApi.FeedSortOrder, String, ConnectApi.FeedItemPage)
API Version
29.0
Signature
public static Void setTestSearchFeedItemsInFeed(String communityId, ConnectApi.FeedType feedType, String subjectId, Integer recentCommentCount, ConnectApi.FeedDensity density, String pageParam, Integer pageSize, ConnectApi.FeedSortOrder sortParam, String q, ConnectApi.FeedItemPage result)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- The type of the feed. Valid values include every ConnectApi.FeedType except Company, Filter, and Topics.
- subjectId
- Type: String
- If feedType is Record, subjectId can be any record ID, including a group ID. If feedType is UserProfile, subjectId can be any user ID. If feedType is any other value, subjectId must be the ID of the context user or the alias me.
- recentCommentCount
- Type: Integer
- The maximum number of comments to return with each feed item. The default value is 3.
- density
- Type: ConnectApi.FeedDensity
- Specify the amount of content in a feed.
- AllUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of.
- FewerUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of, but hides system-generated posts from records that nobody commented on.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- sortParam
- Type: ConnectApi.FeedSortOrder
- Values are:
- CreatedDateDesc—Sorts the feed items by most recent post date.
- LastModifiedDateDesc—Sorts the feed items by most recent activity, which includes new feed items and comments.
- q
- Type: String
- Required and cannot be null. Specifies the string to search. The search string must contain at least two characters, not including wildcards. See Wildcards.
- result
- Type: ConnectApi.FeedItemPage Class
- The object containing test data.
Return Value
Type: Void
setTestSearchFeedItemsInFeed(String, ConnectApi.FeedType, String, Integer, ConnectApi.FeedDensity, String, Integer, ConnectApi.FeedSortOrder, String, Boolean, ConnectApi.FeedItemPage)
API Version
29.0
Signature
public static Void setTestSearchFeedItemsInFeed(String communityId, ConnectApi.FeedType feedType, String subjectId, Integer recentCommentCount, ConnectApi.FeedDensity density, String pageParam, Integer pageSize, ConnectApi.FeedSortOrder sortParam, String q, ConnectApi.FeedItemPage result)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- The type of the feed. Valid values include every ConnectApi.FeedType except Company, Filter, and Topics.
- subjectId
- Type: String
- If feedType is Record, subjectId can be any record ID, including a group ID. If feedType is UserProfile, subjectId can be any user ID. If feedType is any other value, subjectId must be the ID of the context user or the alias me.
- recentCommentCount
- Type: Integer
- The maximum number of comments to return with each feed item. The default value is 3.
- density
- Type: ConnectApi.FeedDensity
- Specify the amount of content in a feed.
- AllUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of.
- FewerUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of, but hides system-generated posts from records that nobody commented on.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- sortParam
- Type: ConnectApi.FeedSortOrder
- Values are:
- CreatedDateDesc—Sorts the feed items by most recent post date.
- LastModifiedDateDesc—Sorts the feed items by most recent activity, which includes new feed items and comments.
- q
- Type: String
- Required and cannot be null. Specifies the string to search. The search string must contain at least two characters, not including wildcards. See Wildcards.
- showInternalOnly
- Type: Boolean
- Specifies whether to show only feed items from internal (non-community) users (true), or not (false). The default value is false.
- result
- Type: ConnectApi.FeedItemPage Class
- The object containing test data.
Return Value
Type: Void
setTestSearchFeedItemsInFilterFeed(String, String, String, String, ConnectApi.FeedItemPage)
API Version
28.0
Signature
public static Void setTestSearchFeedItemsInFilterFeed(String communityId, String subjectId, String keyPrefix, String q, ConnectApi.FeedItemPage result)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- subjectId
- Type: String
- The ID of the context user or the alias me.
- keyPrefix
- Type: String
- A key prefix that specifies record type. A key prefix is the first three characters in the object ID, which specifies the object type. For example, User objects have a prefix of 005 and Group objects have a prefix of 0F9.
- q
- Type: String
- Required and cannot be null. Specifies the string to search. The search string must contain at least two characters, not including wildcards. See Wildcards.
- result
- Type: ConnectApi.FeedItemPage Class
- Specify the test feed item page.
Return Value
Type: Void
setTestSearchFeedItemsInFilterFeed(String, ConnectApi.FeedType, String, String, String, Integer, ConnectApi.FeedSortOrder, String, ConnectApi.FeedItemPage)
API Version
28.0
Signature
public static Void setTestSearchFeedItemsInFilterFeed(String communityId, ConnectApi.FeedType feedType, String subjectId, String keyPrefix, String pageParam, Integer pageSize, ConnectApi.FeedSortOrder sortParam, String q, ConnectApi.FeedItemPage result)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- The type of feed. Valid values include every ConnectApi.FeedType except Company and Filter.
- subjectId
- Type: String
- The ID of the context user or the alias me.
- keyPrefix
- Type: String
- A key prefix that specifies record type. A key prefix is the first three characters in the object ID, which specifies the object type. For example, User objects have a prefix of 005 and Group objects have a prefix of 0F9.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- sortParam
- Type: ConnectApi.FeedSortOrder
- Values are:
- CreatedDateDesc—Sorts the feed items by most recent post date.
- LastModifiedDateDesc—Sorts the feed items by most recent activity, which includes new feed items and comments.
- q
- Type: String
- Required and cannot be null. Specifies the string to search. The search string must contain at least two characters, not including wildcards. See Wildcards.
- result
- Type: ConnectApi.FeedItemPage Class
- Specify the test feed item page.
Return Value
Type: Void
setTestSearchFeedItemsInFilterFeed(String, ConnectApi.FeedType, String, String, Integer, ConnectApi.FeedDensity, String, Integer, ConnectApi.FeedSortOrder, String, ConnectApi.FeedItemPage)
API Version
29.0
Signature
public static Void setTestSearchFeedItemsInFilterFeed(String communityId, ConnectApi.FeedType feedType, String subjectId, String keyPrefix, Integer recentCommentCount, ConnectApi.FeedDensity density, String pageParam, Integer pageSize, ConnectApi.FeedSortOrder sortParam, String q, ConnectApi.FeedItemPage result)
Parameters
- communityId
- Type: String
- Use either the ID for a community, internal, or null.
- feedType
- Type: ConnectApi.FeedType
- The type of feed. Valid values include every ConnectApi.FeedType except Company and Filter.
- subjectId
- Type: String
- The ID of the context user or the alias me.
- keyPrefix
- Type: String
- A key prefix that specifies record type. A key prefix is the first three characters in the object ID, which specifies the object type. For example, User objects have a prefix of 005 and Group objects have a prefix of 0F9.
- recentCommentCount
- Type: Integer
- The maximum number of comments to return with each feed item. The default value is 3.
- density
- Type: ConnectApi.FeedDensity
- Specify the amount of content in a feed.
- AllUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of.
- FewerUpdates—Displays all posts and comments from people and records the user follows and groups the user is a member of, but hides system-generated posts from records that nobody commented on.
- pageParam
- Type: String
- The page token to use to view the page. Page tokens are returned as part of the response class, for example, currentPageToken or nextPageToken. If you pass in null the first page is returned.
- pageSize
- Type: Integer
- Specifies the number of items per page. Valid values are between 1 and 100. If you pass in null, the default size is 25.
- sortParam
- Type: ConnectApi.FeedSortOrder
- Values are:
- CreatedDateDesc—Sorts the feed items by most recent post date.
- LastModifiedDateDesc—Sorts the feed items by most recent activity, which includes new feed items and comments.
- q
- Type: String
- Required and cannot be null. Specifies the string to search. The search string must contain at least two characters, not including wildcards. See Wildcards.
- result
- Type: ConnectApi.FeedItemPage Class
- Specify the test feed item page.
Return Value
Type: Void
updateBookmark(String, String, Boolean)
API Version
28.0
Signature
public static ConnectApi.FeedItem updateBookmark(String communityId, String feedItemId, Boolean isBookmarkedByCurrentUser)