【问题标题】:YouTube Upload using API使用 API 上传 YouTube
【发布时间】:2020-12-24 00:02:11
【问题描述】:

这是什么意思?

我在上传一个视频后收到此错误。 我认为这会让我的 youtube 上传变得更容易。 谁能帮帮我?

client_secret.json-youtube-v3-(['https://www.googleapis.com/auth/youtube.upload'],)
['https://www.googleapis.com/auth/youtube.upload']
youtube service created successfully
Traceback (most recent call last):
  File "c:/Users/dipes/OneDrive/Desktop/Upload YouTube/upload.py", line 197, in <module>
    response_upload = service.videos().insert(
  File "C:\Users\dipes\AppData\Local\Programs\Python\Python38-32\lib\site-packages\googleapiclient\_helpers.py", line 134, in positional_wrapper
    return wrapped(*args, **kwargs)
  File "C:\Users\dipes\AppData\Local\Programs\Python\Python38-32\lib\site-packages\googleapiclient\http.py", line 907, in execute
    raise HttpError(resp, content, uri=self.uri)
googleapiclient.errors.HttpError: <HttpError 403 when requesting https://www.googleapis.com/upload/youtube/v3/videos?part=snippet%2Cstatus&alt=json&uploadType=multipart returned "The request cannot be completed because you have exceeded your <a href="/youtube/v3/getting-started#quota">quota</a>.">

【问题讨论】:

    标签: python youtube youtube-api


    【解决方案1】:

    来自错误信息:

    "The request cannot be completed because you have exceeded your <link> quota"
    

    您已超出配额,请在此处阅读更多信息: https://developers.google.com/youtube/v3/getting-started#quota

    简而言之:

    从上面的链接: Google 通过为每个请求分配费用来计算您的配额使用情况。不同类型的操作有不同的配额成本。例如:

    • 检索资源列表(频道、视频、播放列表)的读取操作通常需要 1 个单位。
    • 创建、更新或删除资源的写入操作通常需要 50 个单位。
    • 一个搜索请求需要 100 个单位。
    • 上传视频需要 1600 个单位。

    【讨论】:

      猜你喜欢
      • 2012-07-08
      • 2013-08-29
      • 2018-02-04
      • 2011-02-22
      • 2017-03-19
      • 2011-11-14
      • 1970-01-01
      • 2016-02-24
      相关资源
      最近更新 更多