dfx 0.98.0 → 0.99.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/types.d.ts CHANGED
@@ -111,7 +111,7 @@ export interface ActivityTimestamp {
111
111
  readonly end?: number;
112
112
  }
113
113
  export declare enum ActivityType {
114
- GAME = 0,
114
+ PLAYING = 0,
115
115
  STREAMING = 1,
116
116
  LISTENING = 2,
117
117
  WATCHING = 3,
@@ -201,7 +201,7 @@ export interface Application {
201
201
  readonly tags?: Array<string>;
202
202
  /** Settings for the app's default in-app authorization link, if enabled */
203
203
  readonly install_params?: InstallParam;
204
- /** In preview. Default scopes and permissions for each supported installation context. Value for each key is an integration type configuration object */
204
+ /** Default scopes and permissions for each supported installation context. Value for each key is an integration type configuration object */
205
205
  readonly integration_types_config?: ApplicationIntegrationType;
206
206
  /** Default custom authorization URL for the app, if enabled */
207
207
  readonly custom_install_url?: string;
@@ -233,9 +233,9 @@ export interface ApplicationCommand {
233
233
  readonly default_permission?: boolean | null;
234
234
  /** Indicates whether the command is age-restricted, defaults to false */
235
235
  readonly nsfw?: boolean;
236
- /** In preview. Installation context(s) where the command is available, only for globally-scoped commands. Defaults to GUILD_INSTALL (0) */
236
+ /** Installation contexts where the command is available, only for globally-scoped commands. Defaults to your app's configured contexts */
237
237
  readonly integration_types?: Array<ApplicationIntegrationType>;
238
- /** In preview. Interaction context(s) where the command can be used, only for globally-scoped commands. By default, all interaction context types included for new commands. */
238
+ /** Interaction context(s) where the command can be used, only for globally-scoped commands. By default, all interaction context types included for new commands. */
239
239
  readonly contexts?: Array<InteractionContextType> | null;
240
240
  /** Autoincrementing version identifier updated during substantial record changes */
241
241
  readonly version: Snowflake;
@@ -414,6 +414,8 @@ export interface Attachment {
414
414
  readonly id: Snowflake;
415
415
  /** name of file attached */
416
416
  readonly filename: string;
417
+ /** the title of the file */
418
+ readonly title?: string;
417
419
  /** description for the file (max 1024 characters) */
418
420
  readonly description?: string;
419
421
  /** the attachment's media type */
@@ -757,9 +759,9 @@ export interface BulkOverwriteGuildApplicationCommandParams {
757
759
  readonly dm_permission?: boolean | null;
758
760
  /** Replaced by default_member_permissions and will be deprecated in the future. Indicates whether the command is enabled by default when the app is added to a guild. Defaults to true */
759
761
  readonly default_permission?: boolean;
760
- /** In preview. Installation context(s) where the command is available, defaults to GUILD_INSTALL ([0]) */
762
+ /** Installation context(s) where the command is available, defaults to GUILD_INSTALL ([0]) */
761
763
  readonly integration_types: Array<ApplicationIntegrationType>;
762
- /** In preview. Interaction context(s) where the command can be used, defaults to all contexts [0,1,2] */
764
+ /** Interaction context(s) where the command can be used, defaults to all contexts [0,1,2] */
763
765
  readonly contexts: Array<InteractionContextType>;
764
766
  /** Type of command, defaults 1 if not set */
765
767
  readonly type?: ApplicationCommandType;
@@ -799,7 +801,7 @@ export interface Channel {
799
801
  readonly type: ChannelType;
800
802
  /** the id of the guild (may be missing for some channel objects received over gateway guild dispatches) */
801
803
  readonly guild_id?: Snowflake;
802
- /** sorting position of the channel */
804
+ /** sorting position of the channel (channels with the same position are sorted by id) */
803
805
  readonly position?: number;
804
806
  /** explicit permission overwrites for members and roles */
805
807
  readonly permission_overwrites?: Array<Overwrite>;
@@ -970,6 +972,12 @@ export interface Connection {
970
972
  /** visibility of this connection */
971
973
  readonly visibility: VisibilityType;
972
974
  }
975
+ export interface CreateApplicationEmojiParams {
976
+ /** name of the emoji */
977
+ readonly name: string;
978
+ /** the 128x128 emoji image */
979
+ readonly image: string;
980
+ }
973
981
  export interface CreateAutoModerationRuleParams {
974
982
  /** the rule name */
975
983
  readonly name: string;
@@ -1079,7 +1087,7 @@ export interface CreateGuildChannelParams {
1079
1087
  readonly user_limit: number;
1080
1088
  /** amount of seconds a user has to wait before sending another message (0-21600); bots, as well as users with the permission manage_messages or manage_channel, are unaffected */
1081
1089
  readonly rate_limit_per_user: number;
1082
- /** sorting position of the channel */
1090
+ /** sorting position of the channel (channels with the same position are sorted by id) */
1083
1091
  readonly position: number;
1084
1092
  /** the channel's permission overwrites */
1085
1093
  readonly permission_overwrites: Array<Overwrite>;
@@ -1179,6 +1187,8 @@ export interface CreateGuildScheduledEventParams {
1179
1187
  readonly entity_type: GuildScheduledEventEntityType;
1180
1188
  /** the cover image of the scheduled event */
1181
1189
  readonly image?: string;
1190
+ /** the definition for how often this event should recur */
1191
+ readonly recurrence_rule?: GuildScheduledEventRecurrenceRule;
1182
1192
  }
1183
1193
  export interface CreateGuildStickerParams {
1184
1194
  /** name of the sticker (2-30 characters) */
@@ -1207,7 +1217,7 @@ export interface CreateMessageParams {
1207
1217
  readonly embeds?: Array<Embed>;
1208
1218
  /** Allowed mentions for the message */
1209
1219
  readonly allowed_mentions?: AllowedMention;
1210
- /** Include to make your message a reply */
1220
+ /** Include to make your message a reply or a forward */
1211
1221
  readonly message_reference?: MessageReference;
1212
1222
  /** Components to include with the message */
1213
1223
  readonly components?: Array<Component>;
@@ -1282,7 +1292,7 @@ export interface EditCurrentApplicationParams {
1282
1292
  readonly role_connections_verification_url: string;
1283
1293
  /** Settings for the app's default in-app authorization link, if enabled */
1284
1294
  readonly install_params: InstallParam;
1285
- /** In preview. Default scopes and permissions for each supported installation context. Value for each key is an integration type configuration object */
1295
+ /** Default scopes and permissions for each supported installation context. Value for each key is an integration type configuration object */
1286
1296
  readonly integration_types_config: ApplicationIntegrationType;
1287
1297
  /** App's public flags */
1288
1298
  readonly flags: number;
@@ -1312,9 +1322,9 @@ export interface EditGlobalApplicationCommandParams {
1312
1322
  readonly dm_permission?: boolean | null;
1313
1323
  /** Replaced by default_member_permissions and will be deprecated in the future. Indicates whether the command is enabled by default when the app is added to a guild. Defaults to true */
1314
1324
  readonly default_permission?: boolean;
1315
- /** In preview. Installation context(s) where the command is available */
1325
+ /** Installation context(s) where the command is available */
1316
1326
  readonly integration_types?: Array<ApplicationIntegrationType>;
1317
- /** In preview. Interaction context(s) where the command can be used */
1327
+ /** Interaction context(s) where the command can be used */
1318
1328
  readonly contexts?: Array<InteractionContextType>;
1319
1329
  /** Indicates whether the command is age-restricted */
1320
1330
  readonly nsfw?: boolean;
@@ -1513,13 +1523,14 @@ export interface Endpoints<O> {
1513
1523
  bulkOverwriteGuildApplicationCommands: (applicationId: string, guildId: string, params?: Partial<BulkOverwriteGuildApplicationCommandParams>, options?: O) => RestResponse<Array<ApplicationCommand>>;
1514
1524
  /** For One-Time Purchase consumable SKUs, marks a given entitlement for the user as consumed. The entitlement will have consumed: true when using List Entitlements. */
1515
1525
  consumeAnEntitlement: (applicationId: string, entitlementId: string, options?: O) => RestResponse<any>;
1526
+ /** Create a new emoji for the application. Returns the new emoji object on success. */
1527
+ createApplicationEmoji: (applicationId: string, params?: Partial<CreateApplicationEmojiParams>, options?: O) => RestResponse<Emoji>;
1516
1528
  /** Create a new rule. Returns an auto moderation rule on success. Fires an Auto Moderation Rule Create Gateway event. */
1517
1529
  createAutoModerationRule: (guildId: string, params?: Partial<CreateAutoModerationRuleParams>, options?: O) => RestResponse<AutoModerationRule>;
1518
1530
  /** Create a new invite object for the channel. Only usable for guild channels. Requires the CREATE_INSTANT_INVITE permission. All JSON parameters for this route are optional, however the request body is not. If you are not sending any fields, you still have to send an empty JSON object ({}). Returns an invite object. Fires an Invite Create Gateway event. */
1519
1531
  createChannelInvite: (channelId: string, params?: Partial<CreateChannelInviteParams>, options?: O) => RestResponse<Invite>;
1520
1532
  /** Create a new DM channel with a user. Returns a DM channel object (if one already exists, it will be returned instead). */
1521
1533
  createDm: (params?: Partial<CreateDmParams>, options?: O) => RestResponse<Channel>;
1522
- /** Create a followup message for an Interaction. Functions the same as Execute Webhook, but wait is always true. The thread_id, avatar_url, and username parameters are not supported when using this endpoint for interaction followups. */
1523
1534
  createFollowupMessage: (applicationId: string, interactionToken: string, params?: Partial<ExecuteWebhookParams>, options?: O) => RestResponse<any>;
1524
1535
  createGlobalApplicationCommand: (applicationId: string, params?: Partial<CreateGlobalApplicationCommandParams>, options?: O) => RestResponse<ApplicationCommand>;
1525
1536
  /** Create a new group DM channel with multiple users. Returns a DM channel object. This endpoint was intended to be used with the now-deprecated GameBridge SDK. Fires a Channel Create Gateway event. */
@@ -1562,6 +1573,8 @@ export interface Endpoints<O> {
1562
1573
  /** Deletes all the reactions for a given emoji on a message. This endpoint requires the MANAGE_MESSAGES permission to be present on the current user. Fires a Message Reaction Remove Emoji Gateway event.
1563
1574
  The emoji must be URL Encoded or the request will fail with 10014: Unknown Emoji. To use custom emoji, you must encode it in the format name:id with the emoji name and emoji id. */
1564
1575
  deleteAllReactionsForEmoji: (channelId: string, messageId: string, emoji: string, options?: O) => RestResponse<any>;
1576
+ /** Delete the given emoji. Returns 204 No Content on success. */
1577
+ deleteApplicationEmoji: (applicationId: string, emojiId: string, options?: O) => RestResponse<any>;
1565
1578
  /** Delete a rule. Returns a 204 on success. Fires an Auto Moderation Rule Delete Gateway event. */
1566
1579
  deleteAutoModerationRule: (guildId: string, autoModerationRuleId: string, options?: O) => RestResponse<any>;
1567
1580
  /** Delete a channel permission overwrite for a user or role in a channel. Only usable for guild channels. Requires the MANAGE_ROLES permission. Returns a 204 empty response on success. Fires a Channel Update Gateway event. For more information about permissions, see permissions */
@@ -1639,6 +1652,8 @@ export interface Endpoints<O> {
1639
1652
  getAnswerVoters: (channelId: string, messageId: string, answerId: string, params?: Partial<GetAnswerVoterParams>, options?: O) => RestResponse<GetAnswerVoterResponse>;
1640
1653
  /** Fetches permissions for a specific command for your application in a guild. Returns a guild application command permissions object. */
1641
1654
  getApplicationCommandPermissions: (applicationId: string, guildId: string, commandId: string, options?: O) => RestResponse<GuildApplicationCommandPermission>;
1655
+ /** Returns an emoji object for the given application and emoji IDs. Includes the user field. */
1656
+ getApplicationEmoji: (applicationId: string, emojiId: string, options?: O) => RestResponse<Emoji>;
1642
1657
  /** Returns a list of application role connection metadata objects for the given application. */
1643
1658
  getApplicationRoleConnectionMetadataRecords: (applicationId: string, options?: O) => RestResponse<Array<ApplicationRoleConnectionMetadatum>>;
1644
1659
  /** Get a single rule. Returns an auto moderation rule object. */
@@ -1669,6 +1684,8 @@ export interface Endpoints<O> {
1669
1684
  getCurrentUserGuildMember: (guildId: string, options?: O) => RestResponse<GuildMember>;
1670
1685
  /** Returns a list of partial guild objects the current user is a member of. For OAuth2, requires the guilds scope. */
1671
1686
  getCurrentUserGuilds: (params?: Partial<GetCurrentUserGuildParams>, options?: O) => RestResponse<Array<Guild>>;
1687
+ /** Returns the current user's voice state in the guild. */
1688
+ getCurrentUserVoiceState: (guildId: string, options?: O) => RestResponse<VoiceState>;
1672
1689
  /** Returns a followup message for an Interaction. Functions the same as Get Webhook Message. */
1673
1690
  getFollowupMessage: (applicationId: string, interactionToken: string, messageId: string, params?: Partial<GetWebhookMessageParams>, options?: O) => RestResponse<Message>;
1674
1691
  getGateway: (options?: O) => RestResponse<any>;
@@ -1749,6 +1766,8 @@ export interface Endpoints<O> {
1749
1766
  getThreadMember: (channelId: string, userId: string, params?: Partial<GetThreadMemberParams>, options?: O) => RestResponse<ThreadMember>;
1750
1767
  /** Returns a user object for a given user ID. */
1751
1768
  getUser: (userId: string, options?: O) => RestResponse<User>;
1769
+ /** Returns the specified user's voice state in the guild. */
1770
+ getUserVoiceState: (guildId: string, userId: string, options?: O) => RestResponse<VoiceState>;
1752
1771
  /** Returns the new webhook object for the given id. */
1753
1772
  getWebhook: (webhookId: string, options?: O) => RestResponse<Webhook>;
1754
1773
  /** Returns a previously-sent webhook message from the same token. Returns a message object on success. */
@@ -1767,6 +1786,8 @@ export interface Endpoints<O> {
1767
1786
  leaveThread: (channelId: string, options?: O) => RestResponse<any>;
1768
1787
  /** Returns all active threads in the guild, including public and private threads. Threads are ordered by their id, in descending order. */
1769
1788
  listActiveGuildThreads: (guildId: string, options?: O) => RestResponse<ListActiveGuildThreadResponse>;
1789
+ /** Returns an object containing a list of emoji objects for the given application under the items key. Includes a user object for the team member that uploaded the emoji from the app's settings, or for the bot user if uploaded using the API. */
1790
+ listApplicationEmojis: (applicationId: string, options?: O) => RestResponse<Array<Emoji>>;
1770
1791
  /** Get a list of all rules currently configured for the guild. Returns a list of auto moderation rule objects for the given guild. */
1771
1792
  listAutoModerationRulesForGuild: (guildId: string, options?: O) => RestResponse<Array<AutoModerationRule>>;
1772
1793
  /** Returns all entitlements for a given app, active and expired. */
@@ -1792,6 +1813,8 @@ export interface Endpoints<O> {
1792
1813
  listThreadMembers: (channelId: string, params?: Partial<ListThreadMemberParams>, options?: O) => RestResponse<Array<ThreadMember>>;
1793
1814
  /** Returns an array of voice region objects that can be used when setting a voice or stage channel's rtc_region. */
1794
1815
  listVoiceRegions: (options?: O) => RestResponse<Array<VoiceRegion>>;
1816
+ /** Modify the given emoji. Returns the updated emoji object on success. */
1817
+ modifyApplicationEmoji: (applicationId: string, emojiId: string, params?: Partial<ModifyApplicationEmojiParams>, options?: O) => RestResponse<Emoji>;
1795
1818
  /** Modify an existing rule. Returns an auto moderation rule on success. Fires an Auto Moderation Rule Update Gateway event. */
1796
1819
  modifyAutoModerationRule: (guildId: string, autoModerationRuleId: string, params?: Partial<ModifyAutoModerationRuleParams>, options?: O) => RestResponse<AutoModerationRule>;
1797
1820
  /** Update a channel's settings. Returns a channel on success, and a 400 BAD REQUEST on invalid parameters. All JSON parameters are optional. */
@@ -2134,7 +2157,7 @@ export interface GetGuildAuditLogParams {
2134
2157
  }
2135
2158
  export interface GetGuildBanParams {
2136
2159
  /** number of users to return (up to maximum 1000) */
2137
- readonly limit?: Number;
2160
+ readonly limit?: number;
2138
2161
  /** consider only users before given user id */
2139
2162
  readonly before?: Snowflake;
2140
2163
  /** consider only users after given user id */
@@ -2156,7 +2179,7 @@ export interface GetGuildScheduledEventParams {
2156
2179
  }
2157
2180
  export interface GetGuildScheduledEventUserParams {
2158
2181
  /** number of users to return (up to maximum 100) */
2159
- readonly limit?: Number;
2182
+ readonly limit?: number;
2160
2183
  /** include guild member data if it exists */
2161
2184
  readonly with_member?: boolean;
2162
2185
  /** consider only users before given user id */
@@ -2591,6 +2614,8 @@ export interface GuildScheduledEvent {
2591
2614
  readonly user_count?: number;
2592
2615
  /** the cover image hash of the scheduled event */
2593
2616
  readonly image?: string | null;
2617
+ /** the definition for how often this event should recur */
2618
+ readonly recurrence_rule?: GuildScheduledEventRecurrenceRule | null;
2594
2619
  }
2595
2620
  export type GuildScheduledEventCreateEvent = GuildScheduledEvent;
2596
2621
  export type GuildScheduledEventDeleteEvent = GuildScheduledEvent;
@@ -2607,6 +2632,63 @@ export declare enum GuildScheduledEventPrivacyLevel {
2607
2632
  /** the scheduled event is only accessible to guild members */
2608
2633
  GUILD_ONLY = 2
2609
2634
  }
2635
+ export interface GuildScheduledEventRecurrenceRule {
2636
+ /** Starting time of the recurrence interval */
2637
+ readonly start: string;
2638
+ /** Ending time of the recurrence interval */
2639
+ readonly end?: string | null;
2640
+ /** How often the event occurs */
2641
+ readonly frequency: GuildScheduledEventRecurrenceRuleFrequency;
2642
+ /** The spacing between the events, defined by frequency. For example, frecency of WEEKLY and an interval of 2 would be "every-other week" */
2643
+ readonly interval: number;
2644
+ /** Set of specific days within a week for the event to recur on */
2645
+ readonly by_weekday?: Array<GuildScheduledEventRecurrenceRuleWeekday> | null;
2646
+ /** List of specific days within a specific week (1-5) to recur on */
2647
+ readonly by_n_weekday?: Array<GuildScheduledEventRecurrenceRuleNWeekday> | null;
2648
+ /** Set of specific months to recur on */
2649
+ readonly by_month?: Array<GuildScheduledEventRecurrenceRuleMonth> | null;
2650
+ /** Set of specific dates within a month to recur on */
2651
+ readonly by_month_day?: Array<number> | null;
2652
+ /** Set of days within a year to recur on (1-364) */
2653
+ readonly by_year_day?: Array<number> | null;
2654
+ /** The total amount of times that the event is allowed to recur before stopping */
2655
+ readonly count?: number | null;
2656
+ }
2657
+ export declare enum GuildScheduledEventRecurrenceRuleFrequency {
2658
+ YEARLY = 0,
2659
+ MONTHLY = 1,
2660
+ WEEKLY = 2,
2661
+ DAILY = 3
2662
+ }
2663
+ export declare enum GuildScheduledEventRecurrenceRuleMonth {
2664
+ JANUARY = 1,
2665
+ FEBRUARY = 2,
2666
+ MARCH = 3,
2667
+ APRIL = 4,
2668
+ MAY = 5,
2669
+ JUNE = 6,
2670
+ JULY = 7,
2671
+ AUGUST = 8,
2672
+ SEPTEMBER = 9,
2673
+ OCTOBER = 10,
2674
+ NOVEMBER = 11,
2675
+ DECEMBER = 12
2676
+ }
2677
+ export interface GuildScheduledEventRecurrenceRuleNWeekday {
2678
+ /** The week to reoccur on. 1 - 5 */
2679
+ readonly n: number;
2680
+ /** The day within the week to reoccur on */
2681
+ readonly day: GuildScheduledEventRecurrenceRuleWeekday;
2682
+ }
2683
+ export declare enum GuildScheduledEventRecurrenceRuleWeekday {
2684
+ MONDAY = 0,
2685
+ TUESDAY = 1,
2686
+ WEDNESDAY = 2,
2687
+ THURSDAY = 3,
2688
+ FRIDAY = 4,
2689
+ SATURDAY = 5,
2690
+ SUNDAY = 6
2691
+ }
2610
2692
  export declare enum GuildScheduledEventStatus {
2611
2693
  SCHEDULED = 1,
2612
2694
  ACTIVE = 2,
@@ -3170,7 +3252,7 @@ export interface Message {
3170
3252
  /** roles specifically mentioned in this message */
3171
3253
  readonly mention_roles: Array<Snowflake>;
3172
3254
  /** channels specifically mentioned in this message */
3173
- readonly mention_channels?: Array<ChannelMention>;
3255
+ readonly mention_channels: Array<ChannelMention>;
3174
3256
  /** any attached files */
3175
3257
  readonly attachments: Array<Attachment>;
3176
3258
  /** any embedded content */
@@ -3191,10 +3273,12 @@ export interface Message {
3191
3273
  readonly application?: Application;
3192
3274
  /** if the message is an Interaction or application-owned webhook, this is the id of the application */
3193
3275
  readonly application_id?: Snowflake;
3194
- /** data showing the source of a crosspost, channel follow add, pin, or reply message */
3195
- readonly message_reference?: MessageReference;
3196
3276
  /** message flags combined as a bitfield */
3197
3277
  readonly flags?: number;
3278
+ /** data showing the source of a crosspost, channel follow add, pin, or reply message */
3279
+ readonly message_reference?: MessageReference;
3280
+ /** the message associated with the message_reference. This is a minimal subset of fields in a message (e.g. author is excluded.) */
3281
+ readonly message_snapshots: Array<MessageSnapshot>;
3198
3282
  /** the message associated with the message_reference */
3199
3283
  readonly referenced_message?: Message | null;
3200
3284
  /** In preview. Sent if the message is sent as a result of an interaction */
@@ -3204,7 +3288,7 @@ export interface Message {
3204
3288
  /** the thread that was started from this message, includes thread member object */
3205
3289
  readonly thread?: Channel;
3206
3290
  /** sent if the message contains components like buttons, action rows, or other interactive components */
3207
- readonly components?: Array<Component>;
3291
+ readonly components: Array<Component>;
3208
3292
  /** sent if the message contains stickers */
3209
3293
  readonly sticker_items?: Array<StickerItem>;
3210
3294
  /** Deprecated the stickers sent with the message */
@@ -3216,7 +3300,7 @@ export interface Message {
3216
3300
  /** data for users, members, channels, and roles in the message's auto-populated select menus */
3217
3301
  readonly resolved?: ResolvedDatum;
3218
3302
  /** A poll! */
3219
- readonly poll?: Poll;
3303
+ readonly poll: Poll;
3220
3304
  /** the call associated with the message */
3221
3305
  readonly call?: MessageCall;
3222
3306
  }
@@ -3406,6 +3490,8 @@ export interface MessageReactionRemoveEvent {
3406
3490
  readonly type: ReactionType;
3407
3491
  }
3408
3492
  export interface MessageReference {
3493
+ /** type of reference. */
3494
+ readonly type?: MessageReferenceType;
3409
3495
  /** id of the originating message */
3410
3496
  readonly message_id?: Snowflake;
3411
3497
  /** id of the originating message's channel */
@@ -3415,6 +3501,16 @@ export interface MessageReference {
3415
3501
  /** when sending, whether to error if the referenced message doesn't exist instead of sending as a normal (non-reply) message, default true */
3416
3502
  readonly fail_if_not_exists?: boolean;
3417
3503
  }
3504
+ export declare enum MessageReferenceType {
3505
+ /** A standard reference used by replies. */
3506
+ DEFAULT = 0,
3507
+ /** Reference used to point to a message at a point in time. */
3508
+ FORWARD = 1
3509
+ }
3510
+ export interface MessageSnapshot {
3511
+ /** minimal subset of fields in the forwarded message */
3512
+ readonly message: Message;
3513
+ }
3418
3514
  export declare enum MessageType {
3419
3515
  DEFAULT = 0,
3420
3516
  RECIPIENT_ADD = 1,
@@ -3466,6 +3562,10 @@ export interface ModalSubmitDatum {
3466
3562
  /** the values submitted by the user */
3467
3563
  readonly components: Array<Component>;
3468
3564
  }
3565
+ export interface ModifyApplicationEmojiParams {
3566
+ /** name of the emoji */
3567
+ readonly name: string;
3568
+ }
3469
3569
  export interface ModifyAutoModerationRuleParams {
3470
3570
  /** the rule name */
3471
3571
  readonly name: string;
@@ -3493,7 +3593,7 @@ export interface ModifyChannelGuildChannelParams {
3493
3593
  readonly name: string;
3494
3594
  /** the type of channel; only conversion between text and announcement is supported and only in guilds with the "NEWS" feature */
3495
3595
  readonly type: ChannelType;
3496
- /** the position of the channel in the left-hand listing */
3596
+ /** the position of the channel in the left-hand listing (channels with the same position are sorted by id) */
3497
3597
  readonly position?: number | null;
3498
3598
  /** 0-1024 character channel topic (0-4096 characters for GUILD_FORUM and GUILD_MEDIA channels) */
3499
3599
  readonly topic?: string | null;
@@ -3574,7 +3674,7 @@ export interface ModifyCurrentUserVoiceStateParams {
3574
3674
  export interface ModifyGuildChannelPositionParams {
3575
3675
  /** channel id */
3576
3676
  readonly id: Snowflake;
3577
- /** sorting position of the channel */
3677
+ /** sorting position of the channel (channels with the same position are sorted by id) */
3578
3678
  readonly position?: number | null;
3579
3679
  /** syncs the permission overwrites with the new parent, if moving to a new category */
3580
3680
  readonly lock_permissions?: boolean | null;
@@ -3680,7 +3780,7 @@ export interface ModifyGuildRoleParams {
3680
3780
  export interface ModifyGuildRolePositionParams {
3681
3781
  /** role */
3682
3782
  readonly id: Snowflake;
3683
- /** sorting position of the role */
3783
+ /** sorting position of the role (roles with the same position are sorted by id) */
3684
3784
  readonly position?: number | null;
3685
3785
  }
3686
3786
  export interface ModifyGuildScheduledEventParams {
@@ -3704,6 +3804,8 @@ export interface ModifyGuildScheduledEventParams {
3704
3804
  readonly status?: GuildScheduledEventStatus;
3705
3805
  /** the cover image of the scheduled event */
3706
3806
  readonly image?: string;
3807
+ /** the definition for how often this event should recur */
3808
+ readonly recurrence_rule?: GuildScheduledEventRecurrenceRule;
3707
3809
  }
3708
3810
  export interface ModifyGuildStickerParams {
3709
3811
  /** name of the sticker (2-30 characters) */
@@ -3976,10 +4078,10 @@ export interface PollCreateRequest {
3976
4078
  readonly question: PollMedia;
3977
4079
  /** Each of the answers available in the poll, up to 10 */
3978
4080
  readonly answers: Array<PollAnswer>;
3979
- /** Number of hours the poll should be open for, up to 7 days */
3980
- readonly duration: number;
3981
- /** Whether a user can select multiple answers */
3982
- readonly allow_multiselect: boolean;
4081
+ /** Number of hours the poll should be open for, up to 32 days. Defaults to 24 */
4082
+ readonly duration?: number;
4083
+ /** Whether a user can select multiple answers. Defaults to false */
4084
+ readonly allow_multiselect?: boolean;
3983
4085
  /** The layout type of the poll. Defaults to... DEFAULT! */
3984
4086
  readonly layout_type?: LayoutType;
3985
4087
  }
@@ -4234,7 +4336,7 @@ export interface Role {
4234
4336
  readonly icon?: string | null;
4235
4337
  /** role unicode emoji */
4236
4338
  readonly unicode_emoji?: string | null;
4237
- /** position of this role */
4339
+ /** position of this role (roles with the same position are sorted by id) */
4238
4340
  readonly position: number;
4239
4341
  /** permission bit set */
4240
4342
  readonly permissions: string;