Class BotServiceGrpc.BotServiceBlockingStub
java.lang.Object
io.grpc.stub.AbstractStub<BotServiceGrpc.BotServiceBlockingStub>
io.grpc.stub.AbstractBlockingStub<BotServiceGrpc.BotServiceBlockingStub>
com.soulfiremc.grpc.generated.BotServiceGrpc.BotServiceBlockingStub
- Enclosing class:
BotServiceGrpc
public static final class BotServiceGrpc.BotServiceBlockingStub
extends io.grpc.stub.AbstractBlockingStub<BotServiceGrpc.BotServiceBlockingStub>
A stub to allow clients to do limited synchronous rpc calls to service BotService.
Service for managing and controlling Minecraft bots.
Provides comprehensive APIs for bot monitoring, movement control,
inventory management, and interaction with server dialogs.
Permissions:
- READ_BOT_INFO: Required for GetBotList, GetBotInfo, GetInventoryState,
RenderBotPov, GetDialog
- UPDATE_BOT_CONFIG: Required for all other operations that modify bot state
Error Handling:
- NOT_FOUND: Instance or bot does not exist
- FAILED_PRECONDITION: Bot is not online or required game state is unavailable
- INTERNAL: Unexpected server errors (check server logs for details)
-
Nested Class Summary
Nested classes/interfaces inherited from class io.grpc.stub.AbstractStub
io.grpc.stub.AbstractStub.StubFactory<T> -
Method Summary
Modifier and TypeMethodDescriptionprotected BotServiceGrpc.BotServiceBlockingStubbuild(io.grpc.Channel channel, io.grpc.CallOptions callOptions) Clicks a container-specific action button.Clicks a button in the current dialog.Performs a click action on an inventory/container slot.closeContainer(BotCloseContainerRequest request) Closes the currently open container (chest, crafting table, etc.).closeDialog(BotCloseDialogRequest request) Closes/dismisses the current dialog.getBotInfo(BotInfoRequest request) Returns detailed information about a specific bot.getBotList(BotListRequest request) Returns a list of all bots configured in the specified instance.getDialog(BotGetDialogRequest request) Returns the currently displayed server dialog (Minecraft 1.21.6+).Returns the current state of the bot's open container/inventory.mouseClick(BotMouseClickRequest request) Simulates a mouse click in the game world.openInventory(BotOpenInventoryRequest request) Opens the player's inventory screen.renderBotPov(BotRenderPovRequest request) Renders the bot's point-of-view as a PNG image using software rendering.resetMovement(BotResetMovementRequest request) Resets all movement to stopped state.Sets text in a container's text input field.setHotbarSlot(BotSetHotbarSlotRequest request) Changes the selected hotbar slot.Updates the bot's movement state (WASD, jump, sneak, sprint).setRotation(BotSetRotationRequest request) Sets the bot's view rotation (look direction).submitDialog(BotSubmitDialogRequest request) Submits a dialog with input values.Updates a single configuration entry for a specific bot.Methods inherited from class io.grpc.stub.AbstractBlockingStub
newStub, newStubMethods inherited from class io.grpc.stub.AbstractStub
getCallOptions, getChannel, withCallCredentials, withChannel, withCompression, withDeadline, withDeadlineAfter, withDeadlineAfter, withExecutor, withInterceptors, withMaxInboundMessageSize, withMaxOutboundMessageSize, withOnReadyThreshold, withOption, withWaitForReady
-
Method Details
-
build
protected BotServiceGrpc.BotServiceBlockingStub build(io.grpc.Channel channel, io.grpc.CallOptions callOptions) - Specified by:
buildin classio.grpc.stub.AbstractStub<BotServiceGrpc.BotServiceBlockingStub>
-
getBotList
Returns a list of all bots configured in the specified instance. Includes both online and offline bots with their current status. For online bots, includes live state (position, health, etc.) but NOT full inventory data. Requires READ_BOT_INFO permission.
-
getBotInfo
Returns detailed information about a specific bot. Includes full live state with complete inventory data when the bot is online. Requires READ_BOT_INFO permission.
-
updateBotConfigEntry
Updates a single configuration entry for a specific bot. The configuration is persisted to the database immediately. Requires UPDATE_BOT_CONFIG permission.
-
renderBotPov
Renders the bot's point-of-view as a PNG image using software rendering. The bot must be online with a valid player and level. Uses the bot's current render distance setting. Requires READ_BOT_INFO permission.
-
clickInventorySlot
Performs a click action on an inventory/container slot. Supports various click types (left, right, shift, drop, swap, middle). The bot must be online with a valid player and gameMode. Requires UPDATE_BOT_CONFIG permission.
-
getInventoryState
Returns the current state of the bot's open container/inventory. Includes layout information, slot contents, and carried item. The bot must be online with a valid player. Requires READ_BOT_INFO permission.
-
closeContainer
Closes the currently open container (chest, crafting table, etc.). Returns to the player inventory view. The bot must be online with a valid player. Requires UPDATE_BOT_CONFIG permission.
-
openInventory
Opens the player's inventory screen. Sends a packet to the server to display the inventory UI. The bot must be online with a valid player. Requires UPDATE_BOT_CONFIG permission.
-
mouseClick
Simulates a mouse click in the game world. Left click: attack entity or start breaking block. Right click: use item or interact with entity/block. The bot must be online with valid player, level, and gameMode. Requires UPDATE_BOT_CONFIG permission.
-
clickContainerButton
Clicks a container-specific action button. Used for: stonecutter recipes, enchanting, loom patterns, villager trades, beacon effects, crafter slot toggles, lectern page navigation. The action is queued and executed on the next game tick. Requires UPDATE_BOT_CONFIG permission.
-
setContainerText
Sets text in a container's text input field. Currently only supports anvil item renaming (field_id: "item_name"). The action is queued and executed on the next game tick. Requires UPDATE_BOT_CONFIG permission.
-
setHotbarSlot
Changes the selected hotbar slot. Valid slot range: 0-8 (corresponding to slots 1-9 in the UI). The action is queued and executed on the next game tick. Requires UPDATE_BOT_CONFIG permission.
-
setMovementState
Updates the bot's movement state (WASD, jump, sneak, sprint). Only specified fields are changed; omitted fields retain their current value. Movement persists until explicitly changed or reset. The action is queued and executed on the next game tick. Requires UPDATE_BOT_CONFIG permission.
-
resetMovement
Resets all movement to stopped state. Equivalent to releasing all movement keys. The action is queued and executed on the next game tick. Requires UPDATE_BOT_CONFIG permission.
-
setRotation
Sets the bot's view rotation (look direction). Yaw is normalized to -180 to 180, pitch is clamped to -90 to 90. The action is queued and executed on the next game tick. Requires UPDATE_BOT_CONFIG permission.
-
getDialog
Returns the currently displayed server dialog (Minecraft 1.21.6+). Dialogs are server-sent UI screens for custom interactions. Returns empty response if no dialog is being shown. Does not require the bot to be online (but dialog will be absent). Requires READ_BOT_INFO permission.
-
submitDialog
Submits a dialog with input values. Used for dialogs containing text fields, checkboxes, dropdowns, or sliders. The dialog is closed after submission. Note: Full dialog response packets are not yet implemented; this clears local state. Requires UPDATE_BOT_CONFIG permission.
-
clickDialogButton
Clicks a button in the current dialog. Button index depends on dialog type (see BotClickDialogButtonRequest). The dialog is typically closed after the button click. Note: Full dialog button packets are not yet implemented; this clears local state. Requires UPDATE_BOT_CONFIG permission.
-
closeDialog
Closes/dismisses the current dialog. Clears the local dialog state. Requires UPDATE_BOT_CONFIG permission.
-