AutoWeb Youtube API - Create Playlist

Discussion in 'AutoApps' started by Avinash Beepath, Jan 10, 2017.

  1. Avinash Beepath

    Avinash Beepath New Member

    Joined:
    Jan 4, 2017
    Messages:
    13
    Likes Received:
    0
    Hey guys,
    First the good news - Thanks to AutoWeb, AutoVoice and BubbleUPnP, I have been able to play music from YouTube directly from my Google Home without having a subscription to YouTube music (Not available in my country). I have been using YouTube api within AutoWeb to do searches and create arrays which contain the videoIDs to play which I hope to pass back to YouTube as a playlist. Unfortunately I only can pass the videos one at a time eg %playlist(1) due to the errors listed below.
    My problem is this - when selecting the Create Playlist API under AutoWeb I keep getting variations of the following such as "YouTube signup required", "Invalid Credentials", "Unauthorized" and I cannot for the life of me figure out what I am doing wrong...I get similiar errors when trying to add to existing playlists as well so i figure they are related...can anyone please assist??? This is driving me up a wall!
    Much Thanks,
    Avinash
     
  2. joaomgcd

    joaomgcd Administrator Staff Member

    Joined:
    Feb 3, 2015
    Messages:
    9,479
    Likes Received:
    806
    Can you please export your task's description (not xml) so I can take a look? Long-click the task in Tasker->export description Thanks in advance
     
  3. Avinash Beepath

    Avinash Beepath New Member

    Joined:
    Jan 4, 2017
    Messages:
    13
    Likes Received:
    0
    Here is the export....the api under AutoWeb for Create Playlist and Add to Playlist is the default but I have tried variations of Secret Key (from youtube developer console Api data v3), Google (not sure if i used right scope) and User Name and Pwd (assumed this was my gmail account)...the only one i didnt try due to lack of in depth knowledge was Oauth..this has been a very long road and I thank you so much for your assistance!

    YoutubeSearchPlaylist (174)
    A1: AutoWeb Web Service [ Configuration:API: YouTube
    API Action: Create playlist
    Title: Test
    Id: Blank Timeout (Seconds):120 ]
     
  4. joaomgcd

    joaomgcd Administrator Staff Member

    Joined:
    Feb 3, 2015
    Messages:
    9,479
    Likes Received:
    806
    You should have to change the Authentication type. That should always be set to Google. I'll give it a shot, thanks
     
  5. joaomgcd

    joaomgcd Administrator Staff Member

    Joined:
    Feb 3, 2015
    Messages:
    9,479
    Likes Received:
    806
    Here. I tried this and it worked for me:

    Code (Text):
    Test (106)
        A1: AutoWeb Web Service [ Configuration:API: YouTube
    API Action: Create playlist
    Title: testing playlist Timeout (Seconds):120 ]
        A2: Flash [ Text:%aid Long:Off ]
        A3: AutoWeb Web Service [ Configuration:API: YouTube
    API Action: Add to playlist
    Video Id: 55lfdlVZHOc Timeout (Seconds):120 ]
        A4: Flash [ Text:%playlistid Long:Off ]
        A5: Join Send Push [ Configuration:Device: Chrome
    Url: https://www.youtube.com/watch?v=55lfdlVZHOc&list=%playlistid Timeout (Seconds):60 ]
     
    This will create a playlist, add a video in it and then push the playlist url to Chrome with Join.

    Hope this helps
     
  6. Avinash Beepath

    Avinash Beepath New Member

    Joined:
    Jan 4, 2017
    Messages:
    13
    Likes Received:
    0
    I am strongly convinced it's the configuration of the api that's causing me to experience the same error after recreating your steps...this is what i have in the Autoweb settings...attached a screenshot...everything else below is set at default...please tell me there's something missing :(
     

    Attached Files:

  7. joaomgcd

    joaomgcd Administrator Staff Member

    Joined:
    Feb 3, 2015
    Messages:
    9,479
    Likes Received:
    806
    I would advise you to delete the YouTube API from your Web Service list and then import it again. Then don't change any settings in the API itself and just use it in Tasker :)
    That should make it work
     
  8. Avinash Beepath

    Avinash Beepath New Member

    Joined:
    Jan 4, 2017
    Messages:
    13
    Likes Received:
    0
    This is the response i keep getting...after I delete and re-import the YouTube api...it's interesting you are not getting the same response...hmmm any other ideas? I am so close but this final step is crucial..
     

    Attached Files:

  9. joaomgcd

    joaomgcd Administrator Staff Member

    Joined:
    Feb 3, 2015
    Messages:
    9,479
    Likes Received:
    806
    Maybe the account you used to authorize is not linked to youtube or doesn't have a YouTube channel? Can that be it?
     
    Avinash Beepath likes this.
  10. Avinash Beepath

    Avinash Beepath New Member

    Joined:
    Jan 4, 2017
    Messages:
    13
    Likes Received:
    0
  11. joaomgcd

    joaomgcd Administrator Staff Member

    Joined:
    Feb 3, 2015
    Messages:
    9,479
    Likes Received:
    806
    No, because the authentication is already correctly specified in the API settings. You don't need to change that. And it already works for my account so it should be something related with your account. Are you sure you used the correct account to sign in when importing the API in AutoWeb?
     
  12. Avinash Beepath

    Avinash Beepath New Member

    Joined:
    Jan 4, 2017
    Messages:
    13
    Likes Received:
    0
    Ahhh you're prior comment solved it...I am so sure I am not the only one to experience this problem so I'll share how I got into and out of the problem.
    When you first sign up for YouTube you could have a username (See attached file - Beepster100 is mine) and choose not to use your real name...which i chose to do...this name had a YouTube channel associated with it. However when signing into AutoWeb it's asking for your account credentials which i populated but failed to realize it wasnt associating with my alias Beepster100 but instead Avinash Beepath...again in the attached file you can see below my name now it's says "No Videos"...before adding the channel this previously said..."No Channel" so I added the channel and boom..I can now use AutoWeb's Add to Playlist and Create Playlist APIs.
    Thanks so much again man...you continue to rock!!!!
     

    Attached Files:

  13. joaomgcd

    joaomgcd Administrator Staff Member

    Joined:
    Feb 3, 2015
    Messages:
    9,479
    Likes Received:
    806
    Awesome! :) Glad you got it!
     
: autoweb

Share This Page