* Search continuations * add another type of playlists * Continuation for search and channels working * Playlist continuation * Fix pagination - what a fucking mess I've created * web app fix * Changelog
31 lines
981 B
Plaintext
31 lines
981 B
Plaintext
namespace Innertube
|
|
|
|
function CreateBrowseRequest(browseId as string, clienType as Innertube.ClientType, params = "" as string, continuation = "" as string) as object
|
|
deviceInfo = CreateObject("roDeviceInfo")
|
|
|
|
payload = {
|
|
"context": Innertube.CreateContext(clienType, deviceInfo, "")
|
|
}
|
|
|
|
if not StringUtils.IsNullOrEmpty(continuation)
|
|
payload["continuation"] = continuation
|
|
else
|
|
payload["browseId"] = browseId
|
|
if not StringUtils.IsNullOrEmpty(params)
|
|
payload["params"] = params
|
|
end if
|
|
end if
|
|
|
|
request = HttpClient.PostJson("https://www.youtube.com/youtubei/v1/browse?prettyPrint=false&alt=json", payload)
|
|
headers = {
|
|
"accept": "*/*"
|
|
"accept-language": "*"
|
|
}
|
|
headers.Append(Innertube.CreateHeaders(clienType))
|
|
request.Headers(headers)
|
|
|
|
return request
|
|
end function
|
|
|
|
end namespace
|