Interface BotServiceGrpc.AsyncService

All Known Implementing Classes:
BotServiceGrpc.BotServiceImplBase, BotServiceImpl
Enclosing class:
BotServiceGrpc

public static interface BotServiceGrpc.AsyncService
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)
  • Method Details

    • getBotList

      default void getBotList(BotListRequest request, io.grpc.stub.StreamObserver<BotListResponse> responseObserver)
      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

      default void getBotInfo(BotInfoRequest request, io.grpc.stub.StreamObserver<BotInfoResponse> responseObserver)
      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

      default void updateBotConfigEntry(BotUpdateConfigEntryRequest request, io.grpc.stub.StreamObserver<BotUpdateConfigEntryResponse> responseObserver)
      Updates a single configuration entry for a specific bot.
      The configuration is persisted to the database immediately.
      Requires UPDATE_BOT_CONFIG permission.
      
    • renderBotPov

      default void renderBotPov(BotRenderPovRequest request, io.grpc.stub.StreamObserver<BotRenderPovResponse> responseObserver)
      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

      default void clickInventorySlot(BotInventoryClickRequest request, io.grpc.stub.StreamObserver<BotInventoryClickResponse> responseObserver)
      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

      default void getInventoryState(BotInventoryStateRequest request, io.grpc.stub.StreamObserver<BotInventoryStateResponse> responseObserver)
      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

      default void closeContainer(BotCloseContainerRequest request, io.grpc.stub.StreamObserver<BotCloseContainerResponse> responseObserver)
      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

      default void openInventory(BotOpenInventoryRequest request, io.grpc.stub.StreamObserver<BotOpenInventoryResponse> responseObserver)
      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

      default void mouseClick(BotMouseClickRequest request, io.grpc.stub.StreamObserver<BotMouseClickResponse> responseObserver)
      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

      default void clickContainerButton(BotContainerButtonClickRequest request, io.grpc.stub.StreamObserver<BotContainerButtonClickResponse> responseObserver)
      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

      default void setContainerText(BotSetContainerTextRequest request, io.grpc.stub.StreamObserver<BotSetContainerTextResponse> responseObserver)
      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

      default void setHotbarSlot(BotSetHotbarSlotRequest request, io.grpc.stub.StreamObserver<BotSetHotbarSlotResponse> responseObserver)
      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

      default void setMovementState(BotSetMovementStateRequest request, io.grpc.stub.StreamObserver<BotSetMovementStateResponse> responseObserver)
      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

      default void resetMovement(BotResetMovementRequest request, io.grpc.stub.StreamObserver<BotResetMovementResponse> responseObserver)
      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

      default void setRotation(BotSetRotationRequest request, io.grpc.stub.StreamObserver<BotSetRotationResponse> responseObserver)
      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

      default void getDialog(BotGetDialogRequest request, io.grpc.stub.StreamObserver<BotGetDialogResponse> responseObserver)
      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

      default void submitDialog(BotSubmitDialogRequest request, io.grpc.stub.StreamObserver<BotSubmitDialogResponse> responseObserver)
      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

      default void clickDialogButton(BotClickDialogButtonRequest request, io.grpc.stub.StreamObserver<BotClickDialogButtonResponse> responseObserver)
      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

      default void closeDialog(BotCloseDialogRequest request, io.grpc.stub.StreamObserver<BotCloseDialogResponse> responseObserver)
      Closes/dismisses the current dialog.
      Clears the local dialog state.
      Requires UPDATE_BOT_CONFIG permission.