A powerful Python-based Dropbox file manager using the mcp agent framework. Easily manage, upload, download, delete, move, rename, and restore files and folders from your Dropbox account.
- ✅ Upload single or multiple files (from URL or local path)
- 📥 Download any file to a temporary path
- ❌ Delete files or folders
- ✏️ Rename files or folders
- 📂 Move files or folders across directories
- ♻️ Restore previous file revisions
- 🔍 Search files and folders
- 🕵️♂️ List files, folders, and file revisions
- Python 3.8+
- Dropbox SDK
- mcp
-
Clone the repository
git clone https://github.com/your-username/dropbox-mcp-tool.git cd dropbox-mcp-tool -
Install dependencies
pip install -r requirements.txt
-
Authenticate Dropbox
You must authenticate your Dropbox using OAuth2 and save the token securely.
Create a .env file (or however you store tokens securely)
DROPBOX_ACCESS_TOKEN=your_access_token_hereEach method is defined using @mcp.tool() decorator. Here are the tools:
download_file_to_tmp(path: str, name: Optional[str])delete_file_or_folder(path: str)list_files_and_folders(path: str, recursive=True, ...)search_files_folders(query: str, max_results=10)list_file_revisions(path: str, mode: Optional[str], limit: Optional[int])restore_file(path: str, rev: str)rename_file_folder(path_from: str, new_name: str, ...)move_file_folder(path_from: str, path_to: str, ...)upload_file_to_dropbox(file_url=None, file_path=None, ...)upload_multiple_files_to_dropbox(file_urls=[], file_paths=[], filenames=[], ...)res = upload_file_to_dropbox(
file_path="/home/user/report.pdf",
dropbox_folder_path="/reports",
file_name="report.pdf",
)
print(res)- All exceptions are gracefully handled and return structured error responses.
- File validation (e.g., renaming rules) is enforced to avoid API rejections.
- Requires valid Dropbox API access token.
MIT License © 2025 [@sukeshofficial]
Pull requests are welcome! Please open an issue first for major changes.