Can not get SSO token for SDK

Description/Error
I have created an OAuth app, and have turned on all scopes.

Which Endpoint/s?

How To Reproduce (If applicable)
Steps to reproduce the behavior:

  1. https://zoom.us/v2/users/{userId}/token
  2. “{“code”:4700,“message”:“Invalid access token, does not contain scopes: [user:write:admin, zms:user:write]”}”

Additional context
I am not sure what scopes I am missing.

Thanks,
Nate

Hey @nate,

Are you using a user-managed OAuth app?

If so can you try passing in me as the `{userId}?

Thanks,
Tommy

Hi tommy,

Does that work with just passing in the authToken as the identification of the user, as that is all I have on the server side to make that request for them.

Thanks,

Hey @nate,

If you pass in me as the {userId} it references the owner of the access_token who made the request to get the Client SDK token.

Thanks,
Tommy

I tried to pass in ‘me’ in the URL and got this response.

Thanks,

Hey @nate, apologies for not being more clear.

Once you have your OAuth access_token, use me in your request here:

GET https://zoom.us/v2/users/me/token

If this doesn’t clear things up then schedule a Zoom call with me so I can assist further :slight_smile:

Thanks,
Tommy

After I got the token, I tried to use it but it just give me a login in failure. I tried to use your demo app and it also fails login. I this the way we should be using this token?

I put a customer support ticket before I remembered that wasn’t the right place for this question.
https://support.zoom.us/hc/en-us/requests/1839757

If you could close that ticket it would be good.

Hey @nate,

What error are you getting and what SDK are you trying to use?

Thanks,
Tommy

I am using the Electron SDK. I get a status of 3 back from the LoginInWithSSOToken

Hey @nate,

After speaking with @Carson_Chen, the token generated from GET /users/{userId}/token is for joining and starting meetings without having to login. Not for logging users into the Electron SDK. Apologies for the confusion.

The SSO token should be generated by your Identity Provider(IDP), not from us. Here are more details about SSO login with Zoom:

The correct way to use the Electron SDK would be to have the user login. Or use the ZAK token to start / join meetings. Details here:

Thanks,
Tommy

So we should be able to start the meeting and join the meeting without logging in. But after I use this token will Zoom use the correct user in the meeting?

Is there a way that we can discuss Carson about a way to login to SDK with a token from OAuth.

Hi nate,

Thanks for the reply. If you authenticate with Zoom API and get zoom token and zak to start/join a meeting, then the Zoom SDK will recognize the user and show in the meeting.

The Zoom SDK does not support OAuth authentication at the moment.

Thanks!

1 Like

Thanks for the reply Carson. I will be trying to use the zak token

Thanks for the help Carson!

Let us know if you have additional questions @nate!

Thanks,
Tommy

Hi Tommy, and @Carson_Chen

I am still having some issues getting the meeting started.

I am calling
StartMeetingWithOutLogin(
{“zoomaccesstoken”:“myzak”,“userid”:“myuserid”,“usertoken”:“myaccesstoken”,“isvideooff”:true}
)

The usertoken is the access token I get from the refresh token
and the zoomaccesstoken is the zak token using https://zoom.us/v2/users/me/token?type=zak
But I get the result of: SDKERR_INVALID_PARAMETER

Is there something I am missing or have incorrect here?

Thanks,

Hi nate,

Thanks for the reply.

Besides the parameters, you also need to provide more information to be able to start a meeting, such as meeting number, displayname(username), you could find the list of parameters/options here:https://github.com/zoom/zoom-sdk-electron/blob/master/lib/zoom_meeting.js#L63

Thanks!

Hi @Carson_Chen ,

Thanks for the reply. I have seen the values there in the zoom_meeting.js before. My issue is I don’t know which values are required. I also didn’t know I needed a meeting number to start a meeting. So I should first create a meeting on the oauth side? Then I will be able to be host of the meeting?

Thanks,

Hi nate,

Thanks for the reply. You may find the required parameters/info for starting a meeting with ZAK here: https://marketplace.zoom.us/docs/sdk/native-sdks/preface/zak.

To start a meeting with ZAK, here are the brief steps:

  1. Authenticate with Zoom API using your API key & secret
  2. Schedule a meeting
  3. Pass the meeting number, displayname, userId, zoom token, zak to the startMeetingWithoutLogin method to start a meeting with ZAK
  4. If you are using the API key & secret that scheduled the meeting, you will be the host; Otherwise, you will join as an attendee.

Thanks!

1 Like