Skip to content
Back to skills

Douban Sync Skill

ASecurity

Export and sync Douban (豆瓣) book/movie/music/game collections to local CSV files (Obsidian-compatible). Use when the user wants to export their Douban reading/watching/listening/gaming history, set up incremental sync via RSS, or manage their Douban data locally.

  • 16 stars
  • 0 votes
  • 0 copies
  • 2 views
  • Added June 7, 2026
documentationgobashnode

Security analysis

A100/100

Pro scans all 7 files and shows the line behind each finding

Scanned June 7, 2026

npx -y skills add modbender/skill-library-mcp --skill douban-sync-skill --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Douban Sync Skill?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Douban Sync Skill
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/modbender-douban-sync-skill/badge)](https://www.skillsdirectory.com/skills/modbender-douban-sync-skill)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: douban-sync
description: Export and sync Douban (豆瓣) book/movie/music/game collections to local CSV files (Obsidian-compatible). Use when the user wants to export their Douban reading/watching/listening/gaming history, set up incremental sync via RSS, or manage their Douban data locally.
metadata: {"openclaw": {"requires": {"env": ["DOUBAN_USER"]}, "primaryEnv": "DOUBAN_USER"}}
---

# Douban Sync

Export Douban collections (books, movies, music, games) to CSV and keep them in sync via RSS.

## Two Modes

### 1. Full Export (first time)

Use the browser tool to scrape all collection pages. Requires the user to be logged into Douban.

```
browser → douban.com/people/{USER_ID}/{category}?start=0&sort=time&mode=list
```

Categories and URL paths:
- Books: `book.douban.com/people/{ID}/collect` (读过), `/do` (在读), `/wish` (想读)
- Movies: `movie.douban.com/people/{ID}/collect` (看过), `/do` (在看), `/wish` (想看)
- Music: `music.douban.com/people/{ID}/collect` (听过), `/do` (在听), `/wish` (想听)
- Games: `www.douban.com/people/{ID}/games?action=collect` (玩过), `=do` (在玩), `=wish` (想玩)

Each page shows up to 30 items in list mode (some pages may have fewer due to delisted entries). Paginate with `?start=0,30,60...` — the script uses the paginator's "next" button to determine whether to continue.

**Rate limiting:** Wait 2-3 seconds between pages. If blocked, wait 30 seconds and retry.

**Scripts:**
- `scripts/douban-scraper.mjs` — HTTP-only, no browser needed (may get rate-limited)
- `scripts/douban-browser-scraper.mjs` — via Puppeteer CDP, needs a running browser
- `scripts/douban-extract.mjs` — generates a browser console script for manual extraction

### 2. Incremental Sync (daily, via RSS)

Run `scripts/douban-rss-sync.mjs` — no login needed.

```bash
node scripts/douban-rss-sync.mjs
```

**Setup:** Set environment variables:
- `DOUBAN_USER` (required): Douban user ID
- `DOUBAN_OUTPUT_DIR` (optional): Output root directory, default `~/douban-sync`

**Recommended:** Add a daily cron job for automatic sync.

## Output Format

Four CSV files per user in the output directory:

```
douban-sync/
└── {user_id}/
    ├── 书.csv
    ├── 影视.csv
    ├── 音乐.csv
    └── 游戏.csv
```

CSV columns:
```csv
title,url,date,rating,status,comment
"书名","https://book.douban.com/subject/12345/","2026-01-15","★★★★★","读过","短评内容"
```

- `status`: 读过/在读/想读, 看过/在看/想看, 听过/在听/想听, 玩过/在玩/想玩

## Deduplication

Both full export and RSS sync deduplicate by Douban URL — safe to run multiple times.

Files in this skill

  • SKILL.md2.7 KB
  • scripts/douban-browser-scraper.mjs6.6 KB
  • scripts/douban-extract.mjs2 KB
  • scripts/douban-rss-sync.mjs7.1 KB
  • scripts/douban-scraper.mjs7.2 KB
  • scripts/lib.mjs2.5 KB
  • scripts/migrate-md-to-csv.mjs5.5 KB

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.