Permissions
Eranio
Permissions
Complete guide to the Hytale Admin permission system, 19 granular permissions, custom permission groups, and OP management.
Permission Reference
The plugin defines 19 custom permissions that control access to every feature:
| Permission | Grants Access To |
|---|---|
hytale-admin.dashboard |
View the dashboard (status, TPS, uptime) |
hytale-admin.players-read |
View the player list |
hytale-admin.players-manage |
Kick, heal, teleport, set gamemode, OP/de-OP players |
hytale-admin.players-inventory |
View and edit player inventories, give items, clear inventory |
hytale-admin.moderation-read |
View the ban list and mute list |
hytale-admin.moderation-manage |
Ban/unban, mute/unmute players |
hytale-admin.chat-read |
View the live chat monitor and death log |
hytale-admin.chat-broadcast |
Send broadcast messages to all players |
hytale-admin.world-read |
View world information (time, weather, seed) |
hytale-admin.world-manage |
Set time, set weather, manage warps |
hytale-admin.serverconfig-read |
View server configuration and whitelist |
hytale-admin.serverconfig-manage |
Edit server config, manage whitelist |
hytale-admin.backups-read |
View the backup list |
hytale-admin.backups-manage |
Create, restore, and delete backups |
hytale-admin.mods-manage |
Mods page: upload, patch, repair and delete mods |
hytale-admin.setup |
Access the setup page (install/uninstall mod, settings) |
hytale-admin.activity |
View the activity log tab |
hytale-admin.achievements-view |
View the Achievements page: overview, leaderboard and player profiles |
hytale-admin.achievements-manage |
Grant and revoke achievements for online players |
Permission Hierarchy
Permissions follow a read → manage pattern:
*-read= view-only access*-manage= full control (includes read)
Having *-manage without *-read still works, the manage permission implies read access.
Permission Groups
Permission groups allow you to define reusable sets of permissions for roles.
Create Permission Group
| Detail | Value |
|---|---|
| Permission | hytale-admin.serverconfig-manage |
| API | POST /permissions/groups |
| Body | Group name + selected permissions |
| Success | "Permission group created: {group}" |
| Failure | "Failed to create permission group" |
| Logged as | server:hytale-admin.group-create |
Delete Permission Group
| Detail | Value |
|---|---|
| Permission | hytale-admin.serverconfig-manage |
| API | DELETE /permissions/groups/{name} |
| Success | "Permission group deleted: {group}" |
| Failure | "Failed to delete permission group" |
| Logged as | server:hytale-admin.group-delete |
Example Groups
| Group Name | Suggested Permissions |
|---|---|
| Moderator | moderation-read, moderation-manage, chat-read, players-read |
| Builder | world-read, world-manage, players-read |
| Admin | All 19 permissions |
| Viewer | dashboard, players-read, chat-read, world-read, achievements-view |
OP Management
Grant or revoke operator status for players:
Grant OP
| Detail | Value |
|---|---|
| Permission | hytale-admin.serverconfig-manage |
| API | POST /permissions/op/{uuid} |
| Success | "OP granted: {uuid}" |
| Failure | "Failed to grant OP" |
| Logged as | server:hytale-admin.op-grant |
Revoke OP
| Detail | Value |
|---|---|
| Permission | hytale-admin.serverconfig-manage |
| API | DELETE /permissions/op/{uuid} |
| Success | "OP revoked: {uuid}" |
| Failure | "Failed to revoke OP" |
| Logged as | server:hytale-admin.op-revoke |
Note: OP management uses UUIDs, not player names. The plugin resolves names to UUIDs for you.
Data Storage
Permissions are stored in permissions.json on the server. The Java mod reads this file on startup and the panel can modify it via the API.
Game Translation System
For the item search and inventory editor, item names are translated using a priority chain:
| Priority | Source | Description |
|---|---|---|
| 1 | Java Mod I18n | Server-side item translations from the mod |
| 2 | Static PHP translations | Bundled translation files in the plugin |
| 3 | Formatted key fallback | Item key formatted as readable name |
13 locale mappings are supported. The gameLanguage setting ('auto' by default) follows the panel locale.
Troubleshooting
User can't access a feature
- Check which permission is required for that feature (see table above)
- Verify the user/subuser has the permission assigned
- Server owners have all permissions by default
Permission group creation fails
- Group name may already exist
- API connection lost
permissions.jsonfile locked or corrupted
OP status doesn't persist
- OP changes should persist across restarts (stored server-side)
- If not persisting, check
permissions.jsonwrite permissions - Server may overwrite permissions on certain events
Activity log shows "unknown" actor
- The admin username is passed from the panel session
- If session expired during action, actor may be empty
Permissions don't take effect immediately
- Some permission changes may require the affected user to refresh their page
- Server-side permission groups may need a server restart to reload
API Client & Internal Architecture
Full API endpoint documentation is available in the HytaleAdminAPI Reference. This section covers the PHP client that the panel plugin uses internally to communicate with the Hytale server mod. For endpoint parameters, response schemas, and request examples, see the HytaleAdminAPI documentation.
HytaleApiService, PHP Client
The panel plugin talks to the Hytale mod through the HytaleApiService class, which wraps all HTTP calls. Every page (Dashboard, Players, Chat and so on) uses this service.
Where the connection details come from
| Value | Source | Description |
|---|---|---|
| Host | Pelican | FQDN of the node the server runs on |
| Port | mods/Eranio_HytaleAdminAPI/config.json |
field port, default 5550 |
| Token | mods/Eranio_HytaleAdminAPI/config.json |
field token, generated by the mod on first start |
| Timeout | mods/Eranio_HytaleAdminAPI/config.json |
field requestTimeout, default 10 seconds |
| Base URL | computed | http://{node-fqdn}:{port} |
The plugin reads the mod's config.json through Pelican's file interface (ModConfigReader), there are no egg variables and no panel setting for it. The values can be changed in the Edit Settings dialog on the setup page, which writes them back to the same file.
// How the connection is built (simplified from HytaleApiService)
$modConfig = app(ModConfigReader::class)->readConfig($server);
$baseUrl = 'http://' . $server->node->fqdn . ':' . ($modConfig['port'] ?? 5550);
Http::baseUrl($baseUrl)
->timeout($modConfig['requestTimeout'] ?? 10)
->withHeaders([
'X-Admin-Token' => $modConfig['token'] ?? '',
'Accept' => 'application/json',
])
->get('/api/status');
The token is sent in the X-Admin-Token header, not as a bearer token. If a call fails (error status or no connection), the service returns null instead of throwing an exception. The pages then show their notice that the API cannot be reached.
Request Flow, Panel to Server Mod
┌──────────────┐ HTTP/JSON ┌─────────────────┐ Java API ┌──────────────┐
│ Panel Plugin │ ──────────────> │ Hytale Mod HTTP │ ──────────── > │ Hytale Server│
│ (PHP/Laravel)│ <────────────── │ Server (Netty) │ < ──────────── │ (Game) │
│ │ JSON response│ │ Game state │ │
└──────────────┘ └─────────────────┘ └──────────────┘
Key architectural notes:
- The mod embeds a Netty HTTP server inside the Hytale server process
- All game-affecting operations (kick, ban, teleport) execute on the server main thread
- Read-only operations (status, player list) may use cached data
- The API is synchronous from the panel's perspective but internally queues to the game thread
Feature → API Endpoint Mapping
See HytaleAdminAPI Reference for request/response details of each endpoint.
| Panel Feature | API Endpoints Used | Notes |
|---|---|---|
| Dashboard status | GET /api/status, GET /api/version |
TPS measured continuously (Hytale target: 30) |
| Active instances (Dashboard) | GET /api/adventure, POST /api/adventure/* |
Portal time, void invasion, world events, close instance |
| Player list | GET /api/players, GET /api/players/known |
Online players live, offline players from the save files |
| Player actions | POST /api/players/{name}/kick, /op, /deop, /heal, /teleport, /gamemode, /give |
Run on the player's world thread |
| Adventure menu (Players) | POST /api/adventure/teleport-player, /send-to-spawn, /scale, /history, /wilderness, /debug-screens, /instance/spawn, /instance/exit, POST /api/worlds/send |
Also across worlds |
| Inventory editor | GET /api/players/{name}/inventory, POST /api/players/{name}/inventory/slot, /slot/remove, /slot/swap, /clear, GET /api/items |
Online players live, offline players via save file |
| Bans | GET /api/bans, POST /api/bans, DELETE /api/bans/{player} |
Hytale's access control, bans.json |
| Mutes | GET /api/mutes, POST /api/mutes, DELETE /api/mutes/{player} |
mutes.json in the mod folder |
| Chat | GET /api/chat, POST /api/chat/broadcast |
Event logs of the mod |
| Deaths | GET /api/deaths |
Last 10 deaths and total |
| Worlds | GET /api/worlds, POST /api/worlds/* |
Create, settings, default, unload, park, reset, trash |
| Player worlds | GET /api/playerworlds, POST /api/playerworlds/config |
Settings and access state |
| Adventure (World page) | GET /api/adventure, POST /api/adventure/* |
World events, portals, spawn |
| Time and weather | POST /api/world/time, POST /api/world/weather |
First loaded world |
| Warps | GET /api/warps, POST /api/warps, POST /api/warps/{name}/tp, DELETE /api/warps/{name} |
Hytale's TeleportPlugin |
| Memories | GET /api/memories |
Server-wide |
| Backups | GET /api/backup, GET /api/backup/status, POST /api/backup/create, DELETE /api/backup |
Hytale's own backup function |
| Server config | GET /api/serverconfig, POST /api/serverconfig |
Restart may be required |
| Whitelist | GET /api/whitelist, POST /api/whitelist, DELETE /api/whitelist/{name} |
Unknown names are resolved by Hytale |
| Permissions and OP | GET /api/permissions, POST /api/permissions/op, DELETE /api/permissions/op/{uuid}, /user/group, /groups |
permissions.json |
| Installed mods (Mod Manager) | no API call | Reads the mods/ folder through Pelican's file API |
| Achievements | GET /api/achievements/status, /categories, /achievements, /players, /player/{name}, /recent, /server-firsts, POST /api/achievements/grant, /revoke |
Passes through the data of an installed achievements plugin, without a hard dependency on it; without the plugin /status only reports available: false |
Inventory Data
For online players the inventory comes live from the API (GET /api/players/{name}/inventory), changes go through POST /api/players/{name}/inventory/slot, /slot/remove, /slot/swap and /clear. For offline players the plugin reads and writes the save file universe/players/{uuid}.json directly through Pelican's file interface.
Save files are decoded as objects (json_decode($content, false)), not as arrays. Hytale distinguishes between {} and []; converting to arrays would turn empty objects into lists on write and damage the file.
Player Names (UUID Resolution)
Hytale stores players, bans and permissions by UUID. The panel shows names and looks them up in known_players.json (maintained by the plugin, new players are added when the dashboard or the players page is opened) and in whitelist.json. Without a match the UUID is shown.
Caching
The pages fetch their data fresh on every refresh (intervals are listed on each page). Very little is cached:
| What | How long | Purpose |
|---|---|---|
| Picking up new players from the server files | at most every 5 minutes per server | Saves file access when pages are opened |
| Looking for a new admin mod version | at most every 6 hours | Request to eranio.de |
| Item and memory pictures | permanently in the panel | Keeps the pages fast |
Demo Mode Architecture
Demo mode never starts on its own, not even when the server is offline. It applies when
- Enable Demo Mode was pressed on the setup page (permission
hytale-admin.setup,toggleDemoMode()), thenDemoInventoryServicecreates test data for this server and the mode stays on until it is switched off, or - a page is opened with
?demo=1, then only for that request.
In demo mode DemoDataService and DemoInventoryService provide all data, actions only show a message ("This action was simulated") and send nothing to the server. A notice banner sits at the top of every page.
If the server is merely unreachable, the dashboard shows API offline and the pages stay empty or show their notice.
API Client Error Map
| Symptom | Cause | Fix |
|---|---|---|
| Dashboard shows API offline | Server stopped, mod not loaded or port blocked | Start the server, check on the setup page that the mod is installed, open the port from config.json in the firewall |
| All pages empty while the mod runs | Token in config.json does not match |
Delete config.json and restart the server, the mod creates a new token and the plugin reads it automatically |
| An action reports an error | The mod answered with an error status, the service then returns null |
Check the Hytale server log and storage/logs/laravel.log |
| Pages load slowly or incompletely | Timeout too short or server overloaded | Raise Request timeout in the settings |
| Actions fail after a long break | Session expired | Reload the page in the browser |
Complete Error Reference (All Features)
Connection
| Symptom | Cause | Fix |
|---|---|---|
| Dashboard shows API offline | The mod does not answer | Start the server, check the mod on the setup page |
| Pages load slowly and stay empty | Timeout exceeded | Raise the request timeout, check the firewall |
| All pages empty while the mod runs | Token does not match (HTTP 403) | Delete config.json, restart the server |
| Actions hang after a long break | Session expired | Reload the page |
| Failures with pauses | Server overloaded | Check TPS on the dashboard |
Players
| Symptom | Cause | Fix |
|---|---|---|
| "Failed to kick player" | The player already left | The list refreshes within 15 seconds |
| Banning not possible | Players page needs hytale-admin.players-manage, moderation page hytale-admin.moderation-manage |
Grant the permission |
| New player missing from the list | Picking up players from the files runs at most every 5 minutes | Wait a moment and reopen the page |
Chat
| Symptom | Cause | Fix |
|---|---|---|
| No new messages | Chat polling set too rarely or mod unreachable | Check the Chat polling every setting |
| "Failed to send broadcast" | Connection to the mod lost | Check the status on the dashboard |
World
| Symptom | Cause | Fix |
|---|---|---|
| Time or weather cannot be set | hytale-admin.world-manage missing |
Grant the permission |
| World actions take long | Large world | Raise the request timeout |
Backups
| Symptom | Cause | Fix |
|---|---|---|
| "Failed to create backup" | No space or no write permission | Free space, check the backup folder permissions |
| "Failed to restore backup" | File damaged or server running | Stop the server, use another backup |
Server Configuration
| Symptom | Cause | Fix |
|---|---|---|
| Saving not possible | hytale-admin.serverconfig-manage missing |
Grant the permission |
| Change has no effect | Restart needed | Restart the server |
API Response Code Reference
The Java mod answers with these status codes:
| HTTP status | Meaning | Typical case |
|---|---|---|
| 200 | Success | Normal operation |
| 400 | Bad request | Required field missing or value invalid |
| 403 | Forbidden | Token in the X-Admin-Token header missing or wrong |
| 404 | Not found | Player, world, warp or file does not exist |
| 405 | Method not allowed | Wrong HTTP method for the endpoint |
| 500 | Server error | Internal error in the mod, check the Hytale server log |
The panel treats every answer other than 2xx as an error, the page then shows its error message.
Messages
The success and error messages of every action are listed with their exact wording in the sections of the individual pages (Players, Moderation, Chat, Backups, Mods, Server Configuration, Setup).