К основному содержанию
скилл CX Codex

pp-google-photos — скилл для Claude Code: что делает и как установить

Скилл pp-google-photos управляет альбомами и файлами в Google Photos через CLI Printing Press. Помогает загружать снимки, создавать альбомы и запрашивать выбор медиа через Picker API.

Apache-2.0 168 установок ★ 2 142 обновлён 2026-10-24

Установить в Claude Code · Через Skills CLI (Vercel) Все способы и платформы ↓
npx skills add mvanhorn/printing-press-library --skill pp-google-photos -a claude-code
Открыть на GitHub

Что делает pp-google-photos

Скилл выступает интерфейсом к утилите google-photos-pp-cli, написанной на Go. Он позволяет агенту работать с Google Photos Library API и Picker API прямо из терминала: создавать альбомы, загружать бинарные файлы фото или видео, добавлять к снимкам геолокацию или текстовые описания, а также вызывать интерактивный выбор медиафайлов из общей галереи.

Команды Library API ограничены только тем контентом, который создало само приложение. Если вам требуется получить доступ к произвольным старым снимкам из общей библиотеки пользователя, скилл переключается на сессии Picker API с ожиданием выбора.

Перед запуском агента обязательна установка бинарника google-photos-pp-cli в системный $PATH через npx или команду go install (требуется Go 1.26.6 или новее). Авторизация выполняется через браузер с передачей OAuth Client ID, при этом утилита умеет хранить токены для нескольких аккаунтов Google и переключаться между ними флагом --account.

Какие задачи решает

  • загрузить исходные файлы фотографий или видео и сформировать медиаобъекты
  • создать альбом в Google Photos и наполнить его текстовыми заметками или геометками
  • запустить сессию Google Photos Picker для доступа к пользовательской медиатеке
  • переключаться между несколькими учётными записями Google с автоматическим обновлением токенов

Примеры запросов агенту

  • Создай альбом «Летняя поездка 2024» в Google Photos и верни его ID
  • Запусти сессию Google Photos Picker, чтобы выбрать фотографии из библиотеки
  • Загрузи фото из папки ./photos/cover.jpg в Google Photos и добавь описание

Как установить pp-google-photos

1Через Skills CLI (Vercel)

npx skills add mvanhorn/printing-press-library --skill pp-google-photos -a claude-code

2Вручную: положить файлы

~/.claude/skills/pp-google-photos/SKILL.md

Папка скилла целиком; для одного проекта — .claude/skills/pp-google-photos/

По шагам, с командами для каждой платформы: Как установить скилл в Claude Code: пять способов

Вопросы о pp-google-photos

Как установить pp-google-photos в Claude Code?

Выполните команду npx skills add mvanhorn/printing-press-library --skill pp-google-photos -a claude-code. Затем убедитесь, что бинарник google-photos-pp-cli установлен и доступен в вашем $PATH.

Что делает скилл pp-google-photos?

Он даёт ИИ-агенту набор команд для работы с Google Photos: создание альбомов, пакетную загрузку медиафайлов, чтение метаданных и запуск сессий Google Photos Picker.

Почему скилл видит не все фотографии в Google Photos?

Политика Google Photos Library API открывает доступ на чтение и редактирование только для тех объектов, которые были созданы данным приложением. Для выборки остальных снимков пользователя используется отдельный механизм сессий Picker API.

Исходный текст

SKILL.md · Apache-2.0
---
name: pp-google-photos
description: "Printing Press CLI for Google Photos. Google Photos Library and Picker APIs for app-created media, albums, uploads, and user-selected media."
author: "Cathryn Lavery"
license: "Apache-2.0"
argument-hint: "<command> [args] | install cli|mcp"
allowed-tools: "Read Bash"
metadata:
  openclaw:
    requires:
      bins:
        - google-photos-pp-cli
    install:
      - kind: go
        bins: [google-photos-pp-cli]
        module: github.com/mvanhorn/printing-press-library/library/media-and-entertainment/google-photos/cmd/google-photos-pp-cli
---
<!-- GENERATED FILE — DO NOT EDIT.
     This file is a verbatim mirror of library/media-and-entertainment/google-photos/SKILL.md,
     regenerated post-merge by tools/generate-skills/. Hand-edits here are
     silently overwritten on the next regen. Edit the library/ source instead.
     See the repository agent guide, section "Generated artifacts: registry.json, cli-skills/". -->

# Google Photos — Printing Press CLI

