seyfert 1.3.1 → 1.3.3

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.
@@ -122,7 +122,13 @@ class RedisAdapter {
122
122
  await this.client.del(...keys.map(x => this.buildKey(x)));
123
123
  }
124
124
  async flush() {
125
- await this.remove(await Promise.all([this.scan(this.buildKey('*'), true), this.__scanSets(this.buildKey('*'), true)]).then(x => x.flat()));
125
+ const keys = await Promise.all([
126
+ this.scan(this.buildKey('*'), true),
127
+ this.__scanSets(this.buildKey('*'), true),
128
+ ]).then(x => x.flat());
129
+ if (!keys.length)
130
+ return;
131
+ await this.remove(keys);
126
132
  }
127
133
  async contains(to, keys) {
128
134
  return (await this.client.sismember(`${this.buildKey(to)}:set`, keys)) === 1;
@@ -6,7 +6,9 @@ const base_1 = require("./base");
6
6
  class InteractionShorter extends base_1.BaseShorter {
7
7
  async reply(id, token, body) {
8
8
  //@ts-expect-error
9
- const { files, ...data } = body.data ?? {};
9
+ const { files, ...rest } = body.data ?? {};
10
+ //@ts-expect-error
11
+ const data = body.data instanceof __1.Modal ? body.data : rest;
10
12
  return this.client.proxy
11
13
  .interactions(id)(token)
12
14
  .callback.post({
@@ -52,13 +52,13 @@ export type ObjectToLower<T> = Identify<{
52
52
  [K in keyof T as CamelCase<Exclude<K, symbol | number>>]: T[K] extends unknown[] ? Identify<ObjectToLower<T[K][0]>[]> : T[K] extends object ? Identify<ObjectToLower<T[K]>> : AuxIsStrictlyUndefined<T[K]> extends true ? undefined : ObjectToLowerUndefined<T[K]>;
53
53
  }>;
54
54
  export type ObjectToLowerUndefined<T> = T extends unknown[] ? ObjectToLower<T[0]>[] : Identify<{
55
- [K in keyof T as CamelCase<Exclude<K, symbol | number>>]?: T[K] extends unknown[] ? ObjectToLower<T[K][0]>[] : T[K] extends object ? ObjectToLower<T[K]> : T[K];
55
+ [K in keyof T as CamelCase<Exclude<K, symbol | number>>]: T[K] extends unknown[] ? ObjectToLower<T[K][0]>[] : T[K] extends object ? ObjectToLower<T[K]> : T[K];
56
56
  }>;
57
57
  export type ObjectToSnake<T> = Identify<{
58
58
  [K in keyof T as SnakeCase<Exclude<K, symbol | number>>]: T[K] extends unknown[] ? Identify<ObjectToSnake<T[K][0]>[]> : T[K] extends object ? Identify<ObjectToSnake<T[K]>> : AuxIsStrictlyUndefined<T[K]> extends true ? undefined : ObjectToSnakeUndefined<T[K]>;
59
59
  }>;
60
60
  export type ObjectToSnakeUndefined<T> = T extends unknown[] ? ObjectToSnake<T[0]>[] : Identify<{
61
- [K in keyof T as SnakeCase<Exclude<K, symbol | number>>]?: T[K] extends unknown[] ? ObjectToSnake<T[K][0]>[] : T[K] extends object ? ObjectToSnake<T[K]> : T[K];
61
+ [K in keyof T as SnakeCase<Exclude<K, symbol | number>>]: T[K] extends unknown[] ? ObjectToSnake<T[K][0]>[] : T[K] extends object ? ObjectToSnake<T[K]> : T[K];
62
62
  }>;
63
63
  export type UnionToTuple<U, A extends any[] = []> = (U extends void ? void : (arg: () => U) => never) extends (arg: infer I) => void ? I extends () => infer W ? UnionToTuple<Exclude<U, W>, [W, ...A]> : A : never;
64
64
  export type KeysWithUndefined<T> = {
@@ -10,6 +10,7 @@ export declare const ENTITLEMENT_CREATE: (_: BaseClient, data: APIEntitlement) =
10
10
  deleted: boolean;
11
11
  startsAt?: string | undefined;
12
12
  endsAt?: string | undefined;
13
+ consumed?: boolean | undefined;
13
14
  };
14
15
  export declare const ENTITLEMENT_UPDATE: (_: BaseClient, data: APIEntitlement) => {
15
16
  id: string;
@@ -21,6 +22,7 @@ export declare const ENTITLEMENT_UPDATE: (_: BaseClient, data: APIEntitlement) =
21
22
  deleted: boolean;
22
23
  startsAt?: string | undefined;
23
24
  endsAt?: string | undefined;
25
+ consumed?: boolean | undefined;
24
26
  };
25
27
  export declare const ENTITLEMENT_DELETE: (_: BaseClient, data: APIEntitlement) => {
26
28
  id: string;
@@ -32,4 +34,5 @@ export declare const ENTITLEMENT_DELETE: (_: BaseClient, data: APIEntitlement) =
32
34
  deleted: boolean;
33
35
  startsAt?: string | undefined;
34
36
  endsAt?: string | undefined;
37
+ consumed?: boolean | undefined;
35
38
  };
@@ -142,6 +142,22 @@ export declare const GUILD_AUDIT_LOG_ENTRY_CREATE: (_self: BaseClient, data: Gat
142
142
  key: "available";
143
143
  newValue?: boolean | undefined;
144
144
  oldValue?: boolean | undefined;
145
+ } | {
146
+ key: "available_tags";
147
+ newValue?: {
148
+ id: string;
149
+ name: string;
150
+ moderated: boolean;
151
+ emojiId: string | null;
152
+ emojiName: string | null;
153
+ }[] | undefined;
154
+ oldValue?: {
155
+ id: string;
156
+ name: string;
157
+ moderated: boolean;
158
+ emojiId: string | null;
159
+ emojiName: string | null;
160
+ }[] | undefined;
145
161
  } | {
146
162
  key: "avatar_hash";
147
163
  newValue?: string | undefined;
@@ -182,6 +198,20 @@ export declare const GUILD_AUDIT_LOG_ENTRY_CREATE: (_self: BaseClient, data: Gat
182
198
  key: "default_message_notifications";
183
199
  newValue?: import("discord-api-types/v10").GuildDefaultMessageNotifications | undefined;
184
200
  oldValue?: import("discord-api-types/v10").GuildDefaultMessageNotifications | undefined;
201
+ } | {
202
+ key: "default_reaction_emoji";
203
+ newValue?: {
204
+ emojiId: string | null;
205
+ emojiName: string | null;
206
+ } | undefined;
207
+ oldValue?: {
208
+ emojiId: string | null;
209
+ emojiName: string | null;
210
+ } | undefined;
211
+ } | {
212
+ key: "default_thread_rate_limit_per_user";
213
+ newValue?: number | undefined;
214
+ oldValue?: number | undefined;
185
215
  } | {
186
216
  key: "deny";
187
217
  newValue?: string | undefined;
@@ -230,6 +260,10 @@ export declare const GUILD_AUDIT_LOG_ENTRY_CREATE: (_self: BaseClient, data: Gat
230
260
  key: "explicit_content_filter";
231
261
  newValue?: import("discord-api-types/v10").GuildExplicitContentFilter | undefined;
232
262
  oldValue?: import("discord-api-types/v10").GuildExplicitContentFilter | undefined;
263
+ } | {
264
+ key: "flags";
265
+ newValue?: number | undefined;
266
+ oldValue?: number | undefined;
233
267
  } | {
234
268
  key: "format_type";
235
269
  newValue?: import("discord-api-types/v10").StickerFormatType | undefined;
@@ -516,7 +550,7 @@ export declare const GUILD_MEMBERS_CHUNK: (self: BaseClient, data: GatewayGuildM
516
550
  emoji?: {
517
551
  id?: string | null | undefined;
518
552
  animated?: boolean | undefined;
519
- name?: string | null | undefined;
553
+ name: string | null;
520
554
  } | undefined;
521
555
  sessionId?: string | undefined;
522
556
  party?: {
@@ -565,11 +599,11 @@ export declare const GUILD_SCHEDULED_EVENT_CREATE: (_self: BaseClient, data: Gat
565
599
  entityType: import("discord-api-types/v10").GuildScheduledEventEntityType.StageInstance;
566
600
  entityId: string | null;
567
601
  creator?: {
568
- id?: string | undefined;
569
- username?: string | undefined;
570
- discriminator?: string | undefined;
571
- globalName?: string | null | undefined;
572
- avatar?: string | null | undefined;
602
+ id: string;
603
+ username: string;
604
+ discriminator: string;
605
+ globalName: string | null;
606
+ avatar: string | null;
573
607
  bot?: boolean | undefined;
574
608
  system?: boolean | undefined;
575
609
  mfaEnabled?: boolean | undefined;
@@ -600,11 +634,11 @@ export declare const GUILD_SCHEDULED_EVENT_CREATE: (_self: BaseClient, data: Gat
600
634
  entityType: import("discord-api-types/v10").GuildScheduledEventEntityType.Voice;
601
635
  entityId: string | null;
602
636
  creator?: {
603
- id?: string | undefined;
604
- username?: string | undefined;
605
- discriminator?: string | undefined;
606
- globalName?: string | null | undefined;
607
- avatar?: string | null | undefined;
637
+ id: string;
638
+ username: string;
639
+ discriminator: string;
640
+ globalName: string | null;
641
+ avatar: string | null;
608
642
  bot?: boolean | undefined;
609
643
  system?: boolean | undefined;
610
644
  mfaEnabled?: boolean | undefined;
@@ -637,11 +671,11 @@ export declare const GUILD_SCHEDULED_EVENT_CREATE: (_self: BaseClient, data: Gat
637
671
  entityType: import("discord-api-types/v10").GuildScheduledEventEntityType.External;
638
672
  entityId: string | null;
639
673
  creator?: {
640
- id?: string | undefined;
641
- username?: string | undefined;
642
- discriminator?: string | undefined;
643
- globalName?: string | null | undefined;
644
- avatar?: string | null | undefined;
674
+ id: string;
675
+ username: string;
676
+ discriminator: string;
677
+ globalName: string | null;
678
+ avatar: string | null;
645
679
  bot?: boolean | undefined;
646
680
  system?: boolean | undefined;
647
681
  mfaEnabled?: boolean | undefined;
@@ -673,11 +707,11 @@ export declare const GUILD_SCHEDULED_EVENT_UPDATE: (_self: BaseClient, data: Gat
673
707
  entityType: import("discord-api-types/v10").GuildScheduledEventEntityType.StageInstance;
674
708
  entityId: string | null;
675
709
  creator?: {
676
- id?: string | undefined;
677
- username?: string | undefined;
678
- discriminator?: string | undefined;
679
- globalName?: string | null | undefined;
680
- avatar?: string | null | undefined;
710
+ id: string;
711
+ username: string;
712
+ discriminator: string;
713
+ globalName: string | null;
714
+ avatar: string | null;
681
715
  bot?: boolean | undefined;
682
716
  system?: boolean | undefined;
683
717
  mfaEnabled?: boolean | undefined;
@@ -708,11 +742,11 @@ export declare const GUILD_SCHEDULED_EVENT_UPDATE: (_self: BaseClient, data: Gat
708
742
  entityType: import("discord-api-types/v10").GuildScheduledEventEntityType.Voice;
709
743
  entityId: string | null;
710
744
  creator?: {
711
- id?: string | undefined;
712
- username?: string | undefined;
713
- discriminator?: string | undefined;
714
- globalName?: string | null | undefined;
715
- avatar?: string | null | undefined;
745
+ id: string;
746
+ username: string;
747
+ discriminator: string;
748
+ globalName: string | null;
749
+ avatar: string | null;
716
750
  bot?: boolean | undefined;
717
751
  system?: boolean | undefined;
718
752
  mfaEnabled?: boolean | undefined;
@@ -745,11 +779,11 @@ export declare const GUILD_SCHEDULED_EVENT_UPDATE: (_self: BaseClient, data: Gat
745
779
  entityType: import("discord-api-types/v10").GuildScheduledEventEntityType.External;
746
780
  entityId: string | null;
747
781
  creator?: {
748
- id?: string | undefined;
749
- username?: string | undefined;
750
- discriminator?: string | undefined;
751
- globalName?: string | null | undefined;
752
- avatar?: string | null | undefined;
782
+ id: string;
783
+ username: string;
784
+ discriminator: string;
785
+ globalName: string | null;
786
+ avatar: string | null;
753
787
  bot?: boolean | undefined;
754
788
  system?: boolean | undefined;
755
789
  mfaEnabled?: boolean | undefined;
@@ -781,11 +815,11 @@ export declare const GUILD_SCHEDULED_EVENT_DELETE: (_self: BaseClient, data: Gat
781
815
  entityType: import("discord-api-types/v10").GuildScheduledEventEntityType.StageInstance;
782
816
  entityId: string | null;
783
817
  creator?: {
784
- id?: string | undefined;
785
- username?: string | undefined;
786
- discriminator?: string | undefined;
787
- globalName?: string | null | undefined;
788
- avatar?: string | null | undefined;
818
+ id: string;
819
+ username: string;
820
+ discriminator: string;
821
+ globalName: string | null;
822
+ avatar: string | null;
789
823
  bot?: boolean | undefined;
790
824
  system?: boolean | undefined;
791
825
  mfaEnabled?: boolean | undefined;
@@ -816,11 +850,11 @@ export declare const GUILD_SCHEDULED_EVENT_DELETE: (_self: BaseClient, data: Gat
816
850
  entityType: import("discord-api-types/v10").GuildScheduledEventEntityType.Voice;
817
851
  entityId: string | null;
818
852
  creator?: {
819
- id?: string | undefined;
820
- username?: string | undefined;
821
- discriminator?: string | undefined;
822
- globalName?: string | null | undefined;
823
- avatar?: string | null | undefined;
853
+ id: string;
854
+ username: string;
855
+ discriminator: string;
856
+ globalName: string | null;
857
+ avatar: string | null;
824
858
  bot?: boolean | undefined;
825
859
  system?: boolean | undefined;
826
860
  mfaEnabled?: boolean | undefined;
@@ -853,11 +887,11 @@ export declare const GUILD_SCHEDULED_EVENT_DELETE: (_self: BaseClient, data: Gat
853
887
  entityType: import("discord-api-types/v10").GuildScheduledEventEntityType.External;
854
888
  entityId: string | null;
855
889
  creator?: {
856
- id?: string | undefined;
857
- username?: string | undefined;
858
- discriminator?: string | undefined;
859
- globalName?: string | null | undefined;
860
- avatar?: string | null | undefined;
890
+ id: string;
891
+ username: string;
892
+ discriminator: string;
893
+ globalName: string | null;
894
+ avatar: string | null;
861
895
  bot?: boolean | undefined;
862
896
  system?: boolean | undefined;
863
897
  mfaEnabled?: boolean | undefined;
@@ -11,11 +11,11 @@ export declare const INTEGRATION_CREATE: (self: BaseClient, data: GatewayIntegra
11
11
  expireBehavior?: import("discord-api-types/v10").IntegrationExpireBehavior | undefined;
12
12
  expireGracePeriod?: number | undefined;
13
13
  user?: {
14
- id?: string | undefined;
15
- username?: string | undefined;
16
- discriminator?: string | undefined;
17
- globalName?: string | null | undefined;
18
- avatar?: string | null | undefined;
14
+ id: string;
15
+ username: string;
16
+ discriminator: string;
17
+ globalName: string | null;
18
+ avatar: string | null;
19
19
  bot?: boolean | undefined;
20
20
  system?: boolean | undefined;
21
21
  mfaEnabled?: boolean | undefined;
@@ -37,10 +37,10 @@ export declare const INTEGRATION_CREATE: (self: BaseClient, data: GatewayIntegra
37
37
  subscriberCount?: number | undefined;
38
38
  revoked?: boolean | undefined;
39
39
  application?: {
40
- id?: string | undefined;
41
- name?: string | undefined;
42
- icon?: string | null | undefined;
43
- description?: string | undefined;
40
+ id: string;
41
+ name: string;
42
+ icon: string | null;
43
+ description: string;
44
44
  bot?: import("discord-api-types/v10").APIUser | undefined;
45
45
  } | undefined;
46
46
  scopes?: import("discord-api-types/v10").OAuth2Scopes[] | undefined;
@@ -57,11 +57,11 @@ export declare const INTEGRATION_UPDATE: (self: BaseClient, data: GatewayIntegra
57
57
  expireBehavior?: import("discord-api-types/v10").IntegrationExpireBehavior | undefined;
58
58
  expireGracePeriod?: number | undefined;
59
59
  user?: {
60
- id?: string | undefined;
61
- username?: string | undefined;
62
- discriminator?: string | undefined;
63
- globalName?: string | null | undefined;
64
- avatar?: string | null | undefined;
60
+ id: string;
61
+ username: string;
62
+ discriminator: string;
63
+ globalName: string | null;
64
+ avatar: string | null;
65
65
  bot?: boolean | undefined;
66
66
  system?: boolean | undefined;
67
67
  mfaEnabled?: boolean | undefined;
@@ -83,10 +83,10 @@ export declare const INTEGRATION_UPDATE: (self: BaseClient, data: GatewayIntegra
83
83
  subscriberCount?: number | undefined;
84
84
  revoked?: boolean | undefined;
85
85
  application?: {
86
- id?: string | undefined;
87
- name?: string | undefined;
88
- icon?: string | null | undefined;
89
- description?: string | undefined;
86
+ id: string;
87
+ name: string;
88
+ icon: string | null;
89
+ description: string;
90
90
  bot?: import("discord-api-types/v10").APIUser | undefined;
91
91
  } | undefined;
92
92
  scopes?: import("discord-api-types/v10").OAuth2Scopes[] | undefined;
@@ -6,11 +6,11 @@ export declare const INVITE_CREATE: (_self: BaseClient, data: GatewayInviteCreat
6
6
  createdAt: number;
7
7
  guildId?: string | undefined;
8
8
  inviter?: {
9
- id?: string | undefined;
10
- username?: string | undefined;
11
- discriminator?: string | undefined;
12
- globalName?: string | null | undefined;
13
- avatar?: string | null | undefined;
9
+ id: string;
10
+ username: string;
11
+ discriminator: string;
12
+ globalName: string | null;
13
+ avatar: string | null;
14
14
  bot?: boolean | undefined;
15
15
  system?: boolean | undefined;
16
16
  mfaEnabled?: boolean | undefined;
@@ -28,11 +28,11 @@ export declare const INVITE_CREATE: (_self: BaseClient, data: GatewayInviteCreat
28
28
  maxUses: number;
29
29
  targetType?: import("discord-api-types/v10").InviteTargetType | undefined;
30
30
  targetUser?: {
31
- id?: string | undefined;
32
- username?: string | undefined;
33
- discriminator?: string | undefined;
34
- globalName?: string | null | undefined;
35
- avatar?: string | null | undefined;
31
+ id: string;
32
+ username: string;
33
+ discriminator: string;
34
+ globalName: string | null;
35
+ avatar: string | null;
36
36
  bot?: boolean | undefined;
37
37
  system?: boolean | undefined;
38
38
  mfaEnabled?: boolean | undefined;
@@ -18,11 +18,11 @@ export declare const MESSAGE_REACTION_ADD: (_self: BaseClient, data: GatewayMess
18
18
  emoji: {
19
19
  roles?: string[] | undefined;
20
20
  user?: {
21
- id?: string | undefined;
22
- username?: string | undefined;
23
- discriminator?: string | undefined;
24
- globalName?: string | null | undefined;
25
- avatar?: string | null | undefined;
21
+ id: string;
22
+ username: string;
23
+ discriminator: string;
24
+ globalName: string | null;
25
+ avatar: string | null;
26
26
  bot?: boolean | undefined;
27
27
  system?: boolean | undefined;
28
28
  mfaEnabled?: boolean | undefined;
@@ -50,12 +50,12 @@ export declare const MESSAGE_REACTION_ADD: (_self: BaseClient, data: GatewayMess
50
50
  user?: import("discord-api-types/v10").APIUser | undefined;
51
51
  nick?: string | null | undefined;
52
52
  avatar?: string | null | undefined;
53
- roles?: string[] | undefined;
54
- joinedAt?: string | undefined;
53
+ roles: string[];
54
+ joinedAt: string;
55
55
  premiumSince?: string | null | undefined;
56
- deaf?: boolean | undefined;
57
- mute?: boolean | undefined;
58
- flags?: import("discord-api-types/v10").GuildMemberFlags | undefined;
56
+ deaf: boolean;
57
+ mute: boolean;
58
+ flags: import("discord-api-types/v10").GuildMemberFlags;
59
59
  pending?: boolean | undefined;
60
60
  communicationDisabledUntil?: string | null | undefined;
61
61
  } | undefined;
@@ -66,11 +66,11 @@ export declare const MESSAGE_REACTION_REMOVE: (_self: BaseClient, data: GatewayM
66
66
  emoji: {
67
67
  roles?: string[] | undefined;
68
68
  user?: {
69
- id?: string | undefined;
70
- username?: string | undefined;
71
- discriminator?: string | undefined;
72
- globalName?: string | null | undefined;
73
- avatar?: string | null | undefined;
69
+ id: string;
70
+ username: string;
71
+ discriminator: string;
72
+ globalName: string | null;
73
+ avatar: string | null;
74
74
  bot?: boolean | undefined;
75
75
  system?: boolean | undefined;
76
76
  mfaEnabled?: boolean | undefined;
@@ -105,11 +105,11 @@ export declare const MESSAGE_REACTION_REMOVE_EMOJI: (_self: BaseClient, data: Ga
105
105
  emoji: {
106
106
  roles?: string[] | undefined;
107
107
  user?: {
108
- id?: string | undefined;
109
- username?: string | undefined;
110
- discriminator?: string | undefined;
111
- globalName?: string | null | undefined;
112
- avatar?: string | null | undefined;
108
+ id: string;
109
+ username: string;
110
+ discriminator: string;
111
+ globalName: string | null;
112
+ avatar: string | null;
113
113
  bot?: boolean | undefined;
114
114
  system?: boolean | undefined;
115
115
  mfaEnabled?: boolean | undefined;
@@ -40,7 +40,7 @@ export declare const PRESENCE_UPDATE: (_self: BaseClient, data: GatewayPresenceU
40
40
  emoji?: {
41
41
  id?: string | null | undefined;
42
42
  animated?: boolean | undefined;
43
- name?: string | null | undefined;
43
+ name: string | null;
44
44
  } | undefined;
45
45
  sessionId?: string | undefined;
46
46
  party?: {
@@ -48,8 +48,8 @@ export declare const THREAD_LIST_SYNC: (_self: BaseClient, data: GatewayThreadLi
48
48
  }[];
49
49
  defaultThreadRateLimitPerUser?: number | undefined;
50
50
  defaultReactionEmoji: {
51
- emojiId?: string | null | undefined;
52
- emojiName?: string | null | undefined;
51
+ emojiId: string | null;
52
+ emojiName: string | null;
53
53
  } | null;
54
54
  defaultSortOrder: import("discord-api-types/v10").SortOrderType | null;
55
55
  name: string;
@@ -147,8 +147,8 @@ export declare const THREAD_LIST_SYNC: (_self: BaseClient, data: GatewayThreadLi
147
147
  }[];
148
148
  defaultThreadRateLimitPerUser?: number | undefined;
149
149
  defaultReactionEmoji: {
150
- emojiId?: string | null | undefined;
151
- emojiName?: string | null | undefined;
150
+ emojiId: string | null;
151
+ emojiName: string | null;
152
152
  } | null;
153
153
  defaultSortOrder: import("discord-api-types/v10").SortOrderType | null;
154
154
  name: string;
@@ -232,14 +232,14 @@ export declare const THREAD_LIST_SYNC: (_self: BaseClient, data: GatewayThreadLi
232
232
  member?: {
233
233
  id?: string | undefined;
234
234
  userId?: string | undefined;
235
- joinTimestamp?: string | undefined;
236
- flags?: import("discord-api-types/v10").ThreadMemberFlags | undefined;
235
+ joinTimestamp: string;
236
+ flags: import("discord-api-types/v10").ThreadMemberFlags;
237
237
  member?: import("discord-api-types/v10").APIGuildMember | undefined;
238
238
  } | undefined;
239
239
  threadMetadata?: {
240
- archived?: boolean | undefined;
241
- autoArchiveDuration?: import("discord-api-types/v10").ThreadAutoArchiveDuration | undefined;
242
- archiveTimestamp?: string | undefined;
240
+ archived: boolean;
241
+ autoArchiveDuration: import("discord-api-types/v10").ThreadAutoArchiveDuration;
242
+ archiveTimestamp: string;
243
243
  locked?: boolean | undefined;
244
244
  invitable?: boolean | undefined;
245
245
  createTimestamp?: string | undefined;
@@ -276,12 +276,12 @@ export declare const THREAD_LIST_SYNC: (_self: BaseClient, data: GatewayThreadLi
276
276
  user?: import("discord-api-types/v10").APIUser | undefined;
277
277
  nick?: string | null | undefined;
278
278
  avatar?: string | null | undefined;
279
- roles?: string[] | undefined;
280
- joinedAt?: string | undefined;
279
+ roles: string[];
280
+ joinedAt: string;
281
281
  premiumSince?: string | null | undefined;
282
- deaf?: boolean | undefined;
283
- mute?: boolean | undefined;
284
- flags?: import("discord-api-types/v10").GuildMemberFlags | undefined;
282
+ deaf: boolean;
283
+ mute: boolean;
284
+ flags: import("discord-api-types/v10").GuildMemberFlags;
285
285
  pending?: boolean | undefined;
286
286
  communicationDisabledUntil?: string | null | undefined;
287
287
  } | undefined;
@@ -296,12 +296,12 @@ export declare const THREAD_MEMBER_UPDATE: (_self: BaseClient, data: GatewayThre
296
296
  user?: import("discord-api-types/v10").APIUser | undefined;
297
297
  nick?: string | null | undefined;
298
298
  avatar?: string | null | undefined;
299
- roles?: string[] | undefined;
300
- joinedAt?: string | undefined;
299
+ roles: string[];
300
+ joinedAt: string;
301
301
  premiumSince?: string | null | undefined;
302
- deaf?: boolean | undefined;
303
- mute?: boolean | undefined;
304
- flags?: import("discord-api-types/v10").GuildMemberFlags | undefined;
302
+ deaf: boolean;
303
+ mute: boolean;
304
+ flags: import("discord-api-types/v10").GuildMemberFlags;
305
305
  pending?: boolean | undefined;
306
306
  communicationDisabledUntil?: string | null | undefined;
307
307
  } | undefined;
@@ -320,12 +320,12 @@ export declare const THREAD_MEMBERS_UPDATE: (_self: BaseClient, data: GatewayThr
320
320
  user?: import("discord-api-types/v10").APIUser | undefined;
321
321
  nick?: string | null | undefined;
322
322
  avatar?: string | null | undefined;
323
- roles?: string[] | undefined;
324
- joinedAt?: string | undefined;
323
+ roles: string[];
324
+ joinedAt: string;
325
325
  premiumSince?: string | null | undefined;
326
- deaf?: boolean | undefined;
327
- mute?: boolean | undefined;
328
- flags?: import("discord-api-types/v10").GuildMemberFlags | undefined;
326
+ deaf: boolean;
327
+ mute: boolean;
328
+ flags: import("discord-api-types/v10").GuildMemberFlags;
329
329
  pending?: boolean | undefined;
330
330
  communicationDisabledUntil?: string | null | undefined;
331
331
  } | undefined;
@@ -10,12 +10,12 @@ export declare const TYPING_START: (self: BaseClient, data: GatewayTypingStartDi
10
10
  user?: import("discord-api-types/v10").APIUser | undefined;
11
11
  nick?: string | null | undefined;
12
12
  avatar?: string | null | undefined;
13
- roles?: string[] | undefined;
14
- joinedAt?: string | undefined;
13
+ roles: string[];
14
+ joinedAt: string;
15
15
  premiumSince?: string | null | undefined;
16
- deaf?: boolean | undefined;
17
- mute?: boolean | undefined;
18
- flags?: import("discord-api-types/v10").GuildMemberFlags | undefined;
16
+ deaf: boolean;
17
+ mute: boolean;
18
+ flags: import("discord-api-types/v10").GuildMemberFlags;
19
19
  pending?: boolean | undefined;
20
20
  communicationDisabledUntil?: string | null | undefined;
21
21
  } | undefined;
@@ -14,12 +14,12 @@ export declare const VOICE_STATE_UPDATE: (self: BaseClient, data: GatewayVoiceSt
14
14
  user?: import("discord-api-types/v10").APIUser | undefined;
15
15
  nick?: string | null | undefined;
16
16
  avatar?: string | null | undefined;
17
- roles?: string[] | undefined;
18
- joinedAt?: string | undefined;
17
+ roles: string[];
18
+ joinedAt: string;
19
19
  premiumSince?: string | null | undefined;
20
- deaf?: boolean | undefined;
21
- mute?: boolean | undefined;
22
- flags?: import("discord-api-types/v10").GuildMemberFlags | undefined;
20
+ deaf: boolean;
21
+ mute: boolean;
22
+ flags: import("discord-api-types/v10").GuildMemberFlags;
23
23
  pending?: boolean | undefined;
24
24
  communicationDisabledUntil?: string | null | undefined;
25
25
  } | undefined;
@@ -100,7 +100,9 @@ class BaseInteraction extends DiscordBase_1.DiscordBase {
100
100
  async matchReplied(body) {
101
101
  if (this.__reply) {
102
102
  //@ts-expect-error
103
- const { files, ...data } = body.data ?? {};
103
+ const { files, ...rest } = body.data ?? {};
104
+ //@ts-expect-error
105
+ const data = body.data instanceof builders_1.Modal ? body.data : rest;
104
106
  return (this.replied = this.__reply({
105
107
  body: BaseInteraction.transformBodyRequest({ data, type: body.type }),
106
108
  files: files ? await (0, builders_1.resolveFiles)(files) : undefined,
@@ -49,8 +49,8 @@ export declare class Message extends BaseMessage {
49
49
  delete(reason?: string): Promise<void>;
50
50
  crosspost(reason?: string): Promise<Message>;
51
51
  }
52
- export type EditMessageWebhook = Omit<MessageWebhookMethodEditParams, 'messageId'>;
53
- export type WriteMessageWebhook = MessageWebhookMethodWriteParams;
52
+ export type EditMessageWebhook = Omit<MessageWebhookMethodEditParams, 'messageId'>['body'] & Pick<MessageWebhookMethodEditParams, 'query'>;
53
+ export type WriteMessageWebhook = MessageWebhookMethodWriteParams['body'] & Pick<MessageWebhookMethodWriteParams, 'query'>;
54
54
  export declare class WebhookMessage extends BaseMessage {
55
55
  readonly webhookId: string;
56
56
  readonly webhookToken: string;
@@ -122,10 +122,19 @@ class WebhookMessage extends BaseMessage {
122
122
  return this.api.webhooks(this.webhookId)(this.webhookToken).get({ query: this.thread?.id });
123
123
  }
124
124
  edit(body) {
125
- return this.client.webhooks.editMessage(this.webhookId, this.webhookToken, { ...body, messageId: this.id });
125
+ const { query, ...rest } = body;
126
+ return this.client.webhooks.editMessage(this.webhookId, this.webhookToken, {
127
+ body: rest,
128
+ query,
129
+ messageId: this.id,
130
+ });
126
131
  }
127
132
  write(body) {
128
- return this.client.webhooks.writeMessage(this.webhookId, this.webhookToken, body);
133
+ const { query, ...rest } = body;
134
+ return this.client.webhooks.writeMessage(this.webhookId, this.webhookToken, {
135
+ body: rest,
136
+ query,
137
+ });
129
138
  }
130
139
  delete(reason) {
131
140
  return this.client.webhooks.deleteMessage(this.webhookId, this.webhookToken, this.id, reason);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "seyfert",
3
- "version": "1.3.1",
3
+ "version": "1.3.3",
4
4
  "description": "The most advanced framework for discord bots",
5
5
  "main": "./lib/index.js",
6
6
  "module": "./lib/index.js",
@@ -71,4 +71,4 @@
71
71
  "url": "https://github.com/socram03"
72
72
  }
73
73
  ]
74
- }
74
+ }