Closed ensiouel closed 1 year ago
What type of auth token are you using? WebHook eventsub subscriptions require an app token, but Websocket eventsub subscriptions require a user access token. This is what I use for my bot that uses this package. https://dev.twitch.tv/docs/authentication/getting-tokens-oauth/#authorization-code-grant-flow
When I get an app access token I also got
ERROR: could not subscribe to event: 400 Bad Request: {"error":"Bad Request","status":400,"message":"invalid transport and auth combination"}
Indeed, I mistakenly used the application token, not the user. Thank you for correcting me!
Hi, when trying to subscribe to stream events online or offline, I get an error
could not subscribe to event: 400 Bad Request: {"error":"Bad Request","status":400,"message":"invalid transport and auth combination"}
even when I try to execute the code from your example.As a result, I am sending a completely correct json
{"type":"stream.online","version":"1","condition":{"broadcaster_user_id":"842366340"},"transport":{"method":"websocket","session_id":"AgoQXqCqQ0RlS0-1URVxCmlCUBIGY2VsbC1j"}}
The error is not in
client_id
,access_token
oruser_id
and the code is 1 in 1 as in your example