Can't get deleting videos to work using the Youtube Data API. I'm using the Python Client Library.
All of this seems straight from the docs, so I'm really confused as to why it's not working. Here's my function:
def delete_youtube_video_by_id(video_id):yt_service = gdata.youtube.service.YouTubeService()yt_service.email = YOUTUBE_EMAILyt_service.password = YOUTUBE_SECRET_PASSWORDyt_service.source = YOUTUBE_SOURCEyt_service.developer_key = YOUTUBE_SECRET_DEVELOPER_KEYyt_service.client_id = YOUTUBE_CLIENT_IDyt_service.ProgrammaticLogin()video_entry = yt_service.GetYouTubeVideoEntry(video_id=video_id)response = yt_service.DeleteVideoEntry(video_entry)return response
From the docs, this should return True if the video is successfully deleted. However, it returns None:
>>> response = delete_youtube_video_by_id('my_youtube_video_id')
>>> type(response)
<type 'NoneType'>
>>>
And the video is not deleted. I know the credentials are good, because they are the same credentials I used to upload the video in the first place, and I know the id is good, because I got it directly from my channel in youtube.
Any ideas?