huddle01_flutter_client 0.0.1-beta-v5.2.4 huddle01_flutter_client: ^0.0.1-beta-v5.2.4 copied to clipboard
The Huddle01 Flutter SDK offers a comprehensive suite of methods and event listeners that allow for seamless real-time audio and video communication with minimal coding required.
Huddle01 Flutter SDK #
Web3-Native Zoom for Builders/DAOs/NFT Communities
Community · Documentation
Flutter SDK #
The Huddle01 Flutter SDK offers a comprehensive suite of methods and event listeners that allow for seamless real-time audio and video communication with minimal coding required.
Pre Requisites #
Before using the Flutter SDK, you must have Flutter installed on your machine. You can install Flutter using one of the following method:
- Use the official flutter docs website
After installing Flutter verify it's installed by running the following command in your terminal:
flutter --version
Installing the packages: #
To get started with the Huddle01 Flutter SDK, you can install the package using:
flutter pub add huddle01_flutter
Initializing the SDK: #
After installing the package, you can initialize the SDK
String projectId = 'YOUR-PROJECT-ID';
String roomId = 'YOUR-ROOM-ID';
// Initialize your huddleClient
HuddleClient huddleClient = HuddleClient();
// Initialize project
huddleClient.initialize(projectId);
Joining the lobby: #
// Join lobby
huddleClient.joinLobby(roomId);
Enabling and Disabling Media Devices #
// enable-mic
huddleClient.fetchAudioStream();
// disable-mic
huddleClient.stopAudioStream();
// enable-cam
huddleClient.fetchVideoStream();
// disable-cam
huddleClient.stopVideoStream();
Joining the room: #
// Join room
huddleClient.joinRoom();
Leaving the lobby #
// Leave lobby
huddleClient.leaveLobby();
Produce media stream #
// Produce Audio
huddleClient.produceAudio(huddleClient.getAudioStream());
// Produce Video
huddleClient.produceVideo(huddleClient.getVideoStream())
Leaving the room #
// leave room
huddleClient.leaveRoom()
Event-Listeners #
// huddleEventListeners
void initState() {
huddleClient.huddleEventListeners();
super.initState();
}
Change Avatar Url #
// change url
String myUrl = 'YOUR_AVATAR_URL';
huddleClient.changeAvatarUrl(myUrl);
Set/Change Display Name #
// change name
String displayName = 'YOUR_NAME';
huddleClient.setDisplayName(displayName);
Kick Peer #
// kick peer
String kickPeerId = 12345;
huddleClient.kickPeer(kickPeerId);
Change Peer Role #
// change peer role
final peerRole = 'listener';
huddleClient.changePeerRole(peerRole);
Change Peer Controls #
// change peer controls
final peerControl = 'disableSounds';
huddleClient.changePeerControls(peerControl);
💡 For more information head to https://huddle01.com/docs
💡 For any help reach out to us on Discord