From c916fd9ed9e14d39b2773590fc4295a967800501 Mon Sep 17 00:00:00 2001 From: "Benjamin A. Shelton" Date: Fri, 23 Oct 2026 10:57:28 -0600 Subject: [PATCH] I *think* commands have to be repeated per-scope. --- internal/app/bot.go | 64 +++++++++++++++++++++++++++++++++------------ 1 file changed, 47 insertions(+), 17 deletions(-) diff --git a/internal/app/bot.go b/internal/app/bot.go index dad7c14..54f0829 100644 --- a/internal/app/bot.go +++ b/internal/app/bot.go @@ -166,26 +166,17 @@ func (b *bot) SetCommands(ctx context.Context) (err error) { Scope: &telego.BotCommandScopeAllChatAdministrators{ Type: "all_chat_administrators", }, - Commands: []telego.BotCommand{ - { - Command: "settings", - Description: "Bot settings.", - IsEphemeral: true, - }, - { - Command: "start", - Description: "Starts the bot and links it to the current user's channel.", - IsEphemeral: true, - }, - }, - }) - b.tgbot.SetMyCommands(ctx, &telego.SetMyCommandsParams{ Commands: []telego.BotCommand{ { Command: "help", Description: "Displays bot usage and help.", IsEphemeral: true, }, + { + Command: "add", + Description: "Submits a passage to the bot's daily passage rotation.", + IsEphemeral: true, + }, { Command: "announce", Description: "Adds an announcement to the bot.", @@ -198,18 +189,57 @@ func (b *bot) SetCommands(ctx context.Context) (err error) { Command: "birthday", Description: "Add, remove, or list birthdays.", }, + { + Command: "random", + Description: "Submits a random Bible passage to the current chat.", + }, + { + Command: "settings", + Description: "Bot settings.", + IsEphemeral: true, + }, + { + Command: "start", + Description: "Starts the bot and links it to the current user's channel.", + IsEphemeral: true, + }, { Command: "verse", Description: "Looks up a Bible passage. Optionally accepts a translation identifier as its second argument.", }, + }, + }) + b.tgbot.SetMyCommands(ctx, &telego.SetMyCommandsParams{ + Commands: []telego.BotCommand{ + { + Command: "help", + Description: "Displays bot usage and help.", + IsEphemeral: true, + }, + { + Command: "add", + Description: "Submits a passage to the bot's daily passage rotation.", + IsEphemeral: true, + }, + { + Command: "announce", + Description: "Adds an announcement to the bot.", + }, + { + Command: "announcements", + Description: "Lists the current announcements for the week.", + }, + { + Command: "birthday", + Description: "Add, remove, or list birthdays.", + }, { Command: "random", Description: "Submits a random Bible passage to the current chat.", }, { - Command: "add", - Description: "Submits a passage to the bot's daily passage rotation.", - IsEphemeral: true, + Command: "verse", + Description: "Looks up a Bible passage. Optionally accepts a translation identifier as its second argument.", }, }, })