activitypub icon indicating copy to clipboard operation
activitypub copied to clipboard

Mark posts as read?

Open vanillajonathan opened this issue 4 years ago • 8 comments

If a user does a GET request to retrieve the posts from his inbox then does the posts still stay in the inbox or do they get deleted after they have been retrieved?

If a user gets a new post then he might want to be able to discern old posts from new posts so a indicator can be displayed like "3 new posts". Is it possible to mark a post as read?

Example in email you can get a list of mail in your inbox and see that 3 email messages are unread.

vanillajonathan avatar May 19 '21 14:05 vanillajonathan

ActivityPub, as specified, does not ever remove posts from a user's inbox.

If a server wishes to implement unread or read tracking, that would be cool, but it should probably be as an extension, and it probably shouldn't remove posts from the inbox (in case the user wishes to view them later)

nightpool avatar May 19 '21 14:05 nightpool

So can a user send a private message (sometimes called a direct message) to another user? And if so, how can the receiving user know if he got any new unread messages and how many?

vanillajonathan avatar May 19 '21 14:05 vanillajonathan

Maybe this could be done with the Read activity, View activity or Update activity?

vanillajonathan avatar May 28 '21 13:05 vanillajonathan

@vanillajonathan Is there anything left do to here or can this issue be closed?

akuckartz avatar Jan 16 '23 07:01 akuckartz

@akuckartz I still wonder how a implementation would go on about to implement this, see my previous post.

Maybe this could be done with the Read activity, View activity or Update activity?

vanillajonathan avatar Jan 16 '23 09:01 vanillajonathan

@vanillajonathan Yes, the Read activity or the View activity can be used. But I do not know which software supports this feature.

Unfortunately the semantics of these activities are not different. I intend to raise that as a separate issue and propose to close this one.

akuckartz avatar Jan 16 '23 16:01 akuckartz

I added a note in the primer for tracking the read status of objects.

https://www.w3.org/wiki/ActivityPub/Primer/Tracking_read_status_of_objects

It is short; there is not a built-in way to do this.

Some ideas for extensions to do this:

  1. Add an extension property for objects and activities such as read or viewed with a datestamp or boolean flag. This could be used by clients to de-emphasize items that have been read. Note that this property would be different for different viewers. For example, if Alice looks at the activity, for her it would be read, but for Bob it would not.

  2. Add an extension property such as unreadInbox that only contains unread activities. The View activity could be used to show that the item has been viewed.

  3. Implement unread activity tracking on the client side, unmanaged by the server. The downside is that activities that are unread in one client may be marked read in another client.

  4. The client tracks read/unread status, and saves it to the server in a property called readMap (or something similar), and this property is available to other clients to use and update. One issue is synchronization, and making sure that clients don't overwrite each other's updates.

This seems like a great candidate for a FEP; I may take a shot at it, so I will self-assign this ticket.

evanp avatar Jul 19 '23 16:07 evanp

Since you're basically reinventing NNTP and IMAP4, I recommend reading their RFCs carefully.

TallTed avatar Jul 19 '23 18:07 TallTed