list_available_commands
Discover available terminal commands by category to understand what operations can be safely executed through the Command-Line MCP Server interface.
Instructions
List all available commands by category.
Returns: A dictionary with commands grouped by category
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- src/cmd_line_mcp/server.py:381-396 (handler)The handler function for the `list_available_commands` tool, which retrieves command lists from the configuration and returns them categorized.
async def list_available_commands() -> dict[str, list[str]]: """ List all available commands by category. Returns: A dictionary with commands grouped by category """ # Get the latest command lists command_lists = self.config.get_effective_command_lists() return { "read_commands": command_lists["read"], "write_commands": command_lists["write"], "system_commands": command_lists["system"], "blocked_commands": command_lists["blocked"], }