Questions tagged [twitch]

Twitch is a live streaming service and global community for content spanning gaming, entertainment, music, sports, and more. Use this tag for questions related to the Twitch API, Extensions, Drops, or EventSub.

Official Twitch Links

Twitch API on GitHub

821 questions
62
votes
1 answer

Python - a bytes like object is required, not str

I'm moving my Twitch bot from Python 2.7 to Python 3.5. I keep getting the error: a bytes like object is required not 'str' on the 2nd line of the code below. twitchdata = irc.recv(1204) data = twitchdata.split(":")[1] twitchuser =…
spencermehta
  • 639
  • 1
  • 5
  • 10
16
votes
4 answers

How to loop a task in discord.py

I am experimenting with making my own little discord bot that can get information from Twitch, but I'm stumped on how to make the bot loop and check for a condition. I want the bot to loop a section of code every few seconds that checks if the…
sharp312
  • 183
  • 1
  • 2
  • 8
16
votes
3 answers

How does Twitch keep a persistent video window over several pages?

Twitch has introduced a functionality that, when you've opened a stream page and navigate to a different part of the site, allows the video to keep playing in the bottom left corner without any interruption. This even works when pressing the back…
jastend
  • 1,529
  • 1
  • 8
  • 17
13
votes
3 answers

How to make create-react-app support .mjs files with webpack?

I'm trying to work with this twitch npm package (https://www.npmjs.com/package/twitch) and am running into some issues when deploying via creat-react-app / react-scripts. From my understanding, the webpack config that is bundled with…
Kyle Pendergast
  • 739
  • 1
  • 8
  • 17
13
votes
5 answers

Running Flask & a Discord bot in the same application

I am building a Discord bot in Python and would like to receive HTTP requests from Twitch.tv's API (See Webhooks Guide & Webhooks Reference) (To subscribe to events like; X streamer has gone live) and based on the content of the HTTP (POST or GET)…
Haxo201
  • 211
  • 1
  • 2
  • 11
13
votes
6 answers

Show Twitch.tv stream within a unity3D application

I would like to make an Unity3D Application in which one can watch a current Twitch.tv live stream. I am not sure if this is possible, for example, with the twitch api (https://github.com/justintv/twitch-api) I know about the video textures in…
mephist0ss
  • 163
  • 1
  • 5
12
votes
11 answers

Is There Any Way To Check if a Twitch Stream Is Live Using Python?

I'm just wondering if there is any way to write a python script to check to see if a twitch.tv stream is live? I'm not sure why my app engine tag was removed, but this would be using app engine.
suitegamer
  • 421
  • 2
  • 7
  • 15
11
votes
2 answers

Stream MP4 video successfully to RTMP with FFMPEG

I'm attempted to stream an already recorded video file to twitch servers using FFMPEG but I only get audio so far no video. I've tried several settings, and different files (avi,etc) but I still get audio only. Here is my FFMPEG settings: ffmpeg…
Fight Fire With Fire
  • 1,626
  • 3
  • 19
  • 28
9
votes
1 answer

Trouble with RTMP ingest chunk stream

I am trying to build my own client RTMP library for an app that I am working on. So far everything has gone pretty successfully in that I am able to connect to the RTMP server negotiate the handshake and then send all the necessary packets…
Charlie
  • 222
  • 3
  • 20
8
votes
2 answers

json_decode() returning error "Notice: Trying to get property of non-object"

I am trying to write a script that gets a JSON file from a remote location (in this case being twitch.tv) using cURL (don't think that part is too relevant, though I better mention it anyway). For example purposes, lets say the JSON object it…
grahamhoyes
  • 321
  • 2
  • 5
  • 12
7
votes
2 answers

Testing streaming service (like selenium)

Good afternoon. I'm testing my company's streaming service, which works like twitch. The task is as follows: Log in to your account and simulate viewing the stream ( and chat) I was thinking of writing code in selenium. But as far as I understand,…
WBLord
  • 874
  • 6
  • 29
7
votes
1 answer

record Linux Wayland/DRM screen using ffmpeg's kmsgrab device with superimposed webcam

Setup is Linux, ffmpeg using kabylake iGPU. I am capturing a running sway instance using the kmsgrab device, which requires the use of a hardware backend to coherently process the image on my hardware. Only VA API fits this bill. I want to overlay…
nrdxp
  • 674
  • 7
  • 12
6
votes
4 answers

Angular how can I use embed script in Component

I'm trying to set up in Angular a way of only showing Twitch player if the stream is online, so in the Documentation there is this inline HTML:
Daniel Turcich
  • 1,764
  • 2
  • 26
  • 48
6
votes
3 answers

Python - Wanting to pass data from one script to another while they are both running

So I'm making a Discord Bot that posts when a person goes live on Twitch.tv. At the moment I have a Python program that runs the bot and a program that runs a mini server to receive the data from the Twitch server(webhook). I am unsure on how to…
Masonator
  • 121
  • 1
  • 6
6
votes
5 answers

Nodejs jQuery needs jsdom

$.getJSON('https://api.twitch.tv/kraken/channels/' + SLoppierKitty7, function(channel) { if (channel["stream"] == null) { var live ="no" } else { var live ="yes" } that is my code but when i run it i get the following error…
SloppierKitty7
  • 81
  • 1
  • 2
  • 3
1
2 3
54 55