Skip to content

Start CallEventHandler and GroupCallEventHandler if isVoipWithNoMediaAllowed is set to true#5108

Closed
alfredjophy wants to merge 1 commit intomatrix-org:developfrom
alfredjophy:fix/support-call-on-server
Closed

Start CallEventHandler and GroupCallEventHandler if isVoipWithNoMediaAllowed is set to true#5108
alfredjophy wants to merge 1 commit intomatrix-org:developfrom
alfredjophy:fix/support-call-on-server

Conversation

@alfredjophy
Copy link

@alfredjophy alfredjophy commented Dec 12, 2025

Start CallEventHandler and GroupCallEventHandler when isVoipWithNoMediaAllowed is set to true. This lets you use the SDK on the server for managing calls.

…Allowed is set to true.

Signed-off-by: Alfred Jophy <alfredjophy@pm.me>
@alfredjophy alfredjophy requested a review from a team as a code owner December 12, 2025 06:22
@github-actions github-actions bot added the Z-Community-PR Issue is solved by a community member's PR label Dec 12, 2025
@florianduros florianduros requested review from a team and robintown and removed request for a team December 12, 2025 08:50
Copy link
Member

@dbkr dbkr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Leaving it to VoIP to works out if this is desired, although I find it confusing that you'd still start Call Event Handlers sometimes even if disableVoip was passed. It feels like we're re-using existing flags to do something else. This definitely feels like something I'd expect docs for, and most certainly tests.

@robintown robintown self-assigned this Jan 5, 2026
Copy link
Member

@robintown robintown left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi there, am speaking for the VoIP team: I agree with Dave that isVoipWithNoMediaAllowed is not really an appropriate flag to use for overriding the disableVoip flag or bypassing the WebRTC support checks. The flag exists for cases where the JS runtime does support WebRTC and you want to join a call, but there happen to be no media devices attached to the computer.

Unfortunately I don't think I would be comfortable with exposing the call handlers in general when WebRTC support is missing, since the MatrixCall class lumps together the externally visible state of a call and methods to participate in a call (which will crash in environments without WebRTC) together by design. I'm open to proposals, but I believe the WebRTC code would need to be separated cleanly from the rest before that would make sense, and that's a big task.

Meanwhile, our team is working on developing MatrixRTC, the next-gen VoIP system for Matrix, which is used by Element Call, Element Web if configured, and the Element X mobile apps. Is there any chance that switching to MatrixRTC is possible already for your particular use case? I bring this up because matrix-js-sdk does provide information about MatrixRTC sessions through MatrixClient.matrixRTC, regardless of WebRTC support. This would be more readily usable on the server.

@alfredjophy
Copy link
Author

Yes thanks for the reply. I do agree the flag might not be really meant for this. Ill be using a private flag for this

@robintown robintown closed this Jan 14, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

T-Enhancement Z-Community-PR Issue is solved by a community member's PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants