The Zoom-sdk functions properly on a local machine, but encounters issues when it is

Using zoom's API, jwt, and the websdk, I am able to create a meeting on button click, join as a host, and start the meeting for others to join. This process works flawlessly when running locally, but once deployed to Cloudflare, I encounter the following error:

Your connection has timed out and you cannot join the meeting. Please check your network connectivity and try again.

Error details:

errorCode: 3706
errorMessage: undefined
method: "join"
result: "The meeting number is wrong."
status: false

The error message stating "The meeting number is wrong." seems misleading as the meeting number comes directly from zoom's API and functions correctly locally.

const joinMeeting = async (meetConfig: MeetConfigData) => {
    const ZoomMtg = require("@zoomus/websdk").ZoomMtg;
    ZoomMtg.setZoomJSLib("https://source.zoom.us/1.9.0/lib", "/av");
    ZoomMtg.preLoadWasm();
    ZoomMtg.prepareJssdk();

    const signature = await generateSignature(meetConfig.role, meetConfig.meetingNumber);

    ZoomMtg.init({
        leaveUrl: meetConfig.leaveUrl,
        isSupportAV: true,
        success: () => {
            ZoomMtg.join({
                signature,
                apiKey: "API_KEY",
                meetingNumber: meetConfig.meetingNumber,
                userName: meetConfig.userName,
                passWord: meetConfig.password,
                success: () => {
                    console.log("Successfully hosted or joined meeting.");
                },
                error: (err: Error) => {
                    console.log("Error: ", err);
                },
            });
        },
        error: (err: Error) => {
            console.log("Error: ", err);
        },
    });
};

The server-side signature method generates the correct signature, which suggests that the issue may lie elsewhere considering it works fine locally:

export const createSignature = ({ role, meetingNumber }) => {
    const timestamp = new Date().getTime() - 30000;
    const msg = Buffer.from(
        process.env.NEXT_PUBLIC_ZOOM_API_KEY + meetingNumber + timestamp + role
    ).toString("base64");
    const hash = crypto
        .createHmac("sha256", process.env.NEXT_PUBLIC_ZOOM_API_SECRET)
        .update(msg)
        .digest("base64");

    return Buffer.from(
        `${process.env.NEXT_PUBLIC_ZOOM_API_KEY}.${meetingNumber}.${timestamp}.${role}.${hash}`
    ).toString("base64");
};

Has anyone encountered similar issues before?

Answer №1

Encountering the message "Your connection has timed out and you cannot join the meeting" when trying to join a meeting that hasn't started? Take action to resolve this issue.

Begin by searching within your project for the following code:

<script src="https://source.zoom.us/zoom-meeting-1.7.8.min.js"></script>
and update it to 

<script src="https://source.zoom.us/zoom-meeting-2.1.1.min.js"></script>

1 Once this change is made, the error should disappear. 2

Similar questions

If you have not found the answer to your question or you are interested in this topic, then look at other similar questions below or use the search

Managing Multiple Operations in Angular Firestore

For the past few weeks, I've been grappling with the theory behind this issue. Despite scouring the internet for solutions, I haven't found anything truly helpful. So, I'm turning to the SO community for the first time. In my Firestore data ...

forming an instance from JSON information

