Return a formatted summary of all registered commands.
(self)
| 152 | return command, args.strip() |
| 153 | |
| 154 | def help_text(self) -> str: |
| 155 | """Return a formatted summary of all registered commands.""" |
| 156 | lines = ["Available commands:"] |
| 157 | commands = [self._commands[name] for name in self._canonical_names] |
| 158 | for command in sorted(commands, key=lambda item: item.name): |
| 159 | lines.append(f"/{command.name:<12} {command.description}") |
| 160 | return "\n".join(lines) |
| 161 | |
| 162 | def list_commands(self) -> list[SlashCommand]: |
| 163 | """Return canonical commands in registration order (aliases omitted).""" |
no outgoing calls