Note to first-time contributors: Please open a discussion post in Discussions and describe your changes before submitting a pull request.
Before submitting, make sure you've checked the following:
Target branch: Please verify that the pull request targets the dev branch.
Description: Provide a concise description of the changes made in this pull request.
Changelog: Ensure a changelog entry following the format of Keep a Changelog is added at the bottom of the PR description.
Documentation: Have you updated relevant documentation Open WebUI Docs, or other documentation sources?
Dependencies: Are there any new dependencies? Have you updated the dependency versions in the documentation?
Testing: Have you written and run sufficient tests for validating the changes?
Code review: Have you performed a self-review of your code, addressing any coding standard issues and ensuring adherence to the project's coding standards?
Prefix: To cleary categorize this pull request, prefix the pull request title, using one of the following:
BREAKING CHANGE: Significant changes that may affect compatibility
build: Changes that affect the build system or external dependencies
ci: Changes to our continuous integration processes or workflows
chore: Refactor, cleanup, or other non-functional code changes
docs: Documentation update or addition
feat: Introduces a new feature or enhancement to the codebase
fix: Bug fix or error correction
i18n: Internationalization or localization changes
perf: Performance improvement
refactor: Code restructuring for better maintainability, readability, or scalability
style: Changes that do not affect the meaning of the code (white-space, formatting, missing semi-colons, etc.)
test: Adding missing tests or correcting existing tests
WIP: Work in progress, a temporary label for incomplete or ongoing work
Changelog Entry
Description
Adds support for requested functionality in feat: data sources #5872 for Google Drive directly in the chat flow
Added
New item where "Upload files" is in the "+" picker for Google Drive uploads
Support for docs, sheets and slides
Support for Google oauth id and secret key in config endpoint
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.
## 📋 Pull Request Information
**Original PR:** https://github.com/open-webui/open-webui/pull/7900
**Author:** [@taylorwilsdon](https://github.com/taylorwilsdon)
**Created:** 12/16/2024
**Status:** ✅ Merged
**Merged:** 12/19/2024
**Merged by:** [@tjbck](https://github.com/tjbck)
**Base:** `dev` ← **Head:** `add_google_drive_integration`
---
### 📝 Commits (10+)
- [`61b1a8f`](https://github.com/open-webui/open-webui/commit/61b1a8fdabb4562c22678562519864f08cb362a2) feat: Add Google Drive file picker integration to chat interface
- [`f566c59`](https://github.com/open-webui/open-webui/commit/f566c5940a7606221d4953061d357f8aebbcae58) feat: Add Google Drive picker button to MessageInput component
- [`90e7060`](https://github.com/open-webui/open-webui/commit/90e70608b9ba5520309a846666fd691fab2f6b40) feat: Add Google Drive upload option to InputMenu
- [`7bc1876`](https://github.com/open-webui/open-webui/commit/7bc1876e37fc6aead331e436dafb39d5c0ee8f2d) fix: Resolve Google Drive picker promise with file data
- [`1cd43b1`](https://github.com/open-webui/open-webui/commit/1cd43b122bc92193933d40603661cc16d01f5b36) feat: Import createPicker function in InputMenu component
- [`b2dc6fe`](https://github.com/open-webui/open-webui/commit/b2dc6fef9fe4994fde8547730fb3b68d87266cee) fix: Improve Google Drive picker API loading and error handling
- [`eed7cfd`](https://github.com/open-webui/open-webui/commit/eed7cfd2a298af9f760f9b09044695ec02744cd2) refactor: Remove unused Google Drive picker imports from Chat.svelte
- [`8550810`](https://github.com/open-webui/open-webui/commit/85508106a8ecbfde153404dc4e213b2cc8b367d8) fix: Improve Google Drive picker initialization and error handling
- [`f29dc2f`](https://github.com/open-webui/open-webui/commit/f29dc2f86547a41fe78d9887bbae5ed6c1a7e7fe) fix: Add missing import for createPicker in MessageInput.svelte
- [`a0ba597`](https://github.com/open-webui/open-webui/commit/a0ba5974f66e1e945478df3614bc6519def274a0) feat: Add credential validation for Google Drive API initialization
### 📊 Changes
**15 files changed** (+770 additions, -285 deletions)
<details>
<summary>View changed files</summary>
📝 `backend/open_webui/config.py` (+19 -0)
📝 `backend/open_webui/main.py` (+9 -0)
📝 `backend/open_webui/routers/knowledge.py` (+19 -16)
📝 `backend/open_webui/routers/retrieval.py` (+9 -0)
📝 `backend/open_webui/static/swagger-ui/swagger-ui-bundle.js` (+28 -34)
📝 `backend/requirements.txt` (+5 -0)
📝 `package-lock.json` (+11 -9)
📝 `src/lib/apis/retrieval/index.ts` (+1 -0)
📝 `src/lib/components/admin/Settings/Documents.svelte` (+219 -195)
📝 `src/lib/components/chat/Chat.svelte` (+127 -0)
📝 `src/lib/components/chat/MessageInput.svelte` (+41 -4)
📝 `src/lib/components/chat/MessageInput/InputMenu.svelte` (+42 -2)
📝 `src/lib/stores/index.ts` (+1 -0)
➕ `src/lib/utils/google-drive-picker.ts` (+212 -0)
📝 `src/lib/utils/index.ts` (+27 -25)
</details>
### 📄 Description
# Pull Request Checklist
### Note to first-time contributors: Please open a discussion post in [Discussions](https://github.com/open-webui/open-webui/discussions) and describe your changes before submitting a pull request.
**Before submitting, make sure you've checked the following:**
- [x] **Target branch:** Please verify that the pull request targets the `dev` branch.
- [x] **Description:** Provide a concise description of the changes made in this pull request.
- [ ] **Changelog:** Ensure a changelog entry following the format of [Keep a Changelog](https://keepachangelog.com/) is added at the bottom of the PR description.
- [x] **Documentation:** Have you updated relevant documentation [Open WebUI Docs](https://github.com/open-webui/docs), or other documentation sources?
- [x] **Dependencies:** Are there any new dependencies? Have you updated the dependency versions in the documentation?
- [x] **Testing:** Have you written and run sufficient tests for validating the changes?
- [x] **Code review:** Have you performed a self-review of your code, addressing any coding standard issues and ensuring adherence to the project's coding standards?
- [x] **Prefix:** To cleary categorize this pull request, prefix the pull request title, using one of the following:
- **BREAKING CHANGE**: Significant changes that may affect compatibility
- **build**: Changes that affect the build system or external dependencies
- **ci**: Changes to our continuous integration processes or workflows
- **chore**: Refactor, cleanup, or other non-functional code changes
- **docs**: Documentation update or addition
- **feat**: Introduces a new feature or enhancement to the codebase
- **fix**: Bug fix or error correction
- **i18n**: Internationalization or localization changes
- **perf**: Performance improvement
- **refactor**: Code restructuring for better maintainability, readability, or scalability
- **style**: Changes that do not affect the meaning of the code (white-space, formatting, missing semi-colons, etc.)
- **test**: Adding missing tests or correcting existing tests
- **WIP**: Work in progress, a temporary label for incomplete or ongoing work
# Changelog Entry
### Description
- Adds support for requested functionality in feat: data sources #5872 for Google Drive directly in the chat flow
### Added
- New item where "Upload files" is in the "+" picker for Google Drive uploads
- Support for docs, sheets and slides
- Support for Google oauth id and secret key in config endpoint
- Error handling
### Additional Information
See discussion #4079
### Screenshots or Videos
Video:
https://github.com/user-attachments/assets/863fecc0-4217-43b5-9fde-698404df42a9
---
<sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
📋 Pull Request Information
Original PR: https://github.com/open-webui/open-webui/pull/7900
Author: @taylorwilsdon
Created: 12/16/2024
Status: ✅ Merged
Merged: 12/19/2024
Merged by: @tjbck
Base:
dev← Head:add_google_drive_integration📝 Commits (10+)
61b1a8ffeat: Add Google Drive file picker integration to chat interfacef566c59feat: Add Google Drive picker button to MessageInput component90e7060feat: Add Google Drive upload option to InputMenu7bc1876fix: Resolve Google Drive picker promise with file data1cd43b1feat: Import createPicker function in InputMenu componentb2dc6fefix: Improve Google Drive picker API loading and error handlingeed7cfdrefactor: Remove unused Google Drive picker imports from Chat.svelte8550810fix: Improve Google Drive picker initialization and error handlingf29dc2ffix: Add missing import for createPicker in MessageInput.sveltea0ba597feat: Add credential validation for Google Drive API initialization📊 Changes
15 files changed (+770 additions, -285 deletions)
View changed files
📝
backend/open_webui/config.py(+19 -0)📝
backend/open_webui/main.py(+9 -0)📝
backend/open_webui/routers/knowledge.py(+19 -16)📝
backend/open_webui/routers/retrieval.py(+9 -0)📝
backend/open_webui/static/swagger-ui/swagger-ui-bundle.js(+28 -34)📝
backend/requirements.txt(+5 -0)📝
package-lock.json(+11 -9)📝
src/lib/apis/retrieval/index.ts(+1 -0)📝
src/lib/components/admin/Settings/Documents.svelte(+219 -195)📝
src/lib/components/chat/Chat.svelte(+127 -0)📝
src/lib/components/chat/MessageInput.svelte(+41 -4)📝
src/lib/components/chat/MessageInput/InputMenu.svelte(+42 -2)📝
src/lib/stores/index.ts(+1 -0)➕
src/lib/utils/google-drive-picker.ts(+212 -0)📝
src/lib/utils/index.ts(+27 -25)📄 Description
Pull Request Checklist
Note to first-time contributors: Please open a discussion post in Discussions and describe your changes before submitting a pull request.
Before submitting, make sure you've checked the following:
devbranch.Changelog Entry
Description
Added
Additional Information
See discussion #4079
Screenshots or Videos
Video:
https://github.com/user-attachments/assets/863fecc0-4217-43b5-9fde-698404df42a9
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.