chrippa / livestreamer

Command-line utility that extracts streams from various services and pipes them into a video player of choice. No longer maintained, use streamlink or youtube-dl instead.
http://livestreamer.io/
BSD 2-Clause "Simplified" License
3.88k stars 585 forks source link

keep getting this error idk if its twitch side or not #1620

Open aryanny opened 6 years ago

aryanny commented 6 years ago

Unable to open URL: https://api.twitch.tv/api/channels/thebrett/access_token.json (400 Client Error: Bad Request)

DominikPohl commented 6 years ago

Hey @aryanny

This is happening since Twitch changed their API and decided to require the client id of the application in every? request.

You can overcome this by supplying a client id in your command line. for example:

livestreamer --http-header Client-ID=jzkbprff40iqj646a697cyrvl0zt2m6 twitch.tv/pgl 1080p60

hope this helps.

Dominik

marrie commented 6 years ago

Thanks. How do I get this client ID? I want to try this on a user who is streaming now and later my own streams as right now it is just easier for me to archive my twitch stuff this way. I just stumbled n this issue by the way. Thanks for this.

Read the blog from 2016 regarding the twitch client ID. I don't know if this is going to be possible on this app. here is the link twitch moved their developer stuff to this site as of I don't know when. I'm new to twitch; And now the application requires a URI end point to receive errors. So, is this even possible anymore? Can I use this to capture live streams from someone's twitch? I hope I still can as I can easily script this on my mac if I can get this working..

skulblakka commented 6 years ago

@marrie Either you add --http-header Client-ID=jzkbprff40iqj646a697cyrvl0zt2m6 to the command you start livestreamer with or you add http-header Client-ID=jzkbprff40iqj646a697cyrvl0zt2m6 to your livestreamer config file.

btw livestreamer is no longer supported and maintained by the original developer. You should consider using the continuation of the project https://github.com/streamlink/streamlink

Edit: I noticed you are asking about how to get the client ID. The ID has to be registered by the developer on the Twitch Developer Portal. (It is the same Client ID for all users of one application if that's what your question is about)

marrie commented 6 years ago

I'll take a look there. Oops? I just amended my comment to reflect twitch's changes, again.

Take care and sorry about that.

Thanks.