activitypub icon indicating copy to clipboard operation
activitypub copied to clipboard

Document *not* using usernames in Actor @id's

Open ThisIsMissEm opened this issue 1 year ago • 5 comments

Instead of having your actor @id be something like https://example.social/users/jane_doe you should instead prefer to use something that is a stable identifier, for instance the database record ID, so https://example.social/users/c7ea4313-91eb-437f-bf15-6074bd7b5f40 or https://example.social/users/123

I was certain we already had a primer page for this, but we've not been able to find it, as such I believe we do need a primer page.

ThisIsMissEm avatar Sep 20 '24 17:09 ThisIsMissEm

@evanp per discussion

ThisIsMissEm avatar Sep 20 '24 17:09 ThisIsMissEm

Related #342

trwnh avatar Sep 22 '24 20:09 trwnh

I think this is also an issue with object ids, like https://social.example/users/evanp/note/1.

I think we have a page about object identifiers at https://www.w3.org/wiki/ActivityPub/Primer/Object_identifiers, and it would be a good place to document this particular issue.

Another related topic is whether dereferencing a URI and getting a redirect is OK, what should consumers do, etc.

If we have redirect support, it makes the immutability of IDs less important.

evanp avatar Oct 04 '24 16:10 evanp

@snarfed notes that we also need to note that if preferredUsername changes, remote systems need to update; they should not treat this as immutable just because it is on their own system.

evanp avatar Oct 04 '24 16:10 evanp

The mutability and immutability of preferredUsername is also covered in the ActivityPub + WebFinger report, since it matters quite a bit for Webfinger.

evanp avatar Oct 04 '24 16:10 evanp