Skip to main content

Post Seen

The LikeMinds Android Feed SDK incorporates a user-ranked feed feature that enables users to get their personalised feed, and to dampen a post based on viewing calling postSeen().

Steps to set posts as seen

  1. Create a PostSeenRequest object using PostSeenRequest.Builder class by passing all the required parameters.
  2. Call postSeen() function using the instance of LMFeedClient.
  3. Process the response LMResponse<Nothing> as per your requirement.
CoroutineScope(Dispatchers.IO).launch {
// object of GetPostLikesRequest
val postSeenRequest = PostSeenRequest.Builder()
.seenPostIds(["ENTER POST IDS"])
.build()
// get response (LMResponse<Nothing>)
val response = LMFeedClient.getInstance().postSeen(postSeenRequest)
if (response.success) {
// your function to process the response data
processResponse(response.data)
} else {
// your function to process error message
processError(response.errorMessage)
}
}

Models

PostSeenRequest

VARIABLETYPEDESCRIPTIONOPTIONAL
seenPostIdsList<String>List of post ids which are seen by the user.