Overview
AutoRejoin accepts start or stop plus an account name. Starting requires a saved auto-rejoin configuration. Stopping removes the worker from the server's worker map when one exists.
Usage
AutoRejoin <start|stop> <account>
With password protection enabled, send AUTH | AutoRejoin <start|stop> <account>
Complete Python example
import asyncio
import websockets
import json
URI = "ws://localhost:8765"
async def main():
async with websockets.connect(URI) as ws:
print("Connected to WebSocket server")
# Start AutoRejoin
await ws.send("AutoRejoin start myAccount")
response = await ws.recv()
print(json.loads(response))
# Stop AutoRejoin
await ws.send("AutoRejoin stop myAccount")
response = await ws.recv()
print(json.loads(response))
if __name__ == "__main__":
asyncio.run(main())
Example response
{
"ok": true,
"result": {
"action": "AutoRejoin",
"mode": "start",
"account": "Main"
}
}