What are Communities?
Communities (also known as servers) are organized spaces where users can communicate through channels, organize with roles, and manage permissions. Each community has its own set of channels, roles, and members.Community Structure
A community consists of:- Channels: Text, voice, or category channels where members communicate
- Roles: Permission groups that can be assigned to members
- Members: Users who have joined the community
- Permissions: Granular access control using bitwise flags
Community Type
Snowflake ID of the community
Whether the current user is the owner of this community
The name of the community
The community’s icon/photo
The current user’s computed permissions in this community (bitwise flags)
Whether the community is muted for the current user
Managing Communities
Get Communities
Retrieve all communities the user is a member of. Method:communities.getCommunities
Request: GetCommunities (empty message)
Response: Communities
List of all communities the user belongs to
User-specific information for each community (unread counts, etc.)
Community IDs that are currently unavailable
Create Community
Create a new community (server). Method:communities.createCommunity
Request: CreateCommunity
The name for the new community
Edit Community
Modify community settings. Method:communities.editCommunity
Request: EditCommunity
Snowflake ID of the community to edit
New name for the community
Edit Photo
Change the community’s icon/photo. Method:communities.editPhoto
Request: EditPhoto
Snowflake ID of the community
Reference to the uploaded photo file. If omitted, removes the current photo.
Leave Community
Leave a community as a member. Method:communities.leaveCommunity
Request: LeaveCommunity
Snowflake ID of the community to leave
Delete Community
Permanently delete a community. Requires ownership. Method:communities.deleteCommunity
Request: DeleteCommunity
Snowflake ID of the community to delete
Community Settings
Configure community-wide settings like system messages. Method:communities.editSettings
Request: EditSettings
Snowflake ID of the community
The settings to apply
CommunitySettings Structure
Configuration for system messages
SystemMessages
Snowflake ID of the channel where system messages should be sent
Whether to send messages when users join the community