Zoom SDK Integration for Video Conferencing on Website

Our company is engaged in the development, support and maintenance of sites of any complexity. From simple one-page sites to large-scale cluster systems built on micro services. Experience of developers is confirmed by certificates from vendors.
Development and maintenance of all types of websites:
Informational websites or web applications
Business card websites, landing pages, corporate websites, online catalogs, quizzes, promo websites, blogs, news resources, informational portals, forums, aggregators
E-commerce websites or web applications
Online stores, B2B portals, marketplaces, online exchanges, cashback websites, exchanges, dropshipping platforms, product parsers
Business process management web applications
CRM systems, ERP systems, corporate portals, production management systems, information parsers
Electronic service websites or web applications
Classified ads platforms, online schools, online cinemas, website builders, portals for electronic services, video hosting platforms, thematic portals

These are just some of the technical types of websites we work with, and each of them can have its own specific features and functionality, as well as be customized to meet the specific needs and goals of the client.

Our competencies:
Development stages
Latest works
  • image_web-applications_feedme_466_0.webp
    Development of a web application for FEEDME
    1161
  • image_ecommerce_furnoro_435_0.webp
    Development of an online store for the company FURNORO
    1041
  • image_crm_enviok_479_0.webp
    Development of a web application for Enviok
    822
  • image_crm_chasseurs_493_0.webp
    CRM development for Chasseurs
    847
  • image_website-sbh_0.png
    Website development for SBH Partners
    999
  • image_website-_0.png
    Website development for Red Pear
    451

Zoom SDK Integration for Video Conferencing on Website

Zoom offers two embedding paths: Meeting SDK (full Zoom client in iframe/widget) and Video SDK (low-level API for custom UI). Meeting SDK deploys faster; Video SDK provides full UI control.

Meeting SDK—Embedding Ready Interface

npm install @zoom/meetingsdk
import { ZoomMtg } from '@zoom/meetingsdk';

// Initialize once on load
ZoomMtg.setZoomJSLib('https://source.zoom.us/3.9.5/lib', '/av');
ZoomMtg.preLoadWasm();
ZoomMtg.prepareWebSDK();

async function joinZoomMeeting(params: {
  meetingNumber: string;
  userName: string;
  signature: string;
  password: string;
}) {
  ZoomMtg.init({
    leaveUrl: `${window.location.origin}/meeting-ended`,
    patchJsMedia: true,
    leaveOnPageUnload: true,
    success: () => {
      ZoomMtg.join({
        meetingNumber: params.meetingNumber,
        userName: params.userName,
        signature: params.signature,
        sdkKey: process.env.NEXT_PUBLIC_ZOOM_SDK_KEY!,
        password: params.password,
        success: () => console.log('Joined meeting'),
        error: (err) => console.error('Join error:', err),
      });
    },
  });
}

Signature Generation on Server

import crypto from 'crypto';

export function generateZoomSignature(
  sdkKey: string,
  sdkSecret: string,
  meetingNumber: string,
  role: 0 | 1  // 0 = attendee, 1 = host
): string {
  const timestamp = new Date().getTime() - 30000;
  const msg = Buffer.from(`${sdkKey}${meetingNumber}${timestamp}${role}`).toString('base64');
  const hash = crypto.createHmac('sha256', sdkSecret).update(msg).digest('base64');
  const signature = Buffer.from(
    `${sdkKey}.${meetingNumber}.${timestamp}.${role}.${hash}`
  ).toString('base64');
  return signature;
}

// API endpoint
app.get('/api/zoom/signature', authenticate, (req, res) => {
  const { meetingNumber, role = 0 } = req.query;

  const signature = generateZoomSignature(
    process.env.ZOOM_SDK_KEY!,
    process.env.ZOOM_SDK_SECRET!,
    meetingNumber as string,
    Number(role) as 0 | 1
  );

  res.json({ signature });
});

Creating Meetings via Zoom API

async function createZoomMeeting(params: {
  topic: string;
  startTime: Date;
  durationMinutes: number;
  hostEmail: string;
}): Promise<{ id: string; joinUrl: string; password: string }> {
  // Get access token via OAuth Server-to-Server
  const tokenResponse = await fetch(
    `https://zoom.us/oauth/token?grant_type=account_credentials&account_id=${process.env.ZOOM_ACCOUNT_ID}`,
    {
      method: 'POST',
      headers: {
        'Authorization': `Basic ${Buffer.from(
          `${process.env.ZOOM_CLIENT_ID}:${process.env.ZOOM_CLIENT_SECRET}`
        ).toString('base64')}`,
      },
    }
  );
  const { access_token } = await tokenResponse.json();

  // Create meeting
  const meetingResponse = await fetch(
    `https://api.zoom.us/v2/users/${params.hostEmail}/meetings`,
    {
      method: 'POST',
      headers: {
        'Authorization': `Bearer ${access_token}`,
        'Content-Type': 'application/json',
      },
      body: JSON.stringify({
        topic: params.topic,
        type: 2,  // scheduled
        start_time: params.startTime.toISOString(),
        duration: params.durationMinutes,
        timezone: 'Europe/Moscow',
        settings: {
          waiting_room: true,
          join_before_host: false,
          mute_upon_entry: true,
          auto_recording: 'none',
        },
      }),
    }
  );

  const meeting = await meetingResponse.json();
  return {
    id: String(meeting.id),
    joinUrl: meeting.join_url,
    password: meeting.password,
  };
}

Zoom Webhooks

app.post('/api/webhooks/zoom', async (req, res) => {
  // Webhook endpoint verification
  if (req.body.event === 'endpoint.url_validation') {
    const hashForValidate = crypto
      .createHmac('sha256', process.env.ZOOM_WEBHOOK_SECRET_TOKEN!)
      .update(req.body.payload.plainToken)
      .digest('hex');

    return res.json({
      plainToken: req.body.payload.plainToken,
      encryptedToken: hashForValidate,
    });
  }

  const { event, payload } = req.body;

  switch (event) {
    case 'meeting.started':
      await db.meetings.markStarted(payload.object.id);
      break;
    case 'meeting.ended':
      await db.meetings.markEnded(payload.object.id, payload.object.duration);
      break;
    case 'meeting.participant_joined':
      await db.meetings.addParticipant(
        payload.object.id,
        payload.object.participant.user_name
      );
      break;
  }

  res.status(200).end();
});

Timeline

Zoom Meeting SDK integration + signature + creating meetings via API—3–4 days. With webhooks and Video SDK for custom UI—1–1.5 weeks.