feat(route/bilibili): authenticated article full text and current Opus images
- Dominant language
- TypeScript
- Stars
- 46.2k
- Forks
- 10.2k
- Avg merge
- 8h 48m
- Merged PRs (30d)
- 175
Description
### What feature is it?
Enhance the existing Bilibili routes so a self-hosted RSSHub instance can use an explicitly configured Bilibili session to retrieve article bodies that the logged-in account is already allowed to read, and render images from the current Opus dynamic payload shape.
Proposed behavior:
- Allow `/bilibili/user/article/:uid/:loginUid?` to select `BILIBILI_COOKIE_`, falling back to the configured Bilibili cookie when `loginUid` is omitted.
- Fetch each article body from the Opus detail API, with the article page as a fallback.
- Keep anonymous/public behavior unchanged.
- Cache article details per authentication context and never cache or publish an authenticated title-only response as a successful full-text item.
- Normalize current Opus image modules in `/bilibili/user/dynamic/:uid/:routeParams?`, including the image payload used by https://www.bilibili.com/opus/1223675872465125381.
This is authenticated access, not a paywall bypass: RSSHub should only return protected content when the supplied account can already access it.
### What problem does this feature solve?
The current article route can return only titles/previews for charging-exclusive articles even when the self-hosted instance has a valid Bilibili cookie. Separately, current Opus dynamics may contain valid pictures in a newer module shape that the route does not render, so image posts appear text-only.
This makes the generated feed incomplete for legitimate logged-in use and causes full-text readers to persist title-only entries.
### Additional description
Suggested acceptance criteria:
1. Public articles still work without a cookie.
2. With `BILIBILI_COOKIE_`, articles already unlocked for that account contain their complete body.
3. CAPTCHA, authentication failure, and title-only responses are not cached or emitted as authenticated full-text success.
4. Cache keys distinguish anonymous and authenticated sessions.
5. Current Opus picture modules render all valid images in dynamic entries.
Related but not duplicate:
- #19985 covered an older `undefined` preview-image regression and was fixed separately.
- #18506 covers Bilibili API request failures (`-352`), not article authorization or Opus image parsing.
### This is not a duplicated feature request or new RSS proposal
- [x] I have searched [existing issues](https://github.com/DIYgod/RSSHub/issues) to ensure this feature has not already been requested and this is not a [new RSS proposal](https://github.com/DIYgod/RSSHub/issues/new?assignees=&labels=RSS+proposal&template=rss_request_en.yml).
Contributor guide
Research direction
Start with the `/bilibili/user/article/:uid/:loginUid?` and `/bilibili/user/dynamic/:uid/:routeParams?` route entry points, then inspect the Opus detail API and the article-page fallback. Verify public and authenticated article behavior, authentication-specific caching, rejection of title-only results, and rendering of all valid images from current Opus modules.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- api, backend
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 48/100