Files
Jörn Friedrich Dreyer 3320159dca feat(userlog): notify users about received ocm shares
Users never got a notification when a federated instance shared
something with them or removed that share again. The ocmcore service
publishes OCMCoreShareCreated and OCMCoreShareDelete, but only when it
has an events config, and the ocm service never passed one.

We now pass the events config to ocmcore, and userlog turns both
events into the regular "Resource shared" / "Resource unshared"
notifications for the grantee. They honor the same in-app settings as
local shares.

The sharer is a federated user, so we look it up with GetAcceptedUser in
the name of the grantee. That call has to go out without the service
account token, otherwise the invite manager filters by the service
account and finds nothing. If the lookup fails, e.g. because the
federated connection was deleted, the notification says "Someone at
<provider domain> shared <resource> with you" instead of showing an
empty name. The federated id itself is "<uuid>@<issuer url>", which
tells the reader nothing. Clients only fill in the known rich
parameters, so we fill in the provider in the rich message ourselves.

The resource lives on the remote instance. The notification points to
the received share id for both events and carries the resource name
without an id, so clients render it like a local share but don't build
a link to a resource that does not exist here.

Assisted-by: Claude Code:claude-opus-5-5
Signed-off-by: Jörn Friedrich Dreyer <jfd@butonic.de>
2026-11-19 15:34:33 +01:00
..
2026-11-18 23:17:11 +00:00
2026-11-17 12:45:18 +01:00
2026-11-17 12:45:18 +01:00
2026-11-17 12:45:18 +01:00
2026-11-17 12:45:18 +01:00
2026-11-17 12:45:18 +01:00
2026-11-17 12:45:18 +01:00
2026-11-17 12:45:18 +01:00
2026-11-17 12:45:18 +01:00
2026-11-17 12:45:18 +01:00
2026-11-17 12:45:18 +01:00
2026-11-17 12:45:18 +01:00
2026-11-17 12:45:18 +01:00
2026-11-17 12:45:18 +01:00
2026-11-17 12:45:18 +01:00
2026-11-18 23:17:11 +00:00
2026-11-17 12:45:18 +01:00
2026-06-03 16:28:44 +02:00
2026-11-17 12:45:18 +01:00
2026-11-17 23:17:37 +00:00
2026-11-17 12:45:18 +01:00
2026-11-17 12:45:18 +01:00
2026-11-17 12:45:18 +01:00
2026-11-18 23:17:11 +00:00
2026-11-17 12:45:18 +01:00
2026-11-17 12:45:18 +01:00
2026-11-17 12:45:18 +01:00
2026-11-17 12:45:18 +01:00
2026-11-17 12:45:18 +01:00
2026-11-17 12:45:18 +01:00
2026-11-17 12:45:18 +01:00