obsproject / obs-websocket

Remote-control of OBS Studio through WebSocket
GNU General Public License v2.0
3.85k stars 706 forks source link

Not receiving GetAuthRequired #502

Closed soumyadeep-ghosh closed 4 years ago

soumyadeep-ghosh commented 4 years ago
Issue type

Question

Description

So as per my understanding the obs-websocket sends data over socket 4444 in JSON Format. So, after connecting using Sockets in Java (no 3rd Library), it says that the Connection to Socket 4444 is successful. But when I try to send "{'request-type':'GetAuthRequired','message-id':'ID0'}" as GetAuthRequired JSON, the socket return nothing, and shown as NULL.

OBS and the WebSocket are properly installed and running in the background, and tested it with the Java Library provided in the description and it works there.

So is my JSON Incorrect ?

Currently I am not using the provided Library, because I need to know how this thing works, before opting for an already existing Library.

Steps to reproduce and other useful info

WebSocket ws=new WebSocket("127.0.0.1",4444,null);

Here WebSocket is a custom class that handles that IP and Port.

Technical information

Windows 10 Pro 1903 OBS 64-bit 25.0.8

Development Environment

BlueJ with JDK 8

tt2468 commented 4 years ago

I understand that you don't want to use a premade library, but you might have luck looking into one of those premade libraries and comparing with your code to see if you made any mistakes somewhere.

soumyadeep-ghosh commented 4 years ago

Thank you, I had some basic misunderstanding between Sockets and WebSockets