## Prerequisites: Install the CLI

This skill drives the `google-photos-pp-cli` binary. **You must verify the CLI is installed before invoking any command from this skill.** If it is missing, install it first:

1. Install via the Printing Press installer. It defaults binaries to `$HOME/.local/bin` on macOS/Linux and `%LOCALAPPDATA%\Programs\PrintingPress\bin` on Windows:
   ```bash
   npx -y @mvanhorn/printing-press-library install google-photos --cli-only
   ```
2. Verify: `google-photos-pp-cli --version`
3. Ensure the reported install directory is on `$PATH` for the agent/runtime that will invoke this skill.

If the `npx` install fails (no Node, offline, etc.), fall back to a direct Go install (requires Go 1.26.6 or newer):

```bash
go install github.com/mvanhorn/printing-press-library/library/media-and-entertainment/google-photos/cmd/google-photos-pp-cli@latest
```

If `--version` reports "command not found" after install, the runtime cannot see the binary directory on `$PATH`. Do not proceed with skill commands until verification succeeds.

## Command Reference

**albums** — Manage app-created Google Photos albums.

- `google-photos-pp-cli albums add-enrichment` — Add text, location, or map enrichment to an app-created album.
- `google-photos-pp-cli albums batch-add-media-items` — Add app-created media items to an app-created album.
- `google-photos-pp-cli albums batch-remove-media-items` — Remove app-created media items from an app-created album.
- `google-photos-pp-cli albums create` — Create an album in the user's Google Photos library.
- `google-photos-pp-cli albums get` — Get an app-created album by ID.
- `google-photos-pp-cli albums list` — List albums created by this app.
- `google-photos-pp-cli albums patch` — Update title or cover photo on an app-created album.

**media-items** — Manage app-created Google Photos media items.

- `google-photos-pp-cli media-items batch-create` — Create media items from upload tokens.
- `google-photos-pp-cli media-items batch-get` — Get multiple app-created media items by ID.
- `google-photos-pp-cli media-items get` — Get an app-created media item by ID.
- `google-photos-pp-cli media-items list` — List media items created by this app.
- `google-photos-pp-cli media-items patch` — Update the description on an app-created media item.
- `google-photos-pp-cli media-items search` — Search app-created media items by album or filters.

**picker** — Create, poll, clean up, and read Google Photos Picker sessions.

- `google-photos-pp-cli picker create-session` — Create a Picker session and return the picker URI.
- `google-photos-pp-cli picker delete-session` — Delete a Picker session after selected media bytes have been retrieved.
- `google-photos-pp-cli picker get-session` — Get Picker session status.
- `google-photos-pp-cli picker list-media-items` — List media items picked by the user during a Picker session.


**Hand-written commands**

- `google-photos-pp-cli upload file <path>` — Upload raw photo or video bytes and print the upload token for media-items batch-create.
- `google-photos-pp-cli picker wait <session-id>` — Poll a Picker session until selected media items are ready.
- `google-photos-pp-cli schema --pretty` — Emit machine-readable command, flag, auth, and safety-policy metadata.
- `google-photos-pp-cli auth list` — List stored OAuth accounts.
- `google-photos-pp-cli auth use <account-email>` — Set the default OAuth account.
- `google-photos-pp-cli auth remove <account-email>` — Remove a stored OAuth account.

## Google Photos Scope Limits

Google Photos Library API read and edit scopes are limited to app-created albums and media. Use Library API commands here for app-created content, uploads, and album/media management. Use Picker commands when a user needs to select media from their broader Google Photos library.


### Finding the right command

When you know what you want to do but not which command does it, ask the CLI directly:

```bash
google-photos-pp-cli which "<capability in your own words>"
```

`which` resolves a natural-language capability query to the best matching command from this CLI's curated feature index. Exit code `0` means at least one match; exit code `2` means no confident match — fall back to `--help` or use a narrower query.

## Auth Setup

Authenticate via the browser:

```bash
google-photos-pp-cli auth login --client-id "$GOOGLE_PHOTOS_CLIENT_ID"
```

Tokens are stored locally and refreshed automatically.

For multiple Google accounts, store tokens under account emails and select the account explicitly:

```bash
google-photos-pp-cli auth login [email protected] --client-id "$GOOGLE_PHOTOS_CLIENT_ID"
google-photos-pp-cli auth list --json
google-photos-pp-cli auth use [email protected]
google-photos-pp-cli --account [email protected] albums list --agent
```

