Allowlist API Documentation
- bedrock_server_manager.api.allowlist.add_to_allowlist(server_name: str, new_players_data: List[Dict[str, Any]], app_context: AppContext) Dict[str, Any]
Adds a list of players to the server’s allowlist.
- Parameters:
server_name (str) – The name of the server.
new_players_data (List[Dict[str, Any]]) – List of player dictionaries (with ‘name’ and ‘xuid’).
app_context (AppContext) – The application context.
- Returns:
Status dictionary containing success or error message.
- Return type:
Dict[str, Any]
- bedrock_server_manager.api.allowlist.get_allowlist(server_name: str, app_context: AppContext) Dict[str, Any]
Retrieves the current allowlist for a given server.
- Parameters:
server_name (str) – The name of the server.
app_context (AppContext) – The application context.
- Returns:
A dictionary containing the list of players on the allowlist.
- Return type:
Dict[str, Any]
- bedrock_server_manager.api.allowlist.remove_from_allowlist(server_name: str, player_names: List[str], app_context: AppContext) Dict[str, Any]
Removes a list of players from the server’s allowlist.
- Parameters:
server_name (str) – The name of the server.
player_names (List[str]) – List of player names to remove.
app_context (AppContext) – The application context.
- Returns:
Status dictionary containing success or error message, and details of removed vs not_found players.
- Return type:
Dict[str, Any]