Create schedule meeting getting : 403 forbidden error and in response: Invalid CORS request

        const url1="https://api.zoom.us/v2/users/example@gmail.com/meetings"
        $.ajax({
            url:url1,
            type: "POST",
            data:JSON.stringify(datainfo),
             username: "example@gmail.com",
            dataType: "json",
            beforeSend: function (xhr) { xhr.setRequestHeader('Authorization', "Bearer <token>");
              xhr.setRequestHeader("Content-Type","application/json")
        },
          success: function (reponse) {
            
                      console.log(reponse)
                  }
              });

Hi,

Can you try the following:

  1. Install an interceptor extension to chrome, then enable it.

  2. Then add an “Origin” header to your request as below:
    Origin : https://developer.zoom.us

Let me know if it helps

This is the error getting after following that two steps

@goalstreets did you ever figure this out? I’m having the same issues.

Hi @kevin.cassidy,

Are you trying to make APIs calls using AJAX or on the client side?

Thanks

HI
I’m running in to the same problem of CORS
i want to create a meeting from the front end angular app. when i use ARC or postman I receive a status of 201 and everything is fine, but from the localhost I’m getting a CORS error
Access to XMLHttpRequest at ‘https://api.zoom.us/v2/users/me/meetings’ from origin ‘http://localhost:4200’ has been blocked by CORS policy: Response to preflight request doesn’t pass access control check: It does not have HTTP ok status

can I call the zoom api from the front end?

Hey @Jake.n,

You cannot call the Zoom API from the frontend. You must setup a proxy server to have a backend make the API request to the Zoom API.

Thanks,
Tommy

Thank you for your quick respond.
So even if i download Zoom Web SDK, or a different npm package I wont be able to make a request?
If yes, then is this permanently, because of security?
It works fine with postman and ARC.

Thank you
Jake

Hey @Jake.n,

Correct, the Web SDK is different from the APIs. The Web SDK puts Zoom meetings in your website, whereas the API allows you to take authorized actions on Zoom users behalf.

Postman is making requests via a backend server. Postman is not the frontend.

Thanks,
tommy