[-] Esca@lemmy.one 9 points 5 months ago

Dude, I have YouTube music and I literally am not able to change or upgrade to YouTube premium. They don't let me, it links me to a useless empty page with no options. I don't even know what the price is like. This whole subscription thing is a mess.

I solved it by using YouTube revanced and have all premium functions and more. On desktop I wrote my own player. It's so much better because their website is a mess. At this point do I really want to pay for features I know I won't use?

[-] Esca@lemmy.one 19 points 5 months ago* (last edited 5 months ago)

Yep, the api in jellyfin is quite easy. Someone already sent the link to the docs. The specific endpoint you want is Sessions. You need to get yourself an api_key which you can get in the admin panel. Here is an example code in Python to give you an idea on how to use the api:

#!/usr/bin/env python3

import requests

response = requests.get("http://your_jellyfin_server:8096/Sessions?api_key=your_api_key")
json = response.json()

currently_watching = []
for session in json:
    if "NowPlayingItem" in session:
        currently_watching.append(session["UserName"])

if currently_watching:
    print("Currently watching: " + ", ".join(currently_watching))
else:
    print("Nobody is watching")

If it is indeed Python that you want to use, you can adjust it to your needs depending on what you want it to output.

Basically, it is as simple as looping through every current session and checking if they have a NowPlayingItem key which is only present when they have a video open (both playing and paused). It works very reliability, I am using it to automatically change my lights when I watch a long video or movie.

[-] Esca@lemmy.one 6 points 5 months ago

Both this and Lurch's comment. It gives an answer without actually answering it, it even hallucinates broken links.

[-] Esca@lemmy.one 6 points 5 months ago

Any good photographer will shoot in raw. And in order to get a picture it has to be processed on a computer, there is no way around it. I wonder how that's supposed to work with these watermarks.

[-] Esca@lemmy.one 8 points 7 months ago

Yeah but instead of a function you just make it an alias.

[-] Esca@lemmy.one 18 points 7 months ago

Isn't this the same effect as just running 'sudo !!' ?

[-] Esca@lemmy.one 14 points 11 months ago

With ublock origin I haven't encountered popups for weeks. They update pretty much every day to keep on top of the YouTube changes.

The only time I really got popups was when another extention I had was making ad changing modifications to YouTube which I didn't realize at that time.

[-] Esca@lemmy.one 15 points 11 months ago

But if you're worried about locale, you can't assume people use the string "Saturday" to describe Saturday either. That solution only works in English.

[-] Esca@lemmy.one 3 points 11 months ago

It looks and sounds like hiccups to me? How long does he have it, does it go away? Of all the hiccups I've seen with dogs, over half are with puppies just because of how wild they are.

[-] Esca@lemmy.one 7 points 1 year ago

That only works if you're using the website. I'm in sync and just want it to open in the YouTube app.

[-] Esca@lemmy.one 75 points 1 year ago

The first time it paused my YouTube video inside Firefox when a call came in on my phone, it blew my mind. And then when the call ended, it just casually resumed the video. I love it. That, the clipboard syncing and easy sharing of files between devices make it absolutely awesome to have.

[-] Esca@lemmy.one 86 points 1 year ago

Isn't app development a recurring cost? It's not like you just work on it for a bit and just forget about it once you got a version out. Especially if it's using a service (lemmy) that is still in development and is constantly changing.

view more: next ›

Esca

joined 1 year ago