Announce and Undo(Announce) in Mastodon

submitted by

NodeBB federates out the Announce activity in two ways.

  1. The “plain object” way, which is an Announce activity wrapping an object (either a uri or the full object itself.)
  2. The “1b12” way, which is an Announce activity wrapping another activity (e.g. Create)

Up until now I haven’t needed to handle the reverse (which in AP-speak is the “undo” of an activity), but since NodeBB sends Announce when moving a topic *in to category, it now makes sense to Undo(Announce) when moving a topic out* of a category.

My first interop test with Mastodon didn’t work, and it turns out that Mastodon checks the id of the embedded Announce for a match. It doesn’t infer it based on actor/object combination.

Once I matched up the IDs, the Undo was processed correctly.

I also noticed that Announces sent from Mastodon have a published property, although this is not relevant in Undo parsing.

4
7

Log in to comment

4 Comments

What does undoing an announce do, in Mastodon? Remove a boost?

Yep, that’s basically it. It’s not really a concept in threadiverse implementations since group actors do the Announcing for synchronization.

Lemmy uses Announce/Undo/Delete and similar activites. So the outermost activity is always Announce from the community. To me Undo/Announce doesnt make much sense, it was already announced and you cant take that back. Its the delete action which is reverted.

Mastodon compatibility is another thing, you likely need a lot of ugly hacks for that.

You’re right! We don’t federate out Announce(Undo(Object)) precisely because threadiverse implementations already do Announce(Delete).

This is purely for microblogs, but it does merit discussion for that reason alone 🙂

Edit: your reply does remind me that we don’t currently handle Announce(Undo(Like)) though, so thanks!

Insert image