• 1
  • 183
  • 184
  • 185(current)
  • 186
  • 187
  • 258
Release YouTube (IMPORTANT - READ FIRST POST)
(2015-12-27, 10:38)landolosto Wrote:
(2015-12-27, 09:40)bluegreen Wrote: I tried setting my own Key, Id, and secret using Google api, and it would say login failed. So I reset the addon to default, I login using the two activation codes, but I can't access the subcriptions/popular right now/subscripts/browse channels/etc. it states "Exception in ContentProvider Unknown kind".

I'm running Kodibuntu 15.2

Did you create a "browser key" and and "OAuth" key? You will need both types for this to work.

Yes I created a browser key and an oath key, and copied and pasted it over every available slot, even under the older Kodi versions in that file.
My api key was working fine on 5.1.12. But on 5.1.15 and 5.1.16 it give 'invalid credentials' error.
use +/- ⇓⇓⇓⇓⇓⇓⇓
(2015-12-27, 05:54)landolosto Wrote:
(2015-12-27, 04:27)codemonkey76 Wrote: Perfect, got it working now, that was the extra hint i needed.

(2015-12-26, 18:44)I_Terrabull Wrote: Through trial and error I got it to work. First I created a Browser API key. This gives you the value for 'key' in the login_client.py file. Then I created a OAuth client ID. This gives you the value of 'id" and 'secret'.

Now that I got it to work, I just need to learn more about developer console.

For Openelec users, this file is located here : ~/.kodi/addons/plugin.video.youtube/resources/lib/youtube/client/login_client.py . You will need to ssh into your openelec server in order to access this file, as its not exposed over SMB. Use putty or the like if you are on windows, or the built in ssh client if you are on linux or mac. The default login is : root / openelec. The file can be edited by nano.

You need to edit the "key", "id" and "secret" numbers below with the ones you generate in the Google developers console located at https://console.developers.google.com/apis . The credentials you need to create are :

'key' = Browser key
'Id' = OAuth 2.0 client ID
'secret' = OAuth 2.0 client secret

I've copied the relevant sections of the file below so you know what to edit. You should be able to just edit the key for your current version of XBMC, but Im still testing to see if this is the case.

*EDIT : DO NOT CHANGE the 'youtube-tv' credentials at the top of the file ( the first entry):

[truncated by blachanc]

Can anybody confirm that theses two keys are the right one to use?
I fail at the second code login (code does not appear)


Image



Code:
/home/osmc/.kodi/addons/plugin.video.youtube/resources/lib/youtube/client
osmc@osmc-soussol:~/.kodi/addons/plugin.video.youtube/resources/lib/youtube/client$ diff login_client_NEW.py login_client_ORG.py
53,55c53,55
<            #youtube-for-kodi-15' new key
<             'key': 'AIzaSyAJOfLFPgVPgndOjJYQBFUDWfRVFuQjJSI',
<             'id': '644982163047-llm80ca4dhauhm9jo54o22l*******.apps.googleusercontent.com',
<             'secret': '-a-L3c1f******Eo-lko3oEr'
---
>             'key': 'AIzaSyBAdxZCHbeJwnQ7dDZQJNfcaF46MdqJ24E',
>             'id': '988476436049-l9sfcivj4jtm1f2ppcvvbgsli6kvtis0.apps.googleusercontent.com',
>             'secret': '_BEENv-a3-egDz_QKo5pGZCK'
59,61c59,61
<              #youtube-for-kodi-16' new key
<             'key': 'AIzaSyAJOfLFPgVPgndOjJYQBFUDWfRVFuQjJSI',
<             'id': '644982163047-llm80ca4dhauhm9jo54o22l*******.apps.googleusercontent.com',
<             'secret': '-a-L3c1f******Eo-lko3oEr'
---
>             'key': 'AIzaSyBbgC4PZ2_hUdqqX7MIgdg2fK1nohv1jrw',
>             'id': '17932591024-8jruv1v7s78gipo7s17c91bnk26rqgpf.apps.googleusercontent.com',
>             'secret': 'bK9T234WWhqzYdcQLif1L35K'
osmc@osmc-soussol:~/.kodi/addons/plugin.video.youtube/resources/lib/youtube/client$

