IMPROPER_MEETING_STATE error on using chat client

chat.sendToAll not working. I am using this simple function:
async function sendMessage(data) { await chat.sendToAll(${data}); }

Uncaught (in promise) {type: "IMPROPER_MEETING_STATE", reason: "closed"}

Which Web Video SDK version?
Knowing the version can help us to identify your issue faster. [e.g. 1.0]

To Reproduce(If applicable)
This is the basic gist of the code:

  1. import ZoomVideoSDK from ‘@zoom/videosdk’
  2. Add a ZoomVideoSDK.createClient() context and pass it on to child components
  3. Create a chat service by const chat = zmClient.getChatClient()
  4. chat.sendToAll(‘some text’)


Device (please complete the following information):

  • OS: Ubuntu 20.04
  • Browser: Chrome
  • Browser Version 91.0.4472.101 (Official Build) (64-bit)

Additional Information:

  1. This is error is by using the latest Zoom Video SDK applications (v1.1.0)

As given in API-references documentation in the sample app, I have also tried using const chat = client.getFeatureModule('chat'); but it also gives and error that getFeatureModule() does not exist.

Could you please help me resolve these errors? I would at least like to have a basic working chat session for my app. If either of these are wrong (code is wrong) please give me a working example for sendToAll() method.

Thanks in advance,

Soon after letting the app run for a while I am getting this error also

js_media.min.js:1 Uncaught RangeError: offset is out of bounds
    at Uint8Array.set (<anonymous>)
    at e.value (js_media.min.js:1)
    at e.value (js_media.min.js:1)
    at e.value (js_media.min.js:1)
    at js_media.min.js:1
    at RTCDataChannel.<anonymous> (js_media.min.js:1)
value @ js_media.min.js:1
value @ js_media.min.js:1
value @ js_media.min.js:1
(anonymous) @ js_media.min.js:1
(anonymous) @ js_media.min.js:1


Hey @krushnal

Thanks for your feedback. Maybe you should wait until client.join resolved, then call the chat.sendToAll method. Hope this can help you.


Hey @vic.yang
Thanks for the reply. I have dropped the chat functionality. Even then I am getting the second error

Getting this error after removing the chat client would mean that it is occurring somewhere else.
Also, I am already using async-await almost everywhere req.

Awaiting your reply,

Hey @krushnal ,

Can you provide steps to reproduce this second error? At what point is this error thrown in the Video SDK code in your project?


Here’s my code structure

  1. from 1st component pass meeting arguments and ZoomSDK.createClient() to 2nd component.
  2. the 2nd component just gives an option to join the meeting when onClick is triggered. when triggered, useEffect() calls
await zmClient.init("en-US", `${window.location.origin}/lib`);
await zmClient.join(topic, signature, name, password)

It also passes the zoomclient which was passed on from 1st client.
3. This is the main meeting session component. It has usual functionalities which include audio mute/unmute, video mute/unmute and a few other events defined.

That second error didn’t point to any specific line so I wasn’t able to narrow it down to a part of the code so I gave the structure of my code. After I click the button to join the meeting(in the 2nd component) the 3rd component automatically starts my audio and mutes it if unmuted in useEffect(). So when the 3rd component is called and after the useEffect() completes its job after a second or two I get the error. Its more of a warning (I think) as it doesn’t crash my app. However, it doesn’t allow me to print anything else in the console.

One thing I would like to point out is that in the sample app, the zoom client is used as a reactJS context. However, I am just passing it as a prop. would that be creating any issue?


Hey @krushnal ,

Does the Video SDK / desired functionality still work after the warning?

This could be the issue, I suggest trying it with reactJS context to see if you see the same warning.


yes just after posting the message I tried it and it still didn’t work.

yes the basic functionality works but I can’t do any more debugging for zoom as it constantly keeps sending the messages and any console output used for debugging just drowns in the warning statements.

pardon me for posting multiple topics but as this is the first time I am working on something like this, I am facing certain errors.

Thanks for understanding,

Hey @krushnal ,

Gotcha. For me on Chrome, if the warning is the same it consolidates them into one warning with a counter.

Here is a suggestion on how to suppress the warning messages: google chrome - Hide warning messages in console window - Stack Overflow


This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.