Skip to content

[Feature] Config option to disable Discord slash commands #4881

@phj1081

Description

@phj1081

Problem

When running Hermes alongside other Discord bots on the same server, Hermes's registered slash commands (e.g. /stop, /reset, /status) override identical text-parsed commands used by other bots. Discord's slash command autocomplete intercepts the input before the other bot can parse it as a text message.

Since Hermes already supports all these commands via text-based parsing (/stop typed as a regular message works fine), the slash command registration is redundant and causes unnecessary conflicts.

Proposed Solution

Add a config option to disable Discord slash command registration:

discord:
  slash_commands: false   # default: true

When set to false, _register_slash_commands() should be skipped, and any previously cached commands should be cleared via tree.clear_commands().

Workaround

Currently the only way is to patch gateway/platforms/discord.py directly — commenting out self._register_slash_commands() and adding tree.clear_commands() calls. This works but breaks on every update.

Additional Context

  • Discord server settings (Integrations) don't always show the bot, so per-server command management isn't reliably available.
  • Text-based /command parsing continues to work perfectly without slash commands registered.
  • Other bots sharing the server need the same command names for their own functionality.

Metadata

Metadata

Assignees

No one assigned

    Labels

    P3Low — cosmetic, nice to havearea/configConfig system, migrations, profilesplatform/discordDiscord bot adaptertype/featureNew feature or request

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions