Getting 3008 code: please init meeting first! with web sdk even meeting is already running

I try to connect my site (drupal) with zoom live meeting/webinar.
I’ve purchased webinar licences and
how can I know if the signature that I’m creating is correct?
the error message is: please init… and I did it… 3008 error code

ZoomMtg.init({
debug: true,
leaveUrl: meetConfig.leaveUrl,
isSupportAV: true,
success: function(e) {
console.log(e);
ZoomMtg.join({
apiKey: meetConfig.apiKey,
signature: meetConfig.signature,
meetingNumber: meetConfig.meetingNumber,
userName: meetConfig.userName,
// Email required for Webinars
userEmail: meetConfig.userEmail,
passWord: “”,
success: function (res) {
console.log(‘join meeting success’);
},
error: function (res) {
console.log(‘error’, res);
}
})
},
error: function() {
console.log('failed to init meeting ’ + meetConfig.meetingNumber);
}
});

web sdk version: 1.72
will appreciate your fast help!
Thanks

1 Like

Hey @webisinc, thanks for posting and using Zoom!

I don’t believe this to be an issue with the signature.

Have you included the following lines above the ZoomMtg.init() function?

ZoomMtg.preLoadWasm();

ZoomMtg.prepareJssdk();

Thanks,
Tommy

yes exactly, what can be the cause of this error?

Hi Tommy,

I would like to extend the question.

Yes, indeed we do have
ZoomMtg.preLoadWasm();
ZoomMtg.prepareJssdk();
lines in our code, exactly as it states in the Example App. Yet, it’s working for us in the example app and not working when we try to integrate this in our javascript.

Trying to investigate the issue more, we notice that in the Example App (both Local and CDN) versions, upon meeting init there is an additional request that is sent by the browser and looks like:

https://zoom.us/api/v1/wc/info?callback=localJsonpCallback&meetingNumber={{my-meeting-number}}&userName=WebSDK1.7.2%23CDN&passWord=&signature={{my-generated-signature}}&apiKey={{my-api-key}}&lang=en-US&userEmail=email%40gmail.com&cv=1.7.2&proxy=1&rwc=&_=1585078266958

Only if this request is successful, the meeting starts.
BUT, this request does not happen when I try to run exactly SAME code from my app.

I copy MY javascript below (we use the CDN version, and I do connect all the scripts).

(function(){

  console.log('checkSystemRequirements');
  console.log(JSON.stringify(ZoomMtg.checkSystemRequirements()));

  // it's option if you want to change the WebSDK dependency link resources. setZoomJSLib must be run at first
  // if (!china) ZoomMtg.setZoomJSLib('https://source.zoom.us/1.7.2/lib', '/av'); // CDN version default
  // else ZoomMtg.setZoomJSLib('https://jssdk.zoomus.cn/1.7.2/lib', '/av'); // china cdn option
  // ZoomMtg.setZoomJSLib('http://localhost:9999/node_modules/@zoomus/websdk/dist/lib', '/av'); // Local version default, Angular Project change to use cdn version
  ZoomMtg.preLoadWasm();

  ZoomMtg.prepareJssdk();

  var API_KEY = 'MY-API-KEY';

  /**
   * NEVER PUT YOUR ACTUAL API SECRET IN CLIENT SIDE CODE, THIS IS JUST FOR QUICK PROTOTYPING
   * The below generateSignature should be done server side as not to expose your api secret in public
   * You can find an eaxmple in here: https://marketplace.zoom.us/docs/sdk/native-sdks/Web-Client-SDK/tutorial/generate-signature
   */
  var API_SECRET = 'MY-API-SECRET';


  document.getElementById('join_meeting').addEventListener('click', function(e){
    e.preventDefault();


    var meetConfig = {
      apiKey: API_KEY,
      apiSecret: API_SECRET,
      meetingNumber: ACTUAL_MEETING_NUMBER,
      userName: 'sample user',
      passWord: "",
      leaveUrl: "https://zoom.us",
      role: 0
    };


    var signature = ZoomMtg.generateSignature({
      meetingNumber: meetConfig.meetingNumber,
      apiKey: meetConfig.apiKey,
      apiSecret: meetConfig.apiSecret,
      role: meetConfig.role,
      success: function(res){
        console.log(res.result);
      }
    });

    ZoomMtg.init({
      leaveUrl: 'http://www.zoom.us',
      isSupportAV: true,
      success: function () {
        ZoomMtg.join(
          {
            meetingNumber: meetConfig.meetingNumber,
            userName: meetConfig.userName,
            signature: signature,
            apiKey: meetConfig.apiKey,
            userEmail: 'email@gmail.com',
            passWord: meetConfig.passWord,
            success: function(res){
              $('#nav-tool').hide();
              console.log('join meeting success');
            },
            error: function(res) {
              console.log(res);
            }
          }
        );
      },
      error: function(res) {
        console.log(res);
      }
    });

  });

})();

Please help, we’ve already spent hours on this issue, this is really crucial for us to get this working!

Hey @miraje, @webisinc,

Depending on how your app is setup and if you are using the Web SDK Local or CDN version, try adding the following before the the PreLoad and Prepare functions:

ZoomMtg.setZoomJSLib('https://source.zoom.us/1.7.2/lib', '/av');

Let me know if that works.

Also, we have an Angular Sample App here that correctly integrates the Local version of Web SDK via NPM / node_modules.

Thanks,
Tommy

Hi @tommy,
Thanks for response.
We are using CDN version for integration with our app.
I have added this line
ZoomMtg.setZoomJSLib(‘https://source.zoom.us/1.7.2/lib’, ‘/av’);
but unfortunately it didn’t help.

Looking into your angular version.

Dunno, not sure the angular version would work for us,
We are trying to integrate with Drupal CMS. e.g to present our webinar(s) on existing web page, I’m afraid angular would not work here.

I think that the major problem is that on Example App CDN version it sends request to https://zoom.us/api/v1/wc/info with parameters, but when we add exactly same script to CMS’ webpage – it doesn’t.

What could be wrong?
With call to ZoomMtg.setZoomJSLib it also doesn’t :frowning:

Hey @miraje,

Can you add a param to the ZoomMtg.Init success function and a console log to see if it is getting a response?

For example:

 ZoomMtg.init({
      leaveUrl: 'http://www.zoom.us',
      isSupportAV: true,
      success: function (res) {
        console.log(res)

Thanks,
Tommy