Developer Documentation
Our new developer documentation is now available. Please check it out!

OdinClient

export class OdinClient

Class providing static methods to handle ODIN client connections.

Properties

NameTypeDescription
configIOdinClientSettingsGlobal settings for ODIN connections.
connectionStateOdinConnectionStateThe current state of the main stream connection.
roomsOdinRoom[]An array of available OdinRoom instances.

Public Methods

NameTypeDescription
addEventListenervoidRegisters to client events from IOdinClientEvents.
disconnectvoidDisconnects from all rooms and stops all audio handling.
initRoomPromise<OdinRoom>Authenticates against the ODIN server and returns an OdinRoom instance for the first room set in the specified token. This function accepts an optional AudioContext parameter for audio capture. The AudioContext interface is a part of the Web Audio API that represents an audio-processing graph, which can be used to control and manipulate audio signals in web applications. If the AudioContext is not provided or explicitly set to undefined, we will try to create one internally.
initRoomsPromise<OdinRoom[]>Authenticates against the ODIN server and returns OdinRoom instances for all rooms set in the specified token. This function accepts an optional AudioContext parameter for audio capture. The AudioContext interface is a part of the Web Audio API that represents an audio-processing graph, which can be used to control and manipulate audio signals in web applications. If the AudioContext is not provided or explicitly set to undefined, we will try to create one internally.