Skip to main content

Dropbox: Register App & Generate Token

Register App

  1. Visit the Dropbox Apps registration portal using Developer's Portal.

  2. Sign in with Dropbox credentials.

    Dropbox1
  3. On the page, click Create App. The app creation page appears.

    Dropbox2
  4. On the page, complete the following process to create an app:

    i. Choose an API.

    Dropbox3

    ii. Select the type of access you need.

    Dropbox4

    iii. Enter a unique app name.

    Dropbox5

    iv. Click Create App, and then provide redirect URIs, such as 'https://automationedge.com' or 'http://localhost:8080'.

    Dropbox6

    v. To provide required permissions on App registration portal, click Permissions tab and provide the appropriate permissions defined in step documentation.

    Dropbox7

Generate Refresh Token URL and Run in browser

  1. Call the following API in browser by adding the App Key and allow app to generate the authorization code:

    https://www.dropbox.com/oauth2/authorize?client_id=<AppKey>&token_access_type=offline&response_type=code
    Dropbox8
  2. Click Continue, and then click Allow.

    Dropbox9
  3. Copy the authorization code from Access Code Generated.

    Dropbox10
    Note:

    The authorization code is valid for short period of time.

  4. Create Post request in postman as follows:

    POST https://api.dropboxapi.com/oauth2/token
    Headers:
    Content-Type: application/x-www-form-urlencoded

    Authorization:
    Select  basic auth and provide
    Username: App Key
    Password: App Secret

    Body:
    Select -> x-www-form-urlencoded
    code: <authorization code generated in previous request>
    grant_type: authorization_code
    Dropbox11 Dropbox12
  5. Redeem the Refresh Token.