Skip to content

feat(events): add support for user-role-changed - #79

Merged
prlanzarin merged 1 commit into
bigbluebutton:developfrom
Arthurk12:issue/78
Oct 28, 2026
Merged

prlanzarin merged 1 commit into
bigbluebutton:developfrom
Arthurk12:issue/78

Conversation

@Arthurk12

Copy link
Copy Markdown
Member

What does this PR do?

Role changes in a meeting are not reported to hooks: UserRoleChangedEvtMsg is not mapped, so integrations cannot tell when a user is promoted to moderator or demoted to viewer.

Map it to a user-role-changed event carrying the new role and the requester under changed-by. Unlike other user messages, its header.userId is the requester rather than the affected user, so list it in BODY_USER_ID_EVENTS and have _extractIntUserID read only body.userId for it; falling back to the header would attribute the change to the moderator who made it.

Also update the role stored in the user mapping, so the user-left events spoofed when a meeting ends report the current role instead of the one the user joined with.

Closes #78

@prlanzarin
prlanzarin self-requested a review October 6, 2026 18:11
@AtilaU19
AtilaU19 self-requested a review October 20, 2026 16:51
Comment thread src/process/event.js Resolved
@Arthurk12
Arthurk12 requested a review from prlanzarin October 28, 2026 00:33
Role changes in a meeting are not reported to hooks:
UserRoleChangedEvtMsg is not mapped, so integrations cannot tell when a
user is promoted to moderator or demoted to viewer.

Map it to a user-role-changed event carrying the new role and the
requester under changed-by. Unlike other user messages, its
header.userId is the requester rather than the affected user, so list it
in BODY_USER_ID_EVENTS and have _extractIntUserID read only body.userId
for it; falling back to the header would attribute the change to the
moderator who made it.

Also update the role stored in the user mapping, so the user-left events
spoofed when a meeting ends report the current role instead of the one
the user joined with.
@prlanzarin
prlanzarin merged commit 6eb1527 into bigbluebutton:develop Oct 28, 2026
3 checks passed
@Arthurk12
Arthurk12 deleted the issue/78 branch October 28, 2026 17:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add support for UserRoleChangedEvtMsg

3 participants