From f22ba3f0eabbb5d520b1fcf7123113ed32cc2cab Mon Sep 17 00:00:00 2001 From: asleepyskye Date: Wed, 10 Dec 2025 13:04:55 -0500 Subject: [PATCH 1/4] fix(bot): add interaction error for wrong account --- PluralKit.Bot/Errors.cs | 2 ++ PluralKit.Bot/Interactive/BaseInteractive.cs | 6 ++++++ PluralKit.Bot/Interactive/YesNoPrompt.cs | 2 +- 3 files changed, 9 insertions(+), 1 deletion(-) diff --git a/PluralKit.Bot/Errors.cs b/PluralKit.Bot/Errors.cs index 25cecab0..9b496da0 100644 --- a/PluralKit.Bot/Errors.cs +++ b/PluralKit.Bot/Errors.cs @@ -183,4 +183,6 @@ public static class Errors public static PKError ChannelNotFound(string channelString) => new($"Channel \"{channelString}\" not found or is not in this server."); + + public static PKError InteractionWrongAccount(ulong user) => new($"This prompt is only available for <@{user}>"); } \ No newline at end of file diff --git a/PluralKit.Bot/Interactive/BaseInteractive.cs b/PluralKit.Bot/Interactive/BaseInteractive.cs index 779058fe..043c5b8d 100644 --- a/PluralKit.Bot/Interactive/BaseInteractive.cs +++ b/PluralKit.Bot/Interactive/BaseInteractive.cs @@ -5,6 +5,7 @@ using Myriad.Rest.Types.Requests; using Myriad.Types; using NodaTime; +using PluralKit.Core; namespace PluralKit.Bot.Interactive; @@ -47,6 +48,11 @@ public abstract class BaseInteractive new InteractionApplicationCommandCallbackData { Components = GetComponents() }); } + protected async Task Error(InteractionContext ctx, PKError error) + { + await ctx.Reply(content: $"{Emojis.Error} {error.Message}"); + } + protected async Task Finish(InteractionContext? ctx = null) { foreach (var button in _buttons) diff --git a/PluralKit.Bot/Interactive/YesNoPrompt.cs b/PluralKit.Bot/Interactive/YesNoPrompt.cs index 194dd1f1..f6de2695 100644 --- a/PluralKit.Bot/Interactive/YesNoPrompt.cs +++ b/PluralKit.Bot/Interactive/YesNoPrompt.cs @@ -43,7 +43,7 @@ public class YesNoPrompt: BaseInteractive { if (ctx.User.Id != User) { - await Update(ctx); + await Error(ctx, Errors.InteractionWrongAccount(User ?? 0)); return; } From 1776902000e9edddf378739025cce3d90c9ac897 Mon Sep 17 00:00:00 2001 From: asleepyskye Date: Thu, 1 Jan 2026 11:16:27 -0500 Subject: [PATCH 2/4] fix(bot): fix server name format command --- PluralKit.Bot/Commands/Config.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/PluralKit.Bot/Commands/Config.cs b/PluralKit.Bot/Commands/Config.cs index 1feb7c37..24cfb43f 100644 --- a/PluralKit.Bot/Commands/Config.cs +++ b/PluralKit.Bot/Commands/Config.cs @@ -645,10 +645,10 @@ public class Config var clearFlag = ctx.MatchClear(); var format = ctx.MatchFormat(); + var guildCfg = await ctx.Repository.GetSystemGuild(ctx.Guild.Id, ctx.System.Id); // if there's nothing next or what's next is raw/plaintext and we're not clearing, it's a query if ((!ctx.HasNext() || format != ReplyFormat.Standard) && !clearFlag) { - var guildCfg = await ctx.Repository.GetSystemGuild(ctx.Guild.Id, ctx.System.Id); if (guildCfg.NameFormat == null) await ctx.Reply("You do not have a specific name format set for this server and member names are formatted with your global name format."); else From 9dfbf64dac4ab5ff252f09ad6f403ca9051e2b0b Mon Sep 17 00:00:00 2001 From: Petal Ladenson Date: Mon, 12 Jan 2026 11:50:00 -0700 Subject: [PATCH 3/4] fix(docs): Correctly reflect what permissions PluralKit needs to work --- docs/content/staff/permissions.md | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/docs/content/staff/permissions.md b/docs/content/staff/permissions.md index 41f27747..b48cf82f 100644 --- a/docs/content/staff/permissions.md +++ b/docs/content/staff/permissions.md @@ -2,21 +2,23 @@ PluralKit requires some channel permissions in order to function properly: -- Message proxying requires the **Manage Messages** and **Manage Webhooks** permissions in a channel. -- Most commands require the **Embed Links**, **Attach Files** and **Add Reactions** permissions to function properly. +- *Everything* PluralKit does aside from the Message Info app command requires **View Channel** permissions in a channel. +- Message proxying requires the **Manage Messages**, **Manage Webhooks**, and **Send Messages** permissions in a channel. +- Most commands require the **Embed Links** and **Add Reactions** permissions to function properly. - Commands with reaction menus also require **Manage Messages** to remove reactions after clicking. + - Commands executed via reactions (for example the :x:, :bell:, and :question: reactions, as well as any commands with reaction menus) need **Read Message History** to be able to see that reactions were added. + - A couple commands (`pk;s color` and `pk;m color`) currently require **Attach Files**. - [Proxy logging](/staff/logging) requires the **Send Messages** permission in the log channel. - [Log cleanup](/staff/compatibility/#log-cleanup) requires the **Manage Messages** permission in the log channels. -Denying the **Send Messages** permission will *not* stop the bot from proxying, although it will prevent it from sending command responses. Denying the **Read Messages** permission will, as any other bot, prevent the bot from interacting in that channel at all. - ## Webhook permissions -Webhooks exist outside of the normal Discord permissions system, and (with a few exceptions) it's not possible to modify their permissions. +Webhooks exist outside of the normal Discord permissions system, but as of August 2022 they mostly follow the permissions of the webhook owner (in this case, PluralKit). -However, PluralKit will make an attempt to apply the sender account's permissions to proxied messages. For example, role mentions, `@everyone`, and `@here` +PluralKit will also make an attempt to apply the sender account's permissions to proxied messages. For example, role mentions, `@everyone`, and `@here` will only function if the sender account has that permission. The same applies to link embeds. -For external emojis to work in proxied messages, the `@everyone` role must have the "Use External Emojis" permission. If it still doesn't work, check if the permission was denied in channel-specific permission settings. +For external emojis to work in proxied messages, PluralKit or one of its roles must have the "Use External Emojis" permission. If it still doesn't work, +check if the permission was denied in channel-specific permission settings. PluralKit must also be in the server the external emoji belongs to. ## Troubleshooting @@ -30,4 +32,4 @@ For example: pk;debug permissions 466707357099884544 -You can find this ID [by enabling Developer Mode and right-clicking (or long-pressing) on the server icon](https://discordia.me/developer-mode). \ No newline at end of file +You can find this ID [by enabling Developer Mode and right-clicking (or long-pressing) on the server icon](https://discordia.me/developer-mode). From 952bb022850c00c6da75c9e625ee6556522f8d7b Mon Sep 17 00:00:00 2001 From: Petal Ladenson Date: Sun, 11 Jan 2026 15:56:34 -0700 Subject: [PATCH 4/4] fix(docs): Correctly display bellhop emoji in user guide --- docs/content/user-guide.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/content/user-guide.md b/docs/content/user-guide.md index 51654841..cfe02c47 100644 --- a/docs/content/user-guide.md +++ b/docs/content/user-guide.md @@ -453,7 +453,7 @@ You can #### Pinging the user who sent it If you'd like to "ping" the account behind a proxied message without having to query the message and ping them yourself, -you can react to the message with the `:bell:` :bell: emoji (or `:bellhop:` :bellhop:, `:exclamation:` :exclamation:, or even `:ping_pong:` :ping_pong:), and PluralKit will ping the relevant member and account in the same channel on your behalf with a link to the message you reacted to. +you can react to the message with the `:bell:` :bell: emoji (or `:bellhop:` :bellhop_bell:, `:exclamation:` :exclamation:, or even `:ping_pong:` :ping_pong:), and PluralKit will ping the relevant member and account in the same channel on your behalf with a link to the message you reacted to. ## Autoproxy The bot's *autoproxy* feature allows you to have messages be proxied without directly including the proxy tags. Autoproxy can be set up in various ways. There are three autoproxy modes currently implemented: