Skip to content

Commit

Permalink
Fix youtube API function's documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
SamantazFox committed May 24, 2021
1 parent cbabf0a commit b7fe212
Showing 1 changed file with 8 additions and 5 deletions.
13 changes: 8 additions & 5 deletions src/invidious/helpers/youtube_api.cr
Original file line number Diff line number Diff line change
Expand Up @@ -19,16 +19,17 @@ def make_youtube_api_context(region : String | Nil) : Hash
"gl" => region || "US", # Can't be empty!
"clientName" => "WEB",
"clientVersion" => HARDCODED_CLIENT_VERS,
}
},
}
end

####################################################################
# request_youtube_api_browse(continuation)
# request_youtube_api_browse(browse_id, params)
#
# Requests the youtubei/vi/browse endpoint with the required headers
# to get JSON in en-US (english US).
# Requests the youtubei/v1/browse endpoint with the required headers
# and POST data in order to get a JSON reply in english US that can
# be easily parsed.
#
# The requested data can either be:
#
Expand Down Expand Up @@ -67,8 +68,10 @@ end
####################################################################
# request_youtube_api_search(search_query, params, region)
#
# Requests the youtubei/vi/search endpoint with the required headers
# to get JSON in en-US (english US).
# Requests the youtubei/v1/search endpoint with the required headers
# and POST data in order to get a JSON reply. As the search results
# vary depending on the region, a region code can be specified in
# order to get non-US results.
#
# The requested data is a search string, with some additional
# paramters, formatted as a base64 string.
Expand Down

0 comments on commit b7fe212

Please sign in to comment.