Guild Resource
Guilds in Discord represent an isolated collection of users and channels, and are often referred to as "servers" in the UI.
Guild Object
Guild Structure
Field | Type | Description |
---|---|---|
id | snowflake | The ID of the guild |
name | string | The name of the guild (2-100 characters) |
icon | ?string | The guild's icon hash |
banner | ?string | The guild's banner hash |
home_header | ?string | The guild's home header hash, also used in server guide |
splash | ?string | The guild's splash hash |
discovery_splash | ?string | The guild's discovery splash hash |
owner_id | snowflake | The user ID of the guild's owner |
application_id | ?snowflake | The application ID of the guild's owner, if bot-created |
description | ?string | The description for the guild |
region? (deprecated) | ?string | The main voice region ID of the guild |
afk_channel_id | ?snowflake | The ID of the guild's AFK channel; this is where members in voice idle for longer than afk_timeout are moved |
afk_timeout | integer | The AFK timeout of the guild (one of 60, 300, 900, 1800, 3600, in seconds) |
widget_enabled? | boolean | Whether the guild widget is enabled |
widget_channel_id? | ?snowflake | The channel ID that the widget will generate an invite to, if any |
verification_level | integer | The verification level required for the guild |
default_message_notifications | integer | Default message notification level for the guild |
explicit_content_filter | integer | Whose messages are scanned and deleted for explicit content in the guild |
features | array[string] | Enabled guild features |
roles | array[role object] | Roles in the guild |
emojis | array[emoji object] | Custom guild emojis |
stickers | array[sticker object] | Custom guild stickers |
mfa_level | integer | Required MFA level for administrative actions within the guild |
system_channel_id | ?snowflake | The ID of the channel where system event messages, such as member joins and premium subscriptions (boosts), are posted |
system_channel_flags | integer | The flags that limit system event messages |
rules_channel_id | ?snowflake | The ID of the channel where community guilds display rules and/or guidelines |
public_updates_channel_id | ?snowflake | The ID of the channel where admins and moderators of community guilds receive notices from Discord |
safety_alerts_channel_id | ?snowflake | The ID of the channel where admins and moderators of community guilds receive safety alerts from Discord |
max_members? | integer | The maximum number of members for the guild |
vanity_url_code | ?string | The guild's vanity invite code |
premium_tier | integer | The guild's premium tier (boost level) |
premium_subscription_count | integer | The number of premium subscriptions (boosts) the guild currently has |
preferred_locale | string | The preferred locale of the guild; used in discovery and notices from Discord (default "en-US") |
max_video_channel_users? | integer | The maximum amount of users that can watch a video stream in a voice channel at once |
max_stage_video_channel_users? | integer | The maximum amount of users that can watch a video stream in a stage channel at once |
nsfw (deprecated) | boolean | Whether the guild is considered NSFW (EXPLICIT or AGE_RESTRICTED ) |
nsfw_level | integer | The NSFW level of the guild |
hub_type | ?integer | The type of student hub the guild is, if it is a student hub |
premium_progress_bar_enabled | boolean | Whether the guild has the premium (boost) progress bar enabled |
latest_onboarding_question_id | ?snowflake | The ID of the guild's latest onboarding prompt option |
incidents_data | ?automod incidents data object | Information on the guild's AutoMod incidents |
approximate_member_count? 1 | integer | Approximate count of total members in the guild |
approximate_presence_count? 1 | integer | Approximate count of non-offline members in the guild |
clan? 2 | partial clan object | The guild's clan information |
1 Only included when fetched from the Get Guild endpoint with with_counts
set to true
.
2 Only included in guild objects returned over the Gateway.
Example Guild
{"id": "81384788765712384","name": "Discord API","icon": "a363a84e969bcbe1353eb2fdfb2e50e6","description": null,"home_header": null,"splash": null,"discovery_splash": null,"features": ["INVITE_SPLASH","VIP_REGIONS","PREVIEW_ENABLED","VANITY_URL","CHANNEL_ICON_EMOJIS_GENERATED","COMMUNITY","NEW_THREAD_PERMISSIONS","WELCOME_SCREEN_ENABLED","NEWS","ANIMATED_ICON","AUTO_MODERATION","MEMBER_VERIFICATION_GATE_ENABLED","THREADS_ENABLED","COMMUNITY_EXP_LARGE_UNGATED","SOUNDBOARD","THREE_DAY_THREAD_ARCHIVE"],"emojis": [],"stickers": [],"banner": null,"owner_id": "80088516616269824","application_id": null,"region": "deprecated","afk_channel_id": null,"afk_timeout": 3600,"system_channel_id": "381870553235193857","widget_enabled": true,"widget_channel_id": null,"verification_level": 3,"roles": [{"id": "81384788765712384","name": "@everyone","description": null,"permissions": "110917634608832","position": 0,"color": 0,"hoist": false,"managed": false,"mentionable": false,"icon": null,"unicode_emoji": null,"flags": 0}],"default_message_notifications": 1,"mfa_level": 1,"explicit_content_filter": 2,"max_presences": null,"max_members": 500000,"max_stage_video_channel_users": 50,"max_video_channel_users": 25,"vanity_url_code": "discord-api","premium_tier": 1,"premium_subscription_count": 5,"system_channel_flags": 9,"preferred_locale": "en-US","rules_channel_id": "381898062269775883","safety_alerts_channel_id": null,"public_updates_channel_id": "650136538264502282","hub_type": null,"premium_progress_bar_enabled": false,"latest_onboarding_question_id": null,"incidents_data": null,"nsfw": false,"nsfw_level": 0}
Message Notification Level
Value | Name | Description |
---|---|---|
0 | ALL_MESSAGES | Receive notifications for all messages |
1 | ONLY_MENTIONS | Receive notifications only for messages that @mention you |
Explicit Content Filter Level
Value | Name | Description |
---|---|---|
0 | DISABLED | Media content will not be scanned |
1 | MEMBERS_WITHOUT_ROLES | Media content sent by members without roles will be scanned |
2 | ALL_MEMBERS | Media content sent by all members will be scanned |
MFA Level
Value | Name | Description |
---|---|---|
0 | NONE | Guild has no MFA requirement for moderation actions |
1 | ELEVATED | Guild has a MFA requirement for moderation actions |
Verification Level
Level | Integer | Description |
---|---|---|
NONE | 0 | Unrestricted |
LOW | 1 | Must have a verified email on file |
MEDIUM | 2 | Must be registered on Discord for longer than 5 minutes |
HIGH | 3 | Must be a member of the server for longer than 10 minutes |
VERY_HIGH | 4 | Must have a verified phone number on file |
NSFW Level
Value | Name | Description |
---|---|---|
0 | DEFAULT | Guild is not yet rated by Discord |
1 | EXPLICIT | Guild has mature content only suitable for users over 18 |
2 | SAFE | Guild is safe for work |
3 | AGE_RESTRICTED | Guild has mildly mature content that may not be suitable for users under 18 |
Premium Tier
Value | Name | Description |
---|---|---|
0 | NONE | Guild has not unlocked any Server Boost perks |
1 | TIER_1 | Guild has unlocked Server Boost level 1 perks |
2 | TIER_2 | Guild has unlocked Server Boost level 2 perks |
3 | TIER_3 | Guild has unlocked Server Boost level 3 perks |
System Channel Flags
Value | Name | Description |
---|---|---|
1 << 0 | SUPPRESS_JOIN_NOTIFICATIONS | Suppress member join notifications |
1 << 1 | SUPPRESS_PREMIUM_SUBSCRIPTIONS | Suppress premium subscription (boost) notifications |
1 << 2 | SUPPRESS_GUILD_REMINDER_NOTIFICATIONS | Suppress guild setup tips |
1 << 3 | SUPPRESS_JOIN_NOTIFICATION_REPLIES | Hide member join sticker reply buttons |
1 << 4 | SUPPRESS_ROLE_SUBSCRIPTION_PURCHASE_NOTIFICATIONS | Suppress role subscription purchase and renewal notifications |
1 << 5 | SUPPRESS_ROLE_SUBSCRIPTION_PURCHASE_NOTIFICATION_REPLIES | Hide role subscription sticker reply buttons |
1 << 7 | SUPPRESS_CHANNEL_PROMPT_DEADCHAT | Suppress dead chat channel prompts |
Privacy Level
Value | Name | Description |
---|---|---|
1 | PUBLIC | Scheduled event or stage instance is visible publicly |
2 | GUILD_ONLY | Scheduled event or stage instance is only visible to guild members |
Hub Type
Value | Name | Description |
---|---|---|
0 | DEFAULT | Student hub is not categorized as a high school or post-secondary institution |
1 | HIGH_SCHOOL | Student hub is for a high school |
2 | COLLEGE | Student hub is for a post-secondary institution (college or university) |
Guild Features
The available guild features, their functionality, and their requirements is subject to arbitrary change. The following table is a best-effort attempt to document the current state of guild features.
Value | Description |
---|---|
ACTIVITIES_ALPHA | Access to alpha embedded activities (soft_launch release phase) |
ACTIVITIES_EMPLOYEE | Access to employee-released embedded activities (employee_release release phase) |
ACTIVITIES_INTERNAL_DEV | Access to internal developer embedded activities (activities_team release phase) |
ACTIVITY_FEED_DISABLED_BY_USER | Member list activity feed disabled |
ACTIVITY_FEED_ENABLED_BY_USER | Member list activity feed enabled |
ANIMATED_BANNER | Ability to set an animated guild banner image |
ANIMATED_ICON | Ability to set an animated guild icon |
AUTO_MODERATION | AutoMod feature enabled |
AUTOMOD_TRIGGER_USER_PROFILE | Access to the user profile trigger for AutoMod |
BANNER | Ability to set a guild banner image |
BFG | Big what now 🤨 |
BOT_DEVELOPER_EARLY_ACCESS | Access to early feature testing for bot and library developers |
BURST_REACTIONS | Access to burst reactions |
CHANNEL_ICON_EMOJIS_GENERATED | Guild has channel icon emojis populated |
CHANNEL_HIGHLIGHTS | Access to channel highlights |
CHANNEL_HIGHLIGHTS_DISABLED | |
CLAN | Guild is a clan |
CLAN_DISCOVERY_DISABLED | Clan discovery permanently disabled by Discord |
CLAN_PILOT_GENSHIN | Access to clan conversion and clan discovery for Genshin Impact |
CLAN_PILOT_VALORANT | Access to clan conversion and clan discovery for Valorant |
CLAN_PREPILOT_GENSHIN | |
CLAN_PREPILOT_VALORANT | |
CLAN_SAFETY_REVIEW_DISABLED | |
COMMERCE | Access to store channels |
COMMUNITY | Access to welcome screen, member verification, stage channels, discovery, community updates reception, and more |
COMMUNITY_CANARY | Early access to experimental community features |
COMMUNITY_EXP_LARGE_GATED | |
COMMUNITY_EXP_LARGE_UNGATED | |
COMMUNITY_EXP_MEDIUM | |
CREATOR_ACCEPTED_NEW_TERMS | Guild owner has accepted the updated monetization agreements |
CREATOR_MONETIZABLE | Monetization enabled |
CREATOR_MONETIZABLE_DISABLED | Monetization permanently disabled by Discord |
CREATOR_MONETIZABLE_PENDING_NEW_OWNER_ONBOARDING | Monetization features are pending until the new guild owner completes the onboarding process |
CREATOR_MONETIZABLE_PROVISIONAL | Monetization enabled |
CREATOR_MONETIZABLE_RESTRICTED | Guild has restrictions on monetization features |
CREATOR_MONETIZABLE_WHITEGLOVE | |
CREATOR_MONETIZATION_APPLICATION_ALLOWLIST | |
CREATOR_STORE_PAGE | Monetization store page enabled |
DEVELOPER_SUPPORT_SERVER | Guild is an application support server |
DISCOVERABLE | Guild is public and discoverable in the directory |
DISCOVERABLE_DISABLED | Discovery permanently disabled by Discord |
ENABLED_DISCOVERABLE_BEFORE | Guild has previously been discoverable |
ENABLED_MODERATION_EXPERIENCE_FOR_NON_COMMUNITY | Guild has enabled the members tab in the channel list without being a community guild |
EXPOSED_TO_ACTIVITIES_WTP_EXPERIMENT | |
BOOSTING_TIERS_EXPERIMENT_MEDIUM_GUILD , BOOSTING_TIERS_EXPERIMENT_SMALL_GUILD ) | |
RELAY_ENABLED ) | |
GENSHIN_L30 | Access to clan conversion based on the intensity of Genshin Impact engagement among the guild's members, as depicted by the power user curve |
GUESTS_ENABLED | Guild has used guest invites |
GUILD_HOME_DEPRECATION_OVERRIDE | Home tab deprecation notice hidden |
GUILD_HOME_OVERRIDE | Access to the Home feature, without additionally checking for the matching user experiment |
GUILD_HOME_TEST | Access to the Home feature |
GUILD_MEMBER_VERIFICATION_EXPERIMENT | |
GUILD_ONBOARDING | Onboarding feature enabled |
GUILD_ONBOARDING_EVER_ENABLED | Guild has previously enabled the onboarding feature |
GUILD_ONBOARDING_HAS_PROMPTS | Guild has prompts configured in onboarding |
GUILD_PRODUCTS | Access to guild products |
GUILD_PRODUCTS_ALLOW_ARCHIVED_FILE | Allows uploading archive formats as guild products |
ROLE_SUBSCRIPTIONS_ENABLED ) | |
SUPPRESS_ROLE_SUBSCRIPTION_PURCHASE_NOTIFICATIONS , SUPPRESS_ROLE_SUBSCRIPTION_PURCHASE_NOTIFICATIONS_REPLIES system channel flags | |
GUILD_SERVER_GUIDE | Server guide feature enabled |
GUILD_WEB_PAGE_VANITY_URL | Guild has an immutable vanity given by the server web page feature |
HAD_EARLY_ACTIVITIES_ACCESS | Guild previously had access to embedded activities and can bypass the premium tier requirement |
HAS_DIRECTORY_ENTRY | Guild is listed in a directory channel |
HIDE_FROM_EXPERIMENT_UI | |
HUB | Guild is a student hub |
INCREASED_THREAD_LIMIT | Ability to have over 1,000 active threads |
INTERNAL_EMPLOYEE_ONLY | Restricts guild joining to Discord employees |
INVITE_SPLASH | Ability to set an invite splash background |
INVITES_DISABLED | Guild has paused invites, preventing new members from joining |
LINKED_TO_HUB | Guild is linked to a student hub |
DISCOVERABLE and PREVIEW_ENABLED ) | |
MEMBER_SAFETY_PAGE_ROLLOUT | Access to member safety tab |
MEMBER_VERIFICATION_GATE_ENABLED | Member verification enabled, requiring new members to pass the verification gate before interacting with the guild |
MEMBER_VERIFICATION_MANUAL_APPROVAL | Membership verification v2 enabled |
CREATOR_MONETIZABLE ) | |
MORE_EMOJI | Increased guild emoji slots (+150 each) |
MORE_SOUNDBOARD | Increased guild soundboard slots (+48) |
MORE_STICKERS | Increased guild sticker slots (+60) |
NEWS | Access to news channels |
NON_COMMUNITY_RAID_ALERTS | Non-community guild is opt-in to raid alerts |
PARTNERED | Guild is partnered with Discord |
PREMIUM_TIER_3_OVERRIDE | Guild premium tier is overrided to 3 regardless of premium subscription count |
PREVIEW_ENABLED | Guild is accessable (read-only) without passing member verification |
PRODUCTS_AVAILABLE_FOR_PURCHASE | Guild has guild products available for purchase |
COMMUNITY ) | |
RAID_ALERTS_DISABLED | Raid alerts opted out |
RAID_ALERTS_DISABLED ) | |
RAPIDASH_TEST | Access to clan conversion general availability |
RELAY_ENABLED | Shards connections to the guild to different nodes that relay information between each other |
ROLE_ICONS | Ability to set an image or emoji as a role icon |
ROLE_SUBSCRIPTIONS_AVAILABLE_FOR_PURCHASE | Guild has role subscriptions available for purchase |
ROLE_SUBSCRIPTIONS_ENABLED | Role subscriptions enabled |
ROLE_SUBSCRIPTIONS_AVAILABLE_FOR_PURCHASE ) | |
SHARD | Shards student hub UI |
SHARED_CANVAS_FRIENDS_AND_FAMILY_TEST | Access to the shared canvas feature |
SOUNDBOARD | Access to the soundboard |
SUMMARIES_ENABLED_GA | Access to conversation summaries general access |
SUMMARIES_DISABLED_BY_USER | Conversation summaries opted out |
SUMMARIES_ENABLED_BY_USER | Conversation summaries enabled |
SUMMARIES_LONG_LOOKBACK | |
SUMMARIES_OPT_OUT_EXPERIENCE | Conversation summaries enabled by default, must be opted out instead of opted in |
STAFF_LEVEL_COLLABORATOR_REQUIRED | Restricts guild joining to users with the COLLABORATOR flag or higher |
STAFF_LEVEL_RESTRICTED_COLLABORATOR_REQUIRED | Restricts guild joining to users with the RESTRICTED_COLLABORATOR flag or higher |
THREAD_DEFAULT_AUTO_ARCHIVE_DURATION | |
TICKETED_EVENTS_ENABLED ) | |
VALORANT_L30 | Access to clan conversion based on the intensity of Valorant engagement among the guild's members, as depicted by the power user curve |
VANITY_URL | Ability to set a vanity URL |
VERIFIED | Guild is verified |
VIP_REGIONS | Access to 384 kbps max bitrate |
VOICE_IN_THREADS | Access to voice in threads (calls within threads) |
WELCOME_SCREEN_ENABLED | Welcome screen enabled |
1 This is now a base feature, and the guild feature has no effect if still present.
Mutable Guild Features
These guild features are mutable, and can be edited with the Modify Guild endpoint.
Feature | Description | Required Permissions |
---|---|---|
MANAGE_GUILD | ||
MANAGE_GUILD | ||
COMMUNITY 1 | Whether community features are available | ADMINISTRATOR |
DISCOVERABLE 2 | Whether the guild is public and discoverable in the directory | ADMINISTRATOR |
ENABLED_MODERATION_EXPERIENCE_FOR_NON_COMMUNITY | Whether the member tab is shown in the channel list for non-community guilds | MANAGE_GUILD |
INVITES_DISABLED | Whether joining the guild is disabled | MANAGE_GUILD |
MEMBER_VERIFICATION_GATE_ENABLED 3 | Whether the member verification gate is enabled | MANAGE_GUILD |
NON_COMMUNITY_RAID_ALERTS | Whether raid alerts are opted in for non-community guilds | MANAGE_GUILD |
RAID_ALERTS_DISABLED | Whether raid alerts are opted out for community guilds | MANAGE_GUILD |
SUMMARIES_ENABLED_BY_USER 4 | Whether conversation summaries are enabled |
1 Modification requires the ADMINISTRATOR
permission.
2 Guild must also pass all discovery requirements in order to set.
3 Feature is only removable, not settable.
4 Guild must have access to conversation summaries (either the SUMMARIES_ENABLED
or SUMMARIES_ENABLED_GA
feature).
User Guild Object
A partial guild object returned from the Get User Guilds endpoint. Represents a guild the user is a member of.
User Guild Structure
Field | Type | Description |
---|---|---|
id | snowflake | The ID of the guild |
name | string | The name of the guild (2-100 characters) |
icon | ?string | The guild's icon hash |
banner | ?string | The guild's banner hash |
owner | boolean | Whether the user is the owner of the guild |
features | array[string] | Enabled guild features |
permissions | string | Total permissions for the user in the guild (excludes overwrites) |
approximate_member_count? 1 | integer | Approximate count of total members in the guild |
approximate_presence_count? 1 | integer | Approximate count of non-offline members in the guild |
1 Only included when fetched from the Get User Guilds endpoint with with_counts
set to true
.
Example User Guild
[{"id": "80351110224678913","name": "1337 Krew","icon": "8342729096ea3675442027381ff50dfe","banner": "bb42bdc37653b7cf58c4c8cc622e76cb","owner": true,"permissions": "36953089","features": ["COMMUNITY", "NEWS", "ANIMATED_ICON", "INVITE_SPLASH", "BANNER", "ROLE_ICONS"],"approximate_member_count": 420,"approximate_presence_count": 69}]
Guild Preview Object
A partial guild object returned from the Get Guild Preview endpoint.
Guild Preview Structure
Field | Type | Description |
---|---|---|
id | snowflake | The ID of the guild |
name | string | The name of the guild (2-100 characters) |
icon | ?string | The guild's icon hash |
description | ?string | The description for the guild |
splash | ?string | The guild's splash hash |
discovery_splash | ?string | The guild's discovery splash hash |
home_header | ?string | The guild's home header hash, also used in server guide |
features | array[string] | Enabled guild features |
emojis | array[emoji object] | Custom guild emojis |
stickers | array[sticker object] | Custom guild stickers |
approximate_member_count | integer | Approximate number of total members in the guild |
approximate_presence_count | integer | Approximate number of non-offline members in the guild |
Example Guild Preview
{"id": "752630786561409076","name": "Elite Creative","icon": "278da1c7740e394657c1179f4782aef1","description": "The largest Fortnite Creative server across the globe. Join a Creative community offering events, 1v1s. and more!","home_header": null,"splash": "2b4ae5cdd71038b4880b1b57a6e5dacb","discovery_splash": "9d7ec672b89b320ef7a51e5b6ae453b8","features": ["ANIMATED_BANNER","ANIMATED_ICON","AUTO_MODERATION","BANNER","COMMUNITY","DISCOVERABLE","ENABLED_DISCOVERABLE_BEFORE","GUILD_ONBOARDING_EVER_ENABLED","GUILD_WEB_PAGE_VANITY_URL","INVITE_SPLASH","NEWS","PREVIEW_ENABLED","RAID_ALERTS_ENABLED","ROLE_ICONS","VANITY_URL","WELCOME_SCREEN_ENABLED"],"approximate_member_count": 155451,"approximate_presence_count": 7532,"emojis": [],"stickers": []}
Guild Widget Object
An embeddable widget for a guild.
Guild Widget Structure
Field | Type | Description |
---|---|---|
id | snowflake | The ID of the guild the widget is for |
name | string | The name of the guild the widget is for |
instant_invite | ?string | The invite URL for the guild's widget channel, if any |
presence_count | integer | Approximate count of non-offline members in the guild |
channels | array[widget channel object] | The public voice and stage channels in the guild |
members | array[widget member object] | The non-offline guild members (max 100) |
Guild Widget Channel Structure
Field | Type | Description |
---|---|---|
id | snowflake | The ID of the channel |
name | string | The name of the channel (1-100 characters) |
position | integer | Sorting position of the channel |
Guild Widget Member Structure
Field | Type | Description |
---|---|---|
id | snowflake | The incrementing ID of the member |
username | string | The display name or censored username of the member |
avatar_url | string | The avatar URL of the member |
status | string | The status of the member |
activity? | widget member activity object | The primary activity the member is participating in |
channel_id? | snowflake | The ID of the voice or stage channel the member is in |
deaf? | boolean | Whether the member is deafened by the guild, if any |
mute? | boolean | Whether the member is muted by the guild, if any |
self_deaf? | boolean | Whether the member is locally deafened |
self_mute? | boolean | Whether the member is locally muted |
suppress? | boolean | Whether the member's permission to speak is denied |
Guild Widget Member Activity Structure
Field | Type | Description |
---|---|---|
name | string | The name of the activity |
Example Guild Widget
{"id": "1046920999469330512","name": "Alien Network","instant_invite": "https://discord.com/invite/alien","channels": [{"id": "1053657210082836620","name": "stage","position": 2}],"members": [{"id": "0","username": "Dolfies","discriminator": "0000","avatar": null,"status": "dnd","activity": {"name": "balls lmao"},"deaf": false,"mute": false,"self_deaf": false,"self_mute": true,"suppress": false,"channel_id": "1057241425793798144","avatar_url": "https://cdn.discordapp.com/widget-avatars/zOXeOyhOGqx-bwpzszp-obU-_RFE9xI9HG19HylPyMs/actPlrz4a6Kz4NSBV4jmkd1E4raF_UjDuIXnyCjJgY5DpcbFPZnVS1SvQbRkHbXaVLvKKv7gkZi0PPXX2gdxngxHSyFH7AuxH0Y-8pgQh5xhWQaC9PsmeJ64Bv8xjF9Wb_whrDVNA-I4Eg"}],"presence_count": 69}
Guild Widget Settings Structure
Field | Type | Description |
---|---|---|
enabled | boolean | Whether the widget is enabled |
channel_id | ?snowflake | The channel ID that the widget will generate an invite to, if any |
Example Guild Widget Settings
{"enabled": true,"channel_id": "41771983444115456"}
Guild Member Object
A participating user in a guild.
Guild Member Structure
Field | Type | Description |
---|---|---|
user 1 | partial user object | The user this guild member represents |
nick? | ?string | The guild-specific nickname of the member (1-32 characters) |
avatar? | ?string | The member's guild avatar hash |
avatar_decoration_data? | ?avatar decoration data object | The member's guild avatar decoration |
banner? | ?string | The member's guild banner hash |
roles | array[snowflake] | The role IDs assigned to this member |
joined_at | ISO8601 timestamp | When the user joined the guild |
premium_since? | ?ISO8601 timestamp | When the member subscribed to (started boosting) the guild |
deaf? | boolean | Whether the member is deafened in voice channels |
mute? | boolean | Whether the member is muted in voice channels |
pending? 2 | boolean | Whether the member has not yet passed the guild's member verification requirements |
communication_disabled_until? 3 | ?ISO8601 timestamp | When the member's timeout will expire and they will be able to communicate in the guild again |
unusual_dm_activity_until? | ?ISO8601 timestamp | When the member's unusual DM activity flag will expire |
flags | integer | The member's flags |
permissions? 4 | string | Total permissions of the member in the channel, including overwrites |
1 Won't be included in the member object attached to Message Create and Message Update Gateway events.
2 Won't be included in contexts that are impossible for a pending member to exist in. If the guild has previewing disabled, this field will always be false
.
3 If the value is a time in the past, the member's timeout has expired and they can communicate again.
4 Only returned when received in a slash command interaction.
Guild Member Flags
Value | Name | Description |
---|---|---|
1 << 0 | DID_REJOIN | This guild member has left and rejoined the guild |
1 << 1 | COMPLETED_ONBOARDING | This guild member has completed onboarding |
1 << 2 | BYPASSES_VERIFICATION 1 | This guild member bypasses guild verification requirements and member verification |
1 << 3 | STARTED_ONBOARDING | This guild member has started onboarding |
1 << 4 | GUEST | This guild member is a guest and not a true member |
1 << 5 | STARTED_SERVER_GUIDE | This guild member has started the server guide |
1 << 6 | COMPLETED_SERVER_GUIDE | This guild member has completed all of the server guide |
1 << 7 | AUTOMOD_QUARANTINED_NAME 2 | This guild member has been indefinitely quarantined by an AutoMod Rule for their username, display name, or nickname |
1 << 8 | AUTOMOD_QUARANTINED_BIO 2 | This guild member has been indefinitely quarantined by an AutoMod Rule for their bio |
1 << 9 | DM_SETTINGS_UPSELL_ACKNOWLEDGED | This guild member has acknowledged the DM privacy settings upsell modal |
1 << 10 | AUTOMOD_QUARANTINED_CLAN_TAG 2 | This guild member has been indefinitely quarantined by an AutoMod Rule for their clan tag |
1 Allows a member who does not meet verification requirements to participate in the guild, and forces the member's pending
status to be false
. Removing this flag does not make the member pending again.
2 Quarantined users, similar to timed out users, are prevented from interacting with the guild in any way.
Example Guild Member
{"avatar": null,"banner": null,"communication_disabled_until": null,"unusual_dm_activity_until": null,"flags": 34,"joined_at": "2023-03-22T13:59:47.553000+00:00","nick": null,"pending": false,"premium_since": null,"roles": ["1040221495437299782","1029330445336313927","1049489484179312691","1053820570367701012","1029317826755956827","1029316630431412287"],"user": {"id": "828387742575624222","username": "jupppper","avatar": "e14a7c62b0b38068be88be194b23910f","discriminator": "0","public_flags": 16384,"banner": "e45c9b5799fcb46b82bd5f1afc1b30c4","global_name": "Jup","accent_color": 1,"avatar_decoration_data": null},"mute": false,"deaf": false}
Supplemental Guild Member Object
Additional information about a participating user's join source in a guild.
Supplemental Guild Member Structure
Field | Type | Description |
---|---|---|
user_id? 1 | snowflake | The ID of the user this guild member represents |
member? 2 | guild member object | The associated guild member |
join_source_type | integer | How the user joined the guild |
source_invite_code | ?string | The invite code or vanity used to join the guild, if applicable |
inviter_id | ?snowflake | The ID of the user who invited the user to the guild, if applicable |
integration_type | ?integer | The type of integration that added the user to the guild, if applicable |
1 user_id
is only included when fetched from the Get Guild Members Supplemental endpoint.
2 member
is only included when fetched from the Search Guild Members endpoint.
Join Source Type
Value | Name | Description |
---|---|---|
0 | UNSPECIFIED | The user joined the guild through an unknown source |
1 | BOT | The user was added to the guild by a bot using the guilds.join OAuth2 scope |
2 | INTEGRATION | The user was added to the guild by an integration (e.g. Twitch) |
3 | DISCOVERY | The user joined the guild through guild discovery |
4 | HUB | The user joined the guild through a student hub |
5 | INVITE | The user joined the guild through an invite |
6 | VANITY_URL | The user joined the guild through a vanity URL |
7 | MANUAL_MEMBER_VERIFICATION | The user was accepted into the guild after applying for membership |
Example Supplemental Guild Member
{"user_id": "257496590401536000","source_invite_code": "41i3n5","join_source_type": 5,"inviter_id": "1001086404203389018","integration_type": null}
Ban Object
A ban for a guild. Banned users can't rejoin a guild unless unbanned.
Ban Structure
Field | Type | Description |
---|---|---|
user | partial user object | The banned user |
reason | ?string | The reason for the ban |
Example Ban
{"user": {"id": "53908232506183680","username": "mason","avatar": "a_d5efa99b3eeaa7dd43acca82f5692432","discriminator": "0","public_flags": 4325445,"banner": "42db4e3be824706cb1304fba05995722","accent_color": null,"global_name": "Mason","avatar_decoration_data": null},"reason": "mentioning b1nzy"}
Welcome Screen Object
Welcome Screen Structure
Field | Type | Description |
---|---|---|
description | ?string | The welcome message shown in the welcome screen |
welcome_channels | array[welcome screen channel object] | The channels shown in the welcome screen (max 5) |
Welcome Screen Channel Structure
Field | Type | Description |
---|---|---|
channel_id | snowflake | The ID of the channel |
description | string | The description shown for the channel |
emoji_id | ?snowflake | The emoji ID, if the emoji is custom |
emoji_name | ?string | The emoji name if custom, the unicode character if standard, or null if no emoji is set |
Example Welcome Screen
{"description": "Discord Developers is a place to learn about Discord's API, bots, and SDKs and integrations. This is NOT a general Discord support server.","welcome_channels": [{"channel_id": "697138785317814292","description": "Follow for official Discord API updates","emoji_id": null,"emoji_name": "📡"},{"channel_id": "697236247739105340","description": "Get help with Bot Verifications","emoji_id": null,"emoji_name": "📸"},{"channel_id": "697489244649816084","description": "Create amazing things with Discord's API","emoji_id": null,"emoji_name": "🔬"},{"channel_id": "613425918748131338","description": "Integrate Discord into your game","emoji_id": null,"emoji_name": "🎮"},{"channel_id": "646517734150242346","description": "Find more places to help you on your quest","emoji_id": null,"emoji_name": "🔦"}]}
Member Verification Object
In guilds with member verification enabled, when a member joins,
a Guild Member Add Gateway event will be dispatched but they will initially be restricted from doing any actions in the guild, and pending
will be true in the guild member object.
When the member completes the verification, a Guild Member Update Gateway event will be dispatched and pending
will be false.
To represent a member's progress towards becoming a full member of the guild, a Guild Join Request Create Gateway event will be dispatched. Once the join request is approved, the member's pending
status will be false and they will be able to interact with the guild.
Unless using manual approval, the join request will be automatically approved when the user submits their join request.
Assigning a member the BYPASSES_VERIFICATION
flag will force their pending
status to be false, regardless of the join request's status.
Guild Previewing
Discoverable guilds and guilds with member verification enabled have the PREVIEW_ENABLED
feature by default.
This allows the guild to be lurkable by users who are not members, if discoverable, and allows members who have not passed the verification gate to view the guild without interacting with it.
If a guild has member verification enabled and is not previewable, new joiners will not be able to view the guild until they pass the verification gate, and are therefore not considered members until they do.
This means that a Guild Member Add Gateway event will not be dispatched until the member has passed the verification gate, and pending
will always be false in the guild member object for new joiners.
Join requests will continue to be dispatched as normal, but there will not be an associated guild member until the join request is approved.
From the joiner's perspective, they will also not receive a Guild Create Gateway event or any other events dispatched from the guild until they pass member verification.
Non-previewable pending guilds can be retrieved with the Get Join Request Guilds endpoint. Their join requests are also sent in the guild_join_requests
field of the Ready event.
Manual Approval
To use form field types other than TERMS
, the guild must have the MEMBER_VERIFICATION_MANUAL_APPROVAL
guild feature enabled.
When using these form field types, join requests must be manually approved after they are submitted before the user can complete member verification.
When only using a TERMS
form field type, the join request will be automatically approved when the user submits the request.
Member Verification Structure
Field | Type | Description |
---|---|---|
version | ?ISO8601 timestamp | When the member verification was last modified |
form_fields | array[member verification form field object] | Questions for applicants to answer (max 5) |
description | ?string | A description of what the guild is about; this can be different than the guild's description (max 300 characters) |
guild 1 | ?member verification guild object | The guild this member verification is for |
1 Only included when fetched from the Get Membership Verification endpoint with with_guild
set to true
.
Member Verification Form Field Structure
Field | Type | Description |
---|---|---|
field_type | string | The type of question |
label | string | The label for the form field (max 300 characters) |
choices? | array[string] | Multiple choice answers (1-8, max 150 characters) |
values? | ?array[string] | The rules that the user must agree to (1-16, max 300 characters) |
response? 1 | ?string | integer | boolean | Response for this field |
required | boolean | Whether this field is required for a successful application |
description | ?string | The subtext of the form field |
automations | ?array[string] | Unknown (max 300 characters, max 10) |
placeholder? | ?string | Placeholder text for the field's response area |
1 Not present when fetched from the Get Guild Member Verification endpoint. For TERMS
form fields, the response should be true
. For MULTIPLE_CHOICE
form field types, the response is the index of the selected choice.
Member Verification Form Field Type
Value | Description |
---|---|
TERMS | User must agree to the guild rules |
TEXT_INPUT | User must respond with a short answer (max 150 characters) |
PARAGRAPH | User must respond with a paragraph (max 1000 characters) |
MULTIPLE_CHOICE | User must select one of the provided choices |
Member Verification Guild Structure
Field | Type | Description |
---|---|---|
id | snowflake | The ID of the guild |
name | string | The name of the guild (2-100 characters) |
icon | ?string | The guild's icon hash |
description | ?string | The description for the guild |
splash | ?string | The guild's splash hash |
discovery_splash | ?string | The guild's discovery splash hash |
home_header | ?string | The guild's home header hash, also used in server guide |
verification_level | integer | The verification level required for the guild |
features | array[string] | Enabled guild features |
emojis | array[emoji object] | Custom guild emojis |
approximate_member_count | integer | Approximate number of total members in the guild |
approximate_presence_count | integer | Approximate number of non-offline members in the guild |
Example Member Verification
{"version": "2022-12-21T16:08:17.822000+00:00","form_fields": [{"field_type": "TERMS","label": "Read and agree to the server rules","description": null,"automations": null,"required": true,"values": ["No spam or self-promotion (server invites, advertisements, etc) without permission from a staff member. This includes DMing fellow members.","No age-restricted or obscene content. This includes text, images, or links featuring nudity, sex, hard violence, or other graphically disturbing content.","If you see something against the rules or something that makes you feel unsafe, let staff know. We want this server to be a welcoming space!"]},{"field_type": "TEXT_INPUT","label": "Why do you like aliens?","description": null,"automations": null,"required": true,"placeholder": null},{"field_type": "MULTIPLE_CHOICE","label": "What is your favorite alien movie?","description": null,"automations": null,"required": true,"choices": ["Alien", "E.T."]}],"description": "Alien","guild": {"id": "1046920999469330512","name": "Alien Network","icon": "66b0f4d96c145970fa9d96ada8afadf3","description": "Where the 👽s 👽 and sometimes very 👽 things happen 😨.","home_header": "39ba384a31e9c285649ad00b359946ab","splash": "b40e61f7730b8781b9a551964570e0cc","discovery_splash": "0e11ae8d9f1c86958be05e61b0c90ac3","features": [],"approximate_member_count": 100,"approximate_presence_count": 99,"emojis": [],"verification_level": 2}}
Guild Join Request Object
Guild join requests are an extension of member verification that represent a user's request to join a guild. A join request is created when a user attempts to join a guild with member verification enabled, and the user must complete the verification process to join the guild. All join requests are stored for 180 days.
Most join request features require the MEMBER_VERIFICATION_MANUAL_APPROVAL
guild feature, as join request are automatically actioned when only using the TERMS
form field type and do not require manual approval.
This includes most of the join request endpoints, such as Get Guild Join Request and Action Guild Join Request.
Guild Join Request Structure
Field | Type | Description |
---|---|---|
id | snowflake | The ID of the join request |
join_request_id | snowflake | The ID of the join request |
created_at | ISO8601 timestamp | When the join request was created |
application_status | string | The status of the join request |
guild_id | snowflake | The ID of the guild this join request is for |
form_responses? 1 | ?array[member verification form field object] | Responses to the guild's member verification questions |
last_seen | ?ISO8601 timestamp | When the request was last seen by a moderator |
actioned_at? 1 | snowflake | A snowflake representing when the join request was actioned |
actioned_by_user? 1 | partial user object | The moderator who actioned the join request |
rejection_reason | ?string | Why the join request was rejected |
user_id | snowflake | The ID of the user who created this join request |
user? 1 2 | partial user object | The user who created this join request |
interview_channel_id | ?snowflake | The ID of a channel where an interview regarding this join request may be conducted |
1 Only included when fetched from the Get Guild Join Request or Get Guild Join Requests endpoints, or when receiving a related Gateway event as a moderator.
2 Only guaranteed for users other than the current user.
Guild Join Request Status
Value | Description |
---|---|
STARTED | The request is started but not submitted |
SUBMITTED | The request has been submitted |
REJECTED | The request has been rejected |
APPROVED | The request has been approved |
Example Guild Join Request
{"created_at": "2024-05-20T03:45:28.965000+00:00","join_request_id": "1241959960003477524","id": "1241959960003477524","rejection_reason": null,"application_status": "APPROVED","actioned_at": "2024-05-20T03:45:44.547975+00:00","actioned_by_user": {"id": "828387742575624222","username": "jupppper","avatar": "e14a7c62b0b38068be88be194b23910f","discriminator": "0","public_flags": 16384,"banner": "e45c9b5799fcb46b82bd5f1afc1b30c4","global_name": "Jup","accent_color": 1,"avatar_decoration_data": null},"form_responses": [{"field_type": "TERMS","label": "Read and agree to the server rules","description": null,"automations": null,"required": true,"values": ["No spam or self-promotion (server invites, advertisements, etc) without permission from a staff member. This includes DMing fellow members.","No age-restricted or obscene content. This includes text, images, or links featuring nudity, sex, hard violence, or other graphically disturbing content.","If you see something against the rules or something that makes you feel unsafe, let staff know. We want this server to be a welcoming space!"],"response": true},{"field_type": "TEXT_INPUT","label": "Why do you like aliens?","description": null,"automations": null,"required": true,"placeholder": null,"response": "I like aliens because they're cool!"},{"field_type": "MULTIPLE_CHOICE","label": "What is your favorite alien movie?","description": null,"automations": null,"required": true,"values": ["Alien", "E.T."],"response": 0}],"last_seen": "2024-05-20T03:45:44.547975+00:00","guild_id": "1046920999469330512","user_id": "852892297661906993","user": {"id": "852892297661906993","username": "alien","global_name": "Alien","avatar": "14733482e560d9267c0a414b21b2fb8d","discriminator": "0","public_flags": 64,"avatar_decoration_data": null},"interview_channel_id": null}
Onboarding Object
The onboarding flow for a guild.
Onboarding Structure
Field | Type | Description |
---|---|---|
guild_id | snowflake | The ID of the guild this onboarding is part of |
prompts | array[onboarding prompt object] | The prompts shown during onboarding and in community customization |
default_channel_ids | array[snowflake] | The channel IDs that members get opted into automatically |
enabled | boolean | Whether onboarding is enabled in the guild |
below_requirements | boolean | Whether the guild is below the requirements for onboarding |
mode | integer | The current criteria mode for onboarding |
Onboarding Mode
Defines the criteria used to satisfy Onboarding constraints that are required for enabling.
Value | Name | Description |
---|---|---|
0 | ONBOARDING_DEFAULT | Count only default channels towards constraints |
1 | ONBOARDING_ADVANCED | Count default channels and questions towards constraints |
Onboarding Prompt Structure
Field | Type | Description |
---|---|---|
id | snowflake | The ID of the prompt |
type | integer | The type of prompt |
options | array[onboarding prompt option object] | Options available within the prompt |
title | string | The title of the prompt |
single_select | boolean | Whether users are limited to selecting one option for the prompt |
required | boolean | Whether the prompt is required before a user completes the onboarding flow |
in_onboarding | boolean | Wether the prompt is present in the onboarding flow, or only appears in community customization |
Onboarding Prompt Option Structure
Field | Type | Description |
---|---|---|
id | snowflake | The ID of the prompt option |
channel_ids | array[snowflake] | The channel IDs a member is added to when the option is selected |
role_ids | array[snowflake] | The role IDs assigned to a member when the option is selected |
emoji | emoji object | Emoji representing the option |
title | string | The title of the option |
description | ?string | The description for the option |
Onboarding Prompt Type
Value | Name | Description |
---|---|---|
0 | MULTIPLE_CHOICE | Prompt offers multiple options to select from |
1 | DROPDOWN | Prompt offers a dropdown menu to select from |
Example Onboarding
{"guild_id": "960007075288915998","prompts": [{"id": "1067461047608422473","title": "What do you want to do in this community?","options": [{"id": "1067461047608422476","title": "Chat with Friends","description": "","emoji": {"id": "1070002302032826408","name": "chat","animated": false},"role_ids": [],"channel_ids": ["962007075288916001"]},{"id": "1070004843541954678","title": "Get Gud","description": "We have excellent teachers!","emoji": {"id": null,"name": "😀","animated": false},"role_ids": ["982014491980083211"],"channel_ids": []}],"single_select": false,"required": false,"in_onboarding": true,"type": 0}],"default_channel_ids": ["998678771706110023","998678693058719784","1070008122577518632","998678764340912138","998678704446263309","998678683592171602","998678699715067986"],"enabled": true,"mode": 0,"below_requirements": false}
Endpoints
Get User Guilds
GET
/users/@me/guilds
Returns a list of user guild objects representing the guilds the current user is a member of.
Query String Params
Field | Type | Description |
---|---|---|
before? | snowflake | Get guilds before this guild ID |
after? | snowflake | Get guilds after this guild ID |
limit? | integer | Max number of guilds to return (1-200, default 200) |
with_counts? 1 | boolean | Whether to include approximate member and presence counts (default false) |
1 For OAuth2 requests, this parameter requires the additional guilds.members.read
scope.
Get Join Request Guilds
GET
/users/@me/join-request-guilds
Returns a list of partial guild objects representing guilds without the PREVIEW_ENABLED
guild feature the current user has pending join requests for.
Example Response
[{"id": "80351110224678913","name": "1337 Krew","icon": "8342729096ea3675442027381ff50dfe","description": null,"home_header": null,"splash": null,"discovery_splash": null,"features": ["COMMUNITY", "NEWS", "MEMBER_VERIFICATION_GATE_ENABLED", "MEMBER_VERIFICATION_MANUAL_APPROVAL"]}]
Leave Guild
DELETE
/users/@me/guilds/{guild.id}
Leaves the given guild ID. Returns a 204 empty response on success. Fires a Guild Delete and a Guild Member Remove Gateway event.
JSON Params
Field | Type | Description |
---|---|---|
lurking? | boolean | Whether the user is lurking in the guild |
Create Guild
POST
/guilds
Creates a new guild. Returns a guild object on success. Fires a Guild Create Gateway event.
JSON Params
Field | Type | Description |
---|---|---|
name | string | The name of the guild (2-100 characters, excluding trailing and leading whitespace) |
region? (deprecated) | ?string | The main voice region ID of the guild |
icon? | ?image data | The guild's icon |
verification_level? | integer | The verification level required for the guild |
default_message_notifications? | integer | Default message notification level for the guild |
explicit_content_filter? | integer | Whose messages are scanned and deleted for explicit content in the guild |
roles? 1 | array[partial role object] | Roles in the new guild |
channels? 2 | array[partial channel object] | Channels in the new guild |
afk_channel_id? | ?snowflake | The ID of the guild's AFK channel; this is where members in voice idle for longer than afk_timeout are moved |
afk_timeout? | integer | The AFK timeout of the guild (one of 60, 300, 900, 1800, 3600, in seconds) |
staff_only? 3 | boolean | Whether the new guild will only be accessible for Discord employees |
system_channel_id? | ?snowflake | The ID of the channel where system event messages, such as member joins and premium subscriptions (boosts), are posted |
system_channel_flags? | integer | The flags that limit system event messages |
guild_template_code? | string | The template code that inspired this guild, used for analytics |
1 The first member of the array is used to change properties of the guild's default (@everyone) role. If you are trying to bootstrap a guild with additional roles, keep this in mind. Additionally, the required id
field within each role object is an integer placeholder, and will be replaced by the API upon consumption. Its purpose is to allow you to overwrite a role's permissions in a channel when also passing in channels with the channels array.
2 When specified, none of the default channels are created, and the position
field is always ignored. Additionally, the id
field within each channel object may be set to an integer placeholder, and will be replaced by the API upon consumption. Its purpose is to allow you to create GUILD_CATEGORY
channels by setting the parent_id
field on any children to the category's id
field. Category channels must be listed before any children.
3 Adds the INTERNAL_EMPLOYEE_ONLY
guild feature, making the server only available for Discord employees. Only settable by Discord employees.
Example Partial Channel Object
{"name": "my-category","type": 4,"id": 1}{"name": "naming-things-is-hard","type": 0,"parent_id": 1}
Get Guild
GET
/guilds/{guild.id}
Returns a guild object for the given guild ID.
Query String Params
Field | Type | Description |
---|---|---|
with_counts? | boolean | Whether to include approximate member and presence counts (default false) |
Get Guild Preview
GET
/guilds/{guild.id}/preview
Returns a guild preview object for the given guild ID. If the user is not in the guild, the guild must be discoverable.
Modify Guild
PATCH
/guilds/{guild.id}
Modifies a guild's settings. Requires the MANAGE_GUILD
permission. Returns the updated guild object on success. Fires a Guild Update Gateway event.
JSON Params
Field | Type | Description |
---|---|---|
name? | string | The name of the guild (2-100 characters, excluding trailing and leading whitespace) |
icon? | ?image data | The guild's icon; animated icons are only shown when the guild has the ANIMATED_ICON feature |
banner? | ?image data | The guild's banner; banners are only shown when the guild has the BANNER feature, animated banners are only shown when the guild has the ANIMATED_BANNER feature |
home_header? | ?image data | The guild's home header, also used in server guide; home headers are only shown when the guild has the BANNER feature |
splash? | ?image data | The guild's invite splash; splashes are only shown when the guild has the INVITE_SPLASH feature |
discovery_splash? | ?image data | The guild's discovery splash |
owner_id? | snowflake | The user ID of the guild's owner (must be the current owner) |
description? | ?string | The description for the guild |
region? (deprecated) | ?string | The main voice region ID of the guild |
afk_channel_id? | ?snowflake | The ID of the guild's AFK channel; this is where members in voice idle for longer than afk_timeout are moved |
afk_timeout? | integer | The AFK timeout of the guild (one of 60, 300, 900, 1800, 3600, in seconds) |
verification_level? | integer | The verification level required for the guild |
default_message_notifications? | integer | Default message notification level for the guild |
explicit_content_filter? | integer | Whose messages are scanned and deleted for explicit content in the guild |
features? | array[string] | Mutable guild features |
system_channel_id? 1 | ?snowflake | The ID of the channel where system event messages, such as member joins and premium subscriptions (boosts), are posted |
system_channel_flags? | integer | The flags that limit system event messages |
rules_channel_id? 1 | ?snowflake | The ID of the channel where community guilds display rules and/or guidelines |
public_updates_channel_id? | ?snowflake | The ID of the channel where admins and moderators of community guilds receive notices from Discord |
safety_alerts_channel_id? | ?snowflake | The ID of the channel where admins and moderators of community guilds receive safety alerts from Discord |
preferred_locale? | string | The preferred locale of the guild; used in discovery and notices from Discord (default "en-US") |
premium_progress_bar_enabled? | boolean | Whether the guild has the premium (boost) progress bar enabled |
1 Setting these to a value of 1
will implicitly create a new "#rules" or "#moderator-only" channel.
Modify Guild MFA Level
POST
/guilds/{guild.id}/mfa
Modifies the guild's MFA requirement for administrative actions within the guild. Requires the MANAGE_GUILD
permission. Fires a Guild Update Gateway event.
JSON Params
Field | Type | Description |
---|---|---|
level | integer | Required MFA level for administrative actions within the guild |
Response Body
Field | Type | Description |
---|---|---|
level | integer | Required MFA level for administrative actions within the guild |
Example Response
{"level": 1}
Delete Guild
DELETE
/guilds/{guild.id}
Deletes a guild permanently. User must be the owner. Returns a 204 empty response on success. Fires a Guild Delete Gateway event.
Get Guild Members
GET
/guilds/{guild.id}/members
Returns a list of guild member objects that are members of the guild.
Query String Params
Field | Type | Description |
---|---|---|
limit? | integer | Max number of members to return (1-1000, default 1) |
after? | snowflake | Get members after this member ID |
Query Guild Members
GET
/guilds/{guild.id}/members/search
Returns a list of guild member objects whose username or nickname contains a provided string. Functionally identical to the Request Guild Members Gateway Opcode.
Query String Params
Field | Type | Description |
---|---|---|
query | string | Query to match username(s) and nickname(s) against |
limit? | integer | Max number of members to return (1-1000, default 1) |
Search Guild Members
POST
/guilds/{guild.id}/members-search
Returns supplemental guild member objects containing guild member objects that match a specified query. Requires the MANAGE_GUILD
permission.
This endpoint utilizes Elasticsearch to power results. This means that while it is very powerful, it's also tricky to use and reliant on the index, meaning results may not be immediately available for a recently-joined member.
JSON Params
Field | Type | Description |
---|---|---|
limit? | integer | Max number of members to return (1-1000, default 25) |
sort? | integer | The sorting algorithm to use (default JOINED_AT_DESC ) |
or_query? | member filter object | The filter criteria to match against members using OR logic |
and_query? | member filter object | The filter criteria to match against members using AND logic |
before? | member pagination filter object | Get members before this member |
after? | member pagination filter object | Get members after this member |
Member Sort Type
Value | Name | Description |
---|---|---|
1 | JOINED_AT_DESC | Sort by when the user joined the guild descending (default) |
2 | JOINED_AT_ASC | Sort by when the user joined the guild ascending |
3 | USER_ID_DESC | Sort by when the user joined Discord descending |
4 | USER_ID_ASC | Sort by when the user joined Discord ascending |
Member Filter Structure
Field | Type | Description | Queries |
---|---|---|---|
user_id? | query object (snowflake) | Query to match member IDs against | or_query , range |
usernames? | query object (string) | Query to match display name(s), username(s), and nickname(s) against | or_query |
role_ids? | query object (snowflake) | IDs of roles to match members against | or_query , and_query |
guild_joined_at? | query object (integer) | When the user joined the guild | range |
safety_signals? | safety signals object | Safety signals to match members against | |
is_pending? | boolean | Whether the member has not yet passed the guild's member verification requirements | true , false |
did_rejoin? | boolean | Whether the member left and rejoined the guild | true , false |
join_source_type? | query object (integer) | How the user joined the guild | or_query |
source_invite_code? | query object (string) | The invite code or vanity used to join the guild | or_query |
Safety Signals Structure
Field | Type | Description | Queries |
---|---|---|---|
unusual_dm_activity_until? | query object (integer) | When the member's unusual DM activity flag will expire | range |
communication_disabled_until? | query object (integer) | When the member's timeout will expire | range |
unusual_account_activity? | boolean | Whether unusual account activity is detected | true , false |
automod_quarantined_username? | boolean | Whether the member has been indefinitely quarantined by an AutoMod Rule for their username, display name, or nickname | true , false |
Query Structure
Field | Type | Description |
---|---|---|
or_query? | array[snowflake | string | integer] | The values to match against using OR logic (1-100 characters, max 10) |
and_query? | array[snowflake | string | integer] | The values to match against using AND logic (1-100 characters, max 10) |
range? | range query object | The range of values to match against |
Range Query Structure
Field | Type | Description |
---|---|---|
gte? | snowflake | integer | Inclusive lower bound value to match |
lte? | snowflake | integer | Inclusive upper bound value to match |
Member Pagination Filter Structure
Field | Type | Description |
---|---|---|
user_id | snowflake | The ID of the user to paginate past |
guild_joined_at | integer | When the user to paginate past joined the guild |
Response Body
Field | Type | Description |
---|---|---|
guild_id | snowflake | The ID of the guild searched |
members | array[supplemental guild member object] | The resulting members |
page_result_count | integer | The number of results returned |
total_result_count | integer | The total number of results found |
Get Guild Members Supplemental
POST
/guilds/{guild.id}/members/supplemental
Returns a list of supplemental guild member objects including join source information for the given user IDs.
JSON Params
Field | Type | Description |
---|---|---|
users | array[snowflake] | The user IDs to fetch supplemental guild member information for (max 200) |
Get Guild Member
GET
/guilds/{guild.id}/members/{user.id}
Returns a guild member object for the specified user.
Join Guild
PUT
/guilds/{guild.id}/members/@me
Adds the current user to the guild. The guild must be discoverable. Returns the guild member object or a 204 empty response (if the user is already a member of the guild) on success. May fire a Guild Create, Guild Member Add, and/or Guild Join Request Create Gateway event.
For guilds with member verification enabled, this endpoint will default to adding new members as pending
in the guild member object. Members that are pending
will have to complete member verification before they become full members that can talk.
Query String Params
Field | Type | Description |
---|---|---|
lurker? 1 | boolean | Whether the user will lurk the guild (default false) |
session_id? | string | The session ID to lurk with, required for lurking |
location? | string | The analytics location the request initiated from |
recommendation_load_id? | string | The unique identifier for the current guild discovery recommendations (client-generated UUID as a hexadecimal string) |
1 Lurking a guild allows the user to receive Gateway events for the guild without being a full member. This is useful for previewing the guild before joining. Lurking requires the PREVIEW_ENABLED
guild feature.
Add Guild Member
PUT
/guilds/{guild.id}/members/{user.id}
Adds a user to the guild, provided you have a valid OAuth2 access token for the user with the guilds.join
scope. Returns the joined guild member object or a 204 empty response (if the user is already a member of the guild) on success. May fire a Guild Member Add and/or Guild Join Request Create Gateway event.
For guilds with member verification and guild previewing enabled, this endpoint will default to adding new members as pending
in the guild member object. Members that are pending
will have to complete member verification before they become full members that can talk.
JSON Params
Field | Type | Description | Permission |
---|---|---|---|
access_token | string | An OAuth2 access token granted with the guilds.join to the bot's application for the user you want to add to the guild | CREATE_INSTANT_INVITE |
nick? | ?string | The guild-specific nickname of the member (1-32 characters) | MANAGE_NICKNAMES |
roles? | array[snowflake] | The role IDs assigned to this member | MANAGE_ROLES |
mute? | boolean | Whether the member is muted in voice channels | MUTE_MEMBERS |
deaf? | boolean | Whether the user is deafened in voice channels | DEAFEN_MEMBERS |
flags? 1 | integer | The member's flags (only BYPASSES_VERIFICATION can be set) | MANAGE_GUILD or (MODERATE_MEMBERS and KICK_MEMBERS and BAN_MEMBERS ) |
1 For guilds with member verification enabled, assigning the BYPASSES_VERIFICATION
guild member flag will add the user as a full member (pending
is false in the member object).
Modify Guild Member
PATCH
/guilds/{guild.id}/members/{user.id}
Modifies attributes of a guild member. Returns the updated guild member object on success. Fires a Guild Member Update Gateway event.
JSON Params
Field | Type | Description | Permission |
---|---|---|---|
nick? | ?string | The guild-specific nickname of the member (1-32 characters) | MANAGE_NICKNAMES |
roles? | array[snowflake] | The role IDs assigned to this member | MANAGE_ROLES |
mute? 1 | boolean | Whether the member is muted in voice channels | MUTE_MEMBERS |
deaf? 1 | boolean | Whether the user is deafened in voice channels | DEAFEN_MEMBERS |
channel_id? 1 | snowflake | The ID of the voice channel the user is connected to | MOVE_MEMBERS |
communication_disabled_until? 2 | ?ISO8601 timestamp | When the user's timeout will expire and they will be able to communicate in the guild again (up to 28 days in the future) | MODERATE_MEMBERS |
flags? | integer | The member's flags (only BYPASSES_VERIFICATION can be set) | MANAGE_GUILD or (MODERATE_MEMBERS and KICK_MEMBERS and BAN_MEMBERS ) |
1 Requires the member to be connected to voice. When moving members to channels, the current user must have permissions to both connect to the channel and have the MOVE_MEMBERS
permission. If the channel_id
is set to null
, this will force the target user to be disconnected from voice.
2 Guild administrators cannot be timed out. If a member is timed out and becomes an administrator before their timeout expires, the timeout will no longer have an effect.
Modify Current Guild Member
PATCH
/guilds/{guild.id}/members/@me
Modifies the current user's member in the guild. Returns the updated guild member object on success (including extra bio
and banner
fields). Fires a Guild Member Update Gateway event.
JSON Params
Field | Type | Description | Permission |
---|---|---|---|
nick? | ?string | The guild-specific nickname of the member (1-32 characters) | CHANGE_NICKNAME |
avatar? | ?image data | The member's guild avatar; can only be changed for premium (Nitro) users | |
avatar_decoration_id? | ?snowflake | The ID of the member's guild avatar decoration | |
avatar_decoration_sku_id? | ?snowflake | The SKU ID of the member's guild avatar decoration | |
pronouns? | ?string | The member's guild pronouns (max 40 characters) | |
bio? | ?string | The member's guild bio; can only be changed for premium (Nitro) users | |
banner? | ?image data | The member's guild banner; can only be changed for premium (Nitro) users |
Modify Current Guild Member Nick
PATCH
/guilds/{guild.id}/members/@me/nick
Modifies the current user's member in the guild. Returns the updated guild member object on success (including extra bio
and banner
fields). Fires a Guild Member Update Gateway event.
See Modify Current Guild Member for more information.
Modify Guild Member Profile
PATCH
/guilds/{guild.id}/profile/@me
Modifies the current user's profile in the guild. Returns a profile metadata object on success. Fires a Guild Member Update Gateway event.
JSON Params
Field | Type | Description |
---|---|---|
pronouns? | ?string | The member's guild pronouns (max 40 characters) |
bio? | ?string | The member's guild bio (max 190 characters); can only be changed for premium (Nitro) users |
banner? | ?image data | The member's guild banner; can only be changed for premium (Nitro) users |
accent_color? | ?integer | The member's guild accent color as a hex integer; can only be changed for premium (Nitro) users |
theme_colors? | ?array[integer, integer] | The member's two guild theme colors encoded as an array of integers representing hexadecimal color codes; can only be changed for premium (Nitro) users |
popout_animation_particle_type? | ?snowflake | The member's guild profile popout animation particle type |
emoji_id? | ?snowflake | The member's guild profile emoji ID |
profile_effect_id? | ?snowflake | The member's guild profile effect ID |
Add Guild Member Role
PUT
/guilds/{guild.id}/members/{user.id}/roles/{role.id}
Adds a role to a guild member. Requires the MANAGE_ROLES
permission. Returns a 204 empty response on success. Fires a Guild Member Update Gateway event.
Remove Guild Member Role
DELETE
/guilds/{guild.id}/members/{user.id}/roles/{role.id}
Removes a role from a guild member. Requires the MANAGE_ROLES
permission. Returns a 204 empty response on success. Fires a Guild Member Update Gateway event.
Remove Guild Member
DELETE
/guilds/{guild.id}/members/{user.id}
Removes a member from a guild. Requires the KICK_MEMBERS
permission. Returns a 204 empty response on success. Fires a Guild Member Remove Gateway event.
Acknowledge DM Settings Upsell Modal
POST
/users/@me/guilds/{guild.id}/member/ack-dm-upsell-settings
Adds the DM_SETTINGS_UPSELL_ACKNOWLEDGED
member flag to the current user. Returns a 204 empty response on success. Fires a Guild Member Update Gateway event.
Get Guild Bans
GET
/guilds/{guild.id}/bans
Returns a list of ban objects for the guild. Requires the BAN_MEMBERS
permission.
Query String Params
Field | Type | Description |
---|---|---|
before? 1 | snowflake | Get bans before this user ID |
after? 1 | snowflake | Get bans after this user ID |
limit? 2 | number | Max number of bans to return (1-1000, default all or 1000) |
1 Bans will always be returned in ascending order by user ID.
2 Ban pagination for user accounts is currently optional. It must be explicitly opted into by specifying the limit
query string parameter. Without specifying it, the before
and after
query string parameters will not work, and all bans will be returned by default. For bots, pagination is always enabled and 1000 bans are returned by default.
Search Guild Bans
GET
/guilds/{guild.id}/bans/search
Returns a list of ban objects whose username or display name contains a provided string.
Query String Params
Field | Type | Description |
---|---|---|
query | string | Query to match username(s) and display name(s) against (1-32 characters) |
limit? | integer | Max number of members to return (1-10, default 10) |
Get Guild Ban
GET
/guilds/{guild.id}/bans/{user.id}
Returns a ban object for the given user. Requires the BAN_MEMBERS
permission.
Create Guild Ban
PUT
/guilds/{guild.id}/bans/{user.id}
Creates a guild ban and optionally deletes previous messages sent by the banned user. Requires the BAN_MEMBERS
permission. Returns a 204 empty response on success. Fires Guild Ban Add and optionally Guild Member Remove Gateway events.
JSON Params
Field | Type | Description |
---|---|---|
delete_message_days? (deprecated) | integer | Number of days to delete messages for (0-7, default 0) |
delete_message_seconds? | integer | Number of seconds to delete messages for (0-604800, default 0) |
Bulk Guild Ban
POST
/guilds/{guild.id}/bulk-ban
Create multiple guild bans and optionally delete previous messages sent by the banned users. Requires both the BAN_MEMBERS
and MANAGE_GUILD
permissions. Fires multiple Guild Ban Add and optionally Guild Member Remove Gateway events.
JSON Params
Field | Type | Description |
---|---|---|
user_ids | array[snowflake] | The user IDs to ban (max 200) |
delete_message_seconds? | integer | Number of seconds to delete messages for (0-604800, default 0) |
Response Body
Field | Type | Description |
---|---|---|
banned_users | array[snowflake] | The user IDs that were successfully banned |
failed_users 1 | array[snowflake] | The user IDs that were not banned |
1 A ban will fail if the user is already banned, the user has a higher role than the current user, the user is the owner of the guild, or the user is the current user. If a bulk ban has no successful bans, the response will be an error.
Delete Guild Ban
DELETE
/guilds/{guild.id}/bans/{user.id}
Removes the ban for a user. Requires the BAN_MEMBERS
permission. Returns a 204 empty response on success. Fires a Guild Ban Remove Gateway event.
Get Guild Roles
GET
/guilds/{guild.id}/roles
Returns a list of role objects for the guild.
Get Guild Role
GET
/guilds/{guild.id}/roles/{role.id}
Returns a role object for the given role.
Get Guild Role Member Counts
GET
/guilds/{guild.id}/roles/member-counts
Returns a mapping of role IDs to their respective member counts.
Example Response
{"1040221495437299782": 2,"1040221495437299783": 1,"1040221495437299784": 0}
Get Guild Role Members
GET
/guilds/{guild.id}/roles/{role.id}/member-ids
Returns a list of member IDs that have the specified role, up to a maximum of 100.
Example Response
["852892297661906993", "907489667895676928"]
Add Guild Role Members
PATCH
/guilds/{guild.id}/roles/{role.id}/members
Adds multiple guild members to a role. Requires the MANAGE_ROLES
permission. Returns a mapping of member IDs to guild member objects. Fires multiple Guild Member Update Gateway events.
JSON Params
Field | Type | Description |
---|---|---|
member_ids | array[snowflake] | The member IDs to assign the role to (max 100) |
Example Response
{"863406480111566858": {"avatar": null,"banner": null,"communication_disabled_until": null,"unusual_dm_activity_until": null,"flags": 0,"joined_at": "2022-10-11T12:31:03.882000+00:00","nick": ":~]","pending": false,"premium_since": null,"roles": ["1040221495437299782"],"user": {"id": "863406480111566858","username": "leaduck","global_name": "LeaDuck","avatar": "bb450561133bac3da5c7e201db40af6c","discriminator": "0","public_flags": 256,"avatar_decoration_data": null},"mute": false,"deaf": false}}
Create Guild Role
POST
/guilds/{guild.id}/roles
Creates a new role for the guild. Requires the MANAGE_ROLES
permission. Returns the new role object on success. Fires a Guild Role Create Gateway event.
JSON Params
Field | Type | Description |
---|---|---|
name? | ?string | The name of the role (max 100 characters, default "new role") |
description? | ?string | The description for the role (max 90 characters) |
color? | ?integer | Integer representation of a hexadecimal color code for the role |
hoist? | boolean | Whether this role is pinned in the user listing (default false) |
icon? | ?image data | The role's icon |
unicode_emoji? | ?string | The role's unicode emoji |
permissions? | ?string | The permission bitwise value for the role (default @everyone permissions) |
mentionable? | boolean | Whether this role is mentionable (default false) |
Modify Guild Role Positions
PATCH
/guilds/{guild.id}/roles
Modifies the positions of a set of role objects for the guild. Requires the MANAGE_ROLES
permission. Returns a list of all of the guild's role objects on success. Fires multiple Guild Role Update Gateway events.
This endpoint takes a JSON array of parameters in the following format:
JSON Params
Field | Type | Description |
---|---|---|
id | snowflake | The ID of the role |
position? | ?integer | Sorting position of the role |
Modify Guild Role
PATCH
/guilds/{guild.id}/roles/{role.id}
Modifies a guild role. Requires the MANAGE_ROLES
permission. Returns the updated role on success. Fires a Guild Role Update Gateway event.
JSON Params
Field | Type | Description |
---|---|---|
name? | ?string | The name of the role (max 100 characters, default "new role" if null ) |
description? | ?string | The description for the role (max 90 characters) |
color? | ?integer | Integer representation of a hexadecimal color code for the role |
hoist? | ?boolean | Whether this role is pinned in the user listing |
icon? | ?image data | The role's icon |
unicode_emoji? | ?string | The role's unicode emoji |
permissions? | ?string | The permission bitwise value for the role (default @everyone permissions if null ) |
mentionable? | ?boolean | Whether this role is mentionable |
Delete Guild Role
DELETE
/guilds/{guild.id}/roles/{role.id}
Deletes a guild role. Requires the MANAGE_ROLES
permission. Returns a 204 empty response on success. Fires a Guild Role Delete Gateway event.
Get Guild Prune
GET
/guilds/{guild.id}/prune
Returns the number of members that would be removed in a prune operation. Requires both the MANAGE_GUILD
and KICK_MEMBERS
permission.
By default, prune will not remove users with roles. You can optionally include specific roles in your prune by providing the include_roles
parameter. Any inactive user that has a subset of the provided role(s) will be counted in the prune and users with additional roles will not.
Query String Params
Field | Type | Description |
---|---|---|
days? | integer | Number of inactive days to count prune for (1-30, default 7) |
include_roles? | array[snowflake] | Additional roles to include |
Response Body
Field | Type | Description |
---|---|---|
pruned | integer | The number of members that would be removed in a prune operation with the provided parameters |
Example Response
{"pruned": 42}
Prune Guild
POST
/guilds/{guild.id}/prune
Begins a prune operation. Requires both the MANAGE_GUILD
and KICK_MEMBERS
permission. For large guilds, it's recommended to set the compute_prune_count
option to false
, allowing the request to return before all members are pruned. Fires multiple Guild Member Remove Gateway events.
By default, prune will not remove users with roles. You can optionally include specific roles in your prune by providing the include_roles
parameter. Any inactive user that has a subset of the provided role(s) will be included in the prune and users with additional roles will not.
JSON Params
Field | Type | Description |
---|---|---|
days? | integer | Number of inactive days to prune for (1-30, default 7) |
compute_prune_count? | boolean | Whether to wait for the prune to complete before responding (default true) |
include_roles? | array[snowflake] | Additional roles to include |
Response Body
Field | Type | Description |
---|---|---|
pruned | ?integer | The number of members that were removed in the prune operation with the provided parameters; null if not computed |
Example Response
{"pruned": null}
Get Guild Widget Settings
GET
/guilds/{guild.id}/widget
Returns a guild widget settings object for the guild. Requires the MANAGE_GUILD
permission.
Modify Guild Widget
PATCH
/guilds/{guild.id}/widget
Modifies the widget settings for the guild. Requires the MANAGE_GUILD
permission. Returns the updated guild widget settings object on success.
JSON Params
Field | Type | Description |
---|---|---|
enabled? | boolean | Whether the widget is enabled |
channel_id? | ?snowflake | The channel ID that the widget will generate an invite to, if any |
Get Guild Widget
GET
/guilds/{guild.id}/widget.json
Returns a guild widget object for the given guild ID. The guild must have the widget enabled. May fire an Invite Create Gateway event.
Get Guild Widget Image
GET
/guilds/{guild.id}/widget.png
Returns a widget image PNG for the given guild ID. The guild must have the widget enabled.
Query String Params
Field | Type | Description |
---|---|---|
style? | string | Style of widget image returned (default shield ) |
Guild Widget Image Style Option
Value | Description | Example |
---|---|---|
shield | Shield style widget with Discord icon and online count | Example |
banner1 | Large image with guild icon, name and online count; "POWERED BY DISCORD" as the footer of the widget | Example |
banner2 | Smaller widget style with guild icon, name and online count; split on the right with Discord logo | Example |
banner3 | Large image with guild icon, name and online count; in the footer, Discord logo on the left and "Chat Now" on the right | Example |
banner4 | Large Discord logo at the top of the widget; guild icon, name and online count in the middle portion of the widget and a "JOIN MY SERVER" button at the bottom | Example |
Get Guild Vanity Invite
GET
/guilds/{guild.id}/vanity-url
Returns the vanity invite for the guild. The guild must have the VANITY_URL
or GUILD_WEB_PAGE_VANITY_URL
feature. Requires the MANAGE_GUILD
permission.
Response Body
Field | Type | Description |
---|---|---|
code | ?string | The vanity invite code for the guild |
uses | integer | The number of times this invite has been used |
Example Response
{"code": "abc","uses": 12}
Modify Guild Vanity Invite
PATCH
/guilds/{guild.id}/vanity-url
Modifies the vanity invite for the guild. The guild must have the VANITY_URL
or GUILD_WEB_PAGE_VANITY_URL
feature. Guilds without the VANITY_URL
feature can only clear their vanity invite. Requires the MANAGE_GUILD
permission. Fires a Guild Update Gateway event.
JSON Params
Field | Type | Description |
---|---|---|
code | ?string | The vanity invite code for the guild (2-25 characters, alphanumeric and - ) |
Response Body
Field | Type | Description |
---|---|---|
code | ?string | The vanity invite code for the guild |
uses | integer | The number of times this invite has been used (now 0) |
Get Guild Member Verification
GET
/guilds/{guild.id}/member-verification
Returns the member verification object for the guild if one is set. If the user is not a member of the guild, the guild must be discoverable or have guild previewing disabled.
Query String Params
Field | Type | Description |
---|---|---|
with_guild? 1 | boolean | Whether to include the guild object in the response (default false) |
invite_code? | string | The invite code the verification is fetched from |
1 Requires that the user is not a member of the guild, and that the guild is not full. If fetching the member verification for a guild the user is not a member of, this must be set to true
.
Modify Guild Member Verification
PATCH
/guilds/{guild.id}/member-verification
Modifies the member verification for the guild. Requires the MANAGE_GUILD
permission. Returns the updated member verification object. May fire a Guild Update Gateway event.
JSON Params
Field | Type | Description |
---|---|---|
enabled? | boolean | Whether the member verification gate is enabled |
form_fields? | array[member verification form field object] | Questions for applicants to answer (max 5) |
description? | ?string | A description of what the guild is about; this can be different than the guild's description (max 300 characters) |
Get Guild Join Requests
GET
/guilds/{guild.id}/requests
Returns a list of join requests for the guild for manual approval. Requires the KICK_MEMBERS
permission.
Query String Params
Field | Type | Description |
---|---|---|
status | string | The status of the join requests to filter by |
limit? | integer | Max number of join requests to return (1-100, default 100) |
before? | snowflake | Get join requests before this request ID |
after? | snowflake | Get join requests after this request ID |
Response Body
Field | Type | Description |
---|---|---|
guild_join_requests? 1 | array[guild join request] | The join requests for the guild |
total? | integer | The total number of join requests that match the query |
limit | integer | The maximum number of join requests returned |
1 Join requests are omitted when retrieving requests with the STARTED
status.
Get Guild Join Request
GET
/join-requests/{guild_join_request.id}
Returns a guild join request object for the given request ID. Requires the KICK_MEMBERS
permission if the request is not for the current user.
Create Guild Join Request
PUT
/guilds/{guild.id}/requests/@me
Submits a request to join a guild. Returns a partial guild join request object on success. Fires a Guild Join Request Create or Guild Join Request Update Gateway event.
{/ TODO: Document the requirements for this endpoint /}
JSON Params
Field | Type | Description |
---|---|---|
form_fields 1 | array[member verification form field object] | The answered member verification questions |
version | ?ISO8601 timestamp | When the member verification was last modified, same as version in the member verification object |
1 The form_fields
array must contain all fields from the guild's member verification object, with a populated response
field for each required
field.
Reset Guild Join Request
POST
/guilds/{guild.id}/requests/@me
Resets the current user's join request for the guild. Returns a partial guild join request object on success. Fires a Guild Join Request Delete and Guild Join Request Create Gateway event.
Delete Guild Join Request
DELETE
/guilds/{guild.id}/requests/@me
If the guild has previewing disabled, deletes the current user's join request. Else, functions the same as Reset Guild Join Request. Returns a 204 empty response if deletion is successful or a partial guild join request object if the join request is reset. Fires a Guild Join Request Delete and optionally Guild Join Request Create Gateway event.
Create Guild Join Request Interview
POST
/join-requests/{guild_join_request.id}/interview
Creates or returns an existing private interview channel for the join request. Requires the KICK_MEMBERS
permission. Returns a group DM channel object on success. Fires a Guild Join Request Update and Channel Create Gateway event.
Action Guild Join Request
PATCH
/guilds/{guild.id}/requests/{user.id}
Accepts or denies a join request for the guild. Requires the KICK_MEMBERS
permission. Returns a guild join request object on success. Fires a Guild Join Request Update and may fire a Guild Member Add or Guild Member Remove Gateway event.
JSON Params
Field | Type | Description |
---|---|---|
action | string | The action to take on the join requests (only APPROVED and REJECTED can be used) |
rejection_reason? | ?string | The reason for rejecting the join request (max 160 characters) |
Bulk Action Guild Join Requests
PATCH
/guilds/{guild.id}/requests
Accepts or denies all pending join requests for the guild. Requires the KICK_MEMBERS
permission. Returns a 204 empty response on success. May fire multiple Guild Join Request Update, Guild Member Add, and Guild Member Remove Gateway events.
JSON Params
Field | Type | Description |
---|---|---|
action | string | The action to take on the join requests (only APPROVED and REJECTED can be used) |
Get Guild Welcome Screen
GET
/guilds/{guild.id}/welcome-screen
Returns the welcome screen object for the guild. Requires the MANAGE_GUILD
permission if the welcome screen is not yet enabled, otherwise no permission is required.
Modify Guild Welcome Screen
PATCH
/guilds/{guild.id}/welcome-screen
Modifies the guild's welcome screen. Requires the MANAGE_GUILD
permission. Returns the updated welcome screen object. May fire a Guild Update Gateway event.
JSON Params
Field | Type | Description |
---|---|---|
enabled? | ?boolean | Whether the welcome screen is enabled |
description? | ?string | The welcome message shown in the welcome screen |
welcome_channels? | ?array[welcome screen channel object] | The channels shown in the welcome screen (max 5) |
Get Guild Onboarding
GET
/guilds/{guild.id}/onboarding
Returns the onboarding object for the guild.
Modify Guild Onboarding
PUT
/guilds/{guild.id}/onboarding
Modifies the onboarding configuration of the guild. Returns the updated onboarding object. Requires the MANAGE_GUILD
permission. Fires a Guild Update Gateway event.
JSON Params
Field | Type | Description |
---|---|---|
prompts? | array[onboarding prompt object] | The prompts shown during onboarding and in community customization |
default_channel_ids? | array[snowflake] | The channel IDs that members get opted into automatically |
enabled? | boolean | Whether onboarding is enabled in the guild |
mode? | integer | The current criteria mode for onboarding |
Get Admin Community Eligibility
GET
/guilds/{guild.id}/admin-server-eligibility
Checks if the user is eligible to join the Discord Admin Community through the guild. Requires the MANAGE_GUILD
permission.
Response Body
Field | Type | Description |
---|---|---|
eligible_for_admin_server | boolean | Whether the user is eligible to join the Discord Admin Community through the guild |
Join Admin Community
POST
/guilds/{guild.id}/join-admin-server
Joins the Discord Admin Community through the guild. Requires the MANAGE_GUILD
permission. Returns the joined guild object on success. Fires a Guild Create, Guild Member Add, and optionally Guild Join Request Create Gateway event.
Join Wumpus Feedback Squad
POST
/guilds/{guild.id}/join-wfs-server
Joins Wumpus Feedback Sqaud through the guild. Requires the MANAGE_GUILD
permission and the CLAN
guild feature. Returns a 204 empty response on success. Fires a Guild Create, Guild Member Add, and optionally Guild Join Request Create Gateway event.