# JsMediaSDK\_Instance is not defined ReferenceError: JsMediaSDK\_Instance is not defined

**URL:** <https://devforum.zoom.us/t/jsmediasdk-instance-is-not-defined-referenceerror-jsmediasdk-instance-is-not-defined/91383>\
**Category:** Video SDK\
**Created:** [July 6, 2023, 2:03am UTC](https://devforum.zoom.us/t/jsmediasdk-instance-is-not-defined-referenceerror-jsmediasdk-instance-is-not-defined/91383 "2023-07-06T02:03:44Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![EH2077](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/eh2077/32/49820_2.png) [@EH2077](https://devforum.zoom.us/u/EH2077)\
**Post date:** [July 6, 2023, 2:03am UTC](https://devforum.zoom.us/t/jsmediasdk-instance-is-not-defined-referenceerror-jsmediasdk-instance-is-not-defined/91383/1 "2023-07-06T02:03:44Z")

</div>

### Before Creating a New Topic:

_If you’re experiencing unexpected Video SDK behavior please search the forum with relevant keywords (e.x. error message) and follow the guidance outlined in those posts. Please also leverage the following support links:_

- Zoom Developer Changelog for Dev Product Changes: [https://marketplace.zoom.us/docs/guides/stay-up-to-date/changelog/](https://marketplace.zoom.us/docs/guides/stay-up-to-date/changelog/)
- General Troubleshooting: [Support](https://devsupport.zoom.us/hc/en-us)
- To Submit a Ticket for Unexpected Video SDK Behavior: [Official Zoom Support | Help Center](https://support.zoom.us/hc/en-us)
- For General & Integrations Related Guidance: [https://community.zoom.com/](https://community.zoom.com/)

* * *

### Format Your New Topic as Follows:

**Video SDK Type and Version**  
_Newest Video SDK._

**Description**  
_When the second participant opens localhost/video, JsMediaSDK\_Instance is not defined  
ReferenceError: JsMediaSDK\_Instance is not defined error occurs ._

**Error?**  
_JsMediaSDK\_Instance is not defined  
ReferenceError: JsMediaSDK\_Instance is not defined  
at qs.getPTZCapability ([http://localhost:3000/static/js/bundle.js:18844:30](http://localhost:3000/static/js/bundle.js:18844:30))  
at H\_ ([http://localhost:3000/static/js/bundle.js:27012:18](http://localhost:3000/static/js/bundle.js:27012:18))  
at F\_ ([http://localhost:3000/static/js/bundle.js:26996:21](http://localhost:3000/static/js/bundle.js:26996:21))  
at [http://localhost:3000/static/js/bundle.js:27058:19](http://localhost:3000/static/js/bundle.js:27058:19)  
at t.project ([http://localhost:3000/static/js/bundle.js:27080:8](http://localhost:3000/static/js/bundle.js:27080:8))  
at t.\_next ([http://localhost:3000/static/js/bundle.js:15388:20](http://localhost:3000/static/js/bundle.js:15388:20))  
at t.next ([http://localhost:3000/static/js/bundle.js:13807:32](http://localhost:3000/static/js/bundle.js:13807:32))  
at t.\_next ([http://localhost:3000/static/js/bundle.js:14863:31](http://localhost:3000/static/js/bundle.js:14863:31))  
at t.next ([http://localhost:3000/static/js/bundle.js:13807:32](http://localhost:3000/static/js/bundle.js:13807:32))  
at t.\_next ([http://localhost:3000/static/js/bundle.js:15576:65](http://localhost:3000/static/js/bundle.js:15576:65))_

**Troubleshooting Routes**  
_The troubleshooting attempt types you’ve already exhausted, including testing with the appropriate sample app (found on [Zoom · GitHub](https://github.com/zoom))._

**How To Reproduce**  
_Steps to reproduce the behavior including:_  
_1. Authentication method or app type_  
_2. Any errors_  
_3. Browser/client type and version_

---

<div class="post-metadata">

**Author:** ![chunsiong.zoom](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/chunsiong.zoom/32/35488_2.png) [@chunsiong.zoom](https://devforum.zoom.us/u/chunsiong.zoom)\
**Post date:** [July 6, 2023, 4:44am UTC](https://devforum.zoom.us/t/jsmediasdk-instance-is-not-defined-referenceerror-jsmediasdk-instance-is-not-defined/91383/2 "2023-07-06T04:44:40Z")

</div>

@EH2077 ,

Could you share the specific

1. Video SDK version
2. browser and operating system
3. URL of the.sample code which you are using

---

<div class="post-metadata">

**Author:** ![EH2077](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/eh2077/32/49820_2.png) [@EH2077](https://devforum.zoom.us/u/EH2077)\
**Post date:** [July 6, 2023, 4:58am UTC](https://devforum.zoom.us/t/jsmediasdk-instance-is-not-defined-referenceerror-jsmediasdk-instance-is-not-defined/91383/3 "2023-07-06T04:58:39Z")

</div>

Thanks for replying, my video sdk version is 1.7.10, browser is Chrome, os is macOS ventura 13.4. I am using my own code now in a private repo currently, any suggestions for which part of the code could possibly cause the error?

---

<div class="post-metadata">

**Author:** ![chunsiong.zoom](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/chunsiong.zoom/32/35488_2.png) [@chunsiong.zoom](https://devforum.zoom.us/u/chunsiong.zoom)\
**Post date:** [July 6, 2023, 5:05am UTC](https://devforum.zoom.us/t/jsmediasdk-instance-is-not-defined-referenceerror-jsmediasdk-instance-is-not-defined/91383/4 "2023-07-06T05:05:03Z")

</div>

@EH2077 Its hard to troubleshoot as this is your custom code, and we do not extensively debug code over the developer forum.

From some of the past forum post, your issue might be caused by a race condition. In other words, there is a possibility that the web application is referencing to our SDK object before it has completely loaded from the web.

Here’s one of the thread which you might find useful

> [@JSMediaSdk\_Instance not defined](https://devforum.zoom.us/t/jsmediasdk-instance-not-defined/8177/3):
>
> hello again, looks like this can be circumvented by setting ZoomMtg.setZoomJSLib(‘http://[URL]/node\_modules/@zoomus/websdk/dist/lib’, ‘/av’); … and copying ‘node\_modules/@zoomus/websdk/dist/lib’ to the corresponding webroot. this way, the AV libs dont need to be fetched from the default URL ([source.zoom.us](http://source.zoom.us) i guess), and JsMediaSDK\_Instance is known instantly… @zoom: is it possible that this JsMediaSDK\_Instance - error can be triggered by calling ZoomMtg.join() BEFORE ZoomMtg.prepareJssdk(); …

do tag me in your response to get my attention to reply