Code:
03:14:05  70.905159 T:1718338592  NOTICE: [plugin.video.youtube] Running: YouTube (5.1.16) on Isengard (15.2) with Python 2.7.9
03:14:05  71.016365 T:1616372768  NOTICE: Thread BackgroundLoader start, auto delete: false
03:14:05  71.029915 T:1607984160  NOTICE: Thread JobWorker start, auto delete: true
03:14:07  73.112106 T:1718338592  NOTICE: Previous line repeats 1 times.
03:14:07  73.112259 T:1718338592  NOTICE: Thread LanguageInvoker start, auto delete: false
03:14:07  73.490555 T:1718338592  NOTICE: -->Python Interpreter Initialized<--
03:14:08  74.586456 T:1718338592  NOTICE: [plugin.video.youtube] Running: YouTube (5.1.16) on Isengard (15.2) with Python 2.7.9
03:16:17 202.922577 T:1958400560   ERROR: GetDirectory - Error getting plugin://plugin.video.youtube/sign/in/
03:16:17 202.924728 T:1958400560   ERROR: CGUIMediaWindow::GetDirectory(plugin://plugin.video.youtube/sign/in/) failed
03:16:17 202.934174 T:1718338592  NOTICE: Thread BackgroundLoader start, auto delete: false

Thank you,
Ben
Argh...please do not change the YouTube-TV KEYS!!!! The other ones I don't care. But you'll break the addon.

And if you change the key by yourself...be aware, that you need to delete the addon data folder...because you must generate a new token via the login process...otherwise you get an invalid credentials.
Hi all,

I'm writing an addon for a video website that points to youtube playlists. In my code, I'm trying to call youtube's addon. I use the following call:

Code:
RunPlugin(plugin://plugin.video.youtube/play/?playlist_id=PLCnTdQ_0mlpKl36Zy_1Y4Ic2s5DxP8K45&order=shuffle)

There call indeed loads the playlist into the queue, but it doesn't automatically start playing.

The log doesn't show anything suspicious. Any idea or workaround?

Cheers!

LM
(2015-12-28, 10:18)bromix Wrote: Argh...please do not change the YouTube-TV KEYS!!!! The other ones I don't care. But you'll break the addon.

And if you change the key by yourself...be aware, that you need to delete the addon data folder...because you must generate a new token via the login process...otherwise you get an invalid credentials.

Hi Bromix,
Understood, but you cannot blame us for trying to keep your baby alive.Wink
The credit expiration is a real show stopper.

Did you select an heir to take over your work? Rofl



Ben

PS:If it is simply a matter of "be patient", than ok, I am totally fine with that.
but based on your first post I feel more like I am in a EOL support situation.

PS2: even after the addon re-install, the keys I generated do not seem to work. As soon as I place back the original ones, the two codes are displayed, and the addon works (it is 11AM here (UTC-5). The credit expiration happens at around 1AM).
I'd say if you have personal reasons, cut ties completely. Family is more important. The internet nerds will figure it out eventually. Let em break it Smile
(2015-12-28, 17:54)blachanc Wrote:
(2015-12-28, 10:18)bromix Wrote: Argh...please do not change the YouTube-TV KEYS!!!! The other ones I don't care. But you'll break the addon.

And if you change the key by yourself...be aware, that you need to delete the addon data folder...because you must generate a new token via the login process...otherwise you get an invalid credentials.

Hi Bromix,
Understood, but you cannot blame us for trying to keep your baby alive.Wink
The credit expiration is a real show stopper.

Did you select an heir to take over your work? Rofl



Ben

PS:If it is simply a matter of "be patient", than ok, I am totally fine with that.
but based on your first post I feel more like I am in a EOL support situation.

PS2: even after the addon re-install, the keys I generated do not seem to work. As soon as I place back the original ones, the two codes are displayed, and the addon works (it is 11AM here (UTC-5). The credit expiration happens at around 1AM).

I'm in the same boat, at least i can use the addon without the credit expiry thing. I just cannot login or access subscriptions or anything. Even with leaving the original youtube-tv keys in place.
I literally used this guide to set me up: https://developers.google.com/youtube/v3...ng-started

First, I enabled the YouTube Data API, v3.

Then, after that was enabled, I created an API key. This is what you will put into the "key" field in the login_client.py file that has been mentioned elsewhere.

Then, I created an OAuth 2.0 ID. The "Client ID" value goes into the "id" field in the login_client.py file, and the "Client Secret" goes into the "secret" field.

Please note, when creating the API and OAuth keys, to use a name that you'd recognize. For instance, I used "Kodi YouTube (wad)" for mine, so I know if I'm hitting the right thing or not.

I'm using Kodi 15, so I just commented out the three old values using # in front, and added (in the same order) my new values. If you're using a different version of Kodi, then find that version and replace those values. Don't try to create a new product, it's not worth the hassle. Then I zipped up the entire folder with no compression and dropped it into a place my Kodi install could access, and then installed an add-on from a zip file (make sure to uninstall the one from repo first).

The last thing you'll want to do is set plugins to prompt for update, otherwise (like me) you'll possibly wake up and find the plugin updated over Christmas and blew away your fix.

Hope that helps!
(2015-12-29, 02:20)superwad Wrote: I literally used this guide to set me up: https://developers.google.com/youtube/v3...ng-started

First, I enabled the YouTube Data API, v3.

Then, after that was enabled, I created an API key. This is what you will put into the "key" field in the login_client.py file that has been mentioned elsewhere.

Then, I created an OAuth 2.0 ID. The "Client ID" value goes into the "id" field in the login_client.py file, and the "Client Secret" goes into the "secret" field.

Please note, when creating the API and OAuth keys, to use a name that you'd recognize. For instance, I used "Kodi YouTube (wad)" for mine, so I know if I'm hitting the right thing or not.

I'm using Kodi 15, so I just commented out the three old values using # in front, and added (in the same order) my new values. If you're using a different version of Kodi, then find that version and replace those values. Don't try to create a new product, it's not worth the hassle. Then I zipped up the entire folder with no compression and dropped it into a place my Kodi install could access, and then installed an add-on from a zip file (make sure to uninstall the one from repo first).

The last thing you'll want to do is set plugins to prompt for update, otherwise (like me) you'll possibly wake up and find the plugin updated over Christmas and blew away your fix.

Hope that helps!

I did the exact same thing, except when prompted for the first code after choosing sign-in and getting the first set of codes, i go to youtube.com/activate and enter the codes and login and click allow, but then kodi comes up with the settings page with a little notification in the corner saying "login failed"
(2015-12-29, 03:28)codemonkey76 Wrote: I did the exact same thing, except when prompted for the first code after choosing sign-in and getting the first set of codes, i go to youtube.com/activate and enter the codes and login and click allow, but then kodi comes up with the settings page with a little notification in the corner saying "login failed"

I was in the same boat, but finally solved this as well... Many thanks to superwad...


superwad Wrote:First, I enabled the YouTube Data API, v3.

1) Opps, forgot that first step Confused Enabled it, and deleted the pre-generated keys (which are probably invalid)


superwad Wrote:Then,I created an API key.

2) did that: (https://console.developers.google.com/ap...al-youtube)
Code:
youtube2    Dec 28, 2015    Browser    AIzaSyC_CaSK0sJ1KPRDgcng9Fy1zB1I13db29k

superwad Wrote:Then, I created an OAuth 2.0 ID. The "Client ID"


This is wrong: not the right key type OTHER worked for me:
3) did that also (WEB APP)Sadhttps://console.developers.google.com/ap...al-youtube)
Code:
youtube2    Dec 28, 2015    Web application    644982163047-53i4nmnni83se6qkcpvegit5oia8nag4.apps.googleusercontent.com


