Code 124, "Invalid access token."

Description
This documentation is not detailed enough:
https://marketplace.zoom.us/docs/guides/tools-resources/postman/using-postman-to-test-zoom-apis

Error
{
“code”: 124,
“message”: “Invalid access token.”
}

Which App Type (OAuth / Chatbot / JWT / Webhook)?
{{baseUrl}}/users?status=active&page_size=30&page_number=1

Which Endpoint/s?
{{baseUrl}}/users?status=active&page_size=30&page_number=1

How To Reproduce (If applicable)
Low confidence that https://jwt.io/ produced the correct key given that this is the second weekend I have spent and failed on both occasions.
Your documentation mentions an API Key but I have been given an SDK Key.
Your documentation mentions an “exp” expiry number, but no help on what the format of this should be?
The error code 124 means nothing.

Additional context
You need to review your documentation and make it easier for API developers.
We do not have time to waste, and failure to provide adequate documentation about authentication reflects badly on Zoom.

1 Like

Hey @garry,

Can you send me your account # and email that you used to create the JWT App.

As a workaround, you can use an Account Level OAuth app and use the OAuth flow to get an access_token to call the Zoom API.

Thanks,
Tommy

Hi Tommy

Thanks for your reply.

My account number is < deleted >

My e-mail address is < deleted >

< deleted >

When you ask about email I used to create the account, this is interesting as I logged in with Google to create the account, and always have to start Zoom, and am unable to actually use my e-mail and a password to bypass Google login. Perhaps this is the problem?

I will try the workaround you suggested.

Kind Regards, Garry.

Hi Tommy

So I looked into the workarounds you suggested, and they look rather too involved for a quick Postman check, so I did a google search and found complaints similar to mine about JWT earlier this month.

I had been using JWT.io to create my JWT manually, but found other people had been using zoom.us to create JWT apps.

When I did the same, I received a new JWT bearer token, then plugged that into Postman and voila, my API calls are now working.

I also reset my garry@trisys.co.uk password having found a reset password link (via google) as there is not one on the profile page.

Thank you so much for your help as it galvanised me to take another path.

Kind Regards, Garry.

Hi Tommy

I have now progressed onto your SDK and have followed the guidelines at https://marketplace.zoom.us/docs/sd/native-sdks/web

however your sample code fails because you expect API keys to be 22 characters in length however mine is 36 characters.

“Api key length error, must 22”

Other people have complained about this at

https://devforum.zoom.us/t/invalid-parameter-websdk-1-7-6/14070

Sorry if some of the above URL’s are incorrect however Google Mail seemingly now does not support text pasting this morning!

Kind Regards, Garry.

Hey @garry,

Just replied to your post here:

Thanks,
Tommy

i face same problem please help me!

Hi Tommy

Did this get fixed as expected?
I just saw a comment today from another user who says it hasn’t been fixed?

Kind Regards, Garry.

So I pulled the latest code from https://github.com/zoom/sample-app-web
I then plugged my API keys into js/index.js and I still get the same error:

Invalid parameter

Hey @garry, @add,

Make sure you are using a JWT App for your API keys.

Thanks,
Tommy

Is this fixed . I am facing the same issue account number 3004285681

Hey @Jayasree,

The issue in the original topic is fixed yes. Can you please create a new topic and fill out the post template so we have enough info to help? :slight_smile:

Thanks,
Tommy

Good Morning, I can’t use my NYCDOE account. https://nycdoe.zoom.us/ I get this error: Token expired (124). https://nycdoe.zoom.us/confirm_sso_change_account?from=web&code=YRdCD7VQEjBNNmxkYJjzFsDh0--UIsp8NAg0U-5lmUc.BQkAAAF0gw9_JwAAAlgXTU1pY2hlbEBzY2hvb2xzLm55Yy5nb3YHFmgwcjVnVUFRU0ZLVjJ2VXVzdmRCaHdkAAAAAAAAAhhyN2hVa2JsV0Zud04zTHArd0NtTGtnPT0gNnZMUTEzNHU0NS9XdDlkakExY051Z0JKRXlrbHZNL0IWamVOLVJ6ZndUUE8wRm1TNTllYXpQZwAAAA

Hi @mmichel,

Can you please reach out to support.zoom.us? They will be best suited to assist you with your account.

Thanks,
Will

Hey@tommy
i am using account level oAuth app . i am receving code in redirect URL but how will i receive the same in my java code? Please help

Hey @zoom31,

If you’re going through the OAuth flow to generate an access_token, after you grab the code from the URL following installation of the app, you will need to pass this code as a parameter in your request to this endpoint:
POST https://zoom.us/oauth/token

This request will return your access_token, and in Java, it would look something like this:

OkHttpClient client = new OkHttpClient().newBuilder()
  .build();
MediaType mediaType = MediaType.parse("text/plain");
RequestBody body = RequestBody.create(mediaType, "");
Request request = new Request.Builder()
  .url("https://zoom.us/oauth/token?grant_type=authorization_code&code={yourCode}&redirect_uri={yourRedirectUri")
  .method("POST", body)
  .addHeader("Authorization", "Basic {Encoded Client Secret: Client Key}")
  .addHeader("Cookie", "_zm_lang=en-US; _zm_mtk_guid=85b1581b57884cae8199dc6228eace1e; _zm_ssid=us04_c_J32Z0u9AScqMznQ7cNB9CA; cred=A3DE8E87AE078B87BA581767EDAA8A84; _zm_ctaid=B3N5y88sRFaHL5bVR0TtdA.1603312359599.420bfa07089f494998402c43c972f6c0; _zm_chtaid=93")
  .build();
Response response = client.newCall(request).execute();

Let me know if this helps,
Will

Hi,
Can anyone please help me with Zoom API integration with Drupal? Need to create Zoom Webinars from the Drupal admin panel?

Currently, I am getting client error (Some authentication error)
I am getting 124 Invalid access token while checking through postman.

Thanks

Hey @shivalik.chopra ,

Please create a new topic and fill out the post template so we have enough info to help! :slight_smile:

Thanks,
Tommy