Audio and video calling overview
Understand WASM SDK call signaling, room information, and event boundaries.
The WASM SDK provides the signaling APIs needed to start, accept, reject, cancel, and end calls, query rooms, and synchronize call state. It coordinates participants, room information, and the call lifecycle. It does not capture camera video, play remote media streams, or render the calling interface.
Pass the returned roomID, token, and liveURL to your chosen real-time audio and video engine. Your application remains responsible for device permissions, media tracks, poor-network strategies, and interface state. The WASM SDK signaling APIs are not a complete WebRTC media SDK.
Call flow
- Call
signalingInvite()to start a one-to-one call orsignalingInviteInGroup()to start a group call. - The invitee receives the invitation through
OnReceiveNewInvitationand chooses to accept or reject it. - The invitee calls
signalingAccept(), and both sides use the returned room credentials to connect to the media engine. - During the call, update local state from participant, media-stream, and custom-signaling events.
- The caller can cancel an invitation that has not been answered. Any participant can end an established call.
Core data
| Data | Description |
|---|---|
SignalingInvitation | Inviter, invitees, group, room, media type, timeout, and session type. |
SignalingInviteResult | roomID, token, liveURL, and busy-user list returned by OpenIMServer. |
SignalingAcceptResult, SignalingTokenResult | Media-room credentials returned when accepting an invitation or refreshing a token. |
SignalingRoomInfo | Room, invitation, and participant information queried by group. |
Use customData and custom signaling only for business negotiation information that may be exposed to call participants. Do not place long-lived credentials, administrator keys, or other sensitive data in them.
State updates and events
For operations such as starting, accepting, rejecting, canceling, and ending a call, handle the API Promise and call events separately. Promise completion means OpenIMServer has accepted or completed the current signaling request. Events report later state changes observed by the inviter, invitees, other devices, or room participants. They are not the same completion signal.
For the complete invitation lifecycle, participant, hang-up, and media-stream listeners, see Call events. For custom signaling events, see Send a custom signal. Room queries, token refreshes, and pending-invitation recovery return the data available at call time through their Promises.
The overview does not register event handlers. Use roomID as the primary key for call state and combine it with the user ID for participant state. After a new login or reconnection, first query the current group-call room or pending invitation to restore any call that is still active, then process later call events. Listening to events alone cannot recover state missed while the client was offline.
Find a page by task
| Task | Page |
|---|---|
| Start a one-to-one or group call | Start a one-to-one call, Start a group call |
| Accept or reject an invitation | Accept a call, Reject a call |
| Cancel an invitation or end a call | Cancel a call invitation, End a call |
| Recover a room or pending invitation | Get a group call room, Get a call room token, Restore a pending call invitation |
| Handle call events and business negotiation | Call events, Send a custom signal |
Was this page helpful?