Appearance
Feeds
About 28230 wordsAbout 94 min
Java SDK - Feeds API
Table of Contents
- addActivity
- upsertActivities
- updateActivitiesPartialBatch
- deleteActivities
- trackActivityMetrics
- queryActivities
- addBookmark
- updateBookmark
- deleteBookmark
- activityFeedback
- castPollVote
- deletePollVote
- addActivityReaction
- queryActivityReactions
- deleteActivityReaction
- getActivity
- updateActivity
- updateActivityPartial
- deleteActivity
- restoreActivity
- queryBookmarkFolders
- updateBookmarkFolder
- deleteBookmarkFolder
- queryBookmarks
- readCollections
- createCollections
- upsertCollections
- updateCollections
- deleteCollections
- queryCollections
- getComments
- addComment
- addCommentsBatch
- queryComments
- addCommentBookmark
- updateCommentBookmark
- deleteCommentBookmark
- getComment
- updateComment
- deleteComment
- updateCommentPartial
- addCommentReaction
- queryCommentReactions
- deleteCommentReaction
- getCommentReplies
- restoreComment
- listFeedGroups
- createFeedGroup
- getOrCreateFeed
- updateFeed
- deleteFeed
- markActivity
- pinActivity
- unpinActivity
- updateFeedMembers
- acceptFeedMemberInvite
- queryFeedMembers
- rejectFeedMemberInvite
- queryPinnedActivities
- getFollowSuggestions
- restoreFeedGroup
- getFeedGroup
- getOrCreateFeedGroup
- updateFeedGroup
- deleteFeedGroup
- listFeedViews
- createFeedView
- getFeedView
- getOrCreateFeedView
- updateFeedView
- deleteFeedView
- listFeedVisibilities
- getFeedVisibility
- updateFeedVisibility
- createFeedsBatch
- deleteFeedsBatch
- ownBatch
- queryFeeds
- getFeedsRateLimits
- follow
- updateFollow
- acceptFollow
- followBatch
- getOrCreateFollows
- queryFollows
- rejectFollow
- unfollow
- createMembershipLevel
- queryMembershipLevels
- updateMembershipLevel
- deleteMembershipLevel
- queryFeedsUsageStats
- unfollowBatch
- getOrCreateUnfollows
- deleteFeedUserData
- exportFeedUserData
- Types Reference
addActivity
Add a single activity to a feed, allowing users to share updates or events. Use this when you want to introduce new content to a feed.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Add a single activity
var response = feedsClient.addActivity(
new AddActivityRequest()
.setFeeds(List.of("user:john", "timeline:global"))
.setType("like")
.setUserID("john")
.setID("activity-123")
).execute();
System.out.println(response);
}
}Example: with text and skip_push
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Add a single activity
var response = feedsClient.addActivity(
new AddActivityRequest()
.setFeeds(List.of("user:john", "timeline:global"))
.setType("like")
.setText("Hello, world!")
.setSkipPush(false)
).execute();
System.out.println(response);
}
}Example: with visibility and enrich_own_fields
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Add a single activity
var response = feedsClient.addActivity(
new AddActivityRequest()
.setFeeds(List.of("user:john", "timeline:global"))
.setType("like")
.setVisibility("public")
.setEnrichOwnFields(false)
).execute();
System.out.println(response);
}
}Example: with expires_at and filter_tags
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Add a single activity
var response = feedsClient.addActivity(
new AddActivityRequest()
.setFeeds(List.of("user:john", "timeline:global"))
.setType("like")
.setExpiresAt("value")
.setFilterTags(List.of("tag1", "tag2"))
).execute();
System.out.println(response);
}
}Response: AddActivityResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| feeds | []string | Yes | List of feeds to add the activity to with a default max limit of 25 feeds |
| type | String | Yes | Type of activity |
| attachments | []Attachment | No | List of attachments for the activity |
| collection_refs | []string | No | Collections that this activity references |
| copy_custom_to_notification | Boolean | No | Whether to copy custom data to the notification activity (only applies when create_notification_a... |
| create_notification_activity | Boolean | No | Whether to create notification activities for mentioned users |
| custom | Map<String, Object> | No | Custom data for the activity |
| enrich_own_fields | Boolean | No | - |
| expires_at | String | No | Expiration time for the activity |
| filter_tags | []string | No | Tags for filtering activities |
| force_moderation | Boolean | No | - |
| id | String | No | Optional ID for the activity |
| interest_tags | []string | No | Tags for indicating user interests |
| location | Location | No | Geographic location related to the activity |
| mentioned_user_ids | []string | No | List of users mentioned in the activity |
| parent_id | String | No | ID of parent activity for replies/comments |
| poll_id | String | No | ID of a poll to attach to activity |
| restrict_replies | String | No | Controls who can add comments/replies to this activity. One of: everyone, people_i_follow, nobody |
| search_data | Map<String, Object> | No | Additional data for search indexing |
| skip_enrich_url | Boolean | No | Whether to skip URL enrichment for the activity |
| skip_push | Boolean | No | Whether to skip push notifications |
| text | String | No | Text content of the activity |
| user_id | String | No | ID of the user creating the activity |
| visibility | String | No | Visibility setting for the activity. One of: public, private, tag |
| visibility_tag | String | No | If visibility is 'tag', this is the tag name and is required |
upsertActivities
Add or update multiple activities in a batch, optimizing feed management by ensuring activities are current and efficiently handled. Use this for bulk operations where activities might need to be created or modified.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Upsert multiple activities
var response = feedsClient.upsertActivities(
new UpsertActivitiesRequest()
.setActivities(List.of())
.setEnrichOwnFields(false)
.setForceModeration(false)
).execute();
System.out.println(response);
}
}Response: UpsertActivitiesResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| activities | []ActivityRequest | Yes | List of activities to create or update |
| enrich_own_fields | Boolean | No | If true, enriches the activities' current_feed with own_* fields (own_follows, own_followings, ow... |
| force_moderation | Boolean | No | If true, forces moderation to run for server-side requests. By default, server-side requests skip... |
updateActivitiesPartialBatch
Use this method to update specific fields of multiple activities in bulk without overwriting the entire activity data, ideal for making incremental changes efficiently.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Batch partial activity update
var response = feedsClient.updateActivitiesPartialBatch(
new UpdateActivitiesPartialBatchRequest()
.setChanges(List.of())
.setForceModeration(false)
).execute();
System.out.println(response);
}
}Response: UpdateActivitiesPartialBatchResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| changes | []UpdateActivityPartialChangeRequest | Yes | List of activity changes to apply. Each change specifies an activity ID and the fields to set/unset |
| force_moderation | Boolean | No | If true, forces moderation to run for server-side requests. By default, server-side requests skip... |
deleteActivities
Remove multiple activities from a feed to keep it relevant and tidy. Use this when you need to clear outdated or unwanted content from a feed.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Remove multiple activities
var response = feedsClient.deleteActivities(
new DeleteActivitiesRequest()
.setIds(List.of("activity-1", "activity-2"))
.setUserID("john")
.setHardDelete(false)
).execute();
System.out.println(response);
}
}Example: with user and delete_notification_activity
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Remove multiple activities
var response = feedsClient.deleteActivities(
new DeleteActivitiesRequest()
.setIds(List.of("activity-1", "activity-2"))
.setUser(new UserRequest().setID("activity-123").setCustom(Map.of()))
.setDeleteNotificationActivity(false)
).execute();
System.out.println(response);
}
}Response: DeleteActivitiesResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| ids | []string | Yes | List of activity IDs to delete |
| delete_notification_activity | Boolean | No | Whether to also delete any notification activities created from mentions in these activities |
| hard_delete | Boolean | No | Whether to permanently delete the activities |
| user | UserRequest | No | - |
| user_id | String | No | - |
trackActivityMetrics
Monitors and records user interactions with activities, providing insights into user engagement and behavior. Use this to analyze activity trends and optimize content strategy.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Track activity metrics
var response = feedsClient.trackActivityMetrics(
new TrackActivityMetricsRequest()
.setEvents(List.of())
.setUserID("john")
.setUser(new UserRequest().setID("activity-123").setCustom(Map.of()))
).execute();
System.out.println(response);
}
}Response: TrackActivityMetricsResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| events | []TrackActivityMetricsEvent | Yes | List of metric events to track (max 100 per request) |
| user | UserRequest | No | - |
| user_id | String | No | - |
queryActivities
Retrieve a list of activities based on specific criteria, enabling users to access relevant content quickly. Use this to filter and display activities that match certain conditions.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Query activities
var response = feedsClient.queryActivities(
new QueryActivitiesRequest()
.setUserID("john")
.setLimit(25)
.setFilter(Map.of())
).execute();
System.out.println(response);
}
}Example: with sort and include_soft_deleted_activities
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Query activities
var response = feedsClient.queryActivities(
new QueryActivitiesRequest()
.setSort(List.of())
.setIncludeSoftDeletedActivities(false)
).execute();
System.out.println(response);
}
}Example: with enrich_own_fields and next
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Query activities
var response = feedsClient.queryActivities(
new QueryActivitiesRequest()
.setEnrichOwnFields(false)
.setNext(null)
).execute();
System.out.println(response);
}
}Example: with prev and include_expired_activities
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Query activities
var response = feedsClient.queryActivities(
new QueryActivitiesRequest()
.setPrev(null)
.setIncludeExpiredActivities(false)
).execute();
System.out.println(response);
}
}Response: QueryActivitiesResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| enrich_own_fields | Boolean | No | - |
| filter | Map<String, Object> | No | Filters to apply to the query. Supports location-based queries with 'near' and 'within_bounds' op... |
| include_expired_activities | Boolean | No | When true, include both expired and non-expired activities in the result. |
| include_private_activities | Boolean | No | - |
| include_soft_deleted_activities | Boolean | No | When true, include soft-deleted activities in the result. |
| limit | Integer | No | - |
| next | String | No | - |
| prev | String | No | - |
| sort | []SortParamRequest | No | Sorting parameters for the query |
| user | UserRequest | No | - |
| user_id | String | No | - |
addBookmark
Save a specific item or activity for easy retrieval later, enhancing user experience by allowing quick access to important content. Use this to enable users to mark favorites or important items.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Add bookmark
var response = feedsClient.addBookmark(
"activity-123",
new AddBookmarkRequest()
.setUserID("john")
.setFolderID("folder-123")
).execute();
System.out.println(response);
}
}Example: with new_folder and user
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Add bookmark
var response = feedsClient.addBookmark(
"activity-123",
new AddBookmarkRequest()
.setNewFolder(new AddFolderRequest().setName("My Feed").setCustom(Map.of()))
.setUser(new UserRequest().setID("activity-123").setCustom(Map.of()))
).execute();
System.out.println(response);
}
}Example: with custom
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Add bookmark
var response = feedsClient.addBookmark(
"activity-123",
new AddBookmarkRequest()
.setCustom(Map.of())
).execute();
System.out.println(response);
}
}Response: AddBookmarkResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| activity_id | String | Yes | - |
| custom | Map<String, Object> | No | Custom data for the bookmark |
| folder_id | String | No | ID of the folder to add the bookmark to |
| new_folder | AddFolderRequest | No | Create a new folder for this bookmark |
| user | UserRequest | No | - |
| user_id | String | No | - |
updateBookmark
Modify the details of an existing bookmark to keep saved content accurate and useful. Use this when there is a need to change the information associated with a bookmark.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Update bookmark
var response = feedsClient.updateBookmark(
"activity-123",
new UpdateBookmarkRequest()
.setUserID("john")
.setFolderID("folder-123")
).execute();
System.out.println(response);
}
}Example: with new_folder and new_folder_id
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Update bookmark
var response = feedsClient.updateBookmark(
"activity-123",
new UpdateBookmarkRequest()
.setNewFolder(new AddFolderRequest().setName("My Feed").setCustom(Map.of()))
.setNewFolderID("value")
).execute();
System.out.println(response);
}
}Example: with user and custom
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Update bookmark
var response = feedsClient.updateBookmark(
"activity-123",
new UpdateBookmarkRequest()
.setUser(new UserRequest().setID("activity-123").setCustom(Map.of()))
.setCustom(Map.of())
).execute();
System.out.println(response);
}
}Response: UpdateBookmarkResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| activity_id | String | Yes | - |
| custom | Map<String, Object> | No | Custom data for the bookmark |
| folder_id | String | No | ID of the folder containing the bookmark |
| new_folder | AddFolderRequest | No | Create a new folder and move the bookmark into it |
| new_folder_id | String | No | Move the bookmark to this folder (empty string removes the folder) |
| user | UserRequest | No | - |
| user_id | String | No | - |
deleteBookmark
Remove a bookmark from the saved list to declutter a user's stored items. Use this when a bookmarked item is no longer needed or relevant.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Delete a bookmark
var response = feedsClient.deleteBookmark(
"activity-123",
new DeleteBookmarkRequest()
.setUserID("john")
.setFolderID("folder-123")
).execute();
System.out.println(response);
}
}Response: DeleteBookmarkResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| activity_id | String | Yes | - |
| folder_id | String | No | - |
| user_id | String | No | - |
activityFeedback
Submit user feedback on an activity to enhance personalization and content relevance. Use this to gather user preferences and improve content recommendations.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Provide feedback on an activity
var response = feedsClient.activityFeedback(
"activity-123",
new ActivityFeedbackRequest()
.setUserID("john")
.setShowLess(false)
).execute();
System.out.println(response);
}
}Example: with show_more and user
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Provide feedback on an activity
var response = feedsClient.activityFeedback(
"activity-123",
new ActivityFeedbackRequest()
.setShowMore(false)
.setUser(new UserRequest().setID("activity-123").setCustom(Map.of()))
).execute();
System.out.println(response);
}
}Example: with hide
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Provide feedback on an activity
var response = feedsClient.activityFeedback(
"activity-123",
new ActivityFeedbackRequest()
.setHide(false)
).execute();
System.out.println(response);
}
}Response: ActivityFeedbackResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| activity_id | String | Yes | - |
| hide | Boolean | No | Whether to hide this activity |
| show_less | Boolean | No | Whether to show less content like this |
| show_more | Boolean | No | Whether to show more content like this |
| user | UserRequest | No | - |
| user_id | String | No | - |
castPollVote
Register a user’s vote in a poll, contributing to collective decision-making or opinion-sharing. Use this to capture user opinions in polls.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Cast vote
var response = feedsClient.castPollVote(
"activity-123",
"poll-123",
new CastPollVoteRequest()
.setUserID("john")
.setUser(new UserRequest().setID("activity-123").setCustom(Map.of()))
).execute();
System.out.println(response);
}
}Example: with vote
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Cast vote
var response = feedsClient.castPollVote(
"activity-123",
"poll-123",
new CastPollVoteRequest()
.setVote(new VoteData().setAnswerText("value"))
).execute();
System.out.println(response);
}
}Response: PollVoteResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| activity_id | String | Yes | - |
| poll_id | String | Yes | - |
| user | UserRequest | No | - |
| user_id | String | No | - |
| vote | VoteData | No | Vote data |
deletePollVote
Remove a user's vote from a poll, allowing for changes in decision or corrections. Use this when a user needs to retract or alter their vote in a poll.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Delete vote
var response = feedsClient.deletePollVote(
"activity-123",
"poll-123",
"vote-123",
new DeletePollVoteRequest()
.setUserID("john")
).execute();
System.out.println(response);
}
}Response: PollVoteResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| activity_id | String | Yes | - |
| poll_id | String | Yes | - |
| vote_id | String | Yes | - |
| user_id | String | No | - |
addActivityReaction
Add a reaction to a specified activity to engage users and track interactions. Use this method to express preferences or sentiments towards an activity.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Add reaction
var response = feedsClient.addActivityReaction(
"activity-123",
new AddActivityReactionRequest()
.setType("like")
.setUserID("john")
.setSkipPush(false)
).execute();
System.out.println(response);
}
}Example: with custom and enforce_unique
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Add reaction
var response = feedsClient.addActivityReaction(
"activity-123",
new AddActivityReactionRequest()
.setType("like")
.setCustom(Map.of())
.setEnforceUnique(true)
).execute();
System.out.println(response);
}
}Example: with copy_custom_to_notification and user
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Add reaction
var response = feedsClient.addActivityReaction(
"activity-123",
new AddActivityReactionRequest()
.setType("like")
.setCopyCustomToNotification(false)
.setUser(new UserRequest().setID("activity-123").setCustom(Map.of()))
).execute();
System.out.println(response);
}
}Example: with create_notification_activity
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Add reaction
var response = feedsClient.addActivityReaction(
"activity-123",
new AddActivityReactionRequest()
.setType("like")
.setCreateNotificationActivity(false)
).execute();
System.out.println(response);
}
}Response: AddReactionResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| activity_id | String | Yes | - |
| type | String | Yes | Type of reaction |
| copy_custom_to_notification | Boolean | No | Whether to copy custom data to the notification activity (only applies when create_notification_a... |
| create_notification_activity | Boolean | No | Whether to create a notification activity for this reaction |
| custom | Map<String, Object> | No | Custom data for the reaction |
| enforce_unique | Boolean | No | Whether to enforce unique reactions per user (remove other reaction types from the user when addi... |
| skip_push | Boolean | No | - |
| user | UserRequest | No | - |
| user_id | String | No | - |
queryActivityReactions
Retrieve a list of reactions associated with a specific activity to analyze user engagement and response patterns. Use this to gain insights into activity interactions.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Query activity reactions
var response = feedsClient.queryActivityReactions(
"activity-123",
new QueryActivityReactionsRequest()
.setLimit(25)
.setFilter(Map.of())
).execute();
System.out.println(response);
}
}Example: with sort and prev
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Query activity reactions
var response = feedsClient.queryActivityReactions(
"activity-123",
new QueryActivityReactionsRequest()
.setSort(List.of())
.setPrev(null)
).execute();
System.out.println(response);
}
}Example: with next
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Query activity reactions
var response = feedsClient.queryActivityReactions(
"activity-123",
new QueryActivityReactionsRequest()
.setNext(null)
).execute();
System.out.println(response);
}
}Response: QueryActivityReactionsResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| activity_id | String | Yes | - |
| filter | Map<String, Object> | No | - |
| limit | Integer | No | - |
| next | String | No | - |
| prev | String | No | - |
| sort | []SortParamRequest | No | - |
deleteActivityReaction
Remove a reaction from an activity to update user feedback or correct erroneous inputs. Use this when a reaction needs to be retracted or modified.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Remove reaction
var response = feedsClient.deleteActivityReaction(
"activity-123",
"like",
new DeleteActivityReactionRequest()
.setUserID("john")
.setDeleteNotificationActivity(false)
).execute();
System.out.println(response);
}
}Response: DeleteActivityReactionResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| activity_id | String | Yes | - |
| type | String | Yes | - |
| delete_notification_activity | Boolean | No | - |
| user_id | String | No | - |
getActivity
Fetch details of a specific activity to view or display the current state and content. Use this to retrieve complete information about an activity for further processing or display.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Get activity
var response = feedsClient.getActivity(
"activity-123",
new GetActivityRequest()
.setUserID("john")
.setCommentLimit(10)
).execute();
System.out.println(response);
}
}Example: with comment_sort
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Get activity
var response = feedsClient.getActivity(
"activity-123",
new GetActivityRequest()
.setCommentSort("value")
).execute();
System.out.println(response);
}
}Response: GetActivityResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| id | String | Yes | - |
| comment_sort | String | No | - |
| comment_limit | Integer | No | - |
| user_id | String | No | - |
updateActivity
Replace all information of a specific activity to reflect new content or corrections. Use this when a full update of the activity's data is necessary.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Full activity update
var response = feedsClient.updateActivity(
"activity-123",
new UpdateActivityRequest()
.setUserID("john")
.setText("Hello, world!")
).execute();
System.out.println(response);
}
}Example: with feeds and visibility
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Full activity update
var response = feedsClient.updateActivity(
"activity-123",
new UpdateActivityRequest()
.setFeeds(List.of("user:john", "timeline:global"))
.setVisibility("public")
).execute();
System.out.println(response);
}
}Example: with enrich_own_fields and expires_at
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Full activity update
var response = feedsClient.updateActivity(
"activity-123",
new UpdateActivityRequest()
.setEnrichOwnFields(false)
.setExpiresAt(10)
).execute();
System.out.println(response);
}
}Example: with attachments and filter_tags
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Full activity update
var response = feedsClient.updateActivity(
"activity-123",
new UpdateActivityRequest()
.setAttachments(List.of())
.setFilterTags(List.of("tag1", "tag2"))
).execute();
System.out.println(response);
}
}Response: UpdateActivityResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| id | String | Yes | - |
| attachments | []Attachment | No | List of attachments for the activity |
| collection_refs | []string | No | Collections that this activity references |
| copy_custom_to_notification | Boolean | No | Whether to copy custom data to the notification activity (only applies when handle_mention_notifi... |
| custom | Map<String, Object> | No | Custom data for the activity |
| enrich_own_fields | Boolean | No | If true, enriches the activity's current_feed with own_* fields (own_follows, own_followings, own... |
| expires_at | float | No | Time when the activity will expire |
| feeds | []string | No | List of feeds the activity is present in |
| filter_tags | []string | No | Tags used for filtering the activity |
| force_moderation | Boolean | No | If true, forces moderation to run for server-side requests. By default, server-side requests skip... |
| handle_mention_notifications | Boolean | No | If true, creates notification activities for newly mentioned users and deletes notifications for ... |
| interest_tags | []string | No | Tags indicating interest categories |
| location | Location | No | Geographic location for the activity |
| mentioned_user_ids | []string | No | List of user IDs mentioned in the activity |
| poll_id | String | No | Poll ID |
| restrict_replies | String | No | Controls who can add comments/replies to this activity. One of: everyone, people_i_follow, nobody |
| run_activity_processors | Boolean | No | If true, runs activity processors on the updated activity. Processors will only run if the activi... |
| search_data | Map<String, Object> | No | Additional data for search indexing |
| skip_enrich_url | Boolean | No | Whether to skip URL enrichment for the activity |
| text | String | No | The text content of the activity |
| user | UserRequest | No | - |
| user_id | String | No | - |
| visibility | String | No | Visibility setting for the activity |
| visibility_tag | String | No | If visibility is 'tag', this is the tag name and is required |
updateActivityPartial
Modify selected fields of an activity to make incremental changes without altering the entire activity. Use this for efficient updates when only specific attributes need adjustment.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Partial activity update
var response = feedsClient.updateActivityPartial(
"activity-123",
new UpdateActivityPartialRequest()
.setUserID("john")
.setEnrichOwnFields(false)
).execute();
System.out.println(response);
}
}Example: with force_moderation and handle_mention_notifications
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Partial activity update
var response = feedsClient.updateActivityPartial(
"activity-123",
new UpdateActivityPartialRequest()
.setForceModeration(false)
.setHandleMentionNotifications(false)
).execute();
System.out.println(response);
}
}Example: with run_activity_processors and set
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Partial activity update
var response = feedsClient.updateActivityPartial(
"activity-123",
new UpdateActivityPartialRequest()
.setRunActivityProcessors(false)
.setSet(Map.of())
).execute();
System.out.println(response);
}
}Example: with unset and user
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Partial activity update
var response = feedsClient.updateActivityPartial(
"activity-123",
new UpdateActivityPartialRequest()
.setUnset(List.of())
.setUser(new UserRequest().setID("activity-123").setCustom(Map.of()))
).execute();
System.out.println(response);
}
}Response: UpdateActivityPartialResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| id | String | Yes | - |
| copy_custom_to_notification | Boolean | No | Whether to copy custom data to the notification activity (only applies when handle_mention_notifi... |
| enrich_own_fields | Boolean | No | If true, enriches the activity's current_feed with own_* fields (own_follows, own_followings, own... |
| force_moderation | Boolean | No | If true, forces moderation to run for server-side requests. By default, server-side requests skip... |
| handle_mention_notifications | Boolean | No | If true, creates notification activities for newly mentioned users and deletes notifications for ... |
| run_activity_processors | Boolean | No | If true, runs activity processors on the updated activity. Processors will only run if the activi... |
| set | Map<String, Object> | No | Map of field names to new values. Supported fields: 'text', 'attachments', 'custom', 'visibility'... |
| unset | []string | No | List of field names to remove. Supported fields: 'custom', 'visibility_tag', 'location', 'expires... |
| user | UserRequest | No | - |
| user_id | String | No | - |
deleteActivity
Remove a specific activity from the feed to maintain relevance or manage content lifecycle. Use this when an activity is no longer needed or should not be displayed.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Delete a single activity
var response = feedsClient.deleteActivity(
"activity-123",
new DeleteActivityRequest()
.setHardDelete(false)
.setDeleteNotificationActivity(false)
).execute();
System.out.println(response);
}
}Response: DeleteActivityResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| id | String | Yes | - |
| hard_delete | Boolean | No | - |
| delete_notification_activity | Boolean | No | - |
restoreActivity
Restore a previously soft-deleted activity to make it active again, useful for recovering activities that were unintentionally removed or need to be reinstated.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Restore a soft-deleted activity
var response = feedsClient.restoreActivity(
"activity-123",
new RestoreActivityRequest()
.setUserID("john")
.setUser(new UserRequest().setID("activity-123").setCustom(Map.of()))
).execute();
System.out.println(response);
}
}Example: with enrich_own_fields
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Restore a soft-deleted activity
var response = feedsClient.restoreActivity(
"activity-123",
new RestoreActivityRequest()
.setEnrichOwnFields(false)
).execute();
System.out.println(response);
}
}Response: RestoreActivityResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| id | String | Yes | - |
| enrich_own_fields | Boolean | No | - |
| user | UserRequest | No | - |
| user_id | String | No | - |
queryBookmarkFolders
Retrieve a list of bookmark folders to organize and access saved activities quickly. Use this to manage user bookmarks and improve content retrieval efficiency.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Query bookmark folders
var response = feedsClient.queryBookmarkFolders(
new QueryBookmarkFoldersRequest()
.setLimit(25)
.setFilter(Map.of())
.setSort(List.of())
).execute();
System.out.println(response);
}
}Example: with prev and next
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Query bookmark folders
var response = feedsClient.queryBookmarkFolders(
new QueryBookmarkFoldersRequest()
.setPrev(null)
.setNext(null)
).execute();
System.out.println(response);
}
}Response: QueryBookmarkFoldersResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| filter | Map<String, Object> | No | Filters to apply to the query |
| limit | Integer | No | - |
| next | String | No | - |
| prev | String | No | - |
| sort | []SortParamRequest | No | Sorting parameters for the query |
updateBookmarkFolder
Modify the details of a bookmark folder to reorganize or rename it for better management. Use this when you need to update folder attributes for improved user experience.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Update a bookmark folder
var response = feedsClient.updateBookmarkFolder(
"folder-123",
new UpdateBookmarkFolderRequest()
.setUserID("john")
.setName("My Feed")
).execute();
System.out.println(response);
}
}Example: with user and custom
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Update a bookmark folder
var response = feedsClient.updateBookmarkFolder(
"folder-123",
new UpdateBookmarkFolderRequest()
.setUser(new UserRequest().setID("activity-123").setCustom(Map.of()))
.setCustom(Map.of())
).execute();
System.out.println(response);
}
}Response: UpdateBookmarkFolderResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| folder_id | String | Yes | - |
| custom | Map<String, Object> | No | Custom data for the folder |
| name | String | No | Name of the folder |
| user | UserRequest | No | - |
| user_id | String | No | - |
deleteBookmarkFolder
Remove a bookmark folder to declutter or reorganize saved content. Use this when a folder is no longer needed or should be consolidated with others.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Delete a bookmark folder
var response = feedsClient.deleteBookmarkFolder(
"folder-123"
).execute();
System.out.println(response);
}
}Response: DeleteBookmarkFolderResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| folder_id | String | Yes | - |
queryBookmarks
Retrieve a list of bookmarks based on specified criteria, useful for accessing saved or frequently accessed items quickly.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Query bookmarks
var response = feedsClient.queryBookmarks(
new QueryBookmarksRequest()
.setLimit(25)
.setFilter(Map.of())
.setSort(List.of())
).execute();
System.out.println(response);
}
}Example: with next and prev
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Query bookmarks
var response = feedsClient.queryBookmarks(
new QueryBookmarksRequest()
.setNext(null)
.setPrev(null)
).execute();
System.out.println(response);
}
}Example: with enrich_own_fields
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Query bookmarks
var response = feedsClient.queryBookmarks(
new QueryBookmarksRequest()
.setEnrichOwnFields(false)
).execute();
System.out.println(response);
}
}Response: QueryBookmarksResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| enrich_own_fields | Boolean | No | - |
| filter | Map<String, Object> | No | Filters to apply to the query |
| limit | Integer | No | - |
| next | String | No | - |
| prev | String | No | - |
| sort | []SortParamRequest | No | Sorting parameters for the query |
readCollections
Fetch details of existing collections, enabling users to view and manage grouped data easily.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Read collections
var response = feedsClient.readCollections(
new ReadCollectionsRequest()
.setUserID("john")
.setCollectionRefs(List.of("food:pizza-123"))
).execute();
System.out.println(response);
}
}Response: ReadCollectionsResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| collection_refs | []string | No | - |
| user_id | String | No | - |
createCollections
Create new collections in bulk, ideal for organizing large sets of data into manageable groups at once.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Create multiple collections
var response = feedsClient.createCollections(
new CreateCollectionsRequest()
.setCollections(List.of())
.setUserID("john")
.setUser(new UserRequest().setID("activity-123").setCustom(Map.of()))
).execute();
System.out.println(response);
}
}Response: CreateCollectionsResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| collections | []CollectionRequest | Yes | List of collections to create |
| user | UserRequest | No | - |
| user_id | String | No | - |
upsertCollections
Insert new collections or update existing ones in a single operation, ensuring your data is current without multiple requests.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Upsert multiple collections
var response = feedsClient.upsertCollections(
new UpsertCollectionsRequest()
.setCollections(List.of())
).execute();
System.out.println(response);
}
}Response: UpsertCollectionsResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| collections | []CollectionRequest | Yes | List of collections to upsert (insert if new, update if existing) |
updateCollections
Modify existing collections by changing their attributes, facilitating the maintenance and customization of grouped data.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Update multiple collections
var response = feedsClient.updateCollections(
new UpdateCollectionsRequest()
.setCollections(List.of())
.setUserID("john")
.setUser(new UserRequest().setID("activity-123").setCustom(Map.of()))
).execute();
System.out.println(response);
}
}Response: UpdateCollectionsResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| collections | []UpdateCollectionRequest | Yes | List of collections to update (only custom data is updatable) |
| user | UserRequest | No | - |
| user_id | String | No | - |
deleteCollections
Remove multiple collections at once, useful for cleaning up and organizing data by eliminating unneeded sets.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Delete multiple collections
var response = feedsClient.deleteCollections(
new DeleteCollectionsRequest()
.setCollectionRefs(List.of("food:pizza-123"))
).execute();
System.out.println(response);
}
}Response: DeleteCollectionsResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| collection_refs | []string | Yes | - |
queryCollections
Retrieves data from specified collections, allowing you to access and filter stored information efficiently. Use this when you need to extract specific data from your collections for analysis or display.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Query collections
var response = feedsClient.queryCollections(
new QueryCollectionsRequest()
.setUserID("john")
.setLimit(25)
.setFilter(Map.of())
).execute();
System.out.println(response);
}
}Example: with sort and next
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Query collections
var response = feedsClient.queryCollections(
new QueryCollectionsRequest()
.setSort(List.of())
.setNext(null)
).execute();
System.out.println(response);
}
}Example: with user and prev
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Query collections
var response = feedsClient.queryCollections(
new QueryCollectionsRequest()
.setUser(new UserRequest().setID("activity-123").setCustom(Map.of()))
.setPrev(null)
).execute();
System.out.println(response);
}
}Response: QueryCollectionsResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| filter | Map<String, Object> | No | Filters to apply to the query |
| limit | Integer | No | - |
| next | String | No | - |
| prev | String | No | - |
| sort | []SortParamRequest | No | Sorting parameters for the query |
| user | UserRequest | No | - |
| user_id | String | No | - |
getComments
Retrieve comments related to a specific object, providing insights and feedback from users or collaborators.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Get comments for an object
var response = feedsClient.getComments(
new GetCommentsRequest()
.setObjectID("activity-123")
.setObjectType("activity")
.setUserID("john")
.setLimit(25)
).execute();
System.out.println(response);
}
}Example: with sort and id_around
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Get comments for an object
var response = feedsClient.getComments(
new GetCommentsRequest()
.setObjectID("activity-123")
.setObjectType("activity")
.setSort([{ field: "created_at", direction: -1 }])
.setIDAround("value")
).execute();
System.out.println(response);
}
}Example: with depth and replies_limit
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Get comments for an object
var response = feedsClient.getComments(
new GetCommentsRequest()
.setObjectID("activity-123")
.setObjectType("activity")
.setDepth(2)
.setRepliesLimit(10)
).execute();
System.out.println(response);
}
}Example: with prev and next
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Get comments for an object
var response = feedsClient.getComments(
new GetCommentsRequest()
.setObjectID("activity-123")
.setObjectType("activity")
.setPrev(null)
.setNext(null)
).execute();
System.out.println(response);
}
}Response: GetCommentsResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| object_id | String | Yes | - |
| object_type | String | Yes | - |
| depth | Integer | No | - |
| sort | String | No | - |
| replies_limit | Integer | No | - |
| id_around | String | No | - |
| user_id | String | No | - |
| limit | Integer | No | - |
| prev | String | No | - |
| next | String | No | - |
addComment
Post a new comment or reply to an existing one, fostering interaction and discussion around a particular object.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Add a comment or reply
var response = feedsClient.addComment(
new AddCommentRequest()
.setUserID("john")
.setID("activity-123")
.setSkipPush(false)
).execute();
System.out.println(response);
}
}Example: with create_notification_activity and custom
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Add a comment or reply
var response = feedsClient.addComment(
new AddCommentRequest()
.setCreateNotificationActivity(false)
.setCustom(Map.of())
).execute();
System.out.println(response);
}
}Example: with force_moderation and attachments
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Add a comment or reply
var response = feedsClient.addComment(
new AddCommentRequest()
.setForceModeration(false)
.setAttachments(List.of())
).execute();
System.out.println(response);
}
}Example: with mentioned_user_ids and object_id
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Add a comment or reply
var response = feedsClient.addComment(
new AddCommentRequest()
.setMentionedUserIds(List.of("user-1", "user-2"))
.setObjectID("activity-123")
).execute();
System.out.println(response);
}
}Response: AddCommentResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| attachments | []Attachment | No | Media attachments for the reply |
| comment | String | No | Text content of the comment |
| copy_custom_to_notification | Boolean | No | Whether to copy custom data to the notification activity (only applies when create_notification_a... |
| create_notification_activity | Boolean | No | Whether to create a notification activity for this comment |
| custom | Map<String, Object> | No | Custom data for the comment |
| force_moderation | Boolean | No | If true, forces moderation to run for server-side requests. By default, server-side requests skip... |
| id | String | No | Optional custom ID for the comment (max 255 characters). If not provided, a UUID will be generated. |
| mentioned_user_ids | []string | No | List of users mentioned in the reply |
| object_id | String | No | ID of the object to comment on. Required for root comments |
| object_type | String | No | Type of the object to comment on. Required for root comments |
| parent_id | String | No | ID of parent comment for replies. When provided, object_id and object_type are automatically inhe... |
| skip_enrich_url | Boolean | No | Whether to skip URL enrichment for this comment |
| skip_push | Boolean | No | - |
| user | UserRequest | No | - |
| user_id | String | No | - |
addCommentsBatch
Submit multiple comments in a single request, streamlining processes where multiple inputs are needed simultaneously.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Add multiple comments in a batch
var response = feedsClient.addCommentsBatch(
new AddCommentsBatchRequest()
.setComments(List.of())
).execute();
System.out.println(response);
}
}Response: AddCommentsBatchResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| comments | []AddCommentRequest | Yes | List of comments to add |
queryComments
Search for comments based on defined parameters, allowing users to filter and locate specific discussions efficiently.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Query comments
var response = feedsClient.queryComments(
new QueryCommentsRequest()
.setFilter(Map.of())
.setUserID("john")
.setLimit(25)
).execute();
System.out.println(response);
}
}Example: with sort and prev
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Query comments
var response = feedsClient.queryComments(
new QueryCommentsRequest()
.setFilter(Map.of())
.setSort([{ field: "created_at", direction: -1 }])
.setPrev(null)
).execute();
System.out.println(response);
}
}Example: with id_around and user
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Query comments
var response = feedsClient.queryComments(
new QueryCommentsRequest()
.setFilter(Map.of())
.setIDAround("value")
.setUser(new UserRequest().setID("activity-123").setCustom(Map.of()))
).execute();
System.out.println(response);
}
}Example: with next
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Query comments
var response = feedsClient.queryComments(
new QueryCommentsRequest()
.setFilter(Map.of())
.setNext(null)
).execute();
System.out.println(response);
}
}Response: QueryCommentsResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| filter | Map<String, Object> | Yes | Filter to apply to the query |
| id_around | String | No | Returns the comment with the specified ID along with surrounding comments for context |
| limit | Integer | No | Maximum number of comments to return |
| next | String | No | - |
| prev | String | No | - |
| sort | String | No | Array of sort parameters |
| user | UserRequest | No | - |
| user_id | String | No | - |
addCommentBookmark
Allows users to bookmark a comment for easy future reference. Use this to enable users to save important comments for quick access later.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Add comment bookmark
var response = feedsClient.addCommentBookmark(
"comment-123",
new AddCommentBookmarkRequest()
.setUserID("john")
.setFolderID("folder-123")
).execute();
System.out.println(response);
}
}Example: with new_folder and user
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Add comment bookmark
var response = feedsClient.addCommentBookmark(
"comment-123",
new AddCommentBookmarkRequest()
.setNewFolder(new AddFolderRequest().setName("My Feed").setCustom(Map.of()))
.setUser(new UserRequest().setID("activity-123").setCustom(Map.of()))
).execute();
System.out.println(response);
}
}Example: with custom
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Add comment bookmark
var response = feedsClient.addCommentBookmark(
"comment-123",
new AddCommentBookmarkRequest()
.setCustom(Map.of())
).execute();
System.out.println(response);
}
}Response: AddCommentBookmarkResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| comment_id | String | Yes | - |
| custom | Map<String, Object> | No | Custom data for the bookmark |
| folder_id | String | No | ID of the folder to add the bookmark to |
| new_folder | AddFolderRequest | No | Create a new folder for this bookmark |
| user | UserRequest | No | - |
| user_id | String | No | - |
updateCommentBookmark
Modifies an existing comment bookmark to reflect changes or updates. Use this to ensure that user bookmarks remain relevant and up-to-date.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Update comment bookmark
var response = feedsClient.updateCommentBookmark(
"comment-123",
new UpdateCommentBookmarkRequest()
.setUserID("john")
.setFolderID("folder-123")
).execute();
System.out.println(response);
}
}Example: with new_folder and new_folder_id
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Update comment bookmark
var response = feedsClient.updateCommentBookmark(
"comment-123",
new UpdateCommentBookmarkRequest()
.setNewFolder(new AddFolderRequest().setName("My Feed").setCustom(Map.of()))
.setNewFolderID("value")
).execute();
System.out.println(response);
}
}Example: with user and custom
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Update comment bookmark
var response = feedsClient.updateCommentBookmark(
"comment-123",
new UpdateCommentBookmarkRequest()
.setUser(new UserRequest().setID("activity-123").setCustom(Map.of()))
.setCustom(Map.of())
).execute();
System.out.println(response);
}
}Response: UpdateCommentBookmarkResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| comment_id | String | Yes | - |
| custom | Map<String, Object> | No | Custom data for the bookmark |
| folder_id | String | No | ID of the folder containing the bookmark |
| new_folder | AddFolderRequest | No | Create a new folder and move the bookmark into it |
| new_folder_id | String | No | Move the bookmark to this folder (empty string removes the folder) |
| user | UserRequest | No | - |
| user_id | String | No | - |
deleteCommentBookmark
Removes a bookmarked comment, freeing up space and reducing clutter. Use this when a bookmarked comment is no longer needed by the user.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Delete a comment bookmark
var response = feedsClient.deleteCommentBookmark(
"comment-123",
new DeleteCommentBookmarkRequest()
.setUserID("john")
.setFolderID("folder-123")
).execute();
System.out.println(response);
}
}Response: DeleteCommentBookmarkResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| comment_id | String | Yes | - |
| folder_id | String | No | - |
| user_id | String | No | - |
getComment
Retrieve a specific comment by its ID to view details or perform further operations. Use this method when you need to access the content or metadata of a particular comment.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Get comment
var response = feedsClient.getComment(
"activity-123",
new GetCommentRequest()
.setUserID("john")
).execute();
System.out.println(response);
}
}Response: GetCommentResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| id | String | Yes | - |
| user_id | String | No | - |
updateComment
Modify the content or metadata of an existing comment. Use this method when you want to edit a comment's text or update its properties.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Update a comment
var response = feedsClient.updateComment(
"activity-123",
new UpdateCommentRequest()
.setUserID("john")
.setSkipPush(false)
).execute();
System.out.println(response);
}
}Example: with copy_custom_to_notification and custom
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Update a comment
var response = feedsClient.updateComment(
"activity-123",
new UpdateCommentRequest()
.setCopyCustomToNotification(false)
.setCustom(Map.of())
).execute();
System.out.println(response);
}
}Example: with force_moderation and handle_mention_notifications
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Update a comment
var response = feedsClient.updateComment(
"activity-123",
new UpdateCommentRequest()
.setForceModeration(false)
.setHandleMentionNotifications(false)
).execute();
System.out.println(response);
}
}Example: with mentioned_user_ids and skip_enrich_url
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Update a comment
var response = feedsClient.updateComment(
"activity-123",
new UpdateCommentRequest()
.setMentionedUserIds(List.of("user-1", "user-2"))
.setSkipEnrichURL(false)
).execute();
System.out.println(response);
}
}Response: UpdateCommentResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| id | String | Yes | - |
| attachments | []Attachment | No | Updated media attachments for the comment. Providing this field will replace all existing attachm... |
| comment | String | No | Updated text content of the comment |
| copy_custom_to_notification | Boolean | No | Whether to copy custom data to the notification activity (only applies when handle_mention_notifi... |
| custom | Map<String, Object> | No | Updated custom data for the comment |
| force_moderation | Boolean | No | If true, forces moderation to run for server-side requests. By default, server-side requests skip... |
| handle_mention_notifications | Boolean | No | If true, creates notification activities for newly mentioned users and deletes notifications for ... |
| mentioned_user_ids | []string | No | List of user IDs mentioned in the comment |
| skip_enrich_url | Boolean | No | Whether to skip URL enrichment for this comment |
| skip_push | Boolean | No | - |
| user | UserRequest | No | - |
| user_id | String | No | - |
deleteComment
Remove a comment from a feed. Use this method to permanently delete a comment when it is no longer needed.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Delete a comment
var response = feedsClient.deleteComment(
"activity-123",
new DeleteCommentRequest()
.setHardDelete(false)
.setDeleteNotificationActivity(false)
).execute();
System.out.println(response);
}
}Response: DeleteCommentResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| id | String | Yes | - |
| hard_delete | Boolean | No | - |
| delete_notification_activity | Boolean | No | - |
updateCommentPartial
Applies partial updates to a comment, allowing for specific fields to be modified without altering the entire comment. Use this to efficiently update comment content or metadata.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Partial comment update
var response = feedsClient.updateCommentPartial(
"activity-123",
new UpdateCommentPartialRequest()
.setUserID("john")
.setSkipPush(false)
).execute();
System.out.println(response);
}
}Example: with handle_mention_notifications and set
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Partial comment update
var response = feedsClient.updateCommentPartial(
"activity-123",
new UpdateCommentPartialRequest()
.setHandleMentionNotifications(false)
.setSet(Map.of())
).execute();
System.out.println(response);
}
}Example: with skip_enrich_url and copy_custom_to_notification
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Partial comment update
var response = feedsClient.updateCommentPartial(
"activity-123",
new UpdateCommentPartialRequest()
.setSkipEnrichURL(false)
.setCopyCustomToNotification(false)
).execute();
System.out.println(response);
}
}Example: with unset and user
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Partial comment update
var response = feedsClient.updateCommentPartial(
"activity-123",
new UpdateCommentPartialRequest()
.setUnset(List.of())
.setUser(new UserRequest().setID("activity-123").setCustom(Map.of()))
).execute();
System.out.println(response);
}
}Response: UpdateCommentPartialResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| id | String | Yes | - |
| copy_custom_to_notification | Boolean | No | Whether to copy custom data to notification activities Deprecated: use notification_context.trigg... |
| force_moderation | Boolean | No | If true, forces moderation to run for server-side requests. By default, server-side requests skip... |
| handle_mention_notifications | Boolean | No | Whether to handle mention notification changes |
| set | Map<String, Object> | No | Map of field names to new values. Supported fields: 'text', 'attachments', 'custom', 'mentioned_u... |
| skip_enrich_url | Boolean | No | Whether to skip URL enrichment |
| skip_push | Boolean | No | Whether to skip push notifications |
| unset | []string | No | List of field names to remove. Supported fields: 'custom', 'attachments', 'mentioned_user_ids', '... |
| user | UserRequest | No | - |
| user_id | String | No | - |
addCommentReaction
Attach a reaction, such as a like or emoji, to a comment. Use this method to allow users to express their sentiments about a comment.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Add comment reaction
var response = feedsClient.addCommentReaction(
"activity-123",
new AddCommentReactionRequest()
.setType("like")
.setUserID("john")
.setSkipPush(false)
).execute();
System.out.println(response);
}
}Example: with custom and enforce_unique
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Add comment reaction
var response = feedsClient.addCommentReaction(
"activity-123",
new AddCommentReactionRequest()
.setType("like")
.setCustom(Map.of())
.setEnforceUnique(true)
).execute();
System.out.println(response);
}
}Example: with copy_custom_to_notification and user
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Add comment reaction
var response = feedsClient.addCommentReaction(
"activity-123",
new AddCommentReactionRequest()
.setType("like")
.setCopyCustomToNotification(false)
.setUser(new UserRequest().setID("activity-123").setCustom(Map.of()))
).execute();
System.out.println(response);
}
}Example: with create_notification_activity
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Add comment reaction
var response = feedsClient.addCommentReaction(
"activity-123",
new AddCommentReactionRequest()
.setType("like")
.setCreateNotificationActivity(false)
).execute();
System.out.println(response);
}
}Response: AddCommentReactionResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| id | String | Yes | - |
| type | String | Yes | The type of reaction, eg upvote, like, ... |
| copy_custom_to_notification | Boolean | No | Whether to copy custom data to the notification activity (only applies when create_notification_a... |
| create_notification_activity | Boolean | No | Whether to create a notification activity for this reaction |
| custom | Map<String, Object> | No | Optional custom data to add to the reaction |
| enforce_unique | Boolean | No | Whether to enforce unique reactions per user (remove other reaction types from the user when addi... |
| skip_push | Boolean | No | - |
| user | UserRequest | No | - |
| user_id | String | No | - |
queryCommentReactions
Retrieve all reactions associated with a specific comment. Use this method to view how users have interacted with a comment through various reactions.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Query comment reactions
var response = feedsClient.queryCommentReactions(
"activity-123",
new QueryCommentReactionsRequest()
.setLimit(25)
.setFilter(Map.of())
).execute();
System.out.println(response);
}
}Example: with sort and prev
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Query comment reactions
var response = feedsClient.queryCommentReactions(
"activity-123",
new QueryCommentReactionsRequest()
.setSort(List.of())
.setPrev(null)
).execute();
System.out.println(response);
}
}Example: with next
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Query comment reactions
var response = feedsClient.queryCommentReactions(
"activity-123",
new QueryCommentReactionsRequest()
.setNext(null)
).execute();
System.out.println(response);
}
}Response: QueryCommentReactionsResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| id | String | Yes | - |
| filter | Map<String, Object> | No | - |
| limit | Integer | No | - |
| next | String | No | - |
| prev | String | No | - |
| sort | []SortParamRequest | No | - |
deleteCommentReaction
Remove a specific reaction from a comment. Use this method when you need to retract or correct a reaction added to a comment.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Delete comment reaction
var response = feedsClient.deleteCommentReaction(
"activity-123",
"like",
new DeleteCommentReactionRequest()
.setUserID("john")
.setDeleteNotificationActivity(false)
).execute();
System.out.println(response);
}
}Response: DeleteCommentReactionResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| id | String | Yes | - |
| type | String | Yes | - |
| delete_notification_activity | Boolean | No | - |
| user_id | String | No | - |
getCommentReplies
Fetch all replies associated with a specific comment. Use this method to view or manage the conversation thread stemming from a comment.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Get replies for a comment
var response = feedsClient.getCommentReplies(
"activity-123",
new GetCommentRepliesRequest()
.setUserID("john")
.setLimit(25)
).execute();
System.out.println(response);
}
}Example: with sort and id_around
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Get replies for a comment
var response = feedsClient.getCommentReplies(
"activity-123",
new GetCommentRepliesRequest()
.setSort([{ field: "created_at", direction: -1 }])
.setIDAround("value")
).execute();
System.out.println(response);
}
}Example: with depth and replies_limit
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Get replies for a comment
var response = feedsClient.getCommentReplies(
"activity-123",
new GetCommentRepliesRequest()
.setDepth(2)
.setRepliesLimit(10)
).execute();
System.out.println(response);
}
}Example: with prev and next
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Get replies for a comment
var response = feedsClient.getCommentReplies(
"activity-123",
new GetCommentRepliesRequest()
.setPrev(null)
.setNext(null)
).execute();
System.out.println(response);
}
}Response: GetCommentRepliesResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| id | String | Yes | - |
| depth | Integer | No | - |
| sort | String | No | - |
| replies_limit | Integer | No | - |
| id_around | String | No | - |
| user_id | String | No | - |
| limit | Integer | No | - |
| prev | String | No | - |
| next | String | No | - |
restoreComment
Reactivates a comment that was previously soft-deleted, making it visible again. Use this to recover comments that were mistakenly deleted or need to be reinstated.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Restore a soft-deleted comment
var response = feedsClient.restoreComment(
"activity-123",
new RestoreCommentRequest()
.setUserID("john")
.setUser(new UserRequest().setID("activity-123").setCustom(Map.of()))
).execute();
System.out.println(response);
}
}Response: RestoreCommentResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| id | String | Yes | - |
| user | UserRequest | No | - |
| user_id | String | No | - |
listFeedGroups
Retrieve a list of all available feed groups within the application. Use this method to explore or manage different categories of feeds.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// List all feed groups
var response = feedsClient.listFeedGroups(
new ListFeedGroupsRequest()
.setIncludeSoftDeleted(false)
).execute();
System.out.println(response);
}
}Response: ListFeedGroupsResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| include_soft_deleted | Boolean | No | - |
createFeedGroup
Establish a new feed group to categorize and organize related feeds. Use this method when you need to create a new grouping for feeds based on specific criteria or topics.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Create a new feed group
var response = feedsClient.createFeedGroup(
new CreateFeedGroupRequest()
.setID("activity-123")
.setActivityProcessors(List.of())
.setActivitySelectors(List.of())
).execute();
System.out.println(response);
}
}Example: with aggregation and custom
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Create a new feed group
var response = feedsClient.createFeedGroup(
new CreateFeedGroupRequest()
.setID("activity-123")
.setAggregation(new AggregationConfig().setActivitiesSort("value"))
.setCustom(Map.of())
).execute();
System.out.println(response);
}
}Example: with default_visibility and notification
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Create a new feed group
var response = feedsClient.createFeedGroup(
new CreateFeedGroupRequest()
.setID("activity-123")
.setDefaultVisibility("value")
.setNotification(new NotificationConfig().setDeduplicationWindow("value"))
).execute();
System.out.println(response);
}
}Example: with push_notification and ranking
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Create a new feed group
var response = feedsClient.createFeedGroup(
new CreateFeedGroupRequest()
.setID("activity-123")
.setPushNotification(new PushNotificationConfig().setEnablePush(false))
.setRanking(new RankingConfig().setType("like").setDefaults(Map.of()))
).execute();
System.out.println(response);
}
}Response: CreateFeedGroupResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| id | String | Yes | Unique identifier for the feed group |
| activity_processors | []ActivityProcessorConfig | No | Configuration for activity processors |
| activity_selectors | []ActivitySelectorConfig | No | Configuration for activity selectors |
| aggregation | AggregationConfig | No | Configuration for activity aggregation |
| custom | Map<String, Object> | No | Custom data for the feed group |
| default_visibility | String | No | Default visibility for the feed group, can be 'public', 'visible', 'followers', 'members', or 'pr... |
| notification | NotificationConfig | No | Configuration for notifications |
| push_notification | PushNotificationConfig | No | - |
| ranking | RankingConfig | No | Configuration for activity ranking |
| stories | StoriesConfig | No | Configuration for stories functionality |
getOrCreateFeed
Retrieve an existing feed or create a new one if it doesn't exist. Use this method to ensure a feed is available for content posting or interaction.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Create a new feed
var response = feedsClient.getOrCreateFeed(
"user",
"john",
new GetOrCreateFeedRequest()
.setUserID("john")
.setLimit(25)
).execute();
System.out.println(response);
}
}Example: with filter and data
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Create a new feed
var response = feedsClient.getOrCreateFeed(
"user",
"john",
new GetOrCreateFeedRequest()
.setFilter(Map.of())
.setData(new FeedInput().setCustom(Map.of()))
).execute();
System.out.println(response);
}
}Example: with followers_pagination and following_pagination
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Create a new feed
var response = feedsClient.getOrCreateFeed(
"user",
"john",
new GetOrCreateFeedRequest()
.setFollowersPagination(new PagerRequest().setLimit(25))
.setFollowingPagination(new PagerRequest().setLimit(25))
).execute();
System.out.println(response);
}
}Example: with friend_reactions_options and id_around
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Create a new feed
var response = feedsClient.getOrCreateFeed(
"user",
"john",
new GetOrCreateFeedRequest()
.setFriendReactionsOptions(new FriendReactionsOptions().setEnabled(false))
.setIDAround("value")
).execute();
System.out.println(response);
}
}Response: GetOrCreateFeedResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| feed_group_id | String | Yes | - |
| feed_id | String | Yes | - |
| data | FeedInput | No | - |
| enrichment_options | EnrichmentOptions | No | - |
| external_ranking | Map<String, Object> | No | - |
| filter | Map<String, Object> | No | - |
| followers_pagination | PagerRequest | No | - |
| following_pagination | PagerRequest | No | - |
| friend_reactions_options | FriendReactionsOptions | No | - |
| id_around | String | No | - |
| interest_weights | Map<String, Object> | No | - |
| limit | Integer | No | - |
| member_pagination | PagerRequest | No | - |
| next | String | No | - |
| prev | String | No | - |
| user | UserRequest | No | - |
| user_id | String | No | - |
| view | String | No | - |
| watch | Boolean | No | - |
updateFeed
Modify the details or settings of an existing feed to keep it current and relevant. Use this method when you want to change aspects like feed name, description, or settings.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Update a feed
var response = feedsClient.updateFeed(
"user",
"john",
new UpdateFeedRequest()
.setName("My Feed")
.setCreatedByID("value")
).execute();
System.out.println(response);
}
}Example: with custom and description
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Update a feed
var response = feedsClient.updateFeed(
"user",
"john",
new UpdateFeedRequest()
.setCustom(Map.of())
.setDescription("A description")
).execute();
System.out.println(response);
}
}Example: with enrich_own_fields and filter_tags
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Update a feed
var response = feedsClient.updateFeed(
"user",
"john",
new UpdateFeedRequest()
.setEnrichOwnFields(false)
.setFilterTags(List.of("tag1", "tag2"))
).execute();
System.out.println(response);
}
}Example: with location and clear_location
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Update a feed
var response = feedsClient.updateFeed(
"user",
"john",
new UpdateFeedRequest()
.setLocation(new Location().setLat(10).setLng(10))
.setClearLocation(false)
).execute();
System.out.println(response);
}
}Response: UpdateFeedResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| feed_group_id | String | Yes | - |
| feed_id | String | Yes | - |
| clear_location | Boolean | No | If true, removes the geographic location from the feed |
| created_by_id | String | No | ID of the new feed creator (owner) |
| custom | Map<String, Object> | No | Custom data for the feed |
| description | String | No | Description of the feed |
| enrich_own_fields | Boolean | No | If true, enriches the feed with own_* fields (own_follows, own_followings, own_capabilities, own_... |
| filter_tags | []string | No | Tags used for filtering feeds |
| location | Location | No | Geographic location for the feed |
| name | String | No | Name of the feed |
deleteFeed
Remove a specific feed permanently to clean up unused or obsolete data. This is useful when a feed is no longer needed and should be completely erased from your system.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Delete a single feed
var response = feedsClient.deleteFeed(
"user",
"john",
new DeleteFeedRequest()
.setHardDelete(false)
).execute();
System.out.println(response);
}
}Response: DeleteFeedResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| feed_group_id | String | Yes | - |
| feed_id | String | Yes | - |
| hard_delete | Boolean | No | - |
markActivity
Designate specific activities as read, seen, or watched to help users track their interactions and stay informed about new content. Use it to manage activity notifications and ensure users only see what is relevant to them.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Mark activities as read/seen/watched
var response = feedsClient.markActivity(
"user",
"john",
new MarkActivityRequest()
.setUserID("john")
.setMarkAllSeen(true)
).execute();
System.out.println(response);
}
}Example: with mark_read and mark_seen
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Mark activities as read/seen/watched
var response = feedsClient.markActivity(
"user",
"john",
new MarkActivityRequest()
.setMarkRead(List.of())
.setMarkSeen(List.of())
).execute();
System.out.println(response);
}
}Example: with mark_watched and user
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Mark activities as read/seen/watched
var response = feedsClient.markActivity(
"user",
"john",
new MarkActivityRequest()
.setMarkWatched(List.of())
.setUser(new UserRequest().setID("activity-123").setCustom(Map.of()))
).execute();
System.out.println(response);
}
}Example: with mark_all_read
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Mark activities as read/seen/watched
var response = feedsClient.markActivity(
"user",
"john",
new MarkActivityRequest()
.setMarkAllRead(true)
).execute();
System.out.println(response);
}
}Response: Response
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| feed_group_id | String | Yes | - |
| feed_id | String | Yes | - |
| mark_all_read | Boolean | No | Whether to mark all activities as read |
| mark_all_seen | Boolean | No | Whether to mark all activities as seen |
| mark_read | []string | No | List of activity IDs to mark as read |
| mark_seen | []string | No | List of activity IDs to mark as seen |
| mark_watched | []string | No | List of activity IDs to mark as watched (for stories) |
| user | UserRequest | No | - |
| user_id | String | No | - |
pinActivity
Highlight or prioritize an activity by pinning it to the top of a feed, ensuring it remains visible and easily accessible. This is useful for emphasizing important updates or content.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Pin an activity to a feed
var response = feedsClient.pinActivity(
"user",
"john",
"activity-123",
new PinActivityRequest()
.setUserID("john")
.setUser(new UserRequest().setID("activity-123").setCustom(Map.of()))
).execute();
System.out.println(response);
}
}Example: with enrich_own_fields
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Pin an activity to a feed
var response = feedsClient.pinActivity(
"user",
"john",
"activity-123",
new PinActivityRequest()
.setEnrichOwnFields(false)
).execute();
System.out.println(response);
}
}Response: PinActivityResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| feed_group_id | String | Yes | - |
| feed_id | String | Yes | - |
| activity_id | String | Yes | - |
| enrich_own_fields | Boolean | No | If true, enriches the activity's current_feed with own_* fields (own_follows, own_followings, own... |
| user | UserRequest | No | - |
| user_id | String | No | - |
unpinActivity
Remove a pinned activity from its prioritized position, allowing it to move naturally within the feed. Use this method when the activity no longer needs special emphasis.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Unpin an activity from a feed
var response = feedsClient.unpinActivity(
"user",
"john",
"activity-123",
new UnpinActivityRequest()
.setUserID("john")
.setEnrichOwnFields(false)
).execute();
System.out.println(response);
}
}Response: UnpinActivityResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| feed_group_id | String | Yes | - |
| feed_id | String | Yes | - |
| activity_id | String | Yes | - |
| enrich_own_fields | Boolean | No | - |
| user_id | String | No | - |
updateFeedMembers
Modify the list of members associated with a feed, adding or removing individuals as necessary. This method is beneficial for managing access and collaboration within a feed.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Update feed members
var response = feedsClient.updateFeedMembers(
"user",
"john",
new UpdateFeedMembersRequest()
.setOperation("add")
.setLimit(25)
.setMembers(List.of())
).execute();
System.out.println(response);
}
}Example: with next and prev
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Update feed members
var response = feedsClient.updateFeedMembers(
"user",
"john",
new UpdateFeedMembersRequest()
.setOperation("add")
.setNext(null)
.setPrev(null)
).execute();
System.out.println(response);
}
}Response: UpdateFeedMembersResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| feed_group_id | String | Yes | - |
| feed_id | String | Yes | - |
| operation | String | Yes | Type of update operation to perform. One of: upsert, remove, set |
| limit | Integer | No | - |
| members | []FeedMemberRequest | No | List of members to upsert, remove, or set |
| next | String | No | - |
| prev | String | No | - |
acceptFeedMemberInvite
Confirm and accept an invitation to join a feed as a member, facilitating collaboration and shared access. Use this method when you wish to join a feed you have been invited to.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Accept a feed member request
var response = feedsClient.acceptFeedMemberInvite(
"john",
"user",
new AcceptFeedMemberInviteRequest()
.setUserID("john")
.setUser(new UserRequest().setID("activity-123").setCustom(Map.of()))
).execute();
System.out.println(response);
}
}Response: AcceptFeedMemberInviteResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| feed_id | String | Yes | - |
| feed_group_id | String | Yes | - |
| user | UserRequest | No | - |
| user_id | String | No | - |
queryFeedMembers
Retrieve a list of all members associated with a specific feed to understand who has access and manage member interactions. This is useful for auditing and managing feed membership.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Query feed members
var response = feedsClient.queryFeedMembers(
"user",
"john",
new QueryFeedMembersRequest()
.setLimit(25)
.setFilter(Map.of())
).execute();
System.out.println(response);
}
}Example: with sort and prev
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Query feed members
var response = feedsClient.queryFeedMembers(
"user",
"john",
new QueryFeedMembersRequest()
.setSort(List.of())
.setPrev(null)
).execute();
System.out.println(response);
}
}Example: with next
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Query feed members
var response = feedsClient.queryFeedMembers(
"user",
"john",
new QueryFeedMembersRequest()
.setNext(null)
).execute();
System.out.println(response);
}
}Response: QueryFeedMembersResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| feed_group_id | String | Yes | - |
| feed_id | String | Yes | - |
| filter | Map<String, Object> | No | Filter parameters for the query |
| limit | Integer | No | - |
| next | String | No | - |
| prev | String | No | - |
| sort | []SortParamRequest | No | Sort parameters for the query |
rejectFeedMemberInvite
Decline an invitation to join a feed, preventing unwanted participation or access. Use this when you do not wish to be part of a feed you have been invited to.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Reject an invite to become a feed member
var response = feedsClient.rejectFeedMemberInvite(
"user",
"john",
new RejectFeedMemberInviteRequest()
.setUserID("john")
.setUser(new UserRequest().setID("activity-123").setCustom(Map.of()))
).execute();
System.out.println(response);
}
}Response: RejectFeedMemberInviteResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| feed_group_id | String | Yes | - |
| feed_id | String | Yes | - |
| user | UserRequest | No | - |
| user_id | String | No | - |
queryPinnedActivities
Retrieves a list of activities that have been pinned for prominence in a feed. Use this to highlight important or popular activities to your users.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Query pinned activities
var response = feedsClient.queryPinnedActivities(
"user",
"john",
new QueryPinnedActivitiesRequest()
.setLimit(25)
.setFilter(Map.of())
).execute();
System.out.println(response);
}
}Example: with sort and next
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Query pinned activities
var response = feedsClient.queryPinnedActivities(
"user",
"john",
new QueryPinnedActivitiesRequest()
.setSort(List.of())
.setNext(null)
).execute();
System.out.println(response);
}
}Example: with prev and enrich_own_fields
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Query pinned activities
var response = feedsClient.queryPinnedActivities(
"user",
"john",
new QueryPinnedActivitiesRequest()
.setPrev(null)
.setEnrichOwnFields(false)
).execute();
System.out.println(response);
}
}Response: QueryPinnedActivitiesResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| feed_group_id | String | Yes | - |
| feed_id | String | Yes | - |
| enrich_own_fields | Boolean | No | - |
| filter | Map<String, Object> | No | Filters to apply to the query |
| limit | Integer | No | - |
| next | String | No | - |
| prev | String | No | - |
| sort | []SortParamRequest | No | Sorting parameters for the query |
getFollowSuggestions
Receive personalized recommendations on which feeds or users to follow, enhancing user engagement and discovery of relevant content. This method is helpful for users looking to expand their network or interests.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Get follow suggestions
var response = feedsClient.getFollowSuggestions(
"user",
new GetFollowSuggestionsRequest()
.setUserID("john")
.setLimit(25)
).execute();
System.out.println(response);
}
}Response: GetFollowSuggestionsResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| feed_group_id | String | Yes | - |
| limit | Integer | No | - |
| user_id | String | No | - |
restoreFeedGroup
Restores a previously deleted feed group, reinstating its activities and user interactions. Use this to recover a feed group that needs to be active again after deletion.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Restore a feed group
var response = feedsClient.restoreFeedGroup(
"user"
).execute();
System.out.println(response);
}
}Response: RestoreFeedGroupResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| feed_group_id | String | Yes | - |
getFeedGroup
Retrieve details of an existing feed group to manage or display its contents effectively.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Get a feed group
var response = feedsClient.getFeedGroup(
"activity-123",
new GetFeedGroupRequest()
.setIncludeSoftDeleted(false)
).execute();
System.out.println(response);
}
}Response: GetFeedGroupResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| id | String | Yes | - |
| include_soft_deleted | Boolean | No | - |
getOrCreateFeedGroup
Obtain an existing feed group or create a new one if it doesn't exist, ensuring your application can seamlessly manage feed group resources.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Get or create a feed group
var response = feedsClient.getOrCreateFeedGroup(
"activity-123",
new GetOrCreateFeedGroupRequest()
.setActivityProcessors(List.of())
.setActivitySelectors(List.of())
).execute();
System.out.println(response);
}
}Example: with aggregation and custom
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Get or create a feed group
var response = feedsClient.getOrCreateFeedGroup(
"activity-123",
new GetOrCreateFeedGroupRequest()
.setAggregation(new AggregationConfig().setActivitiesSort("value"))
.setCustom(Map.of())
).execute();
System.out.println(response);
}
}Example: with default_visibility and notification
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Get or create a feed group
var response = feedsClient.getOrCreateFeedGroup(
"activity-123",
new GetOrCreateFeedGroupRequest()
.setDefaultVisibility("value")
.setNotification(new NotificationConfig().setDeduplicationWindow("value"))
).execute();
System.out.println(response);
}
}Example: with push_notification and ranking
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Get or create a feed group
var response = feedsClient.getOrCreateFeedGroup(
"activity-123",
new GetOrCreateFeedGroupRequest()
.setPushNotification(new PushNotificationConfig().setEnablePush(false))
.setRanking(new RankingConfig().setType("like").setDefaults(Map.of()))
).execute();
System.out.println(response);
}
}Response: GetOrCreateFeedGroupResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| id | String | Yes | - |
| activity_processors | []ActivityProcessorConfig | No | Configuration for activity processors |
| activity_selectors | []ActivitySelectorConfig | No | Configuration for activity selectors |
| aggregation | AggregationConfig | No | Configuration for activity aggregation |
| custom | Map<String, Object> | No | Custom data for the feed group |
| default_visibility | String | No | Default visibility for the feed group, can be 'public', 'visible', 'followers', 'members', or 'pr... |
| notification | NotificationConfig | No | Configuration for notifications |
| push_notification | PushNotificationConfig | No | - |
| ranking | RankingConfig | No | Configuration for activity ranking |
| stories | StoriesConfig | No | Configuration for stories functionality |
updateFeedGroup
Modify the properties of an existing feed group to keep its information up-to-date and relevant to your application's needs.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Update a feed group
var response = feedsClient.updateFeedGroup(
"activity-123",
new UpdateFeedGroupRequest()
.setActivityProcessors(List.of())
.setActivitySelectors(List.of())
).execute();
System.out.println(response);
}
}Example: with aggregation and custom
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Update a feed group
var response = feedsClient.updateFeedGroup(
"activity-123",
new UpdateFeedGroupRequest()
.setAggregation(new AggregationConfig().setActivitiesSort("value"))
.setCustom(Map.of())
).execute();
System.out.println(response);
}
}Example: with default_visibility and notification
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Update a feed group
var response = feedsClient.updateFeedGroup(
"activity-123",
new UpdateFeedGroupRequest()
.setDefaultVisibility("value")
.setNotification(new NotificationConfig().setDeduplicationWindow("value"))
).execute();
System.out.println(response);
}
}Example: with push_notification and ranking
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Update a feed group
var response = feedsClient.updateFeedGroup(
"activity-123",
new UpdateFeedGroupRequest()
.setPushNotification(new PushNotificationConfig().setEnablePush(false))
.setRanking(new RankingConfig().setType("like").setDefaults(Map.of()))
).execute();
System.out.println(response);
}
}Response: UpdateFeedGroupResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| id | String | Yes | - |
| activity_processors | []ActivityProcessorConfig | No | Configuration for activity processors |
| activity_selectors | []ActivitySelectorConfig | No | Configuration for activity selectors |
| aggregation | AggregationConfig | No | Configuration for activity aggregation |
| custom | Map<String, Object> | No | Custom data for the feed group |
| default_visibility | String | No | - |
| notification | NotificationConfig | No | Configuration for notifications |
| push_notification | PushNotificationConfig | No | - |
| ranking | RankingConfig | No | Configuration for activity ranking |
| stories | StoriesConfig | No | Configuration for stories functionality |
deleteFeedGroup
Remove an existing feed group to free up resources or when the feed group is no longer needed in your application.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Delete a feed group
var response = feedsClient.deleteFeedGroup(
"activity-123",
new DeleteFeedGroupRequest()
.setHardDelete(false)
).execute();
System.out.println(response);
}
}Response: DeleteFeedGroupResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| id | String | Yes | - |
| hard_delete | Boolean | No | - |
listFeedViews
Retrieve a list of all feed views to easily navigate and manage the available views in an application.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// List all feed views
var response = feedsClient.listFeedViews().execute();
System.out.println(response);
}
}Response: ListFeedViewsResponse
createFeedView
Generate a new feed view to organize and present feed data in a customized manner for users.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Create a new feed view
var response = feedsClient.createFeedView(
new CreateFeedViewRequest()
.setID("activity-123")
.setActivitySelectors(List.of())
.setAggregation(new AggregationConfig().setActivitiesSort("value"))
).execute();
System.out.println(response);
}
}Example: with ranking
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Create a new feed view
var response = feedsClient.createFeedView(
new CreateFeedViewRequest()
.setID("activity-123")
.setRanking(new RankingConfig().setType("like").setDefaults(Map.of()))
).execute();
System.out.println(response);
}
}Response: CreateFeedViewResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| id | String | Yes | Unique identifier for the feed view |
| activity_selectors | []ActivitySelectorConfig | No | Configuration for selecting activities |
| aggregation | AggregationConfig | No | Configuration for aggregating activities |
| ranking | RankingConfig | No | Configuration for ranking activities |
getFeedView
Access specific details of an existing feed view to analyze or display its configuration and content.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Get a feed view
var response = feedsClient.getFeedView(
"activity-123"
).execute();
System.out.println(response);
}
}Response: GetFeedViewResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| id | String | Yes | - |
getOrCreateFeedView
Retrieve an existing feed view or create a new one if it doesn't exist, ensuring your application can always access the necessary view configurations.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Get or create a feed view
var response = feedsClient.getOrCreateFeedView(
"activity-123",
new GetOrCreateFeedViewRequest()
.setActivitySelectors(List.of())
.setAggregation(new AggregationConfig().setActivitiesSort("value"))
).execute();
System.out.println(response);
}
}Example: with ranking
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Get or create a feed view
var response = feedsClient.getOrCreateFeedView(
"activity-123",
new GetOrCreateFeedViewRequest()
.setRanking(new RankingConfig().setType("like").setDefaults(Map.of()))
).execute();
System.out.println(response);
}
}Response: GetOrCreateFeedViewResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| id | String | Yes | - |
| activity_selectors | []ActivitySelectorConfig | No | Configuration for selecting activities |
| aggregation | AggregationConfig | No | Configuration for aggregating activities |
| ranking | RankingConfig | No | Configuration for ranking activities |
updateFeedView
Alter the settings or content of an existing feed view to reflect changes in data presentation or user requirements.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Update a feed view
var response = feedsClient.updateFeedView(
"activity-123",
new UpdateFeedViewRequest()
.setActivitySelectors(List.of())
.setAggregation(new AggregationConfig().setActivitiesSort("value"))
).execute();
System.out.println(response);
}
}Example: with ranking
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Update a feed view
var response = feedsClient.updateFeedView(
"activity-123",
new UpdateFeedViewRequest()
.setRanking(new RankingConfig().setType("like").setDefaults(Map.of()))
).execute();
System.out.println(response);
}
}Response: UpdateFeedViewResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| id | String | Yes | - |
| activity_selectors | []ActivitySelectorConfig | No | Updated configuration for selecting activities |
| aggregation | AggregationConfig | No | Updated configuration for aggregating activities |
| ranking | RankingConfig | No | Updated configuration for ranking activities |
deleteFeedView
Remove an existing feed view when it is no longer required, helping to maintain an organized and efficient feed view collection.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Delete a feed view
var response = feedsClient.deleteFeedView(
"activity-123"
).execute();
System.out.println(response);
}
}Response: DeleteFeedViewResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| id | String | Yes | - |
listFeedVisibilities
Retrieve a list of visibility settings for multiple feeds. Use this method to gain insights into which feeds are public, private, or have custom visibility rules.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// List feed visibilities
var response = feedsClient.listFeedVisibilities().execute();
System.out.println(response);
}
}Response: ListFeedVisibilitiesResponse
getFeedVisibility
Obtain the visibility status of a specific feed. This method is useful for checking whether a feed is accessible to certain users or groups.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Get feed visibility
var response = feedsClient.getFeedVisibility(
"My Feed"
).execute();
System.out.println(response);
}
}Response: GetFeedVisibilityResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| name | String | Yes | - |
updateFeedVisibility
Modify the visibility settings of a feed. Use this to change who can view or interact with a feed, enhancing content privacy or accessibility as needed.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Update Feed Visibility
var response = feedsClient.updateFeedVisibility(
"My Feed",
new UpdateFeedVisibilityRequest()
.setGrants(Map.of())
).execute();
System.out.println(response);
}
}Response: UpdateFeedVisibilityResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| name | String | Yes | - |
| grants | Map<String, Object> | No | Updated permission grants for each role |
createFeedsBatch
Simultaneously create multiple feeds with a single request. This method is ideal for initializing multiple content streams efficiently.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Create multiple feeds at once
var response = feedsClient.createFeedsBatch(
new CreateFeedsBatchRequest()
.setFeeds(List.of("user:john", "timeline:global"))
.setEnrichOwnFields(false)
).execute();
System.out.println(response);
}
}Response: CreateFeedsBatchResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| feeds | []FeedRequest | Yes | List of feeds to create |
| enrich_own_fields | Boolean | No | If true, enriches the created feeds with own_* fields (own_follows, own_followings, own_capabilit... |
deleteFeedsBatch
Remove multiple feeds in one operation. Use this method to streamline the cleanup process by deleting several feeds at once.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Delete multiple feeds
var response = feedsClient.deleteFeedsBatch(
new DeleteFeedsBatchRequest()
.setFeeds(List.of("user:john", "timeline:global"))
.setHardDelete(false)
).execute();
System.out.println(response);
}
}Response: DeleteFeedsBatchResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| feeds | []string | Yes | List of fully qualified feed IDs (format: group_id:feed_id) to delete |
| hard_delete | Boolean | No | Whether to permanently delete the feeds instead of soft delete |
ownBatch
Retrieve ownership details for multiple feeds. This is useful for managing or auditing which feeds you or your organization control.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Get own fields for multiple feeds
var response = feedsClient.ownBatch(
new OwnBatchRequest()
.setFeeds(List.of("user:john", "timeline:global"))
.setUserID("john")
.setUser(new UserRequest().setID("activity-123").setCustom(Map.of()))
).execute();
System.out.println(response);
}
}Example: with fields
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Get own fields for multiple feeds
var response = feedsClient.ownBatch(
new OwnBatchRequest()
.setFeeds(List.of("user:john", "timeline:global"))
.setFields(List.of())
).execute();
System.out.println(response);
}
}Response: OwnBatchResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| feeds | []string | Yes | List of feed IDs to get own fields for |
| fields | []string | No | Optional list of specific fields to return. If not specified, all fields (own_follows, own_follow... |
| user | UserRequest | No | - |
| user_id | String | No | - |
queryFeeds
Search and filter feeds based on specific criteria. Use this method to efficiently locate feeds that match your interests or requirements.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Query feeds
var response = feedsClient.queryFeeds(
new QueryFeedsRequest()
.setLimit(25)
.setFilter(Map.of())
.setSort(List.of())
).execute();
System.out.println(response);
}
}Example: with next and prev
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Query feeds
var response = feedsClient.queryFeeds(
new QueryFeedsRequest()
.setNext(null)
.setPrev(null)
).execute();
System.out.println(response);
}
}Example: with enrich_own_fields and watch
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Query feeds
var response = feedsClient.queryFeeds(
new QueryFeedsRequest()
.setEnrichOwnFields(false)
.setWatch(false)
).execute();
System.out.println(response);
}
}Response: QueryFeedsResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| enrich_own_fields | Boolean | No | - |
| filter | Map<String, Object> | No | Filters to apply to the query |
| limit | Integer | No | - |
| next | String | No | - |
| prev | String | No | - |
| sort | []SortParamRequest | No | Sorting parameters for the query |
| watch | Boolean | No | Whether to subscribe to realtime updates |
getFeedsRateLimits
Check the rate limits associated with feed operations. This method helps you understand the frequency restrictions on feed interactions to avoid exceeding usage quotas.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Get Feeds Rate Limits
var response = feedsClient.getFeedsRateLimits(
new GetFeedsRateLimitsRequest()
.setEndpoints("value")
.setAndroid(false)
.setIos(false)
).execute();
System.out.println(response);
}
}Example: with web and server_side
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Get Feeds Rate Limits
var response = feedsClient.getFeedsRateLimits(
new GetFeedsRateLimitsRequest()
.setWeb(false)
.setServerSide(false)
).execute();
System.out.println(response);
}
}Response: GetFeedsRateLimitsResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| endpoints | String | No | - |
| android | Boolean | No | - |
| ios | Boolean | No | - |
| web | Boolean | No | - |
| server_side | Boolean | No | - |
follow
Establish a follow relationship with a feed, allowing you to receive updates or notifications about its content. Use this to stay informed about specific topics or creators.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Create a follow
var response = feedsClient.follow(
new FollowRequest()
.setSource("user:john")
.setTarget("timeline:jane")
.setSkipPush(false)
.setCopyCustomToNotification(false)
).execute();
System.out.println(response);
}
}Example: with create_notification_activity and create_users
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Create a follow
var response = feedsClient.follow(
new FollowRequest()
.setSource("user:john")
.setTarget("timeline:jane")
.setCreateNotificationActivity(false)
.setCreateUsers(false)
).execute();
System.out.println(response);
}
}Example: with custom and enrich_own_fields
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Create a follow
var response = feedsClient.follow(
new FollowRequest()
.setSource("user:john")
.setTarget("timeline:jane")
.setCustom(Map.of())
.setEnrichOwnFields(false)
).execute();
System.out.println(response);
}
}Example: with push_preference and activity_copy_limit
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Create a follow
var response = feedsClient.follow(
new FollowRequest()
.setSource("user:john")
.setTarget("timeline:jane")
.setPushPreference("value")
.setActivityCopyLimit(10)
).execute();
System.out.println(response);
}
}Response: SingleFollowResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| source | String | Yes | Fully qualified ID of the source feed |
| target | String | Yes | Fully qualified ID of the target feed |
| activity_copy_limit | Integer | No | Maximum number of historical activities to copy from the target feed when the follow is first mat... |
| copy_custom_to_notification | Boolean | No | Whether to copy custom data to the notification activity (only applies when create_notification_a... |
| create_notification_activity | Boolean | No | Whether to create a notification activity for this follow |
| create_users | Boolean | No | If true, auto-creates users referenced by the source and target FIDs when they don't already exis... |
| custom | Map<String, Object> | No | Custom data for the follow relationship |
| enrich_own_fields | Boolean | No | If true, enriches the follow's source_feed and target_feed with own_* fields (own_follows, own_fo... |
| push_preference | String | No | Push preference for the follow relationship |
| skip_push | Boolean | No | Whether to skip push for this follow |
| status | String | No | Status of the follow relationship. One of: accepted, pending, rejected |
updateFollow
Modify an existing follow relationship. This method can be used to change your notification preferences or unfollow a feed when it is no longer relevant.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Update a follow
var response = feedsClient.updateFollow(
new UpdateFollowRequest()
.setSource("user:john")
.setTarget("timeline:jane")
.setSkipPush(false)
.setCopyCustomToNotification(false)
).execute();
System.out.println(response);
}
}Example: with create_notification_activity and create_users
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Update a follow
var response = feedsClient.updateFollow(
new UpdateFollowRequest()
.setSource("user:john")
.setTarget("timeline:jane")
.setCreateNotificationActivity(false)
.setCreateUsers(false)
).execute();
System.out.println(response);
}
}Example: with custom and enrich_own_fields
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Update a follow
var response = feedsClient.updateFollow(
new UpdateFollowRequest()
.setSource("user:john")
.setTarget("timeline:jane")
.setCustom(Map.of())
.setEnrichOwnFields(false)
).execute();
System.out.println(response);
}
}Example: with follower_role and push_preference
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Update a follow
var response = feedsClient.updateFollow(
new UpdateFollowRequest()
.setSource("user:john")
.setTarget("timeline:jane")
.setFollowerRole("member")
.setPushPreference("value")
).execute();
System.out.println(response);
}
}Response: UpdateFollowResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| source | String | Yes | Fully qualified ID of the source feed |
| target | String | Yes | Fully qualified ID of the target feed |
| activity_copy_limit | Integer | No | Maximum number of historical activities to copy from the target feed when the follow is first mat... |
| copy_custom_to_notification | Boolean | No | Whether to copy custom data to the notification activity (only applies when create_notification_a... |
| create_notification_activity | Boolean | No | Whether to create a notification activity for this follow |
| create_users | Boolean | No | If true, auto-creates users referenced by the source and target FIDs when they don't already exis... |
| custom | Map<String, Object> | No | Custom data for the follow relationship |
| enrich_own_fields | Boolean | No | If true, enriches the follow's source_feed and target_feed with own_* fields (own_follows, own_fo... |
| follower_role | String | No | - |
| push_preference | String | No | Push preference for the follow relationship |
| skip_push | Boolean | No | Whether to skip push for this follow |
| status | String | No | Status of the follow relationship. One of: accepted, pending, rejected |
acceptFollow
Approve a pending follow request to allow a user to follow your feed, useful for managing access in private or protected feeds.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Accept a follow request
var response = feedsClient.acceptFollow(
new AcceptFollowRequest()
.setSource("user:john")
.setTarget("timeline:jane")
.setFollowerRole("member")
).execute();
System.out.println(response);
}
}Response: AcceptFollowResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| source | String | Yes | Fully qualified ID of the source feed |
| target | String | Yes | Fully qualified ID of the target feed |
| follower_role | String | No | Optional role for the follower in the follow relationship |
followBatch
Add multiple followers to a feed simultaneously, ideal for quickly expanding your feed's audience.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Create multiple follows at once
var response = feedsClient.followBatch(
new FollowBatchRequest()
.setFollows(List.of())
.setCreateUsers(false)
.setEnrichOwnFields(false)
).execute();
System.out.println(response);
}
}Response: FollowBatchResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| follows | []FollowRequest | Yes | List of follow relationships to create |
| create_users | Boolean | No | If true, auto-creates users referenced by source/target FIDs in the batch when they don't already... |
| enrich_own_fields | Boolean | No | If true, enriches the follow's source_feed and target_feed with own_* fields (own_follows, own_fo... |
getOrCreateFollows
Ensure specified follows exist by either retrieving existing ones or creating them as needed, simplifying follow management.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Upsert multiple follows at once
var response = feedsClient.getOrCreateFollows(
new GetOrCreateFollowsRequest()
.setFollows(List.of())
.setCreateUsers(false)
.setEnrichOwnFields(false)
).execute();
System.out.println(response);
}
}Response: FollowBatchResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| follows | []FollowRequest | Yes | List of follow relationships to create |
| create_users | Boolean | No | If true, auto-creates users referenced by source/target FIDs in the batch when they don't already... |
| enrich_own_fields | Boolean | No | If true, enriches the follow's source_feed and target_feed with own_* fields (own_follows, own_fo... |
queryFollows
Retrieve a list of users who are following a specific feed, helping you analyze and manage your audience.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Query follows
var response = feedsClient.queryFollows(
new QueryFollowsRequest()
.setLimit(25)
.setFilter(Map.of())
.setSort(List.of())
).execute();
System.out.println(response);
}
}Example: with prev and next
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Query follows
var response = feedsClient.queryFollows(
new QueryFollowsRequest()
.setPrev(null)
.setNext(null)
).execute();
System.out.println(response);
}
}Response: QueryFollowsResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| filter | Map<String, Object> | No | Filters to apply to the query |
| limit | Integer | No | - |
| next | String | No | - |
| prev | String | No | - |
| sort | []SortParamRequest | No | Sorting parameters for the query |
rejectFollow
Deny a follow request to prevent a user from following your feed, useful for maintaining privacy or exclusivity.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Reject a follow request
var response = feedsClient.rejectFollow(
new RejectFollowRequest()
.setSource("user:john")
.setTarget("timeline:jane")
).execute();
System.out.println(response);
}
}Response: RejectFollowResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| source | String | Yes | Fully qualified ID of the source feed |
| target | String | Yes | Fully qualified ID of the target feed |
unfollow
Remove a user from following a feed, helpful for managing your feed's audience or curating content access.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Unfollow a feed
var response = feedsClient.unfollow(
"user:john",
"timeline:jane",
new UnfollowRequest()
.setDeleteNotificationActivity(false)
.setKeepHistory(false)
).execute();
System.out.println(response);
}
}Example: with enrich_own_fields
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Unfollow a feed
var response = feedsClient.unfollow(
"user:john",
"timeline:jane",
new UnfollowRequest()
.setEnrichOwnFields(false)
).execute();
System.out.println(response);
}
}Response: UnfollowResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| source | String | Yes | - |
| target | String | Yes | - |
| delete_notification_activity | Boolean | No | - |
| keep_history | Boolean | No | - |
| enrich_own_fields | Boolean | No | - |
createMembershipLevel
Establish a new membership tier with specific benefits or access rights, allowing for tailored user engagement strategies.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Create membership level
var response = feedsClient.createMembershipLevel(
new CreateMembershipLevelRequest()
.setID("activity-123")
.setName("My Feed")
.setCustom(Map.of())
.setDescription("A description")
).execute();
System.out.println(response);
}
}Example: with priority and tags
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Create membership level
var response = feedsClient.createMembershipLevel(
new CreateMembershipLevelRequest()
.setID("activity-123")
.setName("My Feed")
.setPriority(1)
.setTags(List.of("tag1", "tag2"))
).execute();
System.out.println(response);
}
}Response: CreateMembershipLevelResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| id | String | Yes | Unique identifier for the membership level |
| name | String | Yes | Display name for the membership level |
| custom | Map<String, Object> | No | Custom data for the membership level |
| description | String | No | Optional description of the membership level |
| priority | Integer | No | Priority level (higher numbers = higher priority) |
| tags | []string | No | Activity tags this membership level gives access to |
queryMembershipLevels
Retrieve existing membership levels to review or assess the tiers available for users, aiding in membership management.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Query membership levels
var response = feedsClient.queryMembershipLevels(
new QueryMembershipLevelsRequest()
.setLimit(25)
.setFilter(Map.of())
.setSort(List.of())
).execute();
System.out.println(response);
}
}Example: with prev and next
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Query membership levels
var response = feedsClient.queryMembershipLevels(
new QueryMembershipLevelsRequest()
.setPrev(null)
.setNext(null)
).execute();
System.out.println(response);
}
}Response: QueryMembershipLevelsResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| filter | Map<String, Object> | No | Filters to apply to the query |
| limit | Integer | No | - |
| next | String | No | - |
| prev | String | No | - |
| sort | []SortParamRequest | No | Sorting parameters for the query |
updateMembershipLevel
Modify an existing membership tier to adjust benefits or access rights, supporting dynamic content or service offerings.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Update membership level
var response = feedsClient.updateMembershipLevel(
"activity-123",
new UpdateMembershipLevelRequest()
.setName("My Feed")
.setDescription("A description")
).execute();
System.out.println(response);
}
}Example: with custom and priority
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Update membership level
var response = feedsClient.updateMembershipLevel(
"activity-123",
new UpdateMembershipLevelRequest()
.setCustom(Map.of())
.setPriority(1)
).execute();
System.out.println(response);
}
}Example: with tags
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Update membership level
var response = feedsClient.updateMembershipLevel(
"activity-123",
new UpdateMembershipLevelRequest()
.setTags(List.of("tag1", "tag2"))
).execute();
System.out.println(response);
}
}Response: UpdateMembershipLevelResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| id | String | Yes | - |
| custom | Map<String, Object> | No | Custom data for the membership level |
| description | String | No | Optional description of the membership level |
| name | String | No | Display name for the membership level |
| priority | Integer | No | Priority level (higher numbers = higher priority) |
| tags | []string | No | Activity tags this membership level gives access to |
deleteMembershipLevel
Remove a membership level when it's no longer needed, streamlining your membership structure and offerings.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Delete membership level
var response = feedsClient.deleteMembershipLevel(
"activity-123"
).execute();
System.out.println(response);
}
}Response: Response
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| id | String | Yes | - |
queryFeedsUsageStats
Retrieve comprehensive usage statistics for a specific feed, helping you analyze engagement and performance trends over time.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Query Feed Usage Statistics
var response = feedsClient.queryFeedsUsageStats(
new QueryFeedsUsageStatsRequest()
.setFrom("value")
.setTo("value")
).execute();
System.out.println(response);
}
}Response: QueryFeedsUsageStatsResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| from | String | No | Start date in YYYY-MM-DD format (optional, defaults to 30 days ago) |
| to | String | No | End date in YYYY-MM-DD format (optional, defaults to today) |
unfollowBatch
Efficiently unfollow multiple feeds in a single operation, ideal for streamlining feed management when you no longer wish to receive updates from several sources.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Unfollow multiple feeds at once
var response = feedsClient.unfollowBatch(
new UnfollowBatchRequest()
.setFollows(List.of())
.setDeleteNotificationActivity(false)
.setEnrichOwnFields(false)
).execute();
System.out.println(response);
}
}Response: UnfollowBatchResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| follows | []UnfollowPair | Yes | List of follow relationships to remove, each with optional keep_history |
| delete_notification_activity | Boolean | No | Whether to delete the corresponding notification activity (default: false) |
| enrich_own_fields | Boolean | No | If true, enriches the follow's source_feed and target_feed with own_* fields (own_follows, own_fo... |
getOrCreateUnfollows
Ensure feeds are unfollowed without duplication by using an idempotent operation that simplifies management when transitioning away from specific content sources.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Unfollow multiple feeds (idempotent)
var response = feedsClient.getOrCreateUnfollows(
new GetOrCreateUnfollowsRequest()
.setFollows(List.of())
.setDeleteNotificationActivity(false)
.setEnrichOwnFields(false)
).execute();
System.out.println(response);
}
}Response: UnfollowBatchResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| follows | []UnfollowPair | Yes | List of follow relationships to remove, each with optional keep_history |
| delete_notification_activity | Boolean | No | Whether to delete the corresponding notification activity (default: false) |
| enrich_own_fields | Boolean | No | If true, enriches the follow's source_feed and target_feed with own_* fields (own_follows, own_fo... |
deleteFeedUserData
Permanently remove all data associated with a user's feed, useful for maintaining privacy and complying with data protection regulations when users request data deletion.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Delete all feed data for a user
var response = feedsClient.deleteFeedUserData(
"john",
new DeleteFeedUserDataRequest()
.setHardDelete(false)
).execute();
System.out.println(response);
}
}Response: DeleteFeedUserDataResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| user_id | String | Yes | - |
| hard_delete | Boolean | No | Whether to perform a hard delete instead of a soft delete |
exportFeedUserData
Download a complete set of a user's feed data, allowing for backup, analysis, or migration to other systems while ensuring data portability.
Example
import io.getstream.services.FeedsImpl;
import io.getstream.services.framework.StreamHTTPClient;
import io.getstream.models.*;
import io.getstream.models.framework.StreamResponse;
public class Example {
public static void main(String[] args) throws Exception {
StreamHTTPClient httpClient = new StreamHTTPClient(apiKey, apiSecret);
FeedsImpl feedsClient = new FeedsImpl(httpClient);
// Export all feed data for a user
var response = feedsClient.exportFeedUserData(
"john"
).execute();
System.out.println(response);
}
}Response: ExportFeedUserDataResponse
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| user_id | String | Yes | - |
Types Reference
This section documents the types/interfaces used in this API. These types are extracted from the OpenAPI specification.
AcceptFeedMemberInviteResponse
public class AcceptFeedMemberInviteResponse {
private String duration;
private FeedMemberResponse member;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | |
| member | FeedMemberResponse | Yes | The feed member after accepting the invite |
AcceptFollowResponse
public class AcceptFollowResponse {
private String duration;
private FollowResponse follow;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | |
| follow | FollowResponse | Yes | The accepted follow relationship |
Action
public class Action {
private String name;
private String style;
private String text;
private String type;
private String value;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| name | String | Yes | |
| text | String | Yes | |
| type | String | Yes | |
| style | String | No | |
| value | String | No |
ActivityFeedbackResponse
Response for activity feedback submission
public class ActivityFeedbackResponse {
private String activity_id;
private String duration;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| activity_id | String | Yes | The ID of the activity that received feedback |
| duration | String | Yes |
ActivityPinResponse
public class ActivityPinResponse {
private ActivityResponse activity;
private Double created_at;
private String feed;
private Double updated_at;
private UserResponse user;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| activity | ActivityResponse | Yes | The pinned activity |
| created_at | Double | Yes | When the pin was created |
| feed | String | Yes | ID of the feed where activity is pinned |
| updated_at | Double | Yes | When the pin was last updated |
| user | UserResponse | Yes | User who pinned the activity |
ActivityProcessorConfig
public class ActivityProcessorConfig {
private String type;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| type | String | Yes | Type of activity processor (required) |
ActivityRequest
public class ActivityRequest {
private List<Attachment> attachments;
private List<String> collection_refs;
private Boolean copy_custom_to_notification;
private Boolean create_notification_activity;
private Map<String, Object> custom;
private String expires_at;
private List<String> feeds;
private List<String> filter_tags;
private String id;
private List<String> interest_tags;
private Location location;
private List<String> mentioned_user_ids;
private String parent_id;
private String poll_id;
private String restrict_replies;
private Map<String, Object> search_data;
private Boolean skip_enrich_url;
private Boolean skip_push;
private String text;
private String type;
private String user_id;
private String visibility;
private String visibility_tag;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| feeds | List<String> | Yes | List of feeds to add the activity to with a default max limit of 25 feeds |
| type | String | Yes | Type of activity |
| attachments | List<Attachment> | No | List of attachments for the activity |
| collection_refs | List<String> | No | Collections that this activity references |
| copy_custom_to_notification | Boolean | No | Whether to copy custom data to the notification activity (only applies when c... |
| create_notification_activity | Boolean | No | Whether to create notification activities for mentioned users |
| custom | Map<String, Object> | No | Custom data for the activity |
| expires_at | String | No | Expiration time for the activity |
| filter_tags | List<String> | No | Tags for filtering activities |
| id | String | No | Optional ID for the activity |
| interest_tags | List<String> | No | Tags for indicating user interests |
| location | Location | No | Geographic location related to the activity |
| mentioned_user_ids | List<String> | No | List of users mentioned in the activity |
| parent_id | String | No | ID of parent activity for replies/comments |
| poll_id | String | No | ID of a poll to attach to activity |
| restrict_replies | String | No | Controls who can add comments/replies to this activity. One of: everyone, peo... |
| search_data | Map<String, Object> | No | Additional data for search indexing |
| skip_enrich_url | Boolean | No | Whether to skip URL enrichment for the activity |
| skip_push | Boolean | No | Whether to skip push notifications |
| text | String | No | Text content of the activity |
| user_id | String | No | ID of the user creating the activity |
| visibility | String | No | Visibility setting for the activity. One of: public, private, tag |
| visibility_tag | String | No | If visibility is 'tag', this is the tag name and is required |
ActivityResponse
public class ActivityResponse {
private List<Attachment> attachments;
private Integer bookmark_count;
private Map<String, Object> collections;
private Integer comment_count;
private List<CommentResponse> comments;
private Double created_at;
private FeedResponse current_feed;
private Map<String, Object> custom;
private Double deleted_at;
private Double edited_at;
private Double expires_at;
private List<String> feeds;
private List<String> filter_tags;
private Integer friend_reaction_count;
private List<FeedsReactionResponse> friend_reactions;
private Boolean hidden;
private String id;
private List<String> interest_tags;
private Boolean is_read;
private Boolean is_seen;
private Boolean is_watched;
private List<FeedsReactionResponse> latest_reactions;
private Location location;
private List<UserResponse> mentioned_users;
private Map<String, Object> metrics;
private ModerationV2Response moderation;
private String moderation_action;
private NotificationContext notification_context;
private List<BookmarkResponse> own_bookmarks;
private List<FeedsReactionResponse> own_reactions;
private ActivityResponse parent;
private PollResponseData poll;
private Integer popularity;
private Boolean preview;
private Integer reaction_count;
private Map<String, Object> reaction_groups;
private String restrict_replies;
private Double score;
private Map<String, Object> score_vars;
private Map<String, Object> search_data;
private String selector_source;
private Integer share_count;
private String text;
private String type;
private Double updated_at;
private UserResponse user;
private String visibility;
private String visibility_tag;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| attachments | List<Attachment> | Yes | Media attachments for the activity |
| bookmark_count | Integer | Yes | Number of bookmarks on the activity |
| collections | Map<String, Object> | Yes | Enriched collection data referenced by this activity |
| comment_count | Integer | Yes | Number of comments on the activity |
| comments | List<CommentResponse> | Yes | Latest 5 comments of this activity (comment replies excluded) |
| created_at | Double | Yes | When the activity was created |
| custom | Map<String, Object> | Yes | Custom data for the activity |
| feeds | List<String> | Yes | List of feed IDs containing this activity |
| filter_tags | List<String> | Yes | Tags for filtering |
| hidden | Boolean | Yes | If this activity is hidden by this user (using activity feedback) |
| id | String | Yes | Unique identifier for the activity |
| interest_tags | List<String> | Yes | Tags for user interests |
| latest_reactions | List<FeedsReactionResponse> | Yes | Recent reactions to the activity |
| mentioned_users | List<UserResponse> | Yes | Users mentioned in the activity |
| own_bookmarks | List<BookmarkResponse> | Yes | Current user's bookmarks for this activity |
| own_reactions | List<FeedsReactionResponse> | Yes | Current user's reactions to this activity |
| popularity | Integer | Yes | Popularity score of the activity |
| preview | Boolean | Yes | If this activity is obfuscated for this user. For premium content where you w... |
| reaction_count | Integer | Yes | Number of reactions to the activity |
| reaction_groups | Map<String, Object> | Yes | Grouped reactions by type |
| restrict_replies | String | Yes | Controls who can add comments/replies to this activity. One of: everyone, peo... |
| score | Double | Yes | Ranking score for this activity |
| search_data | Map<String, Object> | Yes | Data for search indexing |
| share_count | Integer | Yes | Number of times the activity was shared |
| type | String | Yes | Type of activity |
| updated_at | Double | Yes | When the activity was last updated |
| user | UserResponse | Yes | User who created the activity |
| visibility | String | Yes | Visibility setting for the activity. One of: public, private, tag |
| current_feed | FeedResponse | No | Feed context for this activity view. If an activity is added only to one feed... |
| deleted_at | Double | No | When the activity was deleted |
| edited_at | Double | No | When the activity was last edited |
| expires_at | Double | No | When the activity will expire |
| friend_reaction_count | Integer | No | Total count of reactions from friends on this activity |
| friend_reactions | List<FeedsReactionResponse> | No | Reactions from users the current user follows or has mutual follows with |
| is_read | Boolean | No | Whether this activity has been read. Only set for feed groups with notificati... |
| is_seen | Boolean | No | Whether this activity has been seen. Only set for feed groups with notificati... |
| is_watched | Boolean | No | |
| location | Location | No | Geographic location related to the activity |
| metrics | Map<String, Object> | No | |
| moderation | ModerationV2Response | No | Moderation information |
| moderation_action | String | No | |
| notification_context | NotificationContext | No | Notification context data for the activity (if this is a reaction, comment, f... |
| parent | ActivityResponse | No | Parent activity (if this is a reply/comment) |
| poll | PollResponseData | No | Poll attached to this activity |
| score_vars | Map<String, Object> | No | Variable values used at ranking time. Only included when include_score_vars i... |
| selector_source | String | No | Which activity selector provided this activity (e.g., 'following', 'popular',... |
| text | String | No | Text content of the activity |
| visibility_tag | String | No | If visibility is 'tag', this is the tag name |
ActivitySelectorConfig
public class ActivitySelectorConfig {
private String cutoff_time;
private String cutoff_window;
private Map<String, Object> filter;
private Integer min_popularity;
private Map<String, Object> params;
private List<SortParamRequest> sort;
private String type;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| type | String | Yes | Type of selector. One of: popular, proximity, following, current_feed, query,... |
| cutoff_time | String | No | Time threshold for activity selection (string). Expected RFC3339 format (e.g.... |
| cutoff_window | String | No | Flexible relative time window for activity selection (e.g., '1h', '3d', '1y')... |
| filter | Map<String, Object> | No | Filter for activity selection |
| min_popularity | Integer | No | Minimum popularity threshold |
| params | Map<String, Object> | No | |
| sort | List<SortParamRequest> | No | Sort parameters for activity selection |
AddActivityResponse
public class AddActivityResponse {
private ActivityResponse activity;
private String duration;
private Integer mention_notifications_created;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| activity | ActivityResponse | Yes | The created activity |
| duration | String | Yes | |
| mention_notifications_created | Integer | No | Number of mention notification activities created for mentioned users |
AddBookmarkResponse
public class AddBookmarkResponse {
private BookmarkResponse bookmark;
private String duration;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| bookmark | BookmarkResponse | Yes | The created bookmark |
| duration | String | Yes |
AddCommentBookmarkResponse
public class AddCommentBookmarkResponse {
private BookmarkResponse bookmark;
private String duration;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| bookmark | BookmarkResponse | Yes | The created comment bookmark |
| duration | String | Yes |
AddCommentReactionResponse
public class AddCommentReactionResponse {
private CommentResponse comment;
private String duration;
private Boolean notification_created;
private FeedsReactionResponse reaction;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| comment | CommentResponse | Yes | The comment the reaction was added to |
| duration | String | Yes | Duration of the request |
| reaction | FeedsReactionResponse | Yes | The created or updated reaction |
| notification_created | Boolean | No | Whether a notification activity was successfully created |
AddCommentRequest
public class AddCommentRequest {
private List<Attachment> attachments;
private String comment;
private Boolean copy_custom_to_notification;
private Boolean create_notification_activity;
private Map<String, Object> custom;
private Boolean force_moderation;
private String id;
private List<String> mentioned_user_ids;
private String object_id;
private String object_type;
private String parent_id;
private Boolean skip_enrich_url;
private Boolean skip_push;
private UserRequest user;
private String user_id;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| attachments | List<Attachment> | No | Media attachments for the reply |
| comment | String | No | Text content of the comment |
| copy_custom_to_notification | Boolean | No | Whether to copy custom data to the notification activity (only applies when c... |
| create_notification_activity | Boolean | No | Whether to create a notification activity for this comment |
| custom | Map<String, Object> | No | Custom data for the comment |
| force_moderation | Boolean | No | If true, forces moderation to run for server-side requests. By default, serve... |
| id | String | No | Optional custom ID for the comment (max 255 characters). If not provided, a U... |
| mentioned_user_ids | List<String> | No | List of users mentioned in the reply |
| object_id | String | No | ID of the object to comment on. Required for root comments |
| object_type | String | No | Type of the object to comment on. Required for root comments |
| parent_id | String | No | ID of parent comment for replies. When provided, object_id and object_type ar... |
| skip_enrich_url | Boolean | No | Whether to skip URL enrichment for this comment |
| skip_push | Boolean | No | |
| user | UserRequest | No | |
| user_id | String | No |
AddCommentResponse
public class AddCommentResponse {
private CommentResponse comment;
private String duration;
private Integer mention_notifications_created;
private Boolean notification_created;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| comment | CommentResponse | Yes | The created comment |
| duration | String | Yes | |
| mention_notifications_created | Integer | No | Number of mention notification activities created for mentioned users |
| notification_created | Boolean | No | Whether a notification activity was successfully created |
AddCommentsBatchResponse
public class AddCommentsBatchResponse {
private List<CommentResponse> comments;
private String duration;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| comments | List<CommentResponse> | Yes | List of comments added |
| duration | String | Yes |
AddFolderRequest
public class AddFolderRequest {
private Map<String, Object> custom;
private String name;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| name | String | Yes | Name of the folder |
| custom | Map<String, Object> | No | Custom data for the folder |
AddReactionResponse
public class AddReactionResponse {
private ActivityResponse activity;
private String duration;
private Boolean notification_created;
private FeedsReactionResponse reaction;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| activity | ActivityResponse | Yes | |
| duration | String | Yes | |
| reaction | FeedsReactionResponse | Yes | The created reaction |
| notification_created | Boolean | No | Whether a notification activity was successfully created |
AggregatedActivityResponse
public class AggregatedActivityResponse {
private List<ActivityResponse> activities;
private Integer activity_count;
private Double created_at;
private String group;
private Boolean is_read;
private Boolean is_seen;
private Boolean is_watched;
private Double score;
private Double updated_at;
private Integer user_count;
private Boolean user_count_truncated;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| activities | List<ActivityResponse> | Yes | List of activities in this aggregation |
| activity_count | Integer | Yes | Number of activities in this aggregation |
| created_at | Double | Yes | When the aggregation was created |
| group | String | Yes | Grouping identifier |
| score | Double | Yes | Ranking score for this aggregation |
| updated_at | Double | Yes | When the aggregation was last updated |
| user_count | Integer | Yes | Number of unique users in this aggregation |
| user_count_truncated | Boolean | Yes | Whether this activity group has been truncated due to exceeding the group siz... |
| is_read | Boolean | No | Whether this aggregated group has been read. Only set for feed groups with no... |
| is_seen | Boolean | No | Whether this aggregated group has been seen. Only set for feed groups with no... |
| is_watched | Boolean | No |
AggregationConfig
public class AggregationConfig {
private String activities_sort;
private String format;
private String score_strategy;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| activities_sort | String | No | Order of member activities inside each aggregated group for non-stories feeds... |
| format | String | No | Format for activity aggregation |
| score_strategy | String | No | Strategy for computing aggregated group scores from member activity scores wh... |
Attachment
An attachment is a message object that represents a file uploaded by a user.
public class Attachment {
private List<Action> actions;
private String asset_url;
private String author_icon;
private String author_link;
private String author_name;
private String color;
private Map<String, Object> custom;
private String fallback;
private List<Field> fields;
private String footer;
private String footer_icon;
private Images giphy;
private String image_url;
private String og_scrape_url;
private Integer original_height;
private Integer original_width;
private String pretext;
private String text;
private String thumb_url;
private String title;
private String title_link;
private String type;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| custom | Map<String, Object> | Yes | |
| actions | List<Action> | No | |
| asset_url | String | No | |
| author_icon | String | No | |
| author_link | String | No | |
| author_name | String | No | |
| color | String | No | |
| fallback | String | No | |
| fields | List<Field> | No | |
| footer | String | No | |
| footer_icon | String | No | |
| giphy | Images | No | |
| image_url | String | No | |
| og_scrape_url | String | No | |
| original_height | Integer | No | |
| original_width | Integer | No | |
| pretext | String | No | |
| text | String | No | |
| thumb_url | String | No | |
| title | String | No | |
| title_link | String | No | |
| type | String | No | Attachment type (e.g. image, video, url) |
BookmarkFolderResponse
public class BookmarkFolderResponse {
private Double created_at;
private Map<String, Object> custom;
private String id;
private String name;
private Double updated_at;
private UserResponse user;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| created_at | Double | Yes | When the folder was created |
| id | String | Yes | Unique identifier for the folder |
| name | String | Yes | Name of the folder |
| updated_at | Double | Yes | When the folder was last updated |
| user | UserResponse | Yes | User who created the folder |
| custom | Map<String, Object> | No | Custom data for the folder |
BookmarkResponse
public class BookmarkResponse {
private ActivityResponse activity;
private String activity_id;
private CommentResponse comment;
private Double created_at;
private Map<String, Object> custom;
private BookmarkFolderResponse folder;
private String object_id;
private String object_type;
private Double updated_at;
private UserResponse user;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| activity | ActivityResponse | Yes | The bookmarked activity (set when object_type is activity) |
| created_at | Double | Yes | When the bookmark was created |
| object_id | String | Yes | ID of the bookmarked object |
| object_type | String | Yes | Type of the bookmarked object (activity or comment) |
| updated_at | Double | Yes | When the bookmark was last updated |
| user | UserResponse | Yes | User who created the bookmark |
| activity_id | String | No | |
| comment | CommentResponse | No | The bookmarked comment (set when object_type is comment) |
| custom | Map<String, Object> | No | Custom data for the bookmark |
| folder | BookmarkFolderResponse | No | Folder containing this bookmark |
CollectionRequest
public class CollectionRequest {
private Map<String, Object> custom;
private String id;
private String name;
private String user_id;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| custom | Map<String, Object> | Yes | Custom data for the collection (required, must contain at least one key) |
| name | String | Yes | Name/type of the collection |
| id | String | No | Unique identifier for the collection within its name (optional, will be auto-... |
| user_id | String | No | ID of the user who owns this collection |
CollectionResponse
public class CollectionResponse {
private Double created_at;
private Map<String, Object> custom;
private String id;
private String name;
private Double updated_at;
private String user_id;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| id | String | Yes | Unique identifier for the collection within its name |
| name | String | Yes | Name/type of the collection |
| created_at | Double | No | When the collection was created |
| custom | Map<String, Object> | No | Custom data for the collection |
| updated_at | Double | No | When the collection was last updated |
| user_id | String | No | ID of the user who owns this collection |
CommentResponse
public class CommentResponse {
private List<Attachment> attachments;
private Integer bookmark_count;
private Double confidence_score;
private Double controversy_score;
private Double created_at;
private Map<String, Object> custom;
private Double deleted_at;
private Integer downvote_count;
private Double edited_at;
private String id;
private List<FeedsReactionResponse> latest_reactions;
private List<UserResponse> mentioned_users;
private ModerationV2Response moderation;
private String object_id;
private String object_type;
private List<FeedsReactionResponse> own_reactions;
private String parent_id;
private Integer reaction_count;
private Map<String, Object> reaction_groups;
private Integer reply_count;
private Integer score;
private String status;
private String text;
private Double updated_at;
private Integer upvote_count;
private UserResponse user;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| bookmark_count | Integer | Yes | |
| confidence_score | Double | Yes | Confidence score of the comment |
| created_at | Double | Yes | When the comment was created |
| downvote_count | Integer | Yes | Number of downvotes for this comment |
| id | String | Yes | Unique identifier for the comment |
| mentioned_users | List<UserResponse> | Yes | Users mentioned in the comment |
| object_id | String | Yes | ID of the object this comment is associated with |
| object_type | String | Yes | Type of the object this comment is associated with |
| own_reactions | List<FeedsReactionResponse> | Yes | Current user's reactions to this activity |
| reaction_count | Integer | Yes | Number of reactions to this comment |
| reply_count | Integer | Yes | Number of replies to this comment |
| score | Integer | Yes | Score of the comment based on reactions |
| status | String | Yes | Status of the comment. One of: active, deleted, removed, hidden |
| updated_at | Double | Yes | When the comment was last updated |
| upvote_count | Integer | Yes | Number of upvotes for this comment |
| user | UserResponse | Yes | User who created the comment |
| attachments | List<Attachment> | No | Attachments associated with the comment |
| controversy_score | Double | No | Controversy score of the comment |
| custom | Map<String, Object> | No | Custom data for the comment |
| deleted_at | Double | No | When the comment was deleted |
| edited_at | Double | No | When the comment was last edited |
| latest_reactions | List<FeedsReactionResponse> | No | Recent reactions to the comment |
| moderation | ModerationV2Response | No | Moderation details for the comment |
| parent_id | String | No | ID of parent comment for nested replies |
| reaction_groups | Map<String, Object> | No | Grouped reactions by type |
| text | String | No | Text content of the comment |
CreateCollectionsResponse
public class CreateCollectionsResponse {
private List<CollectionResponse> collections;
private String duration;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| collections | List<CollectionResponse> | Yes | List of created collections |
| duration | String | Yes |
CreateFeedGroupResponse
public class CreateFeedGroupResponse {
private String duration;
private FeedGroupResponse feed_group;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | |
| feed_group | FeedGroupResponse | Yes | The upserted feed group |
CreateFeedViewResponse
public class CreateFeedViewResponse {
private String duration;
private FeedViewResponse feed_view;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | |
| feed_view | FeedViewResponse | Yes | The created feed view |
CreateFeedsBatchResponse
public class CreateFeedsBatchResponse {
private String duration;
private List<FeedResponse> feeds;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | |
| feeds | List<FeedResponse> | Yes | List of created feeds |
CreateMembershipLevelResponse
public class CreateMembershipLevelResponse {
private String duration;
private MembershipLevelResponse membership_level;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | |
| membership_level | MembershipLevelResponse | Yes | The created membership level |
DailyMetricStatsResponse
public class DailyMetricStatsResponse {
private List<DailyMetricResponse> daily;
private Integer total;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| daily | List<DailyMetricResponse> | Yes | Array of daily metric values |
| total | Integer | Yes | Total value across all days in the date range |
Data
public class Data {
private String id;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| id | String | Yes |
DeleteActivitiesResponse
public class DeleteActivitiesResponse {
private List<String> deleted_ids;
private String duration;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| deleted_ids | List<String> | Yes | List of activity IDs that were successfully deleted |
| duration | String | Yes |
DeleteActivityReactionResponse
public class DeleteActivityReactionResponse {
private ActivityResponse activity;
private String duration;
private FeedsReactionResponse reaction;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| activity | ActivityResponse | Yes | |
| duration | String | Yes | |
| reaction | FeedsReactionResponse | Yes |
DeleteActivityResponse
public class DeleteActivityResponse {
private String duration;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes |
DeleteBookmarkFolderResponse
public class DeleteBookmarkFolderResponse {
private String duration;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes |
DeleteBookmarkResponse
public class DeleteBookmarkResponse {
private BookmarkResponse bookmark;
private String duration;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| bookmark | BookmarkResponse | Yes | The deleted bookmark |
| duration | String | Yes |
DeleteCollectionsResponse
public class DeleteCollectionsResponse {
private String duration;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes |
DeleteCommentBookmarkResponse
public class DeleteCommentBookmarkResponse {
private BookmarkResponse bookmark;
private String duration;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| bookmark | BookmarkResponse | Yes | The deleted comment bookmark |
| duration | String | Yes |
DeleteCommentReactionResponse
public class DeleteCommentReactionResponse {
private CommentResponse comment;
private String duration;
private FeedsReactionResponse reaction;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| comment | CommentResponse | Yes | The comment after reaction removal |
| duration | String | Yes | |
| reaction | FeedsReactionResponse | Yes | The removed reaction |
DeleteCommentResponse
public class DeleteCommentResponse {
private ActivityResponse activity;
private CommentResponse comment;
private String duration;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| activity | ActivityResponse | Yes | The parent activity |
| comment | CommentResponse | Yes | The deleted comment |
| duration | String | Yes |
DeleteFeedGroupResponse
Basic response information
public class DeleteFeedGroupResponse {
private String duration;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | Duration of the request in milliseconds |
DeleteFeedResponse
public class DeleteFeedResponse {
private String duration;
private String task_id;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | |
| task_id | String | Yes | The ID of the async task that will handle feed cleanup and hard deletion |
DeleteFeedUserDataResponse
Response for deleting feed user data
public class DeleteFeedUserDataResponse {
private String duration;
private String task_id;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | |
| task_id | String | Yes | The task ID for the deletion task |
DeleteFeedViewResponse
public class DeleteFeedViewResponse {
private String duration;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes |
DeleteFeedsBatchResponse
public class DeleteFeedsBatchResponse {
private String duration;
private String task_id;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | |
| task_id | String | Yes | The ID of the async task that will handle feed cleanup and hard deletion |
EMAUStatsResponse
public class EMAUStatsResponse {
private List<DailyMetricResponse> daily;
private List<DailyMetricResponse> last_30_days;
private List<DailyMetricResponse> month_to_date;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| daily | List<DailyMetricResponse> | Yes | Per-day unique engaged user counts |
| last_30_days | List<DailyMetricResponse> | Yes | Rolling 30-day engaged user count snapshots |
| month_to_date | List<DailyMetricResponse> | Yes | Calendar month-to-date engaged user count snapshots |
EnrichmentOptions
Options to skip specific enrichments to improve performance. Default is false (enrichments are included). Setting a field to true skips that enrichment.
public class EnrichmentOptions {
private Boolean enrich_own_followings;
private Boolean include_score_vars;
private Boolean skip_activity;
private Boolean skip_activity_collections;
private Boolean skip_activity_comments;
private Boolean skip_activity_current_feed;
private Boolean skip_activity_mentioned_users;
private Boolean skip_activity_own_bookmarks;
private Boolean skip_activity_parents;
private Boolean skip_activity_poll;
private Boolean skip_activity_reactions;
private Boolean skip_activity_refresh_image_urls;
private Boolean skip_all;
private Boolean skip_feed_member_user;
private Boolean skip_followers;
private Boolean skip_following;
private Boolean skip_own_capabilities;
private Boolean skip_own_follows;
private Boolean skip_pins;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| enrich_own_followings | Boolean | No | Default: false. When true, includes fetching and enriching own_followings (fo... |
| include_score_vars | Boolean | No | Default: false. When true, includes score_vars in activity responses containi... |
| skip_activity | Boolean | No | Default: false. When true, skips all activity enrichments. |
| skip_activity_collections | Boolean | No | Default: false. When true, skips enriching collections on activities. |
| skip_activity_comments | Boolean | No | Default: false. When true, skips enriching comments on activities. |
| skip_activity_current_feed | Boolean | No | Default: false. When true, skips enriching current_feed on activities. Note: ... |
| skip_activity_mentioned_users | Boolean | No | Default: false. When true, skips enriching mentioned users on activities. |
| skip_activity_own_bookmarks | Boolean | No | Default: false. When true, skips enriching own bookmarks on activities. |
| skip_activity_parents | Boolean | No | Default: false. When true, skips enriching parent activities. |
| skip_activity_poll | Boolean | No | Default: false. When true, skips enriching poll data on activities. |
| skip_activity_reactions | Boolean | No | Default: false. When true, skips fetching and enriching latest and own reacti... |
| skip_activity_refresh_image_urls | Boolean | No | Default: false. When true, skips refreshing image URLs on activities. |
| skip_all | Boolean | No | Default: false. When true, skips all enrichments. |
| skip_feed_member_user | Boolean | No | Default: false. When true, skips enriching user data on feed members. |
| skip_followers | Boolean | No | Default: false. When true, skips fetching and enriching followers. Note: If f... |
| skip_following | Boolean | No | Default: false. When true, skips fetching and enriching following. Note: If f... |
| skip_own_capabilities | Boolean | No | Default: false. When true, skips computing and including capabilities for feeds. |
| skip_own_follows | Boolean | No | Default: false. When true, skips fetching and enriching own_follows (follows ... |
| skip_pins | Boolean | No | Default: false. When true, skips enriching pinned activities. |
ExportFeedUserDataResponse
Response for exporting feed user data
public class ExportFeedUserDataResponse {
private String duration;
private String task_id;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | |
| task_id | String | Yes | The task ID for the export task |
FeedGroupResponse
public class FeedGroupResponse {
private List<ActivityProcessorConfig> activity_processors;
private List<ActivitySelectorConfigResponse> activity_selectors;
private AggregationConfig aggregation;
private Double created_at;
private Map<String, Object> custom;
private String default_visibility;
private Double deleted_at;
private String id;
private NotificationConfig notification;
private PushNotificationConfig push_notification;
private RankingConfig ranking;
private StoriesConfig stories;
private Double updated_at;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| created_at | Double | Yes | When the feed group was created |
| id | String | Yes | Identifier within the group |
| updated_at | Double | Yes | When the feed group was last updated |
| activity_processors | List<ActivityProcessorConfig> | No | Configuration for activity processors |
| activity_selectors | List<ActivitySelectorConfigResponse> | No | Configuration for activity selectors |
| aggregation | AggregationConfig | No | Configuration for activity aggregation |
| custom | Map<String, Object> | No | Custom data for the feed group |
| default_visibility | String | No | Default visibility for activities. One of: public, visible, followers, member... |
| deleted_at | Double | No | |
| notification | NotificationConfig | No | Configuration for notifications |
| push_notification | PushNotificationConfig | No | Configuration for push notifications |
| ranking | RankingConfig | No | Configuration for activity ranking |
| stories | StoriesConfig | No | Configuration for stories feature |
FeedInput
public class FeedInput {
private Map<String, Object> custom;
private String description;
private List<String> filter_tags;
private Location location;
private List<FeedMemberRequest> members;
private String name;
private String visibility;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| custom | Map<String, Object> | No | |
| description | String | No | |
| filter_tags | List<String> | No | |
| location | Location | No | |
| members | List<FeedMemberRequest> | No | |
| name | String | No | |
| visibility | String | No |
FeedMemberRequest
public class FeedMemberRequest {
private Map<String, Object> custom;
private Boolean invite;
private String membership_level;
private String role;
private String user_id;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| user_id | String | Yes | ID of the user to add as a member |
| custom | Map<String, Object> | No | Custom data for the member |
| invite | Boolean | No | Whether this is an invite to become a member |
| membership_level | String | No | ID of the membership level to assign to the member |
| role | String | No | Role of the member in the feed |
FeedMemberResponse
public class FeedMemberResponse {
private Double created_at;
private Map<String, Object> custom;
private Double invite_accepted_at;
private Double invite_rejected_at;
private MembershipLevelResponse membership_level;
private String role;
private String status;
private Double updated_at;
private UserResponse user;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| created_at | Double | Yes | When the membership was created |
| role | String | Yes | Role of the member in the feed |
| status | String | Yes | Status of the membership. One of: member, pending, rejected |
| updated_at | Double | Yes | When the membership was last updated |
| user | UserResponse | Yes | User who is a member |
| custom | Map<String, Object> | No | Custom data for the membership |
| invite_accepted_at | Double | No | When the invite was accepted |
| invite_rejected_at | Double | No | When the invite was rejected |
| membership_level | MembershipLevelResponse | No | Membership level assigned to the member |
FeedRequest
public class FeedRequest {
private String created_by_id;
private Map<String, Object> custom;
private String description;
private String feed_group_id;
private String feed_id;
private List<String> filter_tags;
private Location location;
private List<FeedMemberRequest> members;
private String name;
private String visibility;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| feed_group_id | String | Yes | ID of the feed group |
| feed_id | String | Yes | ID of the feed |
| created_by_id | String | No | ID of the feed creator |
| custom | Map<String, Object> | No | Custom data for the feed |
| description | String | No | Description of the feed |
| filter_tags | List<String> | No | Tags used for filtering feeds |
| location | Location | No | Geographic location for the feed |
| members | List<FeedMemberRequest> | No | Initial members for the feed |
| name | String | No | Name of the feed |
| visibility | String | No | Visibility setting for the feed. One of: public, visible, followers, members,... |
FeedResponse
public class FeedResponse {
private Integer activity_count;
private Double created_at;
private UserResponse created_by;
private Map<String, Object> custom;
private Double deleted_at;
private String description;
private String feed;
private List<String> filter_tags;
private Integer follower_count;
private Integer following_count;
private String group_id;
private String id;
private Location location;
private Integer member_count;
private String name;
private List<FeedOwnCapability> own_capabilities;
private List<FollowResponse> own_followings;
private List<FollowResponse> own_follows;
private FeedMemberResponse own_membership;
private Integer pin_count;
private Double updated_at;
private String visibility;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| activity_count | Integer | Yes | |
| created_at | Double | Yes | When the feed was created |
| created_by | UserResponse | Yes | User who created the feed |
| description | String | Yes | Description of the feed |
| feed | String | Yes | Fully qualified feed ID (group_id:id) |
| follower_count | Integer | Yes | Number of followers of this feed |
| following_count | Integer | Yes | Number of feeds this feed follows |
| group_id | String | Yes | Group this feed belongs to |
| id | String | Yes | Unique identifier for the feed |
| member_count | Integer | Yes | Number of members in this feed |
| name | String | Yes | Name of the feed |
| pin_count | Integer | Yes | Number of pinned activities in this feed |
| updated_at | Double | Yes | When the feed was last updated |
| custom | Map<String, Object> | No | Custom data for the feed |
| deleted_at | Double | No | When the feed was deleted |
| filter_tags | List<String> | No | Tags used for filtering feeds |
| location | Location | No | Geographic location for the feed |
| own_capabilities | List<FeedOwnCapability> | No | Capabilities the current user has for this feed |
| own_followings | List<FollowResponse> | No | Follow relationships where the feed owner’s feeds are following the current... |
| own_follows | List<FollowResponse> | No | Follow relationships where the current user's feeds are following this feed |
| own_membership | FeedMemberResponse | No | Membership information for the current user in this feed |
| visibility | String | No | Visibility setting for the feed |
FeedSuggestionResponse
public class FeedSuggestionResponse {
private Integer activity_count;
private Map<String, Object> algorithm_scores;
private Double created_at;
private UserResponse created_by;
private Map<String, Object> custom;
private Double deleted_at;
private String description;
private String feed;
private List<String> filter_tags;
private Integer follower_count;
private Integer following_count;
private String group_id;
private String id;
private Location location;
private Integer member_count;
private String name;
private List<FeedOwnCapability> own_capabilities;
private List<FollowResponse> own_followings;
private List<FollowResponse> own_follows;
private FeedMemberResponse own_membership;
private Integer pin_count;
private String reason;
private Double recommendation_score;
private Double updated_at;
private String visibility;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| activity_count | Integer | Yes | |
| created_at | Double | Yes | When the feed was created |
| created_by | UserResponse | Yes | User who created the feed |
| description | String | Yes | Description of the feed |
| feed | String | Yes | Fully qualified feed ID (group_id:id) |
| follower_count | Integer | Yes | Number of followers of this feed |
| following_count | Integer | Yes | Number of feeds this feed follows |
| group_id | String | Yes | Group this feed belongs to |
| id | String | Yes | Unique identifier for the feed |
| member_count | Integer | Yes | Number of members in this feed |
| name | String | Yes | Name of the feed |
| pin_count | Integer | Yes | Number of pinned activities in this feed |
| updated_at | Double | Yes | When the feed was last updated |
| algorithm_scores | Map<String, Object> | No | |
| custom | Map<String, Object> | No | Custom data for the feed |
| deleted_at | Double | No | When the feed was deleted |
| filter_tags | List<String> | No | Tags used for filtering feeds |
| location | Location | No | Geographic location for the feed |
| own_capabilities | List<FeedOwnCapability> | No | Capabilities the current user has for this feed |
| own_followings | List<FollowResponse> | No | Follow relationships where the feed owner’s feeds are following the current... |
| own_follows | List<FollowResponse> | No | Follow relationships where the current user's feeds are following this feed |
| own_membership | FeedMemberResponse | No | Membership information for the current user in this feed |
| reason | String | No | |
| recommendation_score | Double | No | |
| visibility | String | No | Visibility setting for the feed |
FeedViewResponse
public class FeedViewResponse {
private List<ActivitySelectorConfigResponse> activity_selectors;
private AggregationConfig aggregation;
private String id;
private Double last_used_at;
private RankingConfig ranking;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| id | String | Yes | Unique identifier for the custom feed view |
| activity_selectors | List<ActivitySelectorConfigResponse> | No | Configured activity selectors |
| aggregation | AggregationConfig | No | Configuration for activity aggregation |
| last_used_at | Double | No | When the feed view was last used |
| ranking | RankingConfig | No | Configuration for activity ranking |
FeedVisibilityResponse
public class FeedVisibilityResponse {
private Map<String, Object> grants;
private String name;
private List<Permission> permissions;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| grants | Map<String, Object> | Yes | Permission grants for each role |
| name | String | Yes | Name of the feed visibility level |
| permissions | List<Permission> | Yes | List of permission policies |
FeedsReactionResponse
public class FeedsReactionResponse {
private String activity_id;
private String comment_id;
private Double created_at;
private Map<String, Object> custom;
private String type;
private Double updated_at;
private UserResponse user;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| activity_id | String | Yes | ID of the activity that was reacted to |
| created_at | Double | Yes | When the reaction was created |
| type | String | Yes | Type of reaction |
| updated_at | Double | Yes | When the reaction was last updated |
| user | UserResponse | Yes | User who created the reaction |
| comment_id | String | No | ID of the comment that was reacted to |
| custom | Map<String, Object> | No | Custom data for the reaction |
Field
public class Field {
private Boolean short;
private String title;
private String value;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| short | Boolean | Yes | |
| title | String | Yes | |
| value | String | Yes |
FollowBatchResponse
public class FollowBatchResponse {
private List<FollowResponse> created;
private String duration;
private List<FollowResponse> follows;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| created | List<FollowResponse> | Yes | List of newly created follow relationships |
| duration | String | Yes | |
| follows | List<FollowResponse> | Yes | List of current follow relationships |
FollowRequest
public class FollowRequest {
private Integer activity_copy_limit;
private Boolean copy_custom_to_notification;
private Boolean create_notification_activity;
private Boolean create_users;
private Map<String, Object> custom;
private Boolean enrich_own_fields;
private String push_preference;
private Boolean skip_push;
private String source;
private String status;
private String target;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| source | String | Yes | Fully qualified ID of the source feed |
| target | String | Yes | Fully qualified ID of the target feed |
| activity_copy_limit | Integer | No | Maximum number of historical activities to copy from the target feed when the... |
| copy_custom_to_notification | Boolean | No | Whether to copy custom data to the notification activity (only applies when c... |
| create_notification_activity | Boolean | No | Whether to create a notification activity for this follow |
| create_users | Boolean | No | If true, auto-creates users referenced by the source and target FIDs when the... |
| custom | Map<String, Object> | No | Custom data for the follow relationship |
| enrich_own_fields | Boolean | No | If true, enriches the follow's source_feed and target_feed with own_* fields ... |
| push_preference | String | No | Push preference for the follow relationship |
| skip_push | Boolean | No | Whether to skip push for this follow |
| status | String | No | Status of the follow relationship. One of: accepted, pending, rejected |
FollowResponse
public class FollowResponse {
private Double created_at;
private Map<String, Object> custom;
private String follower_role;
private String push_preference;
private Double request_accepted_at;
private Double request_rejected_at;
private FeedResponse source_feed;
private String status;
private FeedResponse target_feed;
private Double updated_at;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| created_at | Double | Yes | When the follow relationship was created |
| follower_role | String | Yes | Role of the follower (source user) in the follow relationship |
| push_preference | String | Yes | Push preference for notifications. One of: all, none |
| source_feed | FeedResponse | Yes | Source feed object |
| status | String | Yes | Status of the follow relationship. One of: accepted, pending, rejected |
| target_feed | FeedResponse | Yes | Target feed object |
| updated_at | Double | Yes | When the follow relationship was last updated |
| custom | Map<String, Object> | No | Custom data for the follow relationship |
| request_accepted_at | Double | No | When the follow request was accepted |
| request_rejected_at | Double | No | When the follow request was rejected |
FriendReactionsOptions
Options to control fetching reactions from friends (users you follow or have mutual follows with).
public class FriendReactionsOptions {
private Boolean enabled;
private Integer limit;
private String type;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| enabled | Boolean | No | Default: false. When true, fetches friend reactions for activities. |
| limit | Integer | No | Default: 3, Max: 10. The maximum number of friend reactions to return per act... |
| type | String | No | Default: 'following'. The type of friend relationship to use. 'following' = u... |
GetActivityResponse
public class GetActivityResponse {
private ActivityResponse activity;
private String duration;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| activity | ActivityResponse | Yes | The requested activity |
| duration | String | Yes |
GetCommentRepliesResponse
public class GetCommentRepliesResponse {
private List<ThreadedCommentResponse> comments;
private String duration;
private String next;
private String prev;
private String sort;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| comments | List<ThreadedCommentResponse> | Yes | Threaded listing of replies to the comment |
| duration | String | Yes | |
| sort | String | Yes | Sort order used for the replies (first, last, top, best, controversial) |
| next | String | No | |
| prev | String | No |
GetCommentResponse
public class GetCommentResponse {
private CommentResponse comment;
private String duration;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| comment | CommentResponse | Yes | Comment |
| duration | String | Yes |
GetCommentsResponse
public class GetCommentsResponse {
private List<ThreadedCommentResponse> comments;
private String duration;
private String next;
private String prev;
private String sort;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| comments | List<ThreadedCommentResponse> | Yes | Threaded listing for the activity |
| duration | String | Yes | |
| sort | String | Yes | Sort order used for the comments (first, last, top, best, controversial) |
| next | String | No | |
| prev | String | No |
GetFeedGroupResponse
public class GetFeedGroupResponse {
private String duration;
private FeedGroupResponse feed_group;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | |
| feed_group | FeedGroupResponse | Yes | The requested feed group |
GetFeedViewResponse
public class GetFeedViewResponse {
private String duration;
private FeedViewResponse feed_view;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | |
| feed_view | FeedViewResponse | Yes | The requested feed view |
GetFeedVisibilityResponse
public class GetFeedVisibilityResponse {
private String duration;
private FeedVisibilityResponse feed_visibility;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | |
| feed_visibility | FeedVisibilityResponse | Yes | Feed visibility configuration and permissions |
GetFeedsRateLimitsResponse
public class GetFeedsRateLimitsResponse {
private Map<String, Object> android;
private String duration;
private Map<String, Object> ios;
private Map<String, Object> server_side;
private Map<String, Object> web;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | |
| android | Map<String, Object> | No | Rate limits for Android platform (endpoint name -> limit info) |
| ios | Map<String, Object> | No | Rate limits for iOS platform (endpoint name -> limit info) |
| server_side | Map<String, Object> | No | Rate limits for server-side platform (endpoint name -> limit info) |
| web | Map<String, Object> | No | Rate limits for Web platform (endpoint name -> limit info) |
GetFollowSuggestionsResponse
public class GetFollowSuggestionsResponse {
private String algorithm_used;
private String duration;
private List<FeedSuggestionResponse> suggestions;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | |
| suggestions | List<FeedSuggestionResponse> | Yes | List of suggested feeds to follow |
| algorithm_used | String | No |
GetOrCreateFeedGroupResponse
public class GetOrCreateFeedGroupResponse {
private String duration;
private FeedGroupResponse feed_group;
private Boolean was_created;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | |
| feed_group | FeedGroupResponse | Yes | The feed group that was retrieved or created |
| was_created | Boolean | Yes | Indicates whether the feed group was created (true) or already existed (false) |
GetOrCreateFeedResponse
Basic response information
public class GetOrCreateFeedResponse {
private List<ActivityResponse> activities;
private List<AggregatedActivityResponse> aggregated_activities;
private Boolean created;
private String duration;
private FeedResponse feed;
private List<FollowResponse> followers;
private PagerResponse followers_pagination;
private List<FollowResponse> following;
private PagerResponse following_pagination;
private PagerResponse member_pagination;
private List<FeedMemberResponse> members;
private String next;
private NotificationStatusResponse notification_status;
private List<ActivityPinResponse> pinned_activities;
private String prev;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| activities | List<ActivityResponse> | Yes | |
| aggregated_activities | List<AggregatedActivityResponse> | Yes | |
| created | Boolean | Yes | |
| duration | String | Yes | Duration of the request in milliseconds |
| feed | FeedResponse | Yes | |
| followers | List<FollowResponse> | Yes | |
| following | List<FollowResponse> | Yes | |
| members | List<FeedMemberResponse> | Yes | |
| pinned_activities | List<ActivityPinResponse> | Yes | |
| followers_pagination | PagerResponse | No | |
| following_pagination | PagerResponse | No | |
| member_pagination | PagerResponse | No | |
| next | String | No | |
| notification_status | NotificationStatusResponse | No | |
| prev | String | No |
GetOrCreateFeedViewResponse
public class GetOrCreateFeedViewResponse {
private String duration;
private FeedViewResponse feed_view;
private Boolean was_created;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | |
| feed_view | FeedViewResponse | Yes | The feed view (either existing or newly created) |
| was_created | Boolean | Yes | Indicates whether the feed view was newly created (true) or already existed (... |
Images
public class Images {
private ImageData fixed_height;
private ImageData fixed_height_downsampled;
private ImageData fixed_height_still;
private ImageData fixed_width;
private ImageData fixed_width_downsampled;
private ImageData fixed_width_still;
private ImageData original;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| fixed_height | ImageData | Yes | |
| fixed_height_downsampled | ImageData | Yes | |
| fixed_height_still | ImageData | Yes | |
| fixed_width | ImageData | Yes | |
| fixed_width_downsampled | ImageData | Yes | |
| fixed_width_still | ImageData | Yes | |
| original | ImageData | Yes |
ListFeedGroupsResponse
Basic response information
public class ListFeedGroupsResponse {
private String duration;
private Map<String, Object> groups;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | Duration of the request in milliseconds |
| groups | Map<String, Object> | Yes |
ListFeedViewsResponse
public class ListFeedViewsResponse {
private String duration;
private Map<String, Object> views;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | |
| views | Map<String, Object> | Yes | Map of feed view ID to feed view |
ListFeedVisibilitiesResponse
public class ListFeedVisibilitiesResponse {
private String duration;
private Map<String, Object> feed_visibilities;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | |
| feed_visibilities | Map<String, Object> | Yes | Map of feed visibility configurations by name |
Location
public class Location {
private Double lat;
private Double lng;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| lat | Double | Yes | Latitude coordinate |
| lng | Double | Yes | Longitude coordinate |
MembershipLevelResponse
public class MembershipLevelResponse {
private Double created_at;
private Map<String, Object> custom;
private String description;
private String id;
private String name;
private Integer priority;
private List<String> tags;
private Double updated_at;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| created_at | Double | Yes | When the membership level was created |
| id | String | Yes | Unique identifier for the membership level |
| name | String | Yes | Display name for the membership level |
| priority | Integer | Yes | Priority level |
| tags | List<String> | Yes | Activity tags this membership level gives access to |
| updated_at | Double | Yes | When the membership level was last updated |
| custom | Map<String, Object> | No | Custom data for the membership level |
| description | String | No | Description of the membership level |
NotificationConfig
public class NotificationConfig {
private String deduplication_window;
private Boolean track_read;
private Boolean track_seen;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| deduplication_window | String | No | Time window for deduplicating notification activities (reactions and follows)... |
| track_read | Boolean | No | Whether to track read status |
| track_seen | Boolean | No | Whether to track seen status |
NotificationStatusResponse
public class NotificationStatusResponse {
private Double last_read_at;
private Double last_seen_at;
private List<String> read_activities;
private List<String> seen_activities;
private Integer unread;
private Integer unseen;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| unread | Integer | Yes | Number of unread notifications |
| unseen | Integer | Yes | Number of unseen notifications |
| last_read_at | Double | No | When notifications were last read |
| last_seen_at | Double | No | When notifications were last seen |
| read_activities | List<String> | No | Deprecated: use is_read on each activity/group instead. IDs of activities tha... |
| seen_activities | List<String> | No | Deprecated: use is_seen on each activity/group instead. IDs of activities tha... |
OwnBatchResponse
public class OwnBatchResponse {
private Map<String, Object> data;
private String duration;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| data | Map<String, Object> | Yes | Map of feed ID to own fields data |
| duration | String | Yes |
PagerRequest
public class PagerRequest {
private Integer limit;
private String next;
private String prev;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| limit | Integer | No | |
| next | String | No | |
| prev | String | No |
PagerResponse
public class PagerResponse {
private String next;
private String prev;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| next | String | No | |
| prev | String | No |
PinActivityResponse
public class PinActivityResponse {
private ActivityResponse activity;
private Double created_at;
private String duration;
private String feed;
private String user_id;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| activity | ActivityResponse | Yes | The pinned activity |
| created_at | Double | Yes | When the activity was pinned |
| duration | String | Yes | |
| feed | String | Yes | Fully qualified ID of the feed the activity was pinned to |
| user_id | String | Yes | ID of the user who pinned the activity |
PollResponseData
public class PollResponseData {
private Boolean allow_answers;
private Boolean allow_user_suggested_options;
private Integer answers_count;
private Double created_at;
private UserResponse created_by;
private String created_by_id;
private Map<String, Object> custom;
private String description;
private Boolean enforce_unique_vote;
private String id;
private Boolean is_closed;
private List<PollVoteResponseData> latest_answers;
private Map<String, Object> latest_votes_by_option;
private Integer max_votes_allowed;
private String name;
private List<PollOptionResponseData> options;
private List<PollVoteResponseData> own_votes;
private Double updated_at;
private Integer vote_count;
private Map<String, Object> vote_counts_by_option;
private String voting_visibility;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| allow_answers | Boolean | Yes | |
| allow_user_suggested_options | Boolean | Yes | |
| answers_count | Integer | Yes | |
| created_at | Double | Yes | |
| created_by_id | String | Yes | |
| custom | Map<String, Object> | Yes | |
| description | String | Yes | |
| enforce_unique_vote | Boolean | Yes | |
| id | String | Yes | |
| latest_answers | List<PollVoteResponseData> | Yes | |
| latest_votes_by_option | Map<String, Object> | Yes | |
| name | String | Yes | |
| options | List<PollOptionResponseData> | Yes | |
| own_votes | List<PollVoteResponseData> | Yes | |
| updated_at | Double | Yes | |
| vote_count | Integer | Yes | |
| vote_counts_by_option | Map<String, Object> | Yes | |
| voting_visibility | String | Yes | |
| created_by | UserResponse | No | |
| is_closed | Boolean | No | |
| max_votes_allowed | Integer | No |
PollVoteResponse
public class PollVoteResponse {
private String duration;
private PollResponseData poll;
private PollVoteResponseData vote;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | Duration of the request in milliseconds |
| poll | PollResponseData | No | Poll |
| vote | PollVoteResponseData | No | Poll vote |
PollVoteResponseData
public class PollVoteResponseData {
private String answer_text;
private Double created_at;
private String id;
private Boolean is_answer;
private String option_id;
private String poll_id;
private Double updated_at;
private UserResponse user;
private String user_id;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| created_at | Double | Yes | |
| id | String | Yes | |
| option_id | String | Yes | |
| poll_id | String | Yes | |
| updated_at | Double | Yes | |
| answer_text | String | No | |
| is_answer | Boolean | No | |
| user | UserResponse | No | |
| user_id | String | No |
PrivacySettingsResponse
public class PrivacySettingsResponse {
private DeliveryReceiptsResponse delivery_receipts;
private ReadReceiptsResponse read_receipts;
private TypingIndicatorsResponse typing_indicators;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| delivery_receipts | DeliveryReceiptsResponse | No | |
| read_receipts | ReadReceiptsResponse | No | |
| typing_indicators | TypingIndicatorsResponse | No |
PushNotificationConfig
public class PushNotificationConfig {
private Boolean enable_push;
private List<String> push_types;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| enable_push | Boolean | No | Whether push notifications are enabled for this feed group |
| push_types | List<String> | No | List of notification types that should trigger push notifications (e.g., foll... |
QueryActivitiesResponse
public class QueryActivitiesResponse {
private List<ActivityResponse> activities;
private String duration;
private String next;
private String prev;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| activities | List<ActivityResponse> | Yes | List of activities matching the query |
| duration | String | Yes | |
| next | String | No | Cursor for next page |
| prev | String | No | Cursor for previous page |
QueryActivityReactionsResponse
Basic response information
public class QueryActivityReactionsResponse {
private String duration;
private String next;
private String prev;
private List<FeedsReactionResponse> reactions;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | Duration of the request in milliseconds |
| reactions | List<FeedsReactionResponse> | Yes | |
| next | String | No | |
| prev | String | No |
QueryBookmarkFoldersResponse
public class QueryBookmarkFoldersResponse {
private List<BookmarkFolderResponse> bookmark_folders;
private String duration;
private String next;
private String prev;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| bookmark_folders | List<BookmarkFolderResponse> | Yes | List of bookmark folders matching the query |
| duration | String | Yes | |
| next | String | No | Cursor for next page |
| prev | String | No | Cursor for previous page |
QueryBookmarksResponse
public class QueryBookmarksResponse {
private List<BookmarkResponse> bookmarks;
private String duration;
private String next;
private String prev;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| bookmarks | List<BookmarkResponse> | Yes | List of bookmarks matching the query |
| duration | String | Yes | |
| next | String | No | Cursor for next page |
| prev | String | No | Cursor for previous page |
QueryCollectionsResponse
public class QueryCollectionsResponse {
private List<CollectionResponse> collections;
private String duration;
private String next;
private String prev;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| collections | List<CollectionResponse> | Yes | List of collections matching the query |
| duration | String | Yes | |
| next | String | No | Cursor for next page |
| prev | String | No | Cursor for previous page |
QueryCommentReactionsResponse
Basic response information
public class QueryCommentReactionsResponse {
private String duration;
private String next;
private String prev;
private List<FeedsReactionResponse> reactions;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | Duration of the request in milliseconds |
| reactions | List<FeedsReactionResponse> | Yes | |
| next | String | No | |
| prev | String | No |
QueryCommentsResponse
public class QueryCommentsResponse {
private List<CommentResponse> comments;
private String duration;
private String next;
private String prev;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| comments | List<CommentResponse> | Yes | List of comments matching the query |
| duration | String | Yes | |
| next | String | No | Cursor for next page |
| prev | String | No | Cursor for previous page |
QueryFeedMembersResponse
public class QueryFeedMembersResponse {
private String duration;
private List<FeedMemberResponse> members;
private String next;
private String prev;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | |
| members | List<FeedMemberResponse> | Yes | List of feed members |
| next | String | No | Cursor for next page |
| prev | String | No | Cursor for previous page |
QueryFeedsResponse
public class QueryFeedsResponse {
private String duration;
private List<FeedResponse> feeds;
private String next;
private String prev;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | |
| feeds | List<FeedResponse> | Yes | List of feeds matching the query |
| next | String | No | Cursor for next page |
| prev | String | No | Cursor for previous page |
QueryFeedsUsageStatsResponse
public class QueryFeedsUsageStatsResponse {
private DailyMetricStatsResponse activities;
private DailyMetricStatsResponse api_requests;
private String duration;
private EMAUStatsResponse emau;
private DailyMetricStatsResponse follows;
private DailyMetricStatsResponse openai_requests;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| activities | DailyMetricStatsResponse | Yes | Activities statistics with daily breakdown and total |
| api_requests | DailyMetricStatsResponse | Yes | API requests statistics with daily breakdown and total |
| duration | String | Yes | |
| follows | DailyMetricStatsResponse | Yes | Follows statistics with daily breakdown and total |
| openai_requests | DailyMetricStatsResponse | Yes | OpenAI requests statistics with daily breakdown and total |
| emau | EMAUStatsResponse | No | Engaged Monthly Active Users snapshots within the requested date range. Omitt... |
QueryFollowsResponse
public class QueryFollowsResponse {
private String duration;
private List<FollowResponse> follows;
private String next;
private String prev;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | |
| follows | List<FollowResponse> | Yes | List of follow relationships matching the query |
| next | String | No | Cursor for next page |
| prev | String | No | Cursor for previous page |
QueryMembershipLevelsResponse
public class QueryMembershipLevelsResponse {
private String duration;
private List<MembershipLevelResponse> membership_levels;
private String next;
private String prev;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | |
| membership_levels | List<MembershipLevelResponse> | Yes | |
| next | String | No | Cursor for next page |
| prev | String | No | Cursor for previous page |
QueryPinnedActivitiesResponse
public class QueryPinnedActivitiesResponse {
private String duration;
private String next;
private List<ActivityPinResponse> pinned_activities;
private String prev;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | |
| pinned_activities | List<ActivityPinResponse> | Yes | List of pinned activities matching the query |
| next | String | No | Cursor for next page |
| prev | String | No | Cursor for previous page |
RankingConfig
public class RankingConfig {
private Map<String, Object> defaults;
private Map<String, Object> functions;
private String score;
private String type;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| type | String | Yes | Type of ranking algorithm. Required. One of: expression, interest |
| defaults | Map<String, Object> | No | Default values for ranking |
| functions | Map<String, Object> | No | Decay functions configuration |
| score | String | No | Scoring formula. Required when type is 'expression' or 'interest' |
Reaction
public class Reaction {
private String activity_id;
private Map<String, Object> children_counts;
private Double created_at;
private Map<String, Object> data;
private Double deleted_at;
private String id;
private String kind;
private Map<String, Object> latest_children;
private Map<String, Object> moderation;
private Map<String, Object> own_children;
private String parent;
private Double score;
private List<String> target_feeds;
private Map<String, Object> target_feeds_extra_data;
private Double updated_at;
private User user;
private String user_id;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| activity_id | String | Yes | |
| created_at | Double | Yes | |
| kind | String | Yes | |
| updated_at | Double | Yes | |
| user_id | String | Yes | |
| children_counts | Map<String, Object> | No | |
| data | Map<String, Object> | No | |
| deleted_at | Double | No | |
| id | String | No | |
| latest_children | Map<String, Object> | No | |
| moderation | Map<String, Object> | No | |
| own_children | Map<String, Object> | No | |
| parent | String | No | |
| score | Double | No | |
| target_feeds | List<String> | No | |
| target_feeds_extra_data | Map<String, Object> | No | |
| user | User | No |
ReadCollectionsResponse
public class ReadCollectionsResponse {
private List<CollectionResponse> collections;
private String duration;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| collections | List<CollectionResponse> | Yes | List of collections matching the references |
| duration | String | Yes |
RejectFeedMemberInviteResponse
public class RejectFeedMemberInviteResponse {
private String duration;
private FeedMemberResponse member;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | |
| member | FeedMemberResponse | Yes | The feed member after rejecting the invite |
RejectFollowResponse
public class RejectFollowResponse {
private String duration;
private FollowResponse follow;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | |
| follow | FollowResponse | Yes | The rejected follow relationship |
Response
Basic response information
public class Response {
private String duration;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | Duration of the request in milliseconds |
RestoreActivityResponse
public class RestoreActivityResponse {
private ActivityResponse activity;
private String duration;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| activity | ActivityResponse | Yes | The restored activity with full enrichment |
| duration | String | Yes |
RestoreCommentResponse
public class RestoreCommentResponse {
private ActivityResponse activity;
private CommentResponse comment;
private String duration;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| activity | ActivityResponse | Yes | The parent activity with updated counts |
| comment | CommentResponse | Yes | The restored comment |
| duration | String | Yes |
RestoreFeedGroupResponse
public class RestoreFeedGroupResponse {
private String duration;
private FeedGroupResponse feed_group;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | |
| feed_group | FeedGroupResponse | Yes | The restored feed group |
SingleFollowResponse
public class SingleFollowResponse {
private String duration;
private FollowResponse follow;
private Boolean notification_created;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | |
| follow | FollowResponse | Yes | The created follow relationship |
| notification_created | Boolean | No | Whether a notification activity was successfully created |
SortParamRequest
public class SortParamRequest {
private Integer direction;
private String field;
private String type;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| direction | Integer | No | Direction of sorting, 1 for Ascending, -1 for Descending, default is 1. One o... |
| field | String | No | Name of field to sort by |
| type | String | No | Type of field to sort by. Empty string or omitted means string type (default)... |
StoriesConfig
public class StoriesConfig {
private Boolean skip_watched;
private Boolean track_watched;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| skip_watched | Boolean | No | Whether to skip already watched stories |
| track_watched | Boolean | No | Whether to track watched status for stories |
ThreadedCommentResponse
A comment with an optional, depth‑limited slice of nested replies.
public class ThreadedCommentResponse {
private List<Attachment> attachments;
private Integer bookmark_count;
private Double confidence_score;
private Double controversy_score;
private Double created_at;
private Map<String, Object> custom;
private Double deleted_at;
private Integer downvote_count;
private Double edited_at;
private String id;
private List<FeedsReactionResponse> latest_reactions;
private List<UserResponse> mentioned_users;
private RepliesMeta meta;
private ModerationV2Response moderation;
private String object_id;
private String object_type;
private List<FeedsReactionResponse> own_reactions;
private String parent_id;
private Integer reaction_count;
private Map<String, Object> reaction_groups;
private List<ThreadedCommentResponse> replies;
private Integer reply_count;
private Integer score;
private String status;
private String text;
private Double updated_at;
private Integer upvote_count;
private UserResponse user;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| bookmark_count | Integer | Yes | |
| confidence_score | Double | Yes | |
| created_at | Double | Yes | |
| downvote_count | Integer | Yes | |
| id | String | Yes | |
| mentioned_users | List<UserResponse> | Yes | |
| object_id | String | Yes | |
| object_type | String | Yes | |
| own_reactions | List<FeedsReactionResponse> | Yes | |
| reaction_count | Integer | Yes | |
| reply_count | Integer | Yes | |
| score | Integer | Yes | |
| status | String | Yes | Status of the comment. One of: active, deleted, removed, hidden |
| updated_at | Double | Yes | |
| upvote_count | Integer | Yes | |
| user | UserResponse | Yes | |
| attachments | List<Attachment> | No | |
| controversy_score | Double | No | |
| custom | Map<String, Object> | No | |
| deleted_at | Double | No | |
| edited_at | Double | No | |
| latest_reactions | List<FeedsReactionResponse> | No | |
| meta | RepliesMeta | No | Pagination & depth info for this node's direct replies. |
| moderation | ModerationV2Response | No | |
| parent_id | String | No | |
| reaction_groups | Map<String, Object> | No | |
| replies | List<ThreadedCommentResponse> | No | Slice of nested comments (may be empty). |
| text | String | No |
Time
public class Time {
}TrackActivityMetricsEvent
A single metric event to track for an activity
public class TrackActivityMetricsEvent {
private String activity_id;
private Integer delta;
private String metric;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| activity_id | String | Yes | The ID of the activity to track the metric for |
| metric | String | Yes | The metric name (e.g. views, clicks, impressions). Alphanumeric and underscor... |
| delta | Integer | No | The amount to increment (positive) or decrement (negative). Defaults to 1. Th... |
TrackActivityMetricsEventResult
Result of tracking a single metric event
public class TrackActivityMetricsEventResult {
private String activity_id;
private Boolean allowed;
private String error;
private String metric;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| activity_id | String | Yes | The activity ID from the request |
| allowed | Boolean | Yes | Whether the metric was counted (false if rate-limited) |
| metric | String | Yes | The metric name from the request |
| error | String | No | Error message if processing failed |
TrackActivityMetricsResponse
Response containing results for each tracked metric event
public class TrackActivityMetricsResponse {
private String duration;
private List<TrackActivityMetricsEventResult> results;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | |
| results | List<TrackActivityMetricsEventResult> | Yes | Results for each event in the request, in the same order |
UnfollowBatchResponse
public class UnfollowBatchResponse {
private String duration;
private List<FollowResponse> follows;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | |
| follows | List<FollowResponse> | Yes | List of follow relationships that were removed |
UnfollowPair
public class UnfollowPair {
private Boolean keep_history;
private String source;
private String target;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| source | String | Yes | Fully qualified ID of the source feed |
| target | String | Yes | Fully qualified ID of the target feed |
| keep_history | Boolean | No | When true, activities from the unfollowed feed will remain in the source feed... |
UnfollowResponse
public class UnfollowResponse {
private String duration;
private FollowResponse follow;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | |
| follow | FollowResponse | Yes | The deleted follow relationship |
UnpinActivityResponse
public class UnpinActivityResponse {
private ActivityResponse activity;
private String duration;
private String feed;
private String user_id;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| activity | ActivityResponse | Yes | The unpinned activity |
| duration | String | Yes | |
| feed | String | Yes | Fully qualified ID of the feed the activity was unpinned from |
| user_id | String | Yes | ID of the user who unpinned the activity |
UpdateActivitiesPartialBatchResponse
public class UpdateActivitiesPartialBatchResponse {
private List<ActivityResponse> activities;
private String duration;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| activities | List<ActivityResponse> | Yes | List of successfully updated activities |
| duration | String | Yes |
UpdateActivityPartialChangeRequest
public class UpdateActivityPartialChangeRequest {
private String activity_id;
private Boolean copy_custom_to_notification;
private Boolean handle_mention_notifications;
private Map<String, Object> set;
private List<String> unset;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| activity_id | String | Yes | ID of the activity to update |
| copy_custom_to_notification | Boolean | No | Whether to copy custom data to the notification activity (only applies when h... |
| handle_mention_notifications | Boolean | No | When true and 'mentioned_user_ids' is updated, automatically creates or delet... |
| set | Map<String, Object> | No | Map of field names to new values. Supported fields: 'text', 'attachments', 'c... |
| unset | List<String> | No | List of field names to remove. Supported fields: 'custom', 'location', 'expir... |
UpdateActivityPartialResponse
public class UpdateActivityPartialResponse {
private ActivityResponse activity;
private String duration;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| activity | ActivityResponse | Yes | The updated activity |
| duration | String | Yes |
UpdateActivityResponse
public class UpdateActivityResponse {
private ActivityResponse activity;
private String duration;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| activity | ActivityResponse | Yes | The updated activity |
| duration | String | Yes |
UpdateBookmarkFolderResponse
public class UpdateBookmarkFolderResponse {
private BookmarkFolderResponse bookmark_folder;
private String duration;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| bookmark_folder | BookmarkFolderResponse | Yes | The updated bookmark folder |
| duration | String | Yes |
UpdateBookmarkResponse
public class UpdateBookmarkResponse {
private BookmarkResponse bookmark;
private String duration;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| bookmark | BookmarkResponse | Yes | The updated bookmark |
| duration | String | Yes |
UpdateCollectionRequest
public class UpdateCollectionRequest {
private Map<String, Object> custom;
private String id;
private String name;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| custom | Map<String, Object> | Yes | Custom data for the collection (required, must contain at least one key) |
| id | String | Yes | Unique identifier for the collection within its name |
| name | String | Yes | Name/type of the collection |
UpdateCollectionsResponse
public class UpdateCollectionsResponse {
private List<CollectionResponse> collections;
private String duration;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| collections | List<CollectionResponse> | Yes | List of updated collections |
| duration | String | Yes |
UpdateCommentBookmarkResponse
public class UpdateCommentBookmarkResponse {
private BookmarkResponse bookmark;
private String duration;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| bookmark | BookmarkResponse | Yes | The updated comment bookmark |
| duration | String | Yes |
UpdateCommentPartialResponse
public class UpdateCommentPartialResponse {
private CommentResponse comment;
private String duration;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| comment | CommentResponse | Yes | The updated comment |
| duration | String | Yes |
UpdateCommentResponse
public class UpdateCommentResponse {
private CommentResponse comment;
private String duration;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| comment | CommentResponse | Yes | The updated comment |
| duration | String | Yes |
UpdateFeedGroupResponse
public class UpdateFeedGroupResponse {
private String duration;
private FeedGroupResponse feed_group;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | |
| feed_group | FeedGroupResponse | Yes | The updated feed group |
UpdateFeedMembersResponse
Basic response information
public class UpdateFeedMembersResponse {
private List<FeedMemberResponse> added;
private String duration;
private List<String> removed_ids;
private List<FeedMemberResponse> updated;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| added | List<FeedMemberResponse> | Yes | |
| duration | String | Yes | Duration of the request in milliseconds |
| removed_ids | List<String> | Yes | |
| updated | List<FeedMemberResponse> | Yes |
UpdateFeedResponse
public class UpdateFeedResponse {
private String duration;
private FeedResponse feed;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | |
| feed | FeedResponse | Yes | The updated feed |
UpdateFeedViewResponse
public class UpdateFeedViewResponse {
private String duration;
private FeedViewResponse feed_view;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | |
| feed_view | FeedViewResponse | Yes | The updated feed view |
UpdateFeedVisibilityResponse
public class UpdateFeedVisibilityResponse {
private String duration;
private FeedVisibilityResponse feed_visibility;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | |
| feed_visibility | FeedVisibilityResponse | Yes | Feed visibility configuration and permissions |
UpdateFollowResponse
public class UpdateFollowResponse {
private String duration;
private FollowResponse follow;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | |
| follow | FollowResponse | Yes | Details of the updated follow relationship |
UpdateMembershipLevelResponse
public class UpdateMembershipLevelResponse {
private String duration;
private MembershipLevelResponse membership_level;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| duration | String | Yes | |
| membership_level | MembershipLevelResponse | Yes | The updated membership level |
UpsertActivitiesResponse
public class UpsertActivitiesResponse {
private List<ActivityResponse> activities;
private String duration;
private Integer mention_notifications_created;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| activities | List<ActivityResponse> | Yes | List of created or updated activities |
| duration | String | Yes | |
| mention_notifications_created | Integer | No | Total number of mention notification activities created for mentioned users a... |
UpsertCollectionsResponse
public class UpsertCollectionsResponse {
private List<CollectionResponse> collections;
private String duration;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| collections | List<CollectionResponse> | Yes | List of upserted collections |
| duration | String | Yes |
User
public class User {
private Map<String, Object> data;
private String id;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| id | String | Yes | |
| data | Map<String, Object> | No |
UserRequest
User request object
public class UserRequest {
private Map<String, Object> custom;
private String id;
private String image;
private Boolean invisible;
private String language;
private String name;
private PrivacySettingsResponse privacy_settings;
private String role;
private List<String> teams;
private Map<String, Object> teams_role;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| id | String | Yes | User ID |
| custom | Map<String, Object> | No | Custom user data |
| image | String | No | User's profile image URL |
| invisible | Boolean | No | |
| language | String | No | |
| name | String | No | Optional name of user |
| privacy_settings | PrivacySettingsResponse | No | |
| role | String | No | User's global role |
| teams | List<String> | No | List of teams the user belongs to |
| teams_role | Map<String, Object> | No | Map of team-specific roles for the user |
UserResponse
User response object
public class UserResponse {
private Integer avg_response_time;
private Double ban_expires;
private Boolean banned;
private List<String> blocked_user_ids;
private Boolean bypass_moderation;
private Double created_at;
private Map<String, Object> custom;
private Double deactivated_at;
private Double deleted_at;
private List<DeviceResponse> devices;
private String id;
private String image;
private Boolean invisible;
private String language;
private Double last_active;
private String name;
private Boolean online;
private PrivacySettingsResponse privacy_settings;
private PushNotificationSettingsResponse push_notifications;
private Double revoke_tokens_issued_before;
private String role;
private Boolean shadow_banned;
private List<String> teams;
private Map<String, Object> teams_role;
private Double updated_at;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| banned | Boolean | Yes | Whether a user is banned or not |
| blocked_user_ids | List<String> | Yes | |
| created_at | Double | Yes | Date/time of creation |
| custom | Map<String, Object> | Yes | Custom data for this object |
| id | String | Yes | Unique user identifier |
| invisible | Boolean | Yes | |
| language | String | Yes | Preferred language of a user |
| online | Boolean | Yes | Whether a user online or not |
| role | String | Yes | Determines the set of user permissions |
| shadow_banned | Boolean | Yes | Whether a user is shadow banned |
| teams | List<String> | Yes | List of teams user is a part of |
| updated_at | Double | Yes | Date/time of the last update |
| avg_response_time | Integer | No | |
| ban_expires | Double | No | Date when ban expires |
| bypass_moderation | Boolean | No | |
| deactivated_at | Double | No | Date of deactivation |
| deleted_at | Double | No | Date/time of deletion |
| devices | List<DeviceResponse> | No | List of devices user is using |
| image | String | No | |
| last_active | Double | No | Date of last activity |
| name | String | No | Optional name of user |
| privacy_settings | PrivacySettingsResponse | No | User privacy settings |
| push_notifications | PushNotificationSettingsResponse | No | User push notification settings |
| revoke_tokens_issued_before | Double | No | Revocation date for tokens |
| teams_role | Map<String, Object> | No |
VoteData
public class VoteData {
private String answer_text;
private String option_id;
}Properties:
| Property | Type | Required | Description |
|---|---|---|---|
| answer_text | String | No | |
| option_id | String | No |