Streamlink: Twitch Drops

Created on 12 Oct 2017  路  3Comments  路  Source: streamlink/streamlink

Checklist

  • [ ] This is a bug report.
  • [x] This is a feature request.
  • [ ] This is a plugin (improvement) request.
  • [x] I have read the contribution guidelines.

Description

Same question as in https://github.com/chrippa/livestreamer/issues/1629

"Twitch Drops" are rewards randomly given to people watching live streams of games while logged on Twitch. Since Streamlink already supports Twitch authentication, a support for Twitch Drops would minimize inconvenience for Twitch Drop idlers, as using only the audio would minimize bandwidth usage.

I would expect to be able to receive a Twitch Drop (e.g. for _The Elder Scrolls Legends_) if I'm _watching_ a stream in audio only mode with Streamlink. If this is not the case, what could be done to support Twitch drops? Otherwise, maybe this could be documented, at least with the Github issue right here.

Expected / Actual behavior

Expected behavior: Twitch drops are awarded to people using Streamlink.

Actual behavior: unknown.

I will test the Twitch drops in the afternoon, but the random aspect of Twitch drops makes it hard to test the support of Twitch drops. This question has not been asked or documented yet, based on my search for Github issues and Streamlink documentation.

Reproduction steps / Explicit stream URLs to test

  1. Create the authentication token
  2. Create the config file %APPDATA%\streamlink\streamlinkrc and paste the token inside it.
  3. Stream the audio only: streamlink twitch.tv/justalazygamer audio_only
  4. Wait for a Twitch Drop.

Environment details

Operating system and version: Windows 10 64 bits
Streamlink and Python version: 0.8.1 and 3.6.1 respectively.

more info required out of scope question

Most helpful comment

This is a question we can't give a definite answer to...

First off, you need to be logged in with your Twitch account by using the generated OAuth token. If you do this, Streamlink will include the OAuth http headers in all its requests (1, 2). That is basically all we can do.

How Twitch is handling the drops is a completely different thing which is unknown to anyone. They have multiple ways of detecting unique viewers, but there is no API that can be used to say "hey, I'm a viewer of channel xyz, please give me ingame items".

What they are probably doing is tracking http requests for each HLS playlist (or chunk), because these request require a signature connected to your OAuth token (and IP). Maybe they are also checking who's joined the streamer's IRC channel (or websocket based chat), or they are doing both.

They could also disable drops for specific client-ids (registered applications using their API). That would applications like Streamlink not allow its users to receive drops, although the application is technically compatible.

I have seen a few people on reddit who are using Streamlink and Streamlink Twitch GUI and who have received csgo drops, but I'm not sure if this is true. I, myself have never seen a drop of any game after almost 4 years now.

Related threads in the Streamlink Twitch GUI repo from 2015 during the livestreamer era:
https://github.com/streamlink/streamlink-twitch-gui/issues/128
https://github.com/streamlink/streamlink-twitch-gui/issues/156

All 3 comments

This is a question we can't give a definite answer to...

First off, you need to be logged in with your Twitch account by using the generated OAuth token. If you do this, Streamlink will include the OAuth http headers in all its requests (1, 2). That is basically all we can do.

How Twitch is handling the drops is a completely different thing which is unknown to anyone. They have multiple ways of detecting unique viewers, but there is no API that can be used to say "hey, I'm a viewer of channel xyz, please give me ingame items".

What they are probably doing is tracking http requests for each HLS playlist (or chunk), because these request require a signature connected to your OAuth token (and IP). Maybe they are also checking who's joined the streamer's IRC channel (or websocket based chat), or they are doing both.

They could also disable drops for specific client-ids (registered applications using their API). That would applications like Streamlink not allow its users to receive drops, although the application is technically compatible.

I have seen a few people on reddit who are using Streamlink and Streamlink Twitch GUI and who have received csgo drops, but I'm not sure if this is true. I, myself have never seen a drop of any game after almost 4 years now.

Related threads in the Streamlink Twitch GUI repo from 2015 during the livestreamer era:
https://github.com/streamlink/streamlink-twitch-gui/issues/128
https://github.com/streamlink/streamlink-twitch-gui/issues/156

I think for now I am going to mark this is out of scope and close it. There are a lot of unknowns and currently we are doing everything we realistically can (as noted by @bastimeyer, thanks for the detailed response!) to allow people to get drops. If more details emerge that wouldn't be problematic for us to implement please re-open this issue so we can start investigating. Thanks for the detailed issue as well as searching before creating it!

@ealuntea

Do Twitch drops work or not, can anyone confirm?

No, they don't and never will be (again) since #2692 got merged.
Twitch authentication has also been completely removed in #2846, as it was already a placebo thing since #2692.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

shahar603 picture shahar603  路  3Comments

SanyaIV picture SanyaIV  路  3Comments

sfkpmr picture sfkpmr  路  3Comments

bastimeyer picture bastimeyer  路  3Comments

ghost picture ghost  路  3Comments