-
Notifications
You must be signed in to change notification settings - Fork 37
WebSocket commands and responses
Technical info below! This is only important to you if you are considering creating a new client or if you want to extend WebConsole possibilities. Below is a detailed list containing all current WebConsole commands, along with the data that the server will send in response to these commands. This information applies to WebConsole v1.1.0
Logs user in into server. This is the first command client should send to server. Login is required in order to run any of the other commands.
Example usage:
LOGIN myPassw0rd
Responds with:
Execute a command into the Minecraft Server console as if you were typing into the real console.
Example usage:
EXEC say Hello from WebConsole!
Responds with:
This message does not generate a response itself, but WebConsole will send you the console output generated for your command with a 010 message.
All responses are sent into a JSON string. Every response will contain a status
and statusDescription
parameter to allow the client know the response type. All possibilities are shown below.
Sends a line printed in Minecraft console.
Extra parameters:
- message: Contains the console line printed into real console.
Example response:
{status: 10, statusDescription: "Console Output", message: "[Server] Hello from WebConsole!"}
Tells the client that a previously sended command was sucessfully processed.
Extra parameters:
- respondsTo: Command that originated this response.
- message: User-readable message containing additional info.
Example response:
{status: 200, statusDescription: "Processed", respondsTo: "LOGIN ********", message: "Logged In"}
A sended command does not exist or was not understood by server.
Extra parameters:
- respondsTo: Command that originated this response.
- message: User-readable message containing additional info.
Example response:
{status: 400, statusDescription: "Unknown Command", respondsTo: "ESEC esec command do not exist!", message: "Unknown command"}
First message that client will receive when connecting to a server. Informs that login is required with a valid password in order to start executing commands.
Extra parameters:
- message: User-readable message containing additional info.
Example response:
{status: 401, statusDescription: "Login Required", message: "Connection started, waiting login"}
WebConsole - MIT License - mesacarlos