Skip to content

Commit

Permalink
PR Comments
Browse files Browse the repository at this point in the history
  • Loading branch information
tianjing-li committed Dec 5, 2023
1 parent 2e22fbf commit 826b56f
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 1 deletion.
2 changes: 2 additions & 0 deletions dropbox/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ This package is a utility for connecting Cohere to Dropbox, featuring a simple l

The Dropbox connector currently searches for all active files within your Dropbox instance. Note that new files added will require a couple minutes of indexing time to be searchable. Dropbox usually takes less than 5 minutes.

Currently, file contents are not decoded.

## Configuration

To use the Dropbox connector, first create an app in the [Developer App Console](https://www.dropbox.com/developers/apps). Select Scoped Access, and give it the access type it needs. Note that `App folder` access will give your app access to a folder specifically created for your app, while `Full Dropbox` access will give your app access to all files and folders currently in your Dropbox instance.
Expand Down
1 change: 1 addition & 0 deletions dropbox/provider/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,4 +30,5 @@ def create_app() -> connexion.FlaskApp:
1
].upper() # Current directory name, upper-cased
flask_app.config.from_prefixed_env(config_prefix)
flask_app.config["APP_ID"] = config_prefix
return flask_app
2 changes: 1 addition & 1 deletion dropbox/provider/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ def search(body):
except UpstreamProviderError as error:
logger.error(f"Upstream search error: {error.message}")
abort(502, error.message)
return {"results": data}
return {"results": data}, 200, {"X-Connector-Id": app.config.get("APP_ID")}


def apikey_auth(token):
Expand Down

0 comments on commit 826b56f

Please sign in to comment.