WeRead MCP Server
January 23, 2026 · View on GitHub
MCP server for WeRead with SQLite caching.
- Sync bookshelf, highlights, thoughts from WeRead API
- Local SQLite cache with TTL-based refresh
- 14 tools: bookshelf, book info, highlights, search, export, etc.
Quick Start
1. Get Cookie
- Open https://weread.qq.com and login
- F12 → Application → Cookies → weread.qq.com
- Copy cookie string
Required cookie fields:
| Field | Description | Example |
|---|---|---|
wr_vid | User ID | 12345678 |
wr_skey | Session key, expires in ~2h | AbcdEfg |
wr_rt | Auth token | web@xxx... |
Full cookie format: wr_vid=xxx; wr_skey=xxx; wr_rt=xxx; ...
2. Configure MCP
{
"mcpServers": {
"weread": {
"command": "weread-mcp",
"env": {
"WEREAD_COOKIE": "wr_vid=xxx; wr_skey=xxx; wr_rt=xxx; ...",
"WEREAD_DATA_DIR": "~/.weread",
"WEREAD_CACHE_TTL": "300"
}
}
}
}
Environment variables:
| Variable | Required | Default | Description |
|---|---|---|---|
WEREAD_COOKIE | Yes | - | Cookie string from browser |
WEREAD_DATA_DIR | No | ~/.weread | Cache directory path |
WEREAD_CACHE_TTL | No | 300 | Cache TTL in seconds |
Tools
| Tool | Description |
|---|---|
get_bookshelf | List all books |
get_book_info | Book details |
get_book_chapters | Table of contents |
get_book_bookmarks | Highlights |
get_book_reviews | Thoughts |
get_book_notes | Export as Markdown |
get_reading_progress | Progress % |
get_finished_books | Completed books |
get_notebooks | Books with notes |
search_books | Search by title/author |
search_notes | Search highlights |
sync_shelf | Force sync |
sync_all_bookmarks | Sync all highlights |
get_cache_stats | Cache info |
All tools support force param to bypass cache.
Disclaimer
⚠️ For educational and personal use only.
- Comply with Tencent ToS and WeRead User Agreement
- Do not use for commercial purposes
- Do not share your cookie
- Authors not responsible for misuse
License
MIT