Socket
Socket
Sign inDemoInstall

@codingfingers/next-dropbox

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@codingfingers/next-dropbox

Tools for using Dropbox API in your NextJS app


Version published
Weekly downloads
1
Maintainers
1
Weekly downloads
 
Created
Source

NextJS + Dropbox API tools

Tools for using some of Dropbox API in your NextJS app. List files from any folder on your static page and benefit from automatic revalidation based on Dropbox webhooks.

Environment variables

Variable nameDescription
DROPBOX_APP_KEYYour app's key
DROPBOX_APP_SECRETYour app's secret
DROPBOX_REFRESH_TOKENNever-expiring refresh token

Creating a Dropbox app

TODO: Write docs for app creation

Obtaining refresh token

  1. Replace the variable in the link below with your app's key and visit the URL in a browser:
https://www.dropbox.com/oauth2/authorize?client_id=<DROPBOX_APP_KEY>&token_access_type=offline&response_type=code
  1. Authorize the app access and copy the <ACCESS_CODE>
  2. Replace variables in the curl request below:
curl --location --request POST 'https://api.dropboxapi.com/oauth2/token' \
-u '<DROPBOX_APP_KEY>:<DROPBOX_APP_SECRET>' \
-H 'Content-Type: application/x-www-form-urlencoded' \
--data-urlencode 'code=<ACCESS_CODE>' \
--data-urlencode 'grant_type=authorization_code'
  1. Execute the command and copy the refresh_token

Keywords

FAQs

Package last updated on 11 Mar 2023

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc