Skip to main content
Version: 0.0.x

Start or Join Meeting

After the successful installation of videoSDK, the next step is to integrate videoSDK features with your webApp/MobileApp.

To Communicate with other participant's audio or video call, you will need to join the meeting.

This guide will provide an overview of how to configure, initialize and join a VideoSDK meeting.

1. Configuration

To configure a meeting, you will need generated token and meetingId, we had discussed in Server Setup. This code snippet calls API from local server

Scenario 1 - Suppose you don't have any meetingId, you can simply generate meetingId by invoking create-meeting API.

Scenario 2 - Suppose you have meetingId, now you don't have to call create-meeting API to generate meetingId, instead you can call validate-meeting API to validate meetingId.

Token generation API is necessary for both scenario.


You can take advantage of regional API to decrease latency in video calling.

To achieve region based meetings, just pass region : REGION_CODE parameter in create-meeting request Body.

Currently the below regions are supported:

  • sg001 Region Code for Singapore, SG.
  • uk001 Region Code for London, UK.
  • us001 Region Code for Fremont, CA.
  • eu001 Region Code for Frankfurt, DE.

In case you are not providing any region code, the default region will be sg001.

import 'dart:convert';
import 'package:http/http.dart' as http; // For API Calling, you need to add third party package "http"
import 'package:videosdk/rtc.dart';

// States Defined in Stateful Component.
String? meetingId;
String? token;

void _getMeetingIdAndToken() async {
final LOCAL_SERVER_URL = dotenv.env['LOCAL_SERVER_URL'];

// Calling get-token API.
final Uri tokenUrl = Uri.parse('$LOCAL_SERVER_URL/get-token');
final http.Response tokenResponse = await http.get(tokenUrl);

final dynamic _token = json.decode(tokenResponse.body)['token'];

// Calling create-meeting API.
final Uri meetingIdUrl =

final http.Response meetingIdResponse =
await, body: {"token": _token,"region": "sg001"});

final _meetingId = json.decode(meetingIdResponse.body)['meetingId'];

// Setting into states of stateful widget
setState(() {
token = _token;
meetingId = _meetingId;

// This API is for validate the meeting id
// Not require to call this API after create meeting API

dynamic validateMeeting(token, meetingId) async {
final String LOCAL_SERVER_URL = dotenv.env['LOCAL_SERVER_URL'];
final Uri validateMeetingUrl =
final http.Response validateMeetingResponse =
await, body: {"token": token});
final _meetingId = json.decode(validateMeetingResponse.body)['meetingId'];
if (_meetingId != null) {
return _meetingId;
} else {
return null;

2. Initialization

After configuration, you will have to Initialize

meeting by providing name, meetingId, micEnabled, webcamEnabled & maxResolution.

import 'package:flutter/material.dart';
import 'package:videosdk/rtc.dart';

class MyApp extends StatelessWidget {
Widget build(BuildContext context) {
return MeetingBuilder(
meetingId: "<Id-on-meeting>",
displayName: "<Name-of-participant>",
micEnabled: "<Flag-to-enable-mic>",
webcamEnabled: "<Flag-to-enable-webcam>",
token: "<Authentication-token>",
builder: (Meeting: meeting) {
// Do Something
return Container(); // Returning widget

3. Join

After configuration & initialization, the third step is to call join() to join a meeting.

After joining, you will be able to Manage Participant in a meeting.

// Join the meeting