@otistav/meet_js_sdk
v0.1.8
Published
SDK for videocalls by EdgeStream LLC
Downloads
3
Maintainers
Readme
meet sdk
is client SDK for GCore meet.
#Instalation
To install the SDK, run the following command:
npm install --save @otistav/meet_js_sdk
#Usage
//create room instance
const room = new sdk.Room('roomid');
//connect to the room
await room.connect('username');
//set up event listeners
//.on method returns room instance, which allows to chain events.
room.on(sdk.ClientEventTypes.RoomConnected, async () => {
//after connect to the room you can join it as participant.
await room.localPeer.joinRoom();
room.peers // At that moment, you have room.peers as peers which already joined the room.
})
.on(sdk.ClientEventTypes.NewPeer, ({ newPeer }) => {
//handle new peer connected here
})