youtube_it
youtube_it copied to clipboard
issue authenticating
I'm getting the error:
YouTubeIt::AuthenticationError: BadAuthentication
I just want to confirm my authentication details:
@client = YouTubeIt::Client.new(:username => "[email protected]", :password => "password_to_gmail", :dev_key => "youtube_api_credentials_key")
So,
- :username is my full gmail address? or just the name before @gmail.com? Or something else?
- :password is the password to above gmail account?
- :dev_key is a youtube_data server API key that I've generated from https://console.developers.google.com/apis/credentials
Does that all look right? Why would I be getting an authentication error? I've verified the credentials manually several times.
Turns out I had to go into my google profile settings to allow less secure apps to have access (I guess apps that don't use Oauth?)

To confirm, @birchlore, this issue can be closed?
Hey @pickhardt yep, thanks! A note could be added to the readme if anyone else mentions it.
I'm getting a 'AuthenticationError' when accessing current_user. So the code looks like:
client = YouTubeIt::Client.new(:username => params['user'],:password => params['pass'], :dev_key => dev_key) begin if client.current_user # 'AuthenticationError' here at runtime end session['user'] = params['user'] session['pass'] = params['pass'] redirect_to :controller => "mainpage", :action => "search" rescue session['user'] = nil session['pass'] = nil redirect_to :controller => "login", :action => "index" end