MccClient exposes typed wrappers over the current MCC WebSocket commands. The low-level equivalent is protocolClient.sendCommand(name, parameters).
authenticate(password)changeSessionId(sessionId)logToConsole(message)logDebugToConsole(message)logToConsoleTranslated(message)logDebugToConsoleTranslated(message)reconnectToServer(extraAttempts?, delaySeconds?)disconnectAndExit()runScript(fileName)
sendChat(message)sendMccCommand(command)sendPrivateMessage(playerName, message)getMaxChatMessageLength()
getTerrainEnabled()setTerrainEnabled(enabled)getEntityHandlingEnabled()sneak(enabled)sendEntityAction(actionType)digBlock(location, direction?)setSlot(slot)getWorld()getEntities()getPlayersLatency()getCurrentLocation()moveToLocation(location, allowUnsafe?, minDistance?)clientIsMoving()lookAtLocation(location)getTimestamp()getServerPort()getServerHost()getUsername()getGamemode()getYaw()getPitch()getUserUUID()getOnlinePlayers()getOnlinePlayersWithUUID()getServerTPS()respawn()getProtocolVersion()
interactEntity(entityId, interactType, hand?)sendAnimation(hand?)sendPlaceBlock(location, direction, hand?)useItemInHand()
creativeGive(type, count, damage?)creativeDelete(slot)getInventoryEnabled()getPlayerInventory()getInventories()windowAction(windowId, slotId, mouseButton, actionType, item?)changeSlot(slot)getCurrentSlot()clearInventories()updateSign(location, lines, frontText?)selectTrade(tradeIndex)updateCommandBlock(location, command, mode, flags, name?)closeInventory(inventoryId)
The current MCC runtime serializes many enum-like values as names. The SDK accepts string names for typed enum inputs and exposes runtime mapping commands for version-sensitive IDs:
getItemTypeMappings()getEntityTypeMappings()
Use the mappings instead of hard-coded numeric tables when you need stable item or entity identifiers across protocol updates.
If you need a command that is not wrapped yet, use:
const response = await client.protocolClient.sendCommand("GetUsername");The command schema is exported as commandDefinitions.
The workspace copy of WebSocketBot.cs includes a session-routing fix, so ChangeSessionId now works in local validation. If you target an older unpatched MCC WebSocket bot, that command may still fail after the rename response.