Guilds Module

class Guilds(*args: Any, **kwargs: Any)

This module manages various guild-related commands and background tasks, including adding, removing, and viewing custom reaction roles, and simulating different events.

Attention

All commands assume minimum bot permissions: View Channel, Send Messages.

async add_reaction_command(ctx, channel, message_id: int, role, emote)

Add a custom reaction role to a message.

Chii-chan’s role must be higher than the target role. If the target role is managed by an integration (e.g., Twitch, Patreon roles etc), this will always return Forbidden.

Syntax

!!acr <channel> <message_id> <role> <emote>

Examples

!!acr #react-roles 1178676725358547006 @Birb <emote>
!!acr 1104549057793376297 1178676725358547006 1118694613272764508 1109559058639356094
Parameters:
  • channel (discord.TextChannel or int) – The channel mention or ID where the reaction role is to be added.

  • message_id (int) – The message ID where the reaction role is added.

  • role (discord.Role or int) – The role mention or ID to be assigned.

  • emote (discord.Emoji or int) – The emote mention or ID to be used for the reaction role.

Returns:

A message indicating success or failure of the addition of the reaction role.

Return type:

discord.Message

Permissions

Author: Administrator

Bot: Manage Roles

async emoteid(ctx, emote)

Return the ID of a given emote. Helpful for setting up reaction commands. This will work for animated emotes also.

Syntax:

!!emoteid <emote>

Example:

!!emoteid

Chiito in Tuxedo
Parameters:

emote (discord.Emote) – The emote to retrieve the ID for.

Returns:

A message displaying the ID of the emote.

Return type:

discord.Message

Permissions

Author: Administrator

async inviteme(ctx)

Get an invite link to the support server for Chii-chan.

Syntax:

!!inviteme
Returns:

A Discord invite link to the support server for Chii-chan.

Return type:

discord.Message

async remove_reaction_command(ctx, message_id: int, emote)

Remove a custom reaction role.

Aliases: rcr

Syntax

!!remove_reaction_command <message_id> <emote>

Examples

!!remove_reaction_command 1178676725358547006 <emote>
!!remove_reaction_command 1178676725358547006 1109559058639356094
Parameters:
  • message_id (int) – The message ID where the reaction role is to be removed.

  • emote (discord.Emoji or int) – The emote mention or ID to be removed from the reaction role.

Returns:

A message indicating success or failure of the removal of the reaction role.

Return type:

discord.Message

Permissions

Author: Administrator

Bot: Manage Roles

async tgj(ctx)

Test the on_guild_join event by manually triggering it.

Syntax:

!!tgj
Returns:

Runs guild_joined functions. Confirms that the on_guild_join event has been triggered.

Return type:

discord.Embed

Permissions

Author: Bot Owner

async tgr(ctx)

Test the on_guild_remove event by manually triggering it.

Syntax:

!!tgr
Returns:

Runs guild_removed functions. Confirms that the on_guild_remove event has been triggered.

Return type:

discord.Embed

Permissions

Author: Bot Owner

async tmj(ctx, member: Member = None)

Simulate the on_member_join event in your server by manually calling the event handler.

Syntax:

!!tmj [member]

Example:

!!tmj @username
Parameters:

member (discord.Member, optional) – The member to simulate the event for. Defaults to the command author if none is given.

Returns:

New member joining functions pre defined in gs, confirms the on_member_join event has been simulated.

Return type:

discord.Message

Permissions

Author: Administrator

async tmr(ctx, member: Member = None)

Simulate the on_member_remove event in your server by manually calling the event handler.

Syntax:

!!tmr [member]

Example:

!!tmr @username
Parameters:

member (discord.Member, optional) – Optional. The member to simulate the event for. Defaults to the command invoker.

Returns:

Confirmation that the on_member_remove event has been simulated.

Return type:

discord.Message

Permissions

Author: Administrator

async view_reactions_command(ctx)

View all current reactions in the database for the guild.

Aliases: vcr

Syntax

!!view_reactions_command
Returns:

A message displaying all current reactions in the database for the guild.

Return type:

discord.Message

Permissions

Author: Administrator