In a .json file, I have data that includes information on countries such as their currency, major language, and land area in square kilometers or square miles. { "countries": { "sweden": { "currency": "Swedish krona", " ...

Obtain the ID of element 1 by clicking on element 2 using JQuery

In the world of javascript/jquery, When button1 is clicked, we can get its id like this: var button1id = $(this).attr("id"); If button2 is clicked, how do we retrieve button1's id? This brings us to the question: How does button2 access the i ...

The Vue component fails to respond to updates in plugin data

I am currently working on implementing a feature where a component reacts to data changes in a custom Vue plugin. To achieve this, the plugin creates a new instance of a Vue object in its constructor: this._vm = new Vue({ data: { obj: null, stat ...

Embed an external website within a div element

Is there a way to embed an entire external website onto another site, without scroll bars or borders? I attempted this method but the entire page did not load, and there were still scroll bars and borders present. <!DOCTYPE HTML> <html> <b ...

An issue arose during the installation of nodemon and jest, about errors with versions and a pes

Currently, I am facing an issue while trying to set up jest and nodemon for my nodejs project. My development environment includes vscode, npm version 6.13.7, and node version 13.8.0. Whenever I try to install nodemon via the command line, the console disp ...

What is the best way to update my component when the selected value is changed?

Currently, I am facing an issue with my map component. It plots polyline data based on the option selected from the select menu component. The problem arises when I change the value in the select menu and click the play button for the animation. Instead of ...

Is there a way to update a data element within a $.get request by utilizing information from a JSON array?

Is there a way to dynamically change a data element in a $.get request using values from a JSON array? Let's take a look at an example code snippet that achieves this: $.get(url, { 'p': testerName, ...

The function documents.getElementsById() is hindering the effectiveness of Javascript validation

I'm facing an issue with this code. If I uncomment the specific line, the form bypasses validation and goes directly to the linked page in the action attribute. However, if I keep it commented out, the validation runs smoothly, and the alert box displ ...

Issue: Incorrectly calling a hook. Hooks can only be used within the body of a function component. Assistance needed to resolve this issue

import React, { useState } from "react"; const RegistrationForm = () => { const [name, setName] = useState(""); const [password, setPassword] = useState(""); const [email, setEmail] = useState(" ...

The mysterious case of the vanishing close button on Curator.io's mobile

Currently, I am using curator.io aggregator to showcase my Instagram feed on the website. An issue arises when switching to mobile view as the close button (class="crt-close") disappears. You can see an example of this here: To replicate the pr ...

Implementing a Where Condition in JavaScript with the MongoDB whereObj

Working on a project involving JavaScript and MongoDB has led me to a specific collection named test_collection. Within this collection, there is a field/object called test_field_1 which contains test_sub_field_1 and test_sub_field_2. Currently, I am sett ...

The execution of JQuery/Javascript is restricted to only the initial condition within a Visualforce page utilizing the apex:outputpanel tag

After using only JavaScript for some time, I decided to try out jQuery. However, I'm facing an issue with executing a jQuery function. It seems that only the first condition in my code (the first IF) is being executed, while the second one (the second ...

What is the process for implementing a decorator pattern using typescript?

I'm on a quest to dynamically create instances of various classes without the need to explicitly define each one. My ultimate goal is to implement the decorator pattern, but I've hit a roadblock in TypeScript due to compilation limitations. Desp ...

How can you initialize Boostrap components or Materialize css in Angular 5 without using any external libraries?

I am a beginner exploring the world of Typescript and Angular. I am curious about how to initialize Bootstrap elements in an Angular-friendly manner without using the ngx-Bootstrap wrapper. For instance, if I wish to initiate a Bootstrap carousel. As per ...

disable the react .hover behavior once clicked

Can someone help me figure out why my attempt to cancel the .hover on function using .off is not working? $("document").ready(function(){ $("button").hover(function(){ $("h1").hide(); }, function(){ ...

Using Regular Expressions to eliminate any characters that are not directly adjacent to numbers (beside specific characters)

My function generates a result that looks like this: given output For comparison, consider the example string below: var string = '    111   1   1\n 1111111 1 \n   &nb ...

Is it better to use Rollup for exporting individual components instead of lumping them all into one index.js

Currently, I am working on developing a custom component library using React and Rollup for bundling. The current setup bundles all components into two large files: dist ├ cjs │ └ index.js (1.7mb) └ esm └ index.js (1.7mb) I would like to ...

Transform HTML into a Vue component dynamically during runtime

Currently, I am in the process of learning Vue and working on a simple wiki page project. The raw article data is stored in a JSON file written using custom markup. For example, the following markup: The ''sun'' is {r=black black} shoul ...