feat: detect subscriber-only tweets via tweetInterstitial (#33)

Extract visibility metadata from TweetWithVisibilityResults wrapper
before unwrapping. Adds is_subscriber_only field to Tweet model,
with full serialization roundtrip and test coverage.

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
Tao BAI
2026-03-17 18:09:15 +08:00
committed by GitHub
parent 90f0635c50
commit 66115a4837
8 changed files with 29 additions and 5 deletions

View File

@@ -15,6 +15,10 @@
"tweet_results": {
"result": {
"__typename": "TweetWithVisibilityResults",
"tweetInterstitial": {
"__typename": "TweetInterstitial",
"text": { "rtl": false, "text": "Subscribe to @lister to see this post" }
},
"tweet": {
"__typename": "Tweet",
"rest_id": "700",