Start 2025 on time and up to date. Seamlessly integrate your calendars into Dropbox with these simple steps.

Forum Discussion

Fomka_Wyverno's avatar
Fomka_Wyverno
New member | Level 2
2 years ago

Get Access Token JavaScript in fetch

    const parameters = { 'code': params.code, 'grant_type': 'authorization_code', 'redirect_uri': window.location.origin, ...
  • Greg-DB's avatar
    Greg-DB
    2 years ago

    It looks like you're sending the parameters as JSON, but the /oauth2/token endpoint expects them as application/x-www-form-urlencoded POST parameters, and so your parameters aren't getting read. Update your implementation to send application/x-www-form-urlencoded POST parameters instead.

About Discuss Dropbox Developer & API

Node avatar for Discuss Dropbox Developer & API
Make connections with other developers799 PostsLatest Activity: 4 days ago
203 Following

If you need more help you can view your support options (expected response time for an email or ticket is 24 hours), or contact us on X or Facebook.

For more info on available support options for your Dropbox plan, see this article.

If you found the answer to your question in this Community thread, please 'like' the post to say thanks and to let us know it was useful!