@startuml
title Системные события → обновления коллекций (sequence)

actor "Система" as Sys
participant "api/system_events" as API
database "MongoDB" as DB

Sys -> API : camera.deleted
API -> DB  : update_many(checklists/facilities,\n  $pull: {camera_id: <id>})
API <-- DB : result

Sys -> API : permission_grant.revoked
API -> DB  : update_many(checklists/facilities,\n  $pull: {camera_id: <id>})
API <-- DB : result
@enduml
