dfx 0.100.0 → 0.101.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.
@@ -236,5 +236,8 @@ export type InteractionResponse =
236
236
  type: Discord.InteractionCallbackType.APPLICATION_COMMAND_AUTOCOMPLETE_RESULT
237
237
  data: Discord.InteractionCallbackAutocomplete
238
238
  }
239
+ | {
240
+ type: Discord.InteractionCallbackType.LAUNCH_ACTIVITY
241
+ }
239
242
 
240
243
  export const response = (r: InteractionResponse) => r
package/src/types.ts CHANGED
@@ -91,6 +91,34 @@ export const ActivityFlag = {
91
91
  PARTY_PRIVACY_VOICE_CHANNEL: 1 << 7,
92
92
  EMBEDDED: 1 << 8,
93
93
  } as const
94
+ export interface ActivityInstance {
95
+ /** Application ID */
96
+ readonly application_id: Snowflake
97
+ /** Activity Instance ID */
98
+ readonly instance_id: string
99
+ /** Unique identifier for the launch */
100
+ readonly launch_id: Snowflake
101
+ /** The Location the instance is runnning in */
102
+ readonly location: ActivityLocation
103
+ /** The IDs of the Users currently connected to the instance */
104
+ readonly users: Array<Snowflake>
105
+ }
106
+ export interface ActivityLocation {
107
+ /** The unique identifier for the location */
108
+ readonly id: string
109
+ /** Enum describing kind of location */
110
+ readonly kind: ActivityLocationKind
111
+ /** The id of the Channel */
112
+ readonly channel_id: Snowflake
113
+ /** The id of the Guild */
114
+ readonly guild_id?: Snowflake | null
115
+ }
116
+ export enum ActivityLocationKind {
117
+ /** The Location is a Guild Channel */
118
+ GC = "'gc'",
119
+ /** The Location is a Private Channel, such as a DM or GDM */
120
+ PC = "'pc'",
121
+ }
94
122
  export interface ActivityParty {
95
123
  /** ID of the party */
96
124
  readonly id?: string
@@ -248,21 +276,23 @@ export interface ApplicationCommand {
248
276
  readonly contexts?: Array<InteractionContextType> | null
249
277
  /** Autoincrementing version identifier updated during substantial record changes */
250
278
  readonly version: Snowflake
279
+ /** Determines whether the interaction is handled by the app's interactions handler or by Discord */
280
+ readonly handler?: EntryPointCommandHandlerType
251
281
  }
252
282
  export interface ApplicationCommandDatum {
253
- /** the ID of the invoked command */
283
+ /** ID of the invoked command */
254
284
  readonly id: Snowflake
255
- /** the name of the invoked command */
285
+ /** name of the invoked command */
256
286
  readonly name: string
257
- /** the type of the invoked command */
287
+ /** type of the invoked command */
258
288
  readonly type: number
259
- /** converted users + roles + channels + attachments */
289
+ /** Converted users + roles + channels + attachments */
260
290
  readonly resolved?: ResolvedDatum
261
- /** the params + values from the user */
291
+ /** Params + values from the user */
262
292
  readonly options?: Array<ApplicationCommandInteractionDataOption>
263
- /** the id of the guild the command is registered to */
293
+ /** ID of the guild the command is registered to */
264
294
  readonly guild_id?: Snowflake
265
- /** id of the user or message targeted by a user or message command */
295
+ /** ID of the user or message targeted by a user or message command */
266
296
  readonly target_id?: Snowflake
267
297
  }
268
298
  export interface ApplicationCommandInteractionDataOption {
@@ -350,6 +380,8 @@ export enum ApplicationCommandType {
350
380
  USER = 2,
351
381
  /** A UI-based command that shows up when you right click or tap on a message */
352
382
  MESSAGE = 3,
383
+ /** A UI-based command that represents the primary way to invoke an app's Activity */
384
+ PRIMARY_ENTRY_POINT = 4,
353
385
  }
354
386
  export const ApplicationFlag = {
355
387
  /** Indicates if an app uses the Auto Moderation API */
@@ -1792,6 +1824,12 @@ export function createRoutes<O = any>(
1792
1824
  params,
1793
1825
  options,
1794
1826
  }),
1827
+ getApplicationActivityInstance: (applicationId, instanceId, options) =>
1828
+ fetch({
1829
+ method: "GET",
1830
+ url: `/applications/${applicationId}/activity-instances/${instanceId}`,
1831
+ options,
1832
+ }),
1795
1833
  getApplicationCommandPermissions: (
1796
1834
  applicationId,
1797
1835
  guildId,
@@ -3047,7 +3085,7 @@ export interface Endpoints<O> {
3047
3085
  params?: Partial<CreateGuildTemplateParams>,
3048
3086
  options?: O,
3049
3087
  ) => RestResponse<GuildTemplate>
3050
- /** Create a response to an Interaction from the gateway. Body is an interaction response. Returns 204 No Content. */
3088
+ /** Create a response to an Interaction. Body is an interaction response. Returns 204 unless with_response is set to true which returns 200 with the body as interaction response. */
3051
3089
  createInteractionResponse: (
3052
3090
  interactionId: string,
3053
3091
  interactionToken: string,
@@ -3337,6 +3375,12 @@ The emoji must be URL Encoded or the request will fail with 10014: Unknown Emoji
3337
3375
  params?: Partial<GetAnswerVoterParams>,
3338
3376
  options?: O,
3339
3377
  ) => RestResponse<GetAnswerVoterResponse>
3378
+ /** Returns a serialized activity instance, if it exists. Useful for preventing unwanted activity sessions. */
3379
+ getApplicationActivityInstance: (
3380
+ applicationId: string,
3381
+ instanceId: string,
3382
+ options?: O,
3383
+ ) => RestResponse<any>
3340
3384
  /** Fetches permissions for a specific command for your application in a guild. Returns a guild application command permissions object. */
3341
3385
  getApplicationCommandPermissions: (
3342
3386
  applicationId: string,
@@ -4012,6 +4056,10 @@ export enum EntitlementType {
4012
4056
  APPLICATION_SUBSCRIPTION = 8,
4013
4057
  }
4014
4058
  export type EntitlementUpdateEvent = Entitlement
4059
+ export enum EntryPointCommandHandlerType {
4060
+ APP_HANDLER = 1,
4061
+ DISCORD_LAUNCH_ACTIVITY = 2,
4062
+ }
4015
4063
  export enum EventType {
4016
4064
  /** when a member sends or edits a message in the guild */
4017
4065
  MESSAGE_SEND = 1,
@@ -5002,6 +5050,24 @@ export interface Interaction {
5002
5050
  /** Context where the interaction was triggered from */
5003
5051
  readonly context?: InteractionContextType
5004
5052
  }
5053
+ export interface InteractionCallback {
5054
+ /** */
5055
+ readonly id: Snowflake
5056
+ /** Interaction type */
5057
+ readonly type: InteractionType
5058
+ /** Instance ID of the Activity if one was launched or joined */
5059
+ readonly activity_instance_id?: string
5060
+ /** ID of the message that was created by the interaction */
5061
+ readonly response_message_id?: Snowflake
5062
+ /** Whether or not the message is in a loading state */
5063
+ readonly response_message_loading?: boolean
5064
+ /** Whether or not the response message was ephemeral */
5065
+ readonly response_message_ephemeral?: boolean
5066
+ }
5067
+ export interface InteractionCallbackActivityInstanceResource {
5068
+ /** Instance ID of the Activity if one was launched or joined. */
5069
+ readonly id: string
5070
+ }
5005
5071
  export interface InteractionCallbackAutocomplete {
5006
5072
  /** autocomplete choices (max of 25 choices) */
5007
5073
  readonly choices: Array<ApplicationCommandOptionChoice>
@@ -5011,48 +5077,64 @@ export type InteractionCallbackDatum =
5011
5077
  | InteractionCallbackMessage
5012
5078
  | InteractionCallbackModal
5013
5079
  export interface InteractionCallbackMessage {
5014
- /** is the response TTS */
5080
+ /** Whether the response is TTS */
5015
5081
  readonly tts?: boolean
5016
- /** message content */
5082
+ /** Message content */
5017
5083
  readonly content?: string
5018
- /** supports up to 10 embeds */
5084
+ /** Supports up to 10 embeds */
5019
5085
  readonly embeds?: Array<Embed>
5020
- /** allowed mentions object */
5086
+ /** Allowed mentions object */
5021
5087
  readonly allowed_mentions?: AllowedMention
5022
- /** message flags combined as a bitfield (only SUPPRESS_EMBEDS, EPHEMERAL, and SUPPRESS_NOTIFICATIONS can be set) */
5088
+ /** Message flags combined as a bitfield (only SUPPRESS_EMBEDS, EPHEMERAL, and SUPPRESS_NOTIFICATIONS can be set) */
5023
5089
  readonly flags?: number
5024
- /** message components */
5090
+ /** Message components */
5025
5091
  readonly components?: Array<Component>
5026
- /** attachment objects with filename and description */
5092
+ /** Attachment objects with filename and description */
5027
5093
  readonly attachments?: Array<Attachment>
5028
- /** A poll! */
5094
+ /** Details about the poll */
5029
5095
  readonly poll?: PollCreateRequest
5030
5096
  }
5031
5097
  export interface InteractionCallbackModal {
5032
- /** a developer-defined identifier for the modal, max 100 characters */
5098
+ /** Developer-defined identifier for the modal, max 100 characters */
5033
5099
  readonly custom_id: string
5034
- /** the title of the popup modal, max 45 characters */
5100
+ /** Title of the popup modal, max 45 characters */
5035
5101
  readonly title: string
5036
- /** between 1 and 5 (inclusive) components that make up the modal */
5102
+ /** Between 1 and 5 (inclusive) components that make up the modal */
5037
5103
  readonly components: Array<Component>
5038
5104
  }
5105
+ export interface InteractionCallbackResource {
5106
+ /** Interaction callback type */
5107
+ readonly type: InteractionCallbackType
5108
+ /** Represents the Activity launched by this interaction. */
5109
+ readonly activity_instance?: InteractionCallbackActivityInstanceResource
5110
+ /** Message created by the interaction. */
5111
+ readonly message?: Message
5112
+ }
5113
+ export interface InteractionCallbackResponse {
5114
+ /** The interaction object associated with the */
5115
+ readonly interaction: InteractionCallback
5116
+ /** The resource that was created by the interaction response. */
5117
+ readonly resource?: InteractionCallbackResource
5118
+ }
5039
5119
  export enum InteractionCallbackType {
5040
5120
  /** ACK a Ping */
5041
5121
  PONG = 1,
5042
- /** respond to an interaction with a message */
5122
+ /** Respond to an interaction with a message */
5043
5123
  CHANNEL_MESSAGE_WITH_SOURCE = 4,
5044
5124
  /** ACK an interaction and edit a response later, the user sees a loading state */
5045
5125
  DEFERRED_CHANNEL_MESSAGE_WITH_SOURCE = 5,
5046
- /** for components, ACK an interaction and edit the original message later; the user does not see a loading state */
5126
+ /** For components, ACK an interaction and edit the original message later; the user does not see a loading state */
5047
5127
  DEFERRED_UPDATE_MESSAGE = 6,
5048
- /** for components, edit the message the component was attached to */
5128
+ /** For components, edit the message the component was attached to */
5049
5129
  UPDATE_MESSAGE = 7,
5050
- /** respond to an autocomplete interaction with suggested choices */
5130
+ /** Respond to an autocomplete interaction with suggested choices */
5051
5131
  APPLICATION_COMMAND_AUTOCOMPLETE_RESULT = 8,
5052
- /** respond to an interaction with a popup modal */
5132
+ /** Respond to an interaction with a popup modal */
5053
5133
  MODAL = 9,
5054
5134
  /** Deprecated; respond to an interaction with an upgrade button, only available for apps with monetization enabled */
5055
5135
  PREMIUM_REQUIRED = 10,
5136
+ /** Launch the Activity associated with the app. Only available for apps with Activities enabled */
5137
+ LAUNCH_ACTIVITY = 12,
5056
5138
  }
5057
5139
  export enum InteractionContextType {
5058
5140
  /** Interaction can be used within servers */
@@ -5068,9 +5150,9 @@ export type InteractionDatum =
5068
5150
  | MessageComponentDatum
5069
5151
  | ModalSubmitDatum
5070
5152
  export interface InteractionResponse {
5071
- /** the type of response */
5153
+ /** Type of response */
5072
5154
  readonly type: InteractionCallbackType
5073
- /** an optional response message */
5155
+ /** An optional response message */
5074
5156
  readonly data?: InteractionCallbackDatum
5075
5157
  }
5076
5158
  export enum InteractionType {
@@ -5411,13 +5493,13 @@ export interface MessageCall {
5411
5493
  readonly ended_timestamp?: string | null
5412
5494
  }
5413
5495
  export interface MessageComponentDatum {
5414
- /** the custom_id of the component */
5496
+ /** custom_id of the component */
5415
5497
  readonly custom_id: string
5416
- /** the type of the component */
5498
+ /** type of the component */
5417
5499
  readonly component_type: ComponentType
5418
- /** values the user selected in a select menu component */
5500
+ /** Values the user selected in a select menu component */
5419
5501
  readonly values?: Array<SelectOption>
5420
- /** resolved entities from selected options */
5502
+ /** Resolved entities from selected options */
5421
5503
  readonly resolved?: ResolvedDatum
5422
5504
  }
5423
5505
  export type MessageCreateEvent = Message & MessageCreateExtra
@@ -5646,9 +5728,9 @@ export enum MfaLevel {
5646
5728
  ELEVATED = 1,
5647
5729
  }
5648
5730
  export interface ModalSubmitDatum {
5649
- /** the custom_id of the modal */
5731
+ /** custom_id of the modal */
5650
5732
  readonly custom_id: string
5651
- /** the values submitted by the user */
5733
+ /** Values submitted by the user */
5652
5734
  readonly components: Array<Component>
5653
5735
  }
5654
5736
  export interface ModifyApplicationEmojiParams {
@@ -6446,17 +6528,17 @@ export interface RequestGuildMember {
6446
6528
  readonly nonce?: string
6447
6529
  }
6448
6530
  export interface ResolvedDatum {
6449
- /** the ids and User objects */
6531
+ /** IDs and User objects */
6450
6532
  readonly users?: Record<Snowflake, User>
6451
- /** the ids and partial Member objects */
6533
+ /** IDs and partial Member objects */
6452
6534
  readonly members?: Record<Snowflake, GuildMember>
6453
- /** the ids and Role objects */
6535
+ /** IDs and Role objects */
6454
6536
  readonly roles?: Record<Snowflake, Role>
6455
- /** the ids and partial Channel objects */
6537
+ /** IDs and partial Channel objects */
6456
6538
  readonly channels?: Record<Snowflake, Channel>
6457
- /** the ids and partial Message objects */
6539
+ /** IDs and partial Message objects */
6458
6540
  readonly messages?: Record<Snowflake, Message>
6459
- /** the ids and attachment objects */
6541
+ /** IDs and attachment objects */
6460
6542
  readonly attachments?: Record<Snowflake, Attachment>
6461
6543
  }
6462
6544
  export interface Response {
package/src/version.ts CHANGED
@@ -1 +1 @@
1
- export const LIB_VERSION = "0.100.0";
1
+ export const LIB_VERSION = "0.101.0";
package/types.d.ts CHANGED
@@ -90,6 +90,34 @@ export declare const ActivityFlag: {
90
90
  readonly PARTY_PRIVACY_VOICE_CHANNEL: number;
91
91
  readonly EMBEDDED: number;
92
92
  };
93
+ export interface ActivityInstance {
94
+ /** Application ID */
95
+ readonly application_id: Snowflake;
96
+ /** Activity Instance ID */
97
+ readonly instance_id: string;
98
+ /** Unique identifier for the launch */
99
+ readonly launch_id: Snowflake;
100
+ /** The Location the instance is runnning in */
101
+ readonly location: ActivityLocation;
102
+ /** The IDs of the Users currently connected to the instance */
103
+ readonly users: Array<Snowflake>;
104
+ }
105
+ export interface ActivityLocation {
106
+ /** The unique identifier for the location */
107
+ readonly id: string;
108
+ /** Enum describing kind of location */
109
+ readonly kind: ActivityLocationKind;
110
+ /** The id of the Channel */
111
+ readonly channel_id: Snowflake;
112
+ /** The id of the Guild */
113
+ readonly guild_id?: Snowflake | null;
114
+ }
115
+ export declare enum ActivityLocationKind {
116
+ /** The Location is a Guild Channel */
117
+ GC = "'gc'",
118
+ /** The Location is a Private Channel, such as a DM or GDM */
119
+ PC = "'pc'"
120
+ }
93
121
  export interface ActivityParty {
94
122
  /** ID of the party */
95
123
  readonly id?: string;
@@ -247,21 +275,23 @@ export interface ApplicationCommand {
247
275
  readonly contexts?: Array<InteractionContextType> | null;
248
276
  /** Autoincrementing version identifier updated during substantial record changes */
249
277
  readonly version: Snowflake;
278
+ /** Determines whether the interaction is handled by the app's interactions handler or by Discord */
279
+ readonly handler?: EntryPointCommandHandlerType;
250
280
  }
251
281
  export interface ApplicationCommandDatum {
252
- /** the ID of the invoked command */
282
+ /** ID of the invoked command */
253
283
  readonly id: Snowflake;
254
- /** the name of the invoked command */
284
+ /** name of the invoked command */
255
285
  readonly name: string;
256
- /** the type of the invoked command */
286
+ /** type of the invoked command */
257
287
  readonly type: number;
258
- /** converted users + roles + channels + attachments */
288
+ /** Converted users + roles + channels + attachments */
259
289
  readonly resolved?: ResolvedDatum;
260
- /** the params + values from the user */
290
+ /** Params + values from the user */
261
291
  readonly options?: Array<ApplicationCommandInteractionDataOption>;
262
- /** the id of the guild the command is registered to */
292
+ /** ID of the guild the command is registered to */
263
293
  readonly guild_id?: Snowflake;
264
- /** id of the user or message targeted by a user or message command */
294
+ /** ID of the user or message targeted by a user or message command */
265
295
  readonly target_id?: Snowflake;
266
296
  }
267
297
  export interface ApplicationCommandInteractionDataOption {
@@ -347,7 +377,9 @@ export declare enum ApplicationCommandType {
347
377
  /** A UI-based command that shows up when you right click or tap on a user */
348
378
  USER = 2,
349
379
  /** A UI-based command that shows up when you right click or tap on a message */
350
- MESSAGE = 3
380
+ MESSAGE = 3,
381
+ /** A UI-based command that represents the primary way to invoke an app's Activity */
382
+ PRIMARY_ENTRY_POINT = 4
351
383
  }
352
384
  export declare const ApplicationFlag: {
353
385
  /** Indicates if an app uses the Auto Moderation API */
@@ -1564,7 +1596,7 @@ export interface Endpoints<O> {
1564
1596
  createGuildSticker: (guildId: string, params?: Partial<CreateGuildStickerParams>, options?: O) => RestResponse<Sticker>;
1565
1597
  /** Creates a template for the guild. Requires the MANAGE_GUILD permission. Returns the created guild template object on success. */
1566
1598
  createGuildTemplate: (guildId: string, params?: Partial<CreateGuildTemplateParams>, options?: O) => RestResponse<GuildTemplate>;
1567
- /** Create a response to an Interaction from the gateway. Body is an interaction response. Returns 204 No Content. */
1599
+ /** Create a response to an Interaction. Body is an interaction response. Returns 204 unless with_response is set to true which returns 200 with the body as interaction response. */
1568
1600
  createInteractionResponse: (interactionId: string, interactionToken: string, params?: Partial<InteractionResponse>, options?: O) => RestResponse<InteractionResponse>;
1569
1601
  createMessage: (channelId: string, params?: Partial<CreateMessageParams>, options?: O) => RestResponse<Message>;
1570
1602
  /** Create a reaction for the message. This endpoint requires the READ_MESSAGE_HISTORY permission to be present on the current user. Additionally, if nobody else has reacted to the message using this emoji, this endpoint requires the ADD_REACTIONS permission to be present on the current user. Returns a 204 empty response on success. Fires a Message Reaction Add Gateway event.
@@ -1660,6 +1692,8 @@ export interface Endpoints<O> {
1660
1692
  followAnnouncementChannel: (channelId: string, params?: Partial<FollowAnnouncementChannelParams>, options?: O) => RestResponse<FollowedChannel>;
1661
1693
  /** Get a list of users that voted for this specific answer. */
1662
1694
  getAnswerVoters: (channelId: string, messageId: string, answerId: string, params?: Partial<GetAnswerVoterParams>, options?: O) => RestResponse<GetAnswerVoterResponse>;
1695
+ /** Returns a serialized activity instance, if it exists. Useful for preventing unwanted activity sessions. */
1696
+ getApplicationActivityInstance: (applicationId: string, instanceId: string, options?: O) => RestResponse<any>;
1663
1697
  /** Fetches permissions for a specific command for your application in a guild. Returns a guild application command permissions object. */
1664
1698
  getApplicationCommandPermissions: (applicationId: string, guildId: string, commandId: string, options?: O) => RestResponse<GuildApplicationCommandPermission>;
1665
1699
  /** Returns an emoji object for the given application and emoji IDs. Includes the user field. */
@@ -1946,6 +1980,10 @@ export declare enum EntitlementType {
1946
1980
  APPLICATION_SUBSCRIPTION = 8
1947
1981
  }
1948
1982
  export type EntitlementUpdateEvent = Entitlement;
1983
+ export declare enum EntryPointCommandHandlerType {
1984
+ APP_HANDLER = 1,
1985
+ DISCORD_LAUNCH_ACTIVITY = 2
1986
+ }
1949
1987
  export declare enum EventType {
1950
1988
  /** when a member sends or edits a message in the guild */
1951
1989
  MESSAGE_SEND = 1,
@@ -2934,54 +2972,88 @@ export interface Interaction {
2934
2972
  /** Context where the interaction was triggered from */
2935
2973
  readonly context?: InteractionContextType;
2936
2974
  }
2975
+ export interface InteractionCallback {
2976
+ /** */
2977
+ readonly id: Snowflake;
2978
+ /** Interaction type */
2979
+ readonly type: InteractionType;
2980
+ /** Instance ID of the Activity if one was launched or joined */
2981
+ readonly activity_instance_id?: string;
2982
+ /** ID of the message that was created by the interaction */
2983
+ readonly response_message_id?: Snowflake;
2984
+ /** Whether or not the message is in a loading state */
2985
+ readonly response_message_loading?: boolean;
2986
+ /** Whether or not the response message was ephemeral */
2987
+ readonly response_message_ephemeral?: boolean;
2988
+ }
2989
+ export interface InteractionCallbackActivityInstanceResource {
2990
+ /** Instance ID of the Activity if one was launched or joined. */
2991
+ readonly id: string;
2992
+ }
2937
2993
  export interface InteractionCallbackAutocomplete {
2938
2994
  /** autocomplete choices (max of 25 choices) */
2939
2995
  readonly choices: Array<ApplicationCommandOptionChoice>;
2940
2996
  }
2941
2997
  export type InteractionCallbackDatum = InteractionCallbackAutocomplete | InteractionCallbackMessage | InteractionCallbackModal;
2942
2998
  export interface InteractionCallbackMessage {
2943
- /** is the response TTS */
2999
+ /** Whether the response is TTS */
2944
3000
  readonly tts?: boolean;
2945
- /** message content */
3001
+ /** Message content */
2946
3002
  readonly content?: string;
2947
- /** supports up to 10 embeds */
3003
+ /** Supports up to 10 embeds */
2948
3004
  readonly embeds?: Array<Embed>;
2949
- /** allowed mentions object */
3005
+ /** Allowed mentions object */
2950
3006
  readonly allowed_mentions?: AllowedMention;
2951
- /** message flags combined as a bitfield (only SUPPRESS_EMBEDS, EPHEMERAL, and SUPPRESS_NOTIFICATIONS can be set) */
3007
+ /** Message flags combined as a bitfield (only SUPPRESS_EMBEDS, EPHEMERAL, and SUPPRESS_NOTIFICATIONS can be set) */
2952
3008
  readonly flags?: number;
2953
- /** message components */
3009
+ /** Message components */
2954
3010
  readonly components?: Array<Component>;
2955
- /** attachment objects with filename and description */
3011
+ /** Attachment objects with filename and description */
2956
3012
  readonly attachments?: Array<Attachment>;
2957
- /** A poll! */
3013
+ /** Details about the poll */
2958
3014
  readonly poll?: PollCreateRequest;
2959
3015
  }
2960
3016
  export interface InteractionCallbackModal {
2961
- /** a developer-defined identifier for the modal, max 100 characters */
3017
+ /** Developer-defined identifier for the modal, max 100 characters */
2962
3018
  readonly custom_id: string;
2963
- /** the title of the popup modal, max 45 characters */
3019
+ /** Title of the popup modal, max 45 characters */
2964
3020
  readonly title: string;
2965
- /** between 1 and 5 (inclusive) components that make up the modal */
3021
+ /** Between 1 and 5 (inclusive) components that make up the modal */
2966
3022
  readonly components: Array<Component>;
2967
3023
  }
3024
+ export interface InteractionCallbackResource {
3025
+ /** Interaction callback type */
3026
+ readonly type: InteractionCallbackType;
3027
+ /** Represents the Activity launched by this interaction. */
3028
+ readonly activity_instance?: InteractionCallbackActivityInstanceResource;
3029
+ /** Message created by the interaction. */
3030
+ readonly message?: Message;
3031
+ }
3032
+ export interface InteractionCallbackResponse {
3033
+ /** The interaction object associated with the */
3034
+ readonly interaction: InteractionCallback;
3035
+ /** The resource that was created by the interaction response. */
3036
+ readonly resource?: InteractionCallbackResource;
3037
+ }
2968
3038
  export declare enum InteractionCallbackType {
2969
3039
  /** ACK a Ping */
2970
3040
  PONG = 1,
2971
- /** respond to an interaction with a message */
3041
+ /** Respond to an interaction with a message */
2972
3042
  CHANNEL_MESSAGE_WITH_SOURCE = 4,
2973
3043
  /** ACK an interaction and edit a response later, the user sees a loading state */
2974
3044
  DEFERRED_CHANNEL_MESSAGE_WITH_SOURCE = 5,
2975
- /** for components, ACK an interaction and edit the original message later; the user does not see a loading state */
3045
+ /** For components, ACK an interaction and edit the original message later; the user does not see a loading state */
2976
3046
  DEFERRED_UPDATE_MESSAGE = 6,
2977
- /** for components, edit the message the component was attached to */
3047
+ /** For components, edit the message the component was attached to */
2978
3048
  UPDATE_MESSAGE = 7,
2979
- /** respond to an autocomplete interaction with suggested choices */
3049
+ /** Respond to an autocomplete interaction with suggested choices */
2980
3050
  APPLICATION_COMMAND_AUTOCOMPLETE_RESULT = 8,
2981
- /** respond to an interaction with a popup modal */
3051
+ /** Respond to an interaction with a popup modal */
2982
3052
  MODAL = 9,
2983
3053
  /** Deprecated; respond to an interaction with an upgrade button, only available for apps with monetization enabled */
2984
- PREMIUM_REQUIRED = 10
3054
+ PREMIUM_REQUIRED = 10,
3055
+ /** Launch the Activity associated with the app. Only available for apps with Activities enabled */
3056
+ LAUNCH_ACTIVITY = 12
2985
3057
  }
2986
3058
  export declare enum InteractionContextType {
2987
3059
  /** Interaction can be used within servers */
@@ -2994,9 +3066,9 @@ export declare enum InteractionContextType {
2994
3066
  export type InteractionCreateEvent = Interaction;
2995
3067
  export type InteractionDatum = ApplicationCommandDatum | MessageComponentDatum | ModalSubmitDatum;
2996
3068
  export interface InteractionResponse {
2997
- /** the type of response */
3069
+ /** Type of response */
2998
3070
  readonly type: InteractionCallbackType;
2999
- /** an optional response message */
3071
+ /** An optional response message */
3000
3072
  readonly data?: InteractionCallbackDatum;
3001
3073
  }
3002
3074
  export declare enum InteractionType {
@@ -3337,13 +3409,13 @@ export interface MessageCall {
3337
3409
  readonly ended_timestamp?: string | null;
3338
3410
  }
3339
3411
  export interface MessageComponentDatum {
3340
- /** the custom_id of the component */
3412
+ /** custom_id of the component */
3341
3413
  readonly custom_id: string;
3342
- /** the type of the component */
3414
+ /** type of the component */
3343
3415
  readonly component_type: ComponentType;
3344
- /** values the user selected in a select menu component */
3416
+ /** Values the user selected in a select menu component */
3345
3417
  readonly values?: Array<SelectOption>;
3346
- /** resolved entities from selected options */
3418
+ /** Resolved entities from selected options */
3347
3419
  readonly resolved?: ResolvedDatum;
3348
3420
  }
3349
3421
  export type MessageCreateEvent = Message & MessageCreateExtra;
@@ -3572,9 +3644,9 @@ export declare enum MfaLevel {
3572
3644
  ELEVATED = 1
3573
3645
  }
3574
3646
  export interface ModalSubmitDatum {
3575
- /** the custom_id of the modal */
3647
+ /** custom_id of the modal */
3576
3648
  readonly custom_id: string;
3577
- /** the values submitted by the user */
3649
+ /** Values submitted by the user */
3578
3650
  readonly components: Array<Component>;
3579
3651
  }
3580
3652
  export interface ModifyApplicationEmojiParams {
@@ -4299,17 +4371,17 @@ export interface RequestGuildMember {
4299
4371
  readonly nonce?: string;
4300
4372
  }
4301
4373
  export interface ResolvedDatum {
4302
- /** the ids and User objects */
4374
+ /** IDs and User objects */
4303
4375
  readonly users?: Record<Snowflake, User>;
4304
- /** the ids and partial Member objects */
4376
+ /** IDs and partial Member objects */
4305
4377
  readonly members?: Record<Snowflake, GuildMember>;
4306
- /** the ids and Role objects */
4378
+ /** IDs and Role objects */
4307
4379
  readonly roles?: Record<Snowflake, Role>;
4308
- /** the ids and partial Channel objects */
4380
+ /** IDs and partial Channel objects */
4309
4381
  readonly channels?: Record<Snowflake, Channel>;
4310
- /** the ids and partial Message objects */
4382
+ /** IDs and partial Message objects */
4311
4383
  readonly messages?: Record<Snowflake, Message>;
4312
- /** the ids and attachment objects */
4384
+ /** IDs and attachment objects */
4313
4385
  readonly attachments?: Record<Snowflake, Attachment>;
4314
4386
  }
4315
4387
  export interface Response {