I have installed Youtube uploader(7.x-2.2) to my web server and registered a project in Google APIs, set OAuth2, turned on YouTube Data API v3 and YouTube Analytics API from API Manager page(https://console.developers.google.com/apis/api/youtube/overview). Everything on connect setting between my web server and Google Youtube Data API seems fine(please take a look on youtube_upload_error_01.png).
But, when I try to upload a video file to Youtube, I got 401 error message(please take a look on youtube_upload_error_02.png).
https://www.googleapis.com/upload/youtube/v3/videos?part=snippet%2Cstatus&uploadType=resumable
Failed to load resource: the server responded with a status of 401 ()
I tried Youtube uploader 7.x-2.x-dev, but got the same problem.
Must I missed any setting in somewhere?
Please anyone help me.
Comment | File | Size | Author |
---|---|---|---|
youtube_upload_error_02.PNG | 210.97 KB | chenpurong | |
youtube_upload_error_01.PNG | 111.64 KB | chenpurong |
Comments
Comment #2
chenpurong CreditAttribution: chenpurong commentedI can upload a video data to Youtube by admin account now. I don't know why.
But when I switch the account to another user, the problem above appeared again.
Comment #3
axooh CreditAttribution: axooh at Gridonic commentedI have the same problem. Can anyone help?
Comment #4
chenpurong CreditAttribution: chenpurong commentedFinally, I found the reason why user can't upload video to Youtube is that I didn't give user a permission as "Upload a video" in Permission Management page after I installed and activated the module.
In fact, the module should give a message to user that he has no permission when he does uploading. Otherwise, we don't know where the problem is.
Comment #6
stred CreditAttribution: stred commentedHi,
This permission is mentioned in the README file. I tried to make it more clear... if you have suggestions, where do you expect to find this information?
Comment #7
chenpurong CreditAttribution: chenpurong commentedHi Stred,
Thanks for your replay.
Yes, I couldn't read module description carefully so that I missed permission setting.
But, I couldn't get the message you posted like "Issue #2704435", I don't now why.
And I just took a look on module's source code(youtube_uploader.ytapi.inc), and found a issue(probably) that a exception:Google_ServiceException (line:111) doesn't exist in google-api-php-client package. The exception class name may be Google_Service_Exception (just a typo?).
Comment #9
stred CreditAttribution: stred commentedthx for the typo, committed
Comment #10
stred CreditAttribution: stred commented