You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: api/application.go
+10-9
Original file line number
Diff line number
Diff line change
@@ -50,15 +50,16 @@ type ApplicationFlags int64
50
50
51
51
//goland:noinspection GoUnusedConst
52
52
const (
53
-
GatewayPresenceApplicationFlags=1<<12// Intent required for bots in 100 or more servers to receive presence_update events
54
-
GatewayPresenceLimitedApplicationFlags=1<<13// Intent required for bots in under 100 servers to receive presence_update events, found in Bot Settings
55
-
GatewayGuildMembersApplicationFlags=1<<14// Intent required for bots in 100 or more servers to receive member-related events like guild_member_add. See list of member-related events under GUILD_MEMBERS
56
-
GatewayGuildMembersLimitedApplicationFlags=1<<15// Intent required for bots in under 100 servers to receive member-related events like guild_member_add, found in Bot Settings. See list of member-related events under GUILD_MEMBERS
57
-
VerificationPendingGuildLimitApplicationFlags=1<<16// Indicates unusual growth of an app that prevents verification
58
-
EmbeddedApplicationFlags=1<<17// Indicates if an app is embedded within the Discord client (currently unavailable publicly)
59
-
GatewayMessageContentApplicationFlags=1<<18// Intent required for bots in 100 or more servers to receive message content
60
-
GatewayMessageContentLimitedApplicationFlags=1<<19// Intent required for bots in under 100 servers to receive message content, found in Bot Settings
61
-
ApplicationCommandBadgeApplicationFlags=1<<23// Indicates if an app has registered global application commands
53
+
ApplicationAutoModerationRuleCreateBadgeApplicationFlags=1<<6// Indicates if an app uses the Auto Moderation API
54
+
GatewayPresenceApplicationFlags=1<<12// Intent required for bots in 100 or more servers to receive presence_update events
55
+
GatewayPresenceLimitedApplicationFlags=1<<13// Intent required for bots in under 100 servers to receive presence_update events, found in Bot Settings
56
+
GatewayGuildMembersApplicationFlags=1<<14// Intent required for bots in 100 or more servers to receive member-related events like guild_member_add. See list of member-related events under GUILD_MEMBERS
57
+
GatewayGuildMembersLimitedApplicationFlags=1<<15// Intent required for bots in under 100 servers to receive member-related events like guild_member_add, found in Bot Settings. See list of member-related events under GUILD_MEMBERS
58
+
VerificationPendingGuildLimitApplicationFlags=1<<16// Indicates unusual growth of an app that prevents verification
59
+
EmbeddedApplicationFlags=1<<17// Indicates if an app is embedded within the Discord client (currently unavailable publicly)
60
+
GatewayMessageContentApplicationFlags=1<<18// Intent required for bots in 100 or more servers to receive message content
61
+
GatewayMessageContentLimitedApplicationFlags=1<<19// Intent required for bots in under 100 servers to receive message content, found in Bot Settings
62
+
ApplicationCommandBadgeApplicationFlags=1<<23// Indicates if an app has registered global application commands
62
63
)
63
64
64
65
// InstallParams - settings for the application's default in-app authorization link, if enabled
DiscoverySplash*string`json:"discovery_splash"`// discovery splash hash; only present for guilds with the "DISCOVERABLE" feature
31
-
OwnerIDSnowflake`json:"owner_id"`// id of owner
32
-
AfkChannelIDSnowflake`json:"afk_channel_id,omitempty"`// id of afk channel
33
-
AfkTimeoutint`json:"afk_timeout"`// afk timeout in seconds
34
-
WidgetEnabledbool`json:"widget_enabled,omitempty"`// true if the server widget is enabled
35
-
WidgetChannelID*Snowflake`json:"widget_channel_id,omitempty"`// the channel id that the widget will generate an "invite" to, or null if set to no invite
36
-
VerificationLevelVerificationLevel`json:"verification_level"`// verification level required for the guild
Features []*GuildFeatures`json:"features"`// enabled guild features
42
-
MfaLevelMfaLevel`json:"mfa_level"`// required MFA level for the guild
43
-
ApplicationID*Snowflake`json:"application_id"`// application id of the guild creator if it is bot-created
44
-
SystemChannelID*Snowflake`json:"system_channel_id"`// the id of the channel where guild notices such as welcome messages and boost events are posted
45
-
SystemChannelFlagsSystemChannelFlags`json:"system_channel_flags"`// system channel flags
46
-
RulesChannelID*Snowflake`json:"rules_channel_id"`// the id of the channel where Community guilds can display rules and/or guidelines
47
-
MaxPresences*int64`json:"max_presences,omitempty"`// the maximum number of presences for the guild (null is always returned, apart from the largest of guilds)
48
-
MaxMembersint64`json:"max_members,omitempty"`// the maximum number of members for the guild
49
-
VanityUrlCode*string`json:"vanity_url_code"`// the vanity url code for the guild
50
-
Description*string`json:"description"`// the description of a Community guild
PremiumSubscriptionCountuint64`json:"premium_subscription_count,omitempty"`// the number of boosts this guild currently has
54
-
PreferredLocalestring`json:"preferred_locale"`// the preferred locale of a Community guild; used in server discovery and notices from Discord, and sent in interactions; defaults to "en-US"
55
-
PublicUpdatesChannelID*Snowflake`json:"public_updates_channel_id"`// the id of the channel where admins and moderators of Community guilds receive notices from Discord
56
-
MaxVideoChannelUsersuint64`json:"max_video_channel_users,omitempty"`// the maximum amount of users in a video channel
57
-
ApproximateMemberCountuint64`json:"approximate_member_count,omitempty"`// approximate number of members in this guild, returned from the GET /guilds/<id> endpoint when with_counts is true
58
-
ApproximatePresenceCountuint64`json:"approximate_presence_count,omitempty"`// approximate number of non-offline members in this guild, returned from the GET /guilds/<id> endpoint when with_counts is true
59
-
WelcomeScreenWelcomeScreen`json:"welcome_screen,omitempty"`// the welcome screen of a Community guild, shown to new members, returned in an Invite's guild object
DiscoverySplash*string`json:"discovery_splash"`// discovery splash hash; only present for guilds with the "DISCOVERABLE" feature
31
+
OwnerIDSnowflake`json:"owner_id"`// id of owner
32
+
AfkChannelIDSnowflake`json:"afk_channel_id,omitempty"`// id of afk channel
33
+
AfkTimeoutint`json:"afk_timeout"`// afk timeout in seconds
34
+
WidgetEnabledbool`json:"widget_enabled,omitempty"`// true if the server widget is enabled
35
+
WidgetChannelID*Snowflake`json:"widget_channel_id,omitempty"`// the channel id that the widget will generate an "invite" to, or null if set to no invite
36
+
VerificationLevelVerificationLevel`json:"verification_level"`// verification level required for the guild
Features []*GuildFeatures`json:"features"`// enabled guild features
42
+
MfaLevelMfaLevel`json:"mfa_level"`// required MFA level for the guild
43
+
ApplicationID*Snowflake`json:"application_id"`// application id of the guild creator if it is bot-created
44
+
SystemChannelID*Snowflake`json:"system_channel_id"`// the id of the channel where guild notices such as welcome messages and boost events are posted
45
+
SystemChannelFlagsSystemChannelFlags`json:"system_channel_flags"`// system channel flags
46
+
RulesChannelID*Snowflake`json:"rules_channel_id"`// the id of the channel where Community guilds can display rules and/or guidelines
47
+
MaxPresences*int64`json:"max_presences,omitempty"`// the maximum number of presences for the guild (null is always returned, apart from the largest of guilds)
48
+
MaxMembersint64`json:"max_members,omitempty"`// the maximum number of members for the guild
49
+
VanityUrlCode*string`json:"vanity_url_code"`// the vanity url code for the guild
50
+
Description*string`json:"description"`// the description of a Community guild
PremiumSubscriptionCountuint64`json:"premium_subscription_count,omitempty"`// the number of boosts this guild currently has
54
+
PreferredLocalestring`json:"preferred_locale"`// the preferred locale of a Community guild; used in server discovery and notices from Discord, and sent in interactions; defaults to "en-US"
55
+
PublicUpdatesChannelID*Snowflake`json:"public_updates_channel_id"`// the id of the channel where admins and moderators of Community guilds receive notices from Discord
56
+
MaxVideoChannelUsersuint64`json:"max_video_channel_users,omitempty"`// the maximum amount of users in a video channel
57
+
MaxStageVideoChannelUsersuint64`json:"max_stage_video_channel_users,omitempty"`// the maximum amount of users in a stage video channel
58
+
ApproximateMemberCountuint64`json:"approximate_member_count,omitempty"`// approximate number of members in this guild, returned from the GET /guilds/<id> endpoint when with_counts is true
59
+
ApproximatePresenceCountuint64`json:"approximate_presence_count,omitempty"`// approximate number of non-offline members in this guild, returned from the GET /guilds/<id> endpoint when with_counts is true
60
+
WelcomeScreenWelcomeScreen`json:"welcome_screen,omitempty"`// the welcome screen of a Community guild, shown to new members, returned in an Invite's guild object
PremiumProgressBarEnabledbool`json:"premium_progress_bar_enabled"`// whether the guild has the boost progress bar enabled
63
64
64
65
// These fields are only sent when using the GET CurrentUserGuilds endpoint and are relative to the requested user
65
66
@@ -316,6 +317,44 @@ type WelcomeScreenChannel struct {
316
317
EmojiName*string`json:"emoji_name,omitempty"`// the emoji name if custom, the unicode character if standard, or null if no emoji is set
317
318
}
318
319
320
+
// GuildOnboarding - Represents the onboarding flow for a guild.
321
+
typeGuildOnboardingstruct {
322
+
GuildIDSnowflake`json:"guild_id"`// ID of the guild this onboarding is part of
323
+
Prompts []OnboardingPrompt`json:"prompts"`// Prompts shown during onboarding and in customize community
324
+
DefaultChanelIds []Snowflake`json:"default_chanel_ids"`// Channel IDs that members get opted into automatically
325
+
Enabledbool`json:"enabled"`// Whether onboarding is enabled in the guild
326
+
}
327
+
328
+
// OnboardingPrompt - Prompts shown during onboarding and in customize community
329
+
typeOnboardingPromptstruct {
330
+
IDSnowflake`json:"id"`// ID of the prompt
331
+
TypePromptType`json:"type"`// Type of prompt
332
+
Options []PromptOption`json:"options"`// Options available within the prompt
333
+
Titlestring`json:"title"`// Title of the prompt
334
+
SingleSelectbool`json:"single_select"`// Indicates whether users are limited to selecting one option for the prompt
335
+
Requiredbool`json:"required"`// Indicates whether the prompt is required before a user completes the onboarding flow
336
+
InOnboardingbool`json:"in_onboarding"`// Indicates whether the prompt is present in the onboarding flow. If false, the prompt will only appear in the Channels & Roles tab
337
+
}
338
+
339
+
// PromptOption - Options available within the prompt
340
+
typePromptOptionstruct {
341
+
IDSnowflake`json:"id"`// ID of the prompt option
342
+
ChannelIds []Snowflake`json:"channel_ids"`// IDs for channels a member is added to when the option is selected
343
+
RoleIds []Snowflake`json:"role_ids"`// IDs for roles assigned to a member when the option is selected
344
+
EmojiEmoji`json:"emoji"`// Emoji of the option
345
+
Titlestring`json:"title"`// Title of the option
346
+
Description*string`json:"description"`// Description of the option
347
+
}
348
+
349
+
// PromptType - Type of prompt
350
+
typePromptTypeint
351
+
352
+
//goland:noinspection GoUnusedConst
353
+
const (
354
+
MultipleChoicePremiumType=iota
355
+
Dropdown
356
+
)
357
+
319
358
// String - Helper function to convert basic Guild data into string form
0 commit comments