Account selection order: `--account`, `GOOGLE_PHOTOS_ACCOUNT`, `auth use` default, then legacy single-token config.

Run `google-photos-pp-cli doctor` to verify setup.

## Agent Mode

Add `--agent` to any command. Expands to: `--json --compact --no-input --no-color --yes`.

- **Pipeable** — JSON on stdout, errors on stderr
- **Filterable** — `--select` keeps a subset of fields. Dotted paths descend into nested structures; arrays traverse element-wise. Critical for keeping context small on verbose APIs:

  ```bash
  google-photos-pp-cli albums list --agent --select id,name,status
  ```
- **Previewable** — `--dry-run` shows the request without sending
- **Offline-friendly** — sync/search commands can use the local SQLite store when available
- **Non-interactive** — never prompts, every input is a flag
- **Guarded** — use `--enable-commands` / `--disable-commands` with dotted command paths:

  ```bash
  google-photos-pp-cli --enable-commands albums.list albums list --agent
  google-photos-pp-cli --disable-commands picker.delete-session picker delete-session SESSION_ID --agent
  ```
- **Introspectable** — use `schema --pretty` or `agent-context --pretty` for the full JSON command contract.

### Baked Safety Profiles

Build stronger local guardrails when exposing this CLI or MCP server to autonomous agents:

```bash
make build-readonly
make build-agent-safe
make build-mcp-readonly
make build-mcp-agent-safe
```

`safety_readonly` permits read/list/search/export/schema-style commands and blocks Google Photos mutations. `safety_agent_safe` permits reads and local archive/search workflows while blocking auth writes, uploads, creates, patches, deletes, and album/media mutations.

### Response envelope

Commands that read from the local store or the API wrap output in a provenance envelope:

```json
{
  "meta": {"source": "live" | "local", "synced_at": "...", "reason": "..."},
  "results": <data>
}
```

Parse `.results` for data and `.meta.source` to know whether it's live or local. A human-readable `N results (live)` summary is printed to stderr only when stdout is a terminal — piped/agent consumers get pure JSON on stdout.

## Agent Feedback

When you (or the agent) notice something off about this CLI, record it:

```
google-photos-pp-cli feedback "the --since flag is inclusive but docs say exclusive"
google-photos-pp-cli feedback --stdin < notes.txt
google-photos-pp-cli feedback list --json --limit 10
```

Entries are stored locally at `~/.google-photos-pp-cli/feedback.jsonl`. They are never POSTed unless `GOOGLE_PHOTOS_FEEDBACK_ENDPOINT` is set AND either `--send` is passed or `GOOGLE_PHOTOS_FEEDBACK_AUTO_SEND=true`. Default behavior is local-only.

Write what *surprised* you, not a bug report. Short, specific, one line: that is the part that compounds.

## Output Delivery

Every command accepts `--deliver <sink>`. The output goes to the named sink in addition to (or instead of) stdout, so agents can route command results without hand-piping. Three sinks are supported:

| Sink | Effect |
|------|--------|
| `stdout` | Default; write to stdout only |
| `file:<path>` | Atomically write output to `<path>` (tmp + rename) |
| `webhook:<url>` | POST the output body to the URL (`application/json` or `application/x-ndjson` when `--compact`) |

Unknown schemes are refused with a structured error naming the supported set. Webhook failures return non-zero and log the URL + HTTP status on stderr.

## Named Profiles

A profile is a saved set of flag values, reused across invocations. Use it when a scheduled agent calls the same command every run with the same configuration - HeyGen's "Beacon" pattern.

```
google-photos-pp-cli profile save briefing --json
google-photos-pp-cli --profile briefing albums list
google-photos-pp-cli profile list --json
google-photos-pp-cli profile show briefing
google-photos-pp-cli profile delete briefing --yes
```

Explicit flags always win over profile values; profile values win over defaults. `agent-context` lists all available profiles under `available_profiles` so introspecting agents discover them at runtime.

## Exit Codes

| Code | Meaning |
|------|---------|
| 0 | Success |
| 2 | Usage error (wrong arguments) |
| 3 | Resource not found |
| 4 | Authentication required |
| 5 | API error (upstream issue) |
| 7 | Rate limited (wait and retry) |
| 10 | Config error |

## Argument Parsing

Parse `$ARGUMENTS`:

1. **Empty, `help`, or `--help`** → show `google-photos-pp-cli --help` output
2. **Starts with `install`** → ends with `mcp` → MCP installation; otherwise → see Prerequisites above
3. **Anything else** → Direct Use (execute as CLI command with `--agent`)
## MCP Server Installation

