PlayerUUIDCacheBungee provides a read-only BungeeCord API for resolving player names to UUIDs and UUIDs to player names. It is intended to use the MySQL tables written by the Bukkit/Paper PlayerUUIDCache plugin.
The plugin never queries Mojang, never writes to the database and does not expose profile/property APIs.
Add this plugin to the BungeeCord proxy and configure it to point at the same MySQL database as PlayerUUIDCache.
For another BungeeCord plugin, add a dependency in bungee.yml:
depends:
- PlayerUUIDCacheBungeeLoad the API from BungeeCord's plugin manager:
Plugin plugin = ProxyServer.getInstance()
.getPluginManager()
.getPlugin("PlayerUUIDCacheBungee");
PlayerUUIDCacheBungeeAPI uuidCache = plugin instanceof PlayerUUIDCacheBungeeAPI api ? api : null;
CachedPlayer player = uuidCache.getPlayerFromNameOrUUID("Notch");Alternatively, use PlayerUUIDCacheBungee.getAPI() after the plugin has been enabled.
Synchronous API calls may perform MySQL queries. Use the async methods from proxy event handlers or latency-sensitive code:
uuidCache.getPlayerAsync("Notch").thenAccept(player -> {
if (player != null) {
UUID uuid = player.getUUID();
}
});The main table must match the schema used by PlayerUUIDCache:
CREATE TABLE playeruuids (
uuid CHAR(36) NOT NULL,
name VARCHAR(100) NOT NULL,
lastSeen BIGINT NOT NULL DEFAULT 0,
PRIMARY KEY (uuid),
INDEX (name)
);Historical name lookups use the optional namehistories and namechanges tables. If either table is missing, getCurrentAndPreviousPlayers only returns current mappings from playeruuids.
/uuidcachebungee stats shows lookup and database counters.
/uuidcachebungee lookup <name|uuid> reads one mapping.
/uuidcachebungee loadAll loads all rows into the memory cache.
/uuidcachebungee reload reloads the configuration.
All commands require playeruuidcachebungee.admin.