python-discord / sir-robin

Our event bot, for managing community events.
MIT License
18 stars 14 forks source link

Add `&cj pin` command for participants to use #53

Closed janine9vn closed 2 years ago

janine9vn commented 2 years ago

Participants in our code jam have asked for a way to pin things in their channel. We can't reasonably give them the native Discord permission, but we do have bots. Let's use the bots.

This command should be usable by Admins, Events Team, and anyone with the Code Jam Participants Role. It'll let people pin/un-pin messages only in their team channel via the bot. This should work with a reply to a message and also a message link.

I figure one way to do this is have a wonky role-check-like-object to see if their role matches the channel name? If it does, allow it? Maybe?

D0rs4n commented 2 years ago

We can use the Code Jam MGMT API, and do a basic ID check. I can do this.

DMFriends commented 2 years ago

I really like this idea. (Note: I'm not a participant). How would the command work? Like reply to a message and invoke the command (pin or unpin), similar to the .uwu command on Lancebot? I think that's probably the best way to implement this. Just stating my opinion.

D0rs4n commented 2 years ago

Yes, exactly like this. We need to add a "middleware" though, to check the channel ID, but basically what you said.