rconwebapi
Simple HTTP/REST JSON bridge for CS:GOs RCON protocol.
Usage
Releases can be found here.
Run the server binary:
./rconwebapi -host 127.0.0.1:8099
API
POST
POST to /rcon with the following Body:
{
"RconRequest": {
"Address": "myserver.com:port",
"Password": "secret_password",
"Command": "status"
}
}
Get a response with the folowing Body:
{
"RconResponse": {
"Output":"hostname: ...\nversion : 1.37.5.2/13752....\n"
}
}
Websocket
Open a websocket on /rcon_ws and send the following text messages:
Connect
Request
{
"RequestType": "connect",
"Request": {
"Address": "myserver.com:port",
"Password": "secret_password"
}
}
Response
{
"ResponseType": "connect",
"Response": {
"Status": "success/fail",
"Message": "maybe something"
}
}
Command
Request
{
"RequestType": "command",
"Request": {
"Command": "status"
}
}
Response
{
"ResponseType": "command",
"Response": {
"Output": "something"
}
}