无法将视频插入稍后观看 (WL) 播放列表
Unable to insert video into the watch later (WL) playlist
我有一个 Google Apps 脚本 运行 一段时间没有错误。
它从我的 RSS 提供商获取新的 RSS 提要项目,从 YoutTbe 获取有关视频的一些基本信息,然后根据这些信息将视频添加到某个播放列表。
从几天前开始,当其余播放列表工作正常时,将任何视频添加到 WL(稍后观看)播放列表会导致以下错误:
GoogleJsonResponseException: API call to youtube.playlistItems.insert failed with error: The API does not support the ability to insert videos into the specified playlist.
这是我发送的请求(同样,为我创建的另外两个播放列表工作):
{
snippet: {
playlistId: 'WL',
resourceId: {
videoId: '<videoId>',
kind: 'youtube#video'
}
}
}
它被这样使用:
YouTube.PlaylistItems.insert(resource, "snippet");
此外,我确实在脚本的开头记录了 WL 播放列表的内容,播放列表项目返回为空列表(尽管列表中有视频)。据我所知,这两个问题是同时开始的。
根据 entry from September 9, 2020 of the official revision history of the YouTube Data API, the watch later playlist is deprecated w.r.t to using it with the PlaylistItems.insert
API 端点:
[...] The playlistItems.insert
method's and playlistItems.delete
method's support for these playlists are also now fully deprecated [...]
entry from January 28, 2021 指出:
[...] While users' watch history and watch later lists are, indeed, not accessible via the API [...]
因此,您必须承认您的 PlaylistItems.insert
端点用例不再有效。
这很不幸,但却是(有据可查的)事实。
我有一个 Google Apps 脚本 运行 一段时间没有错误。
它从我的 RSS 提供商获取新的 RSS 提要项目,从 YoutTbe 获取有关视频的一些基本信息,然后根据这些信息将视频添加到某个播放列表。
从几天前开始,当其余播放列表工作正常时,将任何视频添加到 WL(稍后观看)播放列表会导致以下错误:
GoogleJsonResponseException: API call to youtube.playlistItems.insert failed with error: The API does not support the ability to insert videos into the specified playlist.
这是我发送的请求(同样,为我创建的另外两个播放列表工作):
{
snippet: {
playlistId: 'WL',
resourceId: {
videoId: '<videoId>',
kind: 'youtube#video'
}
}
}
它被这样使用:
YouTube.PlaylistItems.insert(resource, "snippet");
此外,我确实在脚本的开头记录了 WL 播放列表的内容,播放列表项目返回为空列表(尽管列表中有视频)。据我所知,这两个问题是同时开始的。
根据 entry from September 9, 2020 of the official revision history of the YouTube Data API, the watch later playlist is deprecated w.r.t to using it with the PlaylistItems.insert
API 端点:
[...] The
playlistItems.insert
method's andplaylistItems.delete
method's support for these playlists are also now fully deprecated [...]
entry from January 28, 2021 指出:
[...] While users' watch history and watch later lists are, indeed, not accessible via the API [...]
因此,您必须承认您的 PlaylistItems.insert
端点用例不再有效。
这很不幸,但却是(有据可查的)事实。