Skip to content

Commit

Permalink
Add param 8AEB for getting youtube stories
Browse files Browse the repository at this point in the history
  • Loading branch information
unixfox authored Aug 9, 2022
1 parent 9cc0418 commit 7f2ec18
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/invidious/videos.cr
Original file line number Diff line number Diff line change
Expand Up @@ -893,7 +893,8 @@ def extract_video_info(video_id : String, proxy_region : String? = nil, context_
end

# Fetch data from the player endpoint
player_response = YoutubeAPI.player(video_id: video_id, params: "", client_config: client_config)
# 8AEB param for fetching YouTube stories
player_response = YoutubeAPI.player(video_id: video_id, params: "8AEB", client_config: client_config)

playability_status = player_response.dig?("playabilityStatus", "status").try &.as_s

Expand Down Expand Up @@ -931,7 +932,8 @@ def extract_video_info(video_id : String, proxy_region : String? = nil, context_
else
client_config.client_type = YoutubeAPI::ClientType::Android
end
android_player = YoutubeAPI.player(video_id: video_id, params: "", client_config: client_config)
# 8AEB param for fetching YouTube stories
android_player = YoutubeAPI.player(video_id: video_id, params: "8AEB", client_config: client_config)

# Sometime, the video is available from the web client, but not on Android, so check
# that here, and fallback to the streaming data from the web client if needed.
Expand Down

0 comments on commit 7f2ec18

Please sign in to comment.