Oauth/token redirects to oauth/signin

Description
In the documentation located at https://marketplace.zoom.us/docs/guides/auth/oauth the API call for oath/token is called using the code gathered from oath/authorize. However, when I take that code and all the other requirements for oath/token and make the call, the response is HTML content from the following URL:

https://zoom.us/oauth/signin?_rnd=1587150466063&client_id&redirect_uri=&response_type&_x_zm_rtaid=tAkgwXs0SASxLwBK-JJyJw.1587150466062.f99016a0bfd7e10c817eee68728833dd&_x_zm_rhtaid=383”

I tried this server-side and client-side with the same response result. I tried client-side just to see if it was doing icky session checks, thus the redirect to signin.

The documentation states that a JSON result is returned on success, but it does not mention what result to expect on failure. So I expect this is some undesirable failure result. Undesirable because it would be so much more handy if, on failure, a JSON response with a reason for failure was returned!

My first thought is something off in the way I am creating the header for the call:

ClientID:ClientSecret
IFAJNnvTzyQ_Ue1hv3PCg:ERQHCytYJXYWCcHBb2BguRxTzAQDfFdz

Resulting Base64 String:
SUZBSk5udlR6eVFfVWUxaHYzUENnOkVSUUhDeXRZSlhZV0NjSEJiMkJndVJ4VHpBUURmRmR6

Applied as the header:
Authorization: Basic SUZBSk5udlR6eVFfVWUxaHYzUENnOkVSUUhDeXRZSlhZV0NjSEJiMkJndVJ4VHpBUURmRmR6

Just verified the Base64 conversion here: https://www.base64encode.org/

Here’s the URI I am using:
https://zoom.us/oauth/token?grant_type=authorization_code&code=Ty0VjQvN3V_pzBbxhWAQsSA_GZVVLnLZg&redirect_uri=

The code changes each time I run outh/authorize. Always leads to the redirect.

Error
HTTP redirect + HTML instead of JSON

Which App Type (OAuth / Chatbot / JWT / Webhook)?
OAuth

Which Endpoint/s?
oauth/token

How To Reproduce (If applicable)
Not sure in this case

Screenshots (If applicable)
N/A

Additional context
N/A

Self-solve!

I made the assumption that if the endpoint did not require POST data, then it must be a GET.

Switched to POST, and works.

Happy to hear you figured it out! :slight_smile:

Thanks,
Tommy

when I add button in my aapication
Add to ZOOM and when external user click on button then we got the message

You cannot authorize the app

This app cannot be installed outside of the developer’s account. Please contact the application developer to get support with installing this application.

please help me How I can add seeting so everyone can use this

Off topic, but I think I have an answer for you. Curious that it is related to a question I am asking in a different topic!

The OAuth API for your App is not published to the marketplace. This works fine for development purposes, but it does restrict your users to only that single Developer account which controls the APIs. Others will get this message that they are not authorized.

If you are ready to make this public, you can Publish to the Marketplace. If you are not ready, and still want to test with more users, those users need to be added to your Developer account. This can be done here:

Click on User Management. Here you can invite others to your account, and they will then be able to test using your unpublished API.

Official Dev Advocates, feel free to correct any points that may not be clear!

1 Like

Spot on @kmwill23!

@laxman, to install your OAuth / Chatbot app outside your Zoom account, you need to publish it to the Zoom App Marketplace.

Thanks,
Tommy