google-drive · sanjay3290 — скилл для Claude Code: что делает и как установить
Скилл google-drive встраивает полный доступ к Google Drive: поиск, скачивание, загрузка, перемещение и удаление файлов через Python-скрипты с OAuth-авторизацией.
npx skills add sanjay3290/ai-skills --skill google-drive -a claude-codeЧто делает google-drive
Скилл работает через scripts/drive.py и scripts/auth.py. Первый запуск открывает браузер для авторизации OAuth, токены хранятся в системной связке ключей (Keychain на macOS, Credential Locker на Windows, Secret Service на Linux) и обновляются автоматически. Умеет искать по содержимому файлов, названиям, извлекать ID из URL Google Drive, листать папки, создавать папки и копировать файлы между ними.
Google Docs, Sheets и Slides скачать нельзя — скилл работает только с обычными файлами (PDF, изображения, архивы). Поиск принимает полнотекстовый запрос, префикс title: для поиска по имени, URL или ID папки длиннее 25 символов.
Требует аккаунт Google Workspace. Личные Gmail-аккаунты не поддерживаются — без корпоративного аккаунта авторизация не пройдёт.
Какие задачи решает
- найти файл в Drive по содержимому или названию
- скачать PDF или изображение из общей папки
- загрузить отчёт в конкретную папку проекта
- переместить файлы между папками Drive
- создать структуру папок для нового проекта
Примеры запросов агенту
- Найди в Drive все файлы с текстом «quarterly report»
- Скачай файл
1ABC123xyzв./downloads/report.pdf - Загрузи
~/Documents/budget.xlsxв папку1DEF456abcс именем «Бюджет Q4»
Как установить google-drive
1Через Skills CLI (Vercel)
npx skills add sanjay3290/ai-skills --skill google-drive -a claude-code2Вручную: положить файлы
~/.claude/skills/google-drive/SKILL.mdПапка скилла целиком; для одного проекта — .claude/skills/google-drive/
1Через Skills CLI (Vercel)
npx skills add sanjay3290/ai-skills --skill google-drive -a codex2Вручную: положить файлы
.agents/skills/google-drive/SKILL.mdДля всех проектов — ~/.agents/skills/
1Через Skills CLI (Vercel)
npx skills add sanjay3290/ai-skills --skill google-drive -a cursor2Вручную: положить файлы
.cursor/skills/google-drive/SKILL.mdCursor читает и .agents/skills/, и .claude/skills/
1GitHub CLI
gh skill install sanjay3290/ai-skills google-drive2Вручную: положить файлы
.github/skills/google-drive/SKILL.md1Через Skills CLI (Vercel)
npx skills add sanjay3290/ai-skills --skill google-drive -a gemini-cli2Командой платформы
gemini skills install https://github.com/sanjay3290/ai-skills --path skills/google-driveВручную: положить файлы
.devin/skills/google-drive/SKILL.mdСтарый путь .windsurf/skills/ тоже читается
Через Skills CLI (Vercel)
npx skills add sanjay3290/ai-skills --skill google-drive -a opencodeClaude.ai
Упакуйте папку в zip и загрузите в Settings → Capabilities → Skills
По шагам, с командами для каждой платформы: Как установить скилл в Claude Code: пять способов
Вопросы о google-drive
Как установить google-drive в Claude Code?
Выполни npx skills add sanjay3290/ai-skills --skill google-drive -a claude-code, затем проверь ~/.claude/skills/google-drive/SKILL.md.
Что делает скилл google-drive?
Даёт агенту полный доступ к Google Drive: поиск по содержимому и названиям, скачивание и загрузка файлов, создание и перемещение папок, копирование и удаление. Авторизация через OAuth, токены хранятся в системной связке ключей.
Почему не получается скачать Google Docs?
Скилл работает только с обычными файлами (PDF, изображения, архивы). Google Docs, Sheets и Slides требуют экспорта через отдельные инструменты — прямая загрузка через Drive API для них недоступна.
Исходный текст
SKILL.md · Apache-2.0
--- name: google-drive description: | Interact with Google Drive - search files, find folders, list contents, download files, upload files, create folders, move, copy, rename, and trash files. Use when user asks to: search Google Drive, find a file/folder, list Drive contents, download or upload files, create folders, move files, or organize Drive content. Lightweight integration with standalone OAuth authentication supporting full read/write access. license: Apache-2.0 metadata: author: sanjay3290 version: "1.0" --- # Google Drive Lightweight Google Drive integration with standalone OAuth authentication. No MCP server required. Full read/write access. > **Requires Google Workspace account.** Personal Gmail accounts are not supported. ## First-Time Setup Authenticate with Google (opens browser): ```bash python scripts/auth.py login ``` Check authentication status: ```bash python scripts/auth.py status ``` Logout when needed: ```bash python scripts/auth.py logout ``` ## Read Commands All operations via `scripts/drive.py`. Auto-authenticates on first use if not logged in. ```bash # Search for files (full-text search) python scripts/drive.py search "quarterly report" # Search by title only python scripts/drive.py search "title:budget" # Search using Google Drive URL (extracts ID automatically) python scripts/drive.py search "https://drive.google.com/drive/folders/1ABC123..." # Search files shared with you python scripts/drive.py search --shared-with-me # Search with pagination python scripts/drive.py search "report" --limit 5 --page-token "..." # Find a folder by exact name python scripts/drive.py find-folder "Project Documents" # List files in root Drive python scripts/drive.py list # List files in a specific folder python scripts/drive.py list 1ABC123xyz --limit 20 # Download a file python scripts/drive.py download 1ABC123xyz ./downloads/report.pdf ``` ## Write Commands ```bash # Upload a file to Drive root python scripts/drive.py upload ~/Documents/report.pdf # Upload to a specific folder python scripts/drive.py upload ~/Documents/report.pdf --folder 1ABC123xyz # Upload with a custom name python scripts/drive.py upload ~/Documents/report.pdf --name "Q4 Report.pdf" # Create a new folder python scripts/drive.py create-folder "Project Documents" # Create a folder inside another folder python scripts/drive.py create-folder "Attachments" --parent 1ABC123xyz # Move a file to a different folder python scripts/drive.py move FILE_ID DESTINATION_FOLDER_ID # Copy a file python scripts/drive.py copy FILE_ID python scripts/drive.py copy FILE_ID --name "Report Copy" --folder 1ABC123xyz # Rename a file or folder python scripts/drive.py rename FILE_ID "New Name.pdf" # Move a file to trash python scripts/drive.py trash FILE_ID ``` ## Search Query Formats The search command supports multiple query formats: | Format | Example | Description | |--------|---------|-------------| | Full-text | `"quarterly report"` | Searches file contents and names | | Title | `"title:budget"` | Searches file names only | | URL | `https://drive.google.com/...` | Extracts and uses file/folder ID | | Folder ID | `1ABC123...` | Lists folder contents (25+ char IDs) | | Native query | `mimeType='application/pdf'` | Pass-through Drive query syntax | ## File ID Format Google Drive uses long IDs like `1ABC123xyz_-abc123`. Get IDs from: - `search` results - `find-folder` results - `list` results - Google Drive URLs ## Download Limitations - Regular files (PDFs, images, etc.) download directly - Google Docs/Sheets/Slides cannot be downloaded via this tool - For Google Workspace files, use export or dedicated tools ## Token Management Tokens stored securely using the system keyring: - **macOS**: Keychain - **Windows**: Windows Credential Locker - **Linux**: Secret Service API (GNOME Keyring, KDE Wallet, etc.) Service name: `google-drive-skill-oauth` Automatically refreshes expired tokens using Google's cloud function.
© sanjay3290 · Apache-2.0 · sanjay3290/ai-skills
Похожие скиллы
Все скиллы по теме «Настройка агента: память, контекст, субагенты» →Сначала — google-drive от других авторов.