diff --git a/src/auto-reply/commands-registry.test.ts b/src/auto-reply/commands-registry.test.ts index 918310278c9..1d8a1128cc1 100644 --- a/src/auto-reply/commands-registry.test.ts +++ b/src/auto-reply/commands-registry.test.ts @@ -109,6 +109,16 @@ describe("commands registry", () => { expect(findCommandByNativeName("tts", "discord")).toBeUndefined(); }); + it("renames status to agentstatus for slack", () => { + const native = listNativeCommandSpecsForConfig( + { commands: { native: true } }, + { provider: "slack" }, + ); + expect(native.find((spec) => spec.name === "agentstatus")).toBeTruthy(); + expect(native.find((spec) => spec.name === "status")).toBeFalsy(); + expect(findCommandByNativeName("agentstatus", "slack")?.key).toBe("status"); + }); + it("keeps discord native command specs within slash-command limits", () => { const native = listNativeCommandSpecsForConfig( { commands: { native: true } }, diff --git a/src/auto-reply/commands-registry.ts b/src/auto-reply/commands-registry.ts index 34ca31492bc..93f8872e37b 100644 --- a/src/auto-reply/commands-registry.ts +++ b/src/auto-reply/commands-registry.ts @@ -123,6 +123,11 @@ const NATIVE_NAME_OVERRIDES: Record> = { discord: { tts: "voice", }, + slack: { + // Slack reserves /status — registering it returns "invalid name" + // and invalidates the entire slash_commands manifest array. + status: "agentstatus", + }, }; function resolveNativeName(command: ChatCommandDefinition, provider?: string): string | undefined {