Skip to content

[BUG] Plugin commands are always namespaced (contradicting to the documentation): allow optional namespaces or default commands #15882

Description

@rse

Preflight Checklist

  • I have searched existing issues and this hasn't been reported yet
  • This is a single bug report (please file separate reports for different bugs)
  • I am using the latest version of Claude Code

What's Wrong?

In the documentation https://code.claude.com/docs/en/slash-commands it is stated: "Plugin commands are: - Namespaced: Commands can use the format /plugin-name:command-name to avoid conflicts (plugin prefix is optional unless there are name collisions)" But this seems to be not true. The plugin prefix (aka namespace) is never optional. I tried multiple ways to define my plugin command (just through the filesystem relative path, alternatively via the "commands" section in the "plugin.json") but I was never able to make the namespace optional. Even when the command has the same name as the plugin (say "foo"), the slash command then always is /foo:foo and never /foo.

What Should Happen?

Please allow a plugin command to react directly under its plugin namespace with just / (according to the documentation, perhaps by detecting that and are exactly the same word) or / (by allowing the command to be a default command in the namespace, perhaps by having named "default" or something).

Error Messages/Logs

Steps to Reproduce

Create a plugin "foo" with a command "foo", then install the plugin and see that the only possibility to call it is "/foo:foo" and never just "/foo"

Claude Model

Opus

Is this a regression?

I don't know

Last Working Version

No response

Claude Code Version

2.0.76

Platform

Anthropic API

Operating System

macOS

Terminal/Shell

Terminal.app (macOS)

Additional Information

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:tuibugSomething isn't workingdocumentationImprovements or additions to documentationhas reproHas detailed reproduction stepsplatform:macosIssue specifically occurs on macOSstaleIssue is inactive

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions