Flutter
One Flutter package for Android and iOS apps. Speakers publish their microphone, listeners join and listen.
import 'package:gravix_rtc/gravix_rtc.dart';
final room = GravixRoomService();
// Your server signs the token. The App Certificate never ships in the app.
final tokens = GravixTokenProvider.endpoint(
Uri.parse('https://api.example.com/rtc/token'),
headers: {'Authorization': 'Bearer $session'},
);
// Speakers publish their mic; listeners join the same room and listen.
final joined = await room.connectWithTokenProvider(
tokenProvider: tokens,
request: GravixTokenRequest(room: roomId, identity: userId, name: displayName),
publishMic: isOnStage,
enableVideo: false,
);
room.activeSpeakers.addListener(() => glowSeats(room.activeSpeakers.value));
// Leaving the room.
await room.disconnect();