Dropbox integrations / Where to put dropbox access token

There is no place to add access token

image

Can’t customize or check whether that field is hidden. Possible permission issue?

I’m using Frappe version 14.

Please check the video.

This is the error I got

  File "apps/frappe/frappe/app.py", line 95, in application
    response = frappe.api.handle()
  File "apps/frappe/frappe/api.py", line 54, in handle
    return frappe.handler.handle()
  File "apps/frappe/frappe/handler.py", line 47, in handle
    data = execute_cmd(cmd)
  File "apps/frappe/frappe/handler.py", line 85, in execute_cmd
    return frappe.call(method, **frappe.form_dict)
  File "apps/frappe/frappe/__init__.py", line 1622, in call
    return fn(*args, **newargs)
  File "apps/frappe/frappe/integrations/doctype/dropbox_settings/dropbox_settings.py", line 346, in dropbox_auth_finish
    token = dropbox_oauth_flow.finish({"state": callback.state, "code": callback.code})
  File "env/lib/python3.10/site-packages/dropbox/oauth.py", line 534, in finish
    no_redirect_result = self._finish(code, self.redirect_uri, self.code_verifier)
  File "env/lib/python3.10/site-packages/dropbox/oauth.py", line 189, in _finish
    resp.raise_for_status()
  File "env/lib/python3.10/site-packages/requests/models.py", line 1021, in raise_for_status
    raise HTTPError(http_error_msg, response=self)
requests.exceptions.HTTPError: 400 Client Error: Bad Request for url: https://api.dropboxapi.com/oauth2/token```

I think there were some problems, I have tackled one by one.
Could it be because of the access token (from Dropbox) is not set in the ERPNext.
OR
Could it be because of some mistake in the Redirect URIs set in the Dropbox.

Well, since nobody interested ! I have figured it out.

Here are the lessons.

  1. The access token has nothing to do with configurations.
  2. The Redirect URL also is not wrong. But the error kept coming. Fix: Add the base URL to the site config.
  3. Additional tip: Add both access key and the secret key to the same site config. Once it is done the two fields disappear from the Dropbox settings page.
    Screenshot_6-6-2024_9413_self.stingray.lk

Now, no error for [ Allow Dropbox Access ] and then [ Take Backup Now ] appear.

I hope this helps somebody.