bot

Entry point for the Byte Discord bot.

Byte Bot.

class src.byte.bot.Byte(command_prefix: list[str], intents: Intents, activity: Activity)[source]

Bases: Bot

Byte Bot Base Class.

Initialize the bot.

Parameters:
__init__(command_prefix: list[str], intents: Intents, activity: Activity) None[source]

Initialize the bot.

Parameters:
async setup_hook() None[source]

Any setup we need can be here.

async load_cogs() None[source]

Load cogs.

async on_ready() None[source]

Handle bot ready event.

async on_message(message: Message) None[source]

Handle message events.

Parameters:

message – Message object.

async on_command_error(ctx: Context, error: CommandError) None[source]

Handle command errors.

Parameters:
  • ctx – Context object.

  • error – Error object.

async static on_member_join(member: Member) None[source]

Handle member join event.

Parameters:

member – Member object.

async on_guild_join(guild: Guild) None[source]

Handle guild join event.

Parameters:

guild – Guild object.

src.byte.bot.run_bot() None[source]

Run the bot.