1. Install the MCP server:
   ```bash
   go install github.com/mvanhorn/printing-press-library/library/media-and-entertainment/google-photos/cmd/google-photos-pp-mcp@latest
   ```
2. Register with Claude Code:
   ```bash
   claude mcp add google-photos-pp-mcp -- google-photos-pp-mcp
   ```
3. Verify: `claude mcp list`

## Direct Use

1. Check if installed: `which google-photos-pp-cli`
   If not found, offer to install (see Prerequisites at the top of this skill).
2. Match the user query to the best command from the Unique Capabilities and Command Reference above.
3. Execute with the `--agent` flag:
   ```bash
   google-photos-pp-cli <command> [subcommand] [args] --agent
   ```
4. If ambiguous, drill into subcommand help: `google-photos-pp-cli <command> --help`.

© Cathryn Lavery · Apache-2.0 · mvanhorn/printing-press-library

Похожие скиллы

Все скиллы по теме «Облака: AWS, Azure, GCP» →
google-calendar membrane Подключает Google Calendar через Membrane CLI. Агент читает расписание, создаёт и удаляет события прямо из чата. CX Codex +1 337установок cloudinary cloudinary-devs Подключает пять MCP-серверов Cloudinary, обрабатывает медиа и трансформации URL, тянет живую документацию. Готовит ассеты прямо из редактора. google-ads-api-mcp-setup официальный google-ads-api-team Скилл google-ads-api-mcp-setup для Claude Code помогает установить Google Ads MCP Server и подключить ИИ-ассистента к аккаунту. Запускается при настройке запросов к кампаниям и отчётным метрикам на естественном языке. CX Codex +1 6 910установок Upstream.so upstream-so Удалённый MCP-сервер для облачной платформы стриминга Upstream.so. Даёт ассистенту запускать эфиры, править очереди воспроизведения и расписания. CX Codex +1 ★ 1звёзд репо yt-dlp-downloader MapleShaw Скилл yt-dlp-downloader для Claude Code, который запускает yt-dlp по ссылке на видео. Скачивает ролики, вытаскивает аудио в MP3 и субтитры. CX Codex +1 846установок google-drive sanjay3290 Скилл google-drive встраивает полный доступ к Google Drive: поиск, скачивание, загрузка, перемещение и удаление файлов через Python-скрипты с OAuth-авторизацией. CX Codex +1 878установок

Из того же набора87

Весь набор →
pp-redfin Скилл pp-redfin запускает утилиту redfin-pp-cli для аналитики недвижимости Redfin: отслеживает изменения в поиске, считает цену за квадратный фут и строит выборки проданных объектов. CX Codex +1 178установок pp-amazon-seller Скилл pp-amazon-seller для работы с данными Amazon Seller: заказы, инвентарь FBA, отчёты, листинги и каталог. Нужен установленный CLI. CX Codex +1 174установок pp-dub Скилл pp-dub для управления ссылками Dub через локальную базу SQLite. Находит неактивные URL, дубликаты и рассчитывает партнёрские выплаты. CX Codex +1 170установок pp-cloudflare Скилл pp-cloudflare для работы с Cloudflare через CLI: учётные записи, зоны, DNS, Workers, Pages, R2, туннели, Zero Trust и агентские инструменты. Нужен установленный cloudflare-pp-cli и API-токен. CX Codex +1 169установок pp-cal-com Скилл pp-cal-com для Claude Code расширяет Cal.com функциями для агентов: бронирование в один вызов, поиск свободных слотов, аналитика показов и отмен, обнаружение двойных бронирований. CX Codex +1 168установок pp-elevenlabs Скилл pp-elevenlabs управляет elevenlabs-pp-cli для ElevenLabs: ищет голоса, проверяет параметры озвучки и создаёт аудиофайлы. CX Codex +1 165установок pp-fedex Скилл pp-fedex для Claude Code управляет отправками FedEx через CLI: сравнивает тарифы, печатает этикетки из CSV и ведёт локальный журнал. Обрабатывает регулярные отправки. CX Codex +1 162установок pp-food52 Скилл pp-food52 гоняет бинарник food52-pp-cli по рецептам Food52: поиск, пересчёт порций, подбор по продуктам на кухне и печать без рекламы. CX Codex +1 159установок

Спонсоры проекта

Компании, которые помогают держать аналитику открытой