A lightweight UDP query protocol plugin for Hytale servers that enables external tools to query server information, with no webserver requirements.
<h1 style="text-align: center;">HyQuery</h1><p style="text-align: center;">Let server lists show your server's status - players online, MOTD, and more!</p>
HyQuery is a server query protocol developed specifically for Hytale servers. Once installed, server lists and monitoring tools can automatically display your player count, server name, and other details - no manual updates needed!
Whether you're building a server listing website, a Discord bot, or a server management tool, HyQuery provides a standardized way to get server information.
HyQuery is the standard implementation for most Hytale server lists.
By default, just the basics:
You can optionally enable:
HyQuery returns server information in a simple JSON format:
{
"online": true,
"players": {
"online": 42,
"max": 100
},
"version": "1.0.0",
"motd": {
"raw": "Welcome to My Server!",
"clean": "Welcome to My Server!"
},
"latency": 24
}For a single server, it's as simple as:
mods folderThat's it!
If you're running a network with multiple servers (such as a lobby and several minigame servers), HyQuery supports aggregating player counts across your entire network. This allows server lists to display your total network population accurately.
#### How It Works
The network feature uses a primary/worker architecture. Your hub server acts as the primary and your game servers act as workers. All servers connect to a shared Redis instance — workers publish their player data, and the primary aggregates it into a single response when queried. This supports hub clustering with multiple primary servers out of the box.
You'll need a Redis server accessible to all your game servers. This can run on the same machine as your primary, or on a dedicated host. Secure it with a strong password and make sure port 6379 is open between your servers.
#### 1\. Install on All Servers
Download HyQuery and place it in the mods folder on all servers in your network (hub and workers).
#### 2\. Configure Your Hub Server (Primary)
On your hub server, configure the plugin as the primary node that aggregates data from Redis:
{
"enabled": true,
"showPlayerList": true,
"showPlugins": false,
"network": {
"enabled": true,
"role": "primary",
"coordinator": "redis",
"namespace": "global",
"staleAfterSeconds": 10,
"redis": {
"host": "127.0.0.1",
"port": 6379,
"password": "your-redis-password",
"tls": false,
"requireAvailable": true
},
"logStatusUpdates": false
}
}#### 3\. Configure Your Worker Servers
On your minigame/gamemode servers, configure each as a worker that publishes to the same Redis instance:
{
"enabled": true,
"network": {
"enabled": true,
"role": "worker",
"coordinator": "redis",
"id": "minigame-1",
"namespace": "global",
"redis": {
"host": "127.0.0.1",
"port": 6379,
"password": "your-redis-password",
"tls": false,
"requireAvailable": true
},
"logStatusUpdates": false
}
}If you want to tweak things, edit mods/HyQuery/config.json:
Set logStatusUpdates to true while configuring your network. This outputs to the console whenever updates are sent or received. Once everything is working, switch it back to false to reduce console spam.
Use the namespace setting to isolate groups of servers within the same Redis instance. All servers sharing a namespace will be aggregated together. This is useful if you're running multiple networks on the same Redis server.
You can use the Server Status checker on Hyvote to verify HyQuery is working correctly on your server.
[Test Server Status →](https://hyvote.org/tools/server-status)
Running a server list? Get in touch on Discord to be added.
MIT - use it however you like!
Join us on Discord for setup help, bug reports, or just to chat with other server owners.
👉 [https://discord.gg/7espErav5n](https://discord.gg/7espErav5n)
0 Comments