3) did that also creating an Other type key.
Code:
Name    Creation date    Type            Client ID    
youtube2 other    Dec 28, 2015    Other    644982163047-thsi9qv33u1l45k2e72v6mtc489qievc.apps.googleusercontent.com

4) deleted the plugin.
5) installed the plugin from scratch
6) copied my modified login_client.py in /home/osmc/.kodi/addons/plugin.video.youtube/resources/lib/youtube/client

and ended up with a working youtube...

Code:
/home/osmc/.kodi/addons/plugin.video.youtube/resources/lib/youtube/client
osmc@osmc-soussol:~/.kodi/addons/plugin.video.youtube/resources/lib/youtube/client$ diff login_client.py ~/login_client_ORG.py
51d50
<               # Modif by blac
54,56c53,55
<             'key': 'AIzaSyC_CaSK0sJ1KPRDgcng9Fy1zB1I13db29k',
<             'id': '644982163047-thsi9qv33u1l45k2e72v6mtc489qievc.apps.googleusercontent.com',
<             'secret': 'tYrDp53zooMUe2UQk4wcL7-V'
---
>             'key': 'AIzaSyBAdxZCHbeJwnQ7dDZQJNfcaF46MdqJ24E',
>             'id': '988476436049-l9sfcivj4jtm1f2ppcvvbgsli6kvtis0.apps.googleusercontent.com',
>             'secret': '_BEENv-a3-egDz_QKo5pGZCK'



Code:
https://console.developers.google.com/project
Project Name    Project ID      Requests     Errors     Charges     
trial youtube    trial-youtube    14           0            $0.00

thanks again to superwad.
(2015-12-29, 06:34)blachanc Wrote:
(2015-12-29, 03:28)codemonkey76 Wrote: I did the exact same thing, except when prompted for the first code after choosing sign-in and getting the first set of codes, i go to youtube.com/activate and enter the codes and login and click allow, but then kodi comes up with the settings page with a little notification in the corner saying "login failed"

I Finally solved this as well...


superwad Wrote:First, I enabled the YouTube Data API, v3.

1) Opps, forgot that first step Confused Enabled it, and deleted the pre-generated keys (which are probably invalid)


superwad Wrote:Then,I created an API key.

2) did that: (https://console.developers.google.com/ap...al-youtube)
Code:
youtube2    Dec 28, 2015    Browser    AIzaSyC_CaSK0sJ1KPRDgcng9Fy1zB1I13db29k

superwad Wrote:Then, I created an OAuth 2.0 ID. The "Client ID"

This is wrong: not the right key type OTHER worked for me:
3) did that also (WEB APP)Sadhttps://console.developers.google.com/ap...al-youtube)
Code:
youtube2    Dec 28, 2015    Web application    644982163047-53i4nmnni83se6qkcpvegit5oia8nag4.apps.googleusercontent.com


3) did that also creating an Other type key.
Code:
Name    Creation date    Type            Client ID    
youtube2 other    Dec 28, 2015    Other    644982163047-thsi9qv33u1l45k2e72v6mtc489qievc.apps.googleusercontent.com

4) deleted the plugin.
5) installed the plugin from scratch
6) copied my modified login_client.py in /home/osmc/.kodi/addons/plugin.video.youtube/resources/lib/youtube/client

and ended up with a working youtube...

Code:
/home/osmc/.kodi/addons/plugin.video.youtube/resources/lib/youtube/client
osmc@osmc-soussol:~/.kodi/addons/plugin.video.youtube/resources/lib/youtube/client$ diff login_client.py ~/login_client_ORG.py
51d50
<               # Modif by blac
54,56c53,55
<             'key': 'AIzaSyC_CaSK0sJ1KPRDgcng9Fy1zB1I13db29k',
<             'id': '644982163047-thsi9qv33u1l45k2e72v6mtc489qievc.apps.googleusercontent.com',
<             'secret': 'tYrDp53zooMUe2UQk4wcL7-V'
---
>             'key': 'AIzaSyBAdxZCHbeJwnQ7dDZQJNfcaF46MdqJ24E',
>             'id': '988476436049-l9sfcivj4jtm1f2ppcvvbgsli6kvtis0.apps.googleusercontent.com',
>             'secret': '_BEENv-a3-egDz_QKo5pGZCK'



Code:
https://console.developers.google.com/project
Project Name    Project ID      Requests     Errors     Charges     
trial youtube    trial-youtube    14           0            $0.00

you still able to login in the youtube app?
(2015-12-29, 07:18)codemonkey76 Wrote: you still able to login in the youtube app?

Yes sir, I have access to all my playlists (this is what I was missing)

Maybe you should try my keys: ( rest of login_client.py file is unchanged )

Code:
        # Modif by blac
        'youtube-for-kodi-15': {
            'system': 'Isengard',
            'key': 'AIzaSyC_CaSK0sJ1KPRDgcng9Fy1zB1I13db29k',
            'id': '644982163047-thsi9qv33u1l45k2e72v6mtc489qievc.apps.googleusercontent.com',
            'secret': 'tYrDp53zooMUe2UQk4wcL7-V'
        },
Ben
(2015-12-29, 07:41)blachanc Wrote:
(2015-12-29, 07:18)codemonkey76 Wrote: you still able to login in the youtube app?

Yes sir, I have access to all my playlists (this is what I was missing)

Maybe you should try my keys: ( rest of login_client.py file is unchanged )

Code:
        # Modif by blac
        'youtube-for-kodi-15': {
            'system': 'Isengard',
            'key': 'AIzaSyC_CaSK0sJ1KPRDgcng9Fy1zB1I13db29k',
            'id': '644982163047-thsi9qv33u1l45k2e72v6mtc489qievc.apps.googleusercontent.com',
            'secret': 'tYrDp53zooMUe2UQk4wcL7-V'
        },
Ben


thanks dude, that worked.
Hi all

I think I've got the addon working in Kodi now and I can see that "My subscriptions" are synced between all my devices. However the "Watch later" option isn't working, I don't even see "Watch later" listed in the YouTube add on. I have checked in the addon config and I do have "Watch later" selected in the FOLDERS tab.

I'm running addon version 5.1.16 on Kodiubuntu kodi version 15.2

and

addon version 5.1.16 on Windows 8.1 kodi version 15.2

Same problem on both installs

Any ideas please?

Thanks
  • 1
  • 183
  • 184
  • 185(current)
  • 186
  • 187
  • 258

Logout Mark Read Team Forum Stats Members Help
YouTube (IMPORTANT - READ FIRST POST)20