dqqt31923 2015-02-06 14:18
浏览 75

Youtube API 3.0 - 无法启动可恢复上传异常0

I created a PHP script to directly upload video to a YouTube Channel using Youtube API 3.0 and Google Api Php Client, as described in this tutorial: https://www.domsammut.com/code/php-server-side-youtube-v3-oauth-api-video-upload-guide

Differently from this tutorial, I generate The OAuth access token using the OAuth 2.0 Playground (https://developers.google.com/oauthplayground) and then I stored the json data into a MySQL database (instead of using a text file).

Everything worked right for a couple of days, but today I get this error:

Caught Google service Exception 0 
message is 
Failed to start the resumable upload (HTTP 400: youtube.video, Bad Request)

Stack trace is 
#0 /home2/xxx/public_html/google-api-php-client/src/Google/Http/MediaFileUpload.php(134): Google_Http_MediaFileUpload->getResumeUri() 
#1 /home2/xxx/public_html/_upload_video.php(98): Google_Http_MediaFileUpload->nextChunk('\x00\x00\x00\x14ftypqt \x00\x00\x00...') 
#2 {main}

several times. Despite this, the video is uploaded correctly into YouTube!

Row 98 is:

$status = $media->nextChunk($chunk);

I really can't understand where the problem is. Can you help me? Thank you!

  • 写回答

1条回答 默认 最新

  • douyi1779 2016-02-04 21:28
    关注

    Can you check to see if you have a channel created in youtube?

    评论

报告相同问题?

悬赏问题

  • ¥15 51单片机中C语言怎么做到下面类似的功能的函数(相关搜索:c语言)
  • ¥15 seatunnel 怎么配置Elasticsearch
  • ¥15 PSCAD安装问题 ERROR: Visual Studio 2013, 2015, 2017 or 2019 is not found in the system.
  • ¥15 (标签-MATLAB|关键词-多址)
  • ¥15 关于#MATLAB#的问题,如何解决?(相关搜索:信噪比,系统容量)
  • ¥500 52810做蓝牙接受端
  • ¥15 基于PLC的三轴机械手程序
  • ¥15 多址通信方式的抗噪声性能和系统容量对比
  • ¥15 msix packaging tool打包问题
  • ¥15 finalshell节点的搭建代码和那个端口代码教程