feat(api): 新增微信读书 v2 数据接口层

新建 api_v2.py,以独立 Flask Blueprint 挂载 /api/v2/*,与既有 /api/* 完全隔离,不影响 v1 接口。

- 提供 status / dashboard / shelf / notebooks / notes / book / reviews /
  highlights / underline-thoughts / thought / archives / recommend / search 等接口
- 进程内 TTL 缓存降低接口调用频次;MySQL 不可用时返回 degraded 降级标记
- 阅读状态按 finish_reading / progress / 近 30 天阅读记录综合判定
- 周月维度缺少偏好画像时回退 overall 口径补齐,并标注 preference_source
- app.py 注册 Blueprint;__main__ 端口改为读取 PORT 环境变量
This commit is contained in:
admin committed 2026-09-11 18:21:06 +08:00
1 parent e3856ccdcf
commit a114f3f407
2 files changed
+1686 -2

No files matched your search

+1677
View File
File diff suppressed because it is too large. Load diff