官方 API 驱动云端相册自动化
简介
Google Photos 官方 API 封装工具,支持本地照片备份、相册创建与管理,适合需要自动化云端图库的用户。
原始描述
Manage Google Photos library. Upload photos, create albums, and list library content. Use when the user wants to backup, organize, or share images via Google Photos.
通过你的 Agent 添加
点「快速安装」复制一段指令,粘给你正在用的 Agent(Claude Code、Codex、OpenClaw 等),它会自己完成安装。
或者手动安装
包里是 SKILL.md 加作者附带的文件,解压后目录名就是技能名。
技能申请的权限由作者决定,装之前请确认它能读什么、能执行什么。
技能正文
name: google-photos description: Manage Google Photos library. Upload photos, create albums, and list library content. Use when the user wants to backup, organize, or share images via Google Photos. metadata: {"openclaw":{"emoji":"📸","requires":{"apis":["photoslibrary.googleapis.com"]}}}
Google Photos
This skill provides a way to interact with Google Photos Library API to automate photo management.
Setup
- Enable API: Enable the "Google Photos Library API" in your Google Cloud Console project.
- Credentials: Download your OAuth 2.0 Client ID credentials as
credentials.json. - Environment: This skill uses a Python virtual environment located in its folder.
Usage
All commands are run through the scripts/gphotos.py script.
List Albums
Useful for finding the ID of an existing album.
./scripts/gphotos.py --action list --credentials /path/to/credentials.json --token /path/to/token.pickle
Create a New Album
./scripts/gphotos.py --action create --title "Vacations 2026" --credentials /path/to/credentials.json --token /path/to/token.pickle
Upload a Photo
You can optionally specify an --album-id to add the photo to a specific album.
./scripts/gphotos.py --action upload --photo "/path/to/image.jpg" --album-id "ALBUM_ID" --credentials /path/to/credentials.json --token /path/to/token.pickle
Privacy & Security
- This skill only has access to photos it uploads or that are explicitly shared with the application.
- Credentials and tokens are stored locally and should be kept secure.
- Never share your
credentials.jsonortoken.picklefiles.
正文来自原始发布页, 版权归作者所有,许可未标注。 权利人认为有不妥,可申请下架。