antisocial is the other half of a StopTheMadness redirect rule. Links to X, Threads, Instagram, TikTok and Bluesky get rewritten to /<prefix>/<original path>, and this resolves the post and shows the media and the words, with a badge saying where it came from and a button to copy the original URL. Every request drives a real headless Chromium, logged out, from a residential IP. One code path, and it survives markup changes better than parsing from the outside would. Extraction is layered, most structured first: the platform's own API response caught in flight, then an inline payload, then the rendered DOM, then Open Graph tags. Media is never linked straight at a CDN. Instagram and TikTok reject requests without a matching Referer and cookies, and proxying keeps the viewer's browser from talking to the platform at all. Range is forwarded so the native video scrubber can seek. HLS is the exception, since proxying it would mean rewriting playlists. TikTok sometimes answers with a slider puzzle. Rather than reporting that as a failure, the page is parked and the viewer is handed the puzzle: screenshots stream out, pointer events are replayed back. Solving it leaves the cookie in the shared browser context, so the retry is an ordinary request. A failed resolve is never a blank error page. The card carries the platform, the original URL and the copy button, so a broken adapter still leaves the link one tap away. Verified end to end against real shared links on all five platforms, in the container, including multi-image carousels, reels, TikTok short links and photo posts. 49 tests run the adapters against captured payloads with no network. Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01BGkRmLfiWuJHx6tQ12EELY
47 lines
1.1 KiB
JSON
47 lines
1.1 KiB
JSON
{
|
|
"__typename": "Tweet",
|
|
"favorite_count": 309220,
|
|
"lang": "en",
|
|
"created_at": "2006-03-21T20:50:14.000Z",
|
|
"display_text_range": [
|
|
0,
|
|
24
|
|
],
|
|
"entities": {},
|
|
"id_str": "20",
|
|
"text": "just setting up my twttr",
|
|
"user": {
|
|
"id_str": "12",
|
|
"name": "jack",
|
|
"screen_name": "jack",
|
|
"is_blue_verified": true,
|
|
"profile_image_shape": "Circle",
|
|
"verified": false,
|
|
"profile_image_url_https": "https://pbs.twimg.com/profile_images/1661201415899951105/azNjKOSH_normal.jpg",
|
|
"highlighted_label": {
|
|
"badge": {
|
|
"url": "https://pbs.twimg.com/profile_images/1285655593592791040/HtwPZgej_bigger.jpg"
|
|
},
|
|
"description": "Square",
|
|
"url": {
|
|
"url": "https://twitter.com/Square",
|
|
"url_type": "DeepLink"
|
|
},
|
|
"user_label_display_type": "Badge",
|
|
"user_label_type": "BusinessLabel"
|
|
}
|
|
},
|
|
"edit_control": {
|
|
"edit_tweet_ids": [
|
|
"20"
|
|
],
|
|
"editable_until_msecs": "1142976014000",
|
|
"edits_remaining": "5",
|
|
"is_edit_eligible": true
|
|
},
|
|
"conversation_count": 17998,
|
|
"news_action_type": "conversation",
|
|
"isEdited": false,
|
|
"isStaleEdit": false
|
|
}
|