So, what I’m trying to do is use a java CLI program running both a twitch and discord bot to connect to the webhook system to auto ping on stream status changing, but I seem to be running into an issue.
Is this something that’s even possible using java? Am I just trying to call the initial …/…/hub url wrong? Any assistance would be appreciated.
That’s the rough base for calling the initial URL. The URL points to the IP of my raspberry pi, which is running a java web server which SHOULD, from my understanding, be able to handle the response just fine, however trying to test the code above gives me a 400 error and I’m not entirely sure why.
Or, conversely, should I refactor my bots to use something like the twitch4j wrapper instead of what I’m currently using (I believe pircbotX, which is no longer really maintained, resulting in me having to try and do things like this by hand lol)
Unfortunately I’m not familiar enough with Java to help debug. But given the CURL version works perfectly fine, I’d be suspicious of how the request payload is being created in Java.
I appreciate it, that at least let’s me know it’s none of my auth codes. I’m probably going to look into a better library for creating and parsing HTTP calls to make this hopefully work. I know people have working websocket connections in other code, so I know it should be possible, I’m just not sure where MINE is breaking.