cpl_discord.container package

Submodules

cpl_discord.container.category_channel module

class cpl_discord.container.category_channel.CategoryChannel(_t: CategoryChannel)

Bases: CategoryChannel, Container

category_id: int | None
guild: Guild
id: int
name: str
nsfw
position: int
property text_channels: TextChannel

List[TextChannel]: Returns the text channels that are under this category.

property voice_channels: VoiceChannel

List[VoiceChannel]: Returns the voice channels that are under this category.

cpl_discord.container.container module

class cpl_discord.container.container.Container(_o: object, _t: type)

Bases: object

cpl_discord.container.guild module

class cpl_discord.container.guild.Guild(_t: Guild)

Bases: Container, Guild

afk_channel
afk_timeout
approximate_member_count
approximate_presence_count
property categories: CategoryChannel

List[CategoryChannel]: A list of categories that belongs to this guild.

This is sorted by the position and are in UI order from top to bottom.

default_notifications
description
emojis
explicit_content_filter
features
id: int
max_members
max_presences
max_video_channel_users
property members: Member

Sequence[Member]: A list of members that belong to this guild.

mfa_level
name
nsfw_level
owner_id
preferred_locale
premium_progress_bar_enabled
premium_subscription_count
premium_tier
property roles: Role

Sequence[Role]: Returns a sequence of the guild’s roles in hierarchy order.

The first element of this sequence will be the lowest role in the hierarchy.

stickers
property text_channels: TextChannel

List[TextChannel]: A list of text channels that belongs to this guild.

This is sorted by the position and are in UI order from top to bottom.

property threads: TextChannel

Sequence[Thread]: A list of threads that you have permission to view.

New in version 2.0.

unavailable
vanity_url_code
verification_level
property voice_channels: VoiceChannel

List[VoiceChannel]: A list of voice channels that belongs to this guild.

This is sorted by the position and are in UI order from top to bottom.

widget_enabled

cpl_discord.container.member module

class cpl_discord.container.member.Member(_t: Member)

Bases: Member, Container

activities: Tuple[ActivityTypes, ...]
guild: Guild
joined_at: datetime.datetime | None
nick: str | None
pending: bool
premium_since: datetime.datetime | None
property roles: Role

List[Role]: A list of Role that the member belongs to. Note that the first element of this list is always the default @everyone’ role.

These roles are sorted by their position in the role hierarchy.

timed_out_until: datetime.datetime | None

cpl_discord.container.role module

class cpl_discord.container.role.Role(_t: Role)

Bases: Role, Container

guild: Guild
hoist
id: int
managed
property members: Member

List[Member]: Returns all the members with this role.

mentionable
name
position
tags
unicode_emoji

cpl_discord.container.text_channel module

class cpl_discord.container.text_channel.TextChannel(_t: TextChannel)

Bases: TextChannel, Container

category_id: int | None
default_auto_archive_duration
guild: Guild
id: int
last_message_id
property members: Member

List[Member]: Returns all members that can see this channel.

name: str
nsfw
position: int
slowmode_delay
property threads: Thread

List[Thread]: Returns all the threads that you can see.

New in version 2.0.

topic

cpl_discord.container.thread module

class cpl_discord.container.thread.Thread(_t: Thread)

Bases: Thread, Container

archive_timestamp
archived
archiver_id
auto_archive_duration
guild: Guild
id: int
invitable
last_message_id
locked
me
member_count
property members: Member

List[ThreadMember]: A list of thread members in this thread.

This requires Intents.members to be properly filled. Most of the time however, this data is not provided by the gateway and a call to fetch_members() is needed.

message_count
name
owner_id
parent_id
slowmode_delay

cpl_discord.container.voice_channel module

class cpl_discord.container.voice_channel.VoiceChannel(_t: VoiceChannel)

Bases: VoiceChannel, Container

property members: Member

List[Member]: Returns all members that are currently inside this voice channel.

Module contents

cpl-discord CPL Discord

Link between discord.py and CPL

copyright:
  1. 2022 - 2023 sh-edraft.de

license:

MIT, see LICENSE for more details.

class cpl_discord.container.VersionInfo(major, minor, micro)

Bases: tuple

major

Alias for field number 0

micro

Alias for field number 2

minor

Alias for field number 1