以下是提供的链接.. https://developers.google.com/youtube/v3/quickstart/python 但是,当我尝试它的工作原理,但我需要视图计数数据转到文本文件
def channels_list_by_username(service, **kwargs):
results = service.channels().list(
**kwargs
).execute()
print('This channel\'s ID is %s. Its title is %s, and it has %s views.' %
(results['items'][0]['id'],
results['items'][0]['snippet']['title'],
results['items'][0]['statistics']['viewCount']))
我无法访问结果视图计数参数 可以指导一些人 感谢