▶️ ЗАБЕРИ СВОИ 8 ПОДАРКОВ 🎁 ПРИ СОЗДАНИИ СВОЕГО МАЙНКРАФТ СЕРВЕРА
Моды/velostat
velostat

velostat

Collects the status of servers under the Velocity server and exports it as JSON.

11
0

This plugin provides a lightweight HTTP API that exports the real-time status of all Velocity backend servers in JSON format. Exported fields are fully configurable via plugins/velostat/config.yml, allowing safe public exposure.

The game version is for all versions supported by Velocity 3.4.0-SNAPSHOT as it is added to the proxy server only. The game version must be specified and is specified, but see the Server compatibility for details.


Installation

  1. Download the latest release of the plugin
  2. Put velostat-x.x.jar in /plugins directory of velocity

This completes the process!


Config reference

Setting nameDescriptionDefault
api.portThe port number for the internal HTTP server to listen on.8080
ping.interval_secondsThe interval (in seconds) at which the plugin pings sub-servers to collect status.10
export.server.nameWhether to include the server name (defined in Velocity) in the JSON output.true
export.server.addressWhether to include the server address in the JSON output.true
export.server.statusWhether to include the online/offline status in the JSON output.true
export.server.motdWhether to include the server's MOTD (Message of the Day) in the JSON output.true
export.server.playersWhether to include player counts (online/max) in the JSON output.true
export.server.versionWhether to include the game version name and protocol version in the JSON output.true
export.server.updated_atWhether to include the last update timestamp in the JSON output.true

Example Json output

Accessing http://<SERVER_IP>:<PORT>/status will return data with a Content-Type: application/json.

FULL data

{
  "lobby": {
    "name": "lobby",
    "address": "127.0.0.1:25565",
    "online": true,
    "motd": "Welcome to the Lobby!",
    "players": {
      "online": 12,
      "max": 100
    },
    "version": {
      "name": "Paper 1.21.1",
      "protocol": 767
    },
    "updated_at": 1704681000000
  },
  "survival": {
    "name": "survival",
    "address": "127.0.0.1:25566",
    "online": false,
    "motd": null,
    "players": {
      "online": 0,
      "max": 0
    },
    "version": null,
    "updated_at": 1704681000000
  }
}

Configured data

{
  "lobby": {
    "name": "lobby",
    "online": true,
    "motd": "Welcome to the Lobby!",
    "players": {
      "online": 12,
      "max": 100
    },
    "updated_at": 1704681000000
  },
  "survival": {
    "name": "survival",
    "online": false,
    "motd": null,
    "players": {
      "online": 0,
      "max": 0
    },
    "updated_at": 1704681000000
  }
}

Field Description

Root Object

FieldTypeDescription
serversarrayList of servers defined in velocity.toml

Server Object

FieldTypeDescription
namestringServer name defined in [servers] section of velocity.toml
addressstringServer address (host:port)
onlinebooleanWhether the server responded to a ping
motdstringServer MOTD (may contain legacy color codes)
playersobjectPlayer information (only present if enabled and server is online)
versionobjectMinecraft version information
updated_atnumberLast update timestamp(UNIX time)

Players Object

FieldTypeDescription
onlinenumberCurrent number of online players
maxnumberMaximum player capacity

Version Object

FieldTypeDescription
namestringVersion name reported by the server
protocolnumberMinecraft protocol version

Notes

  • Fields may be omitted depending on config.yml settings.
  • If a server is offline, only name, address, and online are guaranteed.
  • This API is intended for internal dashboards, status pages, or monitoring tools.

Issue and question

If the plugin does not work properly, try deleting config.yml.
Problems and questions feature request here.

Совместимость

Minecraft: Java Edition

1.21.x1.20.x1.19.x1.18.x1.17.x1.16.x1.15.x1.14.x1.13.x1.12.x1.11.x1.10.x1.9.x1.8.x1.7.x

Платформы

Поддерживаемые окружения

Сервер

Детали

Лицензия:MIT
Опубликован:2 месяца назад
Обновлён:2 месяца назад
Главная