Compare commits

...

27 Commits

Author SHA1 Message Date
almeidx
83df57b45a fix(Interactions): add missing fields to types
Add `messages` to `APIInteractionDataResolved` and `id` to
`APIMessageComponentBaseInteractionData` per Discord API docs.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-19 16:39:18 +00:00
Almeida
a4aa724eb8 fix(Channel): correct PATCH channel field nullability (#1575)
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-19 13:08:49 +02:00
Almeida
dea22dc487 fix(poll): mark expiry as nullable (#1576)
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-19 13:08:37 +02:00
Almeida
cf6476dc8a fix(Guild): correct optionality and nullability (#1574)
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-19 13:08:15 +02:00
Almeida
f76c2fa249 fix: split grouped gateway dispatch types (#1563) 2026-03-19 10:04:56 +00:00
Almeida
0000e9afe3 fix: role colors optionality, color deprecation, and stale annotations (#1566)
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-19 09:40:56 +02:00
kshitijanurag
c3b331d80a feat(message): shared client themes (#1565) 2026-03-19 09:40:28 +02:00
Almeida
f1a3cb7bb7 fix: send soundboard result type (#1568) 2026-03-19 09:37:28 +02:00
Almeida
38b9467178 fix(Gateway): invite create timestamp type, zstd-stream (#1569)
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-19 09:37:05 +02:00
Almeida
32b544e05e chore: run clean:node on pre-commit (#1564) 2026-03-19 09:36:39 +02:00
Almeida
e1ff008cd6 feat(Application): add webhook event fields to PATCH (#1570)
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-19 09:35:34 +02:00
Almeida
46b8cbd46f feat(Guild): add flags to modify guild member (#1571)
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-19 09:35:15 +02:00
Almeida
c8ef2fefde feat(Guild): add collectibles to guild member (#1572)
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-19 09:35:02 +02:00
Almeida
bf12195401 fix(guildScheduledEvent): entity_type required, channel_id nullable (#1573)
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-19 09:34:45 +02:00
kshitijanurag
a73d1d0ce2 docs: update TSDoc comments for PermissionFlagsBits (#1558) 2026-03-17 01:36:23 +02:00
renovate[bot]
17eade718c chore(deps): update crazy-max/ghaction-github-labeler action to v6 (#1552)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-03-17 01:35:55 +02:00
dependabot[bot]
c242454e9f chore(deps): bump immutable from 5.0.3 to 5.1.5 in /website (#1545)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-17 01:34:45 +02:00
dependabot[bot]
6dc3caa692 chore(deps): bump svgo from 3.3.2 to 3.3.3 in /website (#1546)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-17 01:34:34 +02:00
kshitijanurag
6b47a0c960 docs(channel): update slowmode bypass permission information (#1562) 2026-03-17 01:34:21 +02:00
renovate[bot]
e9169b8acb chore(deps): lock file maintenance (#1561)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-03-13 08:52:09 +00:00
renovate[bot]
d7a38425c0 chore(deps): update patch/minor dependencies (#1560)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-03-13 06:15:34 +00:00
Vlad Frangu
8190a1a475 chore(release): 0.38.42 🎉 (#1557)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-03-09 23:24:31 +02:00
advaith
818b899f9d feat: mark new modal components as stable (#1556) 2026-03-09 13:19:42 +02:00
renovate[bot]
61788ced57 chore(deps): lock file maintenance (#1555)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-03-06 13:51:38 +00:00
renovate[bot]
f6ae280ab5 chore(deps): update dependency @types/node to v24.12.0 (#1554)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-03-06 13:50:16 +00:00
renovate[bot]
6708005f0c chore(deps): lock file maintenance (#1553)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-03-06 09:02:14 +00:00
renovate[bot]
9b00e9d441 chore(deps): update patch/minor dependencies (#1551)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-03-06 05:10:57 +00:00
75 changed files with 1953 additions and 1536 deletions

View File

@@ -67,7 +67,7 @@ jobs:
with:
swap-size-gb: 10
- uses: pnpm/action-setup@v4.2.0
- uses: pnpm/action-setup@v4.3.0
name: Install pnpm
with:
run_install: false

View File

@@ -17,6 +17,6 @@ jobs:
uses: actions/checkout@v6
- name: Label sync
uses: crazy-max/ghaction-github-labeler@v5
uses: crazy-max/ghaction-github-labeler@v6
with:
github-token: ${{ secrets.GITHUB_TOKEN }}

View File

@@ -1 +1 @@
yarn pretty-quick --staged && yarn lint-staged && yarn build:deno && git add deno
yarn pretty-quick --staged && yarn lint-staged && yarn clean:node && yarn build:deno && git add deno

View File

@@ -1,3 +1,10 @@
## [0.38.42](https://github.com/discordjs/discord-api-types/compare/0.38.41...0.38.42) (2026-03-09)
### Features
* mark new modal components as stable ([#1556](https://github.com/discordjs/discord-api-types/issues/1556)) ([818b899](https://github.com/discordjs/discord-api-types/commit/818b899f9dd8f93c93168550ba08976888927f77))
## [0.38.41](https://github.com/discordjs/discord-api-types/compare/0.38.40...0.38.41) (2026-03-05)

7
deno/CHANGELOG.md generated
View File

@@ -1,3 +1,10 @@
## [0.38.42](https://github.com/discordjs/discord-api-types/compare/0.38.41...0.38.42) (2026-03-09)
### Features
* mark new modal components as stable ([#1556](https://github.com/discordjs/discord-api-types/issues/1556)) ([818b899](https://github.com/discordjs/discord-api-types/commit/818b899f9dd8f93c93168550ba08976888927f77))
## [0.38.41](https://github.com/discordjs/discord-api-types/compare/0.38.40...0.38.41) (2026-03-05)

View File

@@ -4,5 +4,5 @@
export interface GatewayURLQuery {
v: string;
encoding: 'etf' | 'json';
compress?: 'zlib-stream';
compress?: 'zlib-stream' | 'zstd-stream';
}

102
deno/gateway/v10.ts generated
View File

@@ -331,12 +331,17 @@ export type GatewayDispatchPayload =
| GatewayAutoModerationActionExecutionDispatch
| GatewayAutoModerationRuleCreateDispatch
| GatewayAutoModerationRuleDeleteDispatch
| GatewayAutoModerationRuleModifyDispatch
| GatewayChannelModifyDispatch
| GatewayAutoModerationRuleUpdateDispatch
| GatewayChannelCreateDispatch
| GatewayChannelDeleteDispatch
| GatewayChannelPinsUpdateDispatch
| GatewayEntitlementModifyDispatch
| GatewayChannelUpdateDispatch
| GatewayEntitlementCreateDispatch
| GatewayEntitlementDeleteDispatch
| GatewayEntitlementUpdateDispatch
| GatewayGuildAuditLogEntryCreateDispatch
| GatewayGuildBanModifyDispatch
| GatewayGuildBanAddDispatch
| GatewayGuildBanRemoveDispatch
| GatewayGuildCreateDispatch
| GatewayGuildDeleteDispatch
| GatewayGuildEmojisUpdateDispatch
@@ -346,8 +351,9 @@ export type GatewayDispatchPayload =
| GatewayGuildMembersChunkDispatch
| GatewayGuildMemberUpdateDispatch
| GatewayGuildModifyDispatch
| GatewayGuildRoleCreateDispatch
| GatewayGuildRoleDeleteDispatch
| GatewayGuildRoleModifyDispatch
| GatewayGuildRoleUpdateDispatch
| GatewayGuildScheduledEventCreateDispatch
| GatewayGuildScheduledEventDeleteDispatch
| GatewayGuildScheduledEventUpdateDispatch
@@ -382,7 +388,9 @@ export type GatewayDispatchPayload =
| GatewayStageInstanceCreateDispatch
| GatewayStageInstanceDeleteDispatch
| GatewayStageInstanceUpdateDispatch
| GatewaySubscriptionModifyDispatch
| GatewaySubscriptionCreateDispatch
| GatewaySubscriptionDeleteDispatch
| GatewaySubscriptionUpdateDispatch
| GatewayThreadCreateDispatch
| GatewayThreadDeleteDispatch
| GatewayThreadListSyncDispatch
@@ -529,7 +537,10 @@ export type GatewayAutoModerationRuleModifyDispatchData = APIAutoModerationRule;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#auto-moderation-rule-create}
*/
export type GatewayAutoModerationRuleCreateDispatch = GatewayAutoModerationRuleModifyDispatch;
export type GatewayAutoModerationRuleCreateDispatch = _DataPayload<
GatewayDispatchEvents.AutoModerationRuleCreate,
GatewayAutoModerationRuleCreateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#auto-moderation-rule-create}
@@ -539,7 +550,10 @@ export type GatewayAutoModerationRuleCreateDispatchData = GatewayAutoModerationR
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#auto-moderation-rule-update}
*/
export type GatewayAutoModerationRuleUpdateDispatch = GatewayAutoModerationRuleModifyDispatch;
export type GatewayAutoModerationRuleUpdateDispatch = _DataPayload<
GatewayDispatchEvents.AutoModerationRuleUpdate,
GatewayAutoModerationRuleUpdateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#auto-moderation-rule-update}
@@ -549,7 +563,10 @@ export type GatewayAutoModerationRuleUpdateDispatchData = GatewayAutoModerationR
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#auto-moderation-rule-delete}
*/
export type GatewayAutoModerationRuleDeleteDispatch = GatewayAutoModerationRuleModifyDispatch;
export type GatewayAutoModerationRuleDeleteDispatch = _DataPayload<
GatewayDispatchEvents.AutoModerationRuleDelete,
GatewayAutoModerationRuleDeleteDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#auto-moderation-rule-delete}
@@ -674,7 +691,10 @@ export type GatewaySubscriptionModifyDispatchData = APISubscription;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#subscription-create}
*/
export type GatewaySubscriptionCreateDispatch = GatewaySubscriptionModifyDispatch;
export type GatewaySubscriptionCreateDispatch = _DataPayload<
GatewayDispatchEvents.SubscriptionCreate,
GatewaySubscriptionCreateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#subscription-create}
@@ -684,7 +704,10 @@ export type GatewaySubscriptionCreateDispatchData = GatewaySubscriptionModifyDis
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#subscription-update}
*/
export type GatewaySubscriptionUpdateDispatch = GatewaySubscriptionModifyDispatch;
export type GatewaySubscriptionUpdateDispatch = _DataPayload<
GatewayDispatchEvents.SubscriptionUpdate,
GatewaySubscriptionUpdateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#subscription-update}
@@ -694,7 +717,10 @@ export type GatewaySubscriptionUpdateDispatchData = GatewaySubscriptionModifyDis
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#subscription-delete}
*/
export type GatewaySubscriptionDeleteDispatch = GatewaySubscriptionModifyDispatch;
export type GatewaySubscriptionDeleteDispatch = _DataPayload<
GatewayDispatchEvents.SubscriptionDelete,
GatewaySubscriptionDeleteDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#subscription-delete}
@@ -724,7 +750,10 @@ export type GatewayChannelModifyDispatchData = APIChannel & {
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#channel-create}
*/
export type GatewayChannelCreateDispatch = GatewayChannelModifyDispatch;
export type GatewayChannelCreateDispatch = _DataPayload<
GatewayDispatchEvents.ChannelCreate,
GatewayChannelCreateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#channel-create}
@@ -734,7 +763,10 @@ export type GatewayChannelCreateDispatchData = GatewayChannelModifyDispatchData;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#channel-update}
*/
export type GatewayChannelUpdateDispatch = GatewayChannelModifyDispatch;
export type GatewayChannelUpdateDispatch = _DataPayload<
GatewayDispatchEvents.ChannelUpdate,
GatewayChannelUpdateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#channel-update}
@@ -744,7 +776,10 @@ export type GatewayChannelUpdateDispatchData = GatewayChannelModifyDispatchData;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#channel-delete}
*/
export type GatewayChannelDeleteDispatch = GatewayChannelModifyDispatch;
export type GatewayChannelDeleteDispatch = _DataPayload<
GatewayDispatchEvents.ChannelDelete,
GatewayChannelDeleteDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#channel-delete}
@@ -804,7 +839,10 @@ export type GatewayEntitlementCreateDispatchData = GatewayEntitlementModifyDispa
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#entitlement-create}
*/
export type GatewayEntitlementCreateDispatch = GatewayEntitlementModifyDispatch;
export type GatewayEntitlementCreateDispatch = _DataPayload<
GatewayDispatchEvents.EntitlementCreate,
GatewayEntitlementCreateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#entitlement-update}
@@ -814,7 +852,10 @@ export type GatewayEntitlementUpdateDispatchData = GatewayEntitlementModifyDispa
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#entitlement-update}
*/
export type GatewayEntitlementUpdateDispatch = GatewayEntitlementModifyDispatch;
export type GatewayEntitlementUpdateDispatch = _DataPayload<
GatewayDispatchEvents.EntitlementUpdate,
GatewayEntitlementUpdateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#entitlement-delete}
@@ -824,7 +865,10 @@ export type GatewayEntitlementDeleteDispatchData = GatewayEntitlementModifyDispa
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#entitlement-delete}
*/
export type GatewayEntitlementDeleteDispatch = GatewayEntitlementModifyDispatch;
export type GatewayEntitlementDeleteDispatch = _DataPayload<
GatewayDispatchEvents.EntitlementDelete,
GatewayEntitlementDeleteDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#guild-update}
@@ -999,7 +1043,10 @@ export interface GatewayGuildBanModifyDispatchData {
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#guild-ban-add}
*/
export type GatewayGuildBanAddDispatch = GatewayGuildBanModifyDispatch;
export type GatewayGuildBanAddDispatch = _DataPayload<
GatewayDispatchEvents.GuildBanAdd,
GatewayGuildBanAddDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#guild-ban-add}
@@ -1009,7 +1056,10 @@ export type GatewayGuildBanAddDispatchData = GatewayGuildBanModifyDispatchData;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#guild-ban-remove}
*/
export type GatewayGuildBanRemoveDispatch = GatewayGuildBanModifyDispatch;
export type GatewayGuildBanRemoveDispatch = _DataPayload<
GatewayDispatchEvents.GuildBanRemove,
GatewayGuildBanRemoveDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#guild-ban-remove}
@@ -1226,7 +1276,10 @@ export interface GatewayGuildRoleModifyDispatchData {
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#guild-role-create}
*/
export type GatewayGuildRoleCreateDispatch = GatewayGuildRoleModifyDispatch;
export type GatewayGuildRoleCreateDispatch = _DataPayload<
GatewayDispatchEvents.GuildRoleCreate,
GatewayGuildRoleCreateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#guild-role-create}
@@ -1236,7 +1289,10 @@ export type GatewayGuildRoleCreateDispatchData = GatewayGuildRoleModifyDispatchD
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#guild-role-update}
*/
export type GatewayGuildRoleUpdateDispatch = GatewayGuildRoleModifyDispatch;
export type GatewayGuildRoleUpdateDispatch = _DataPayload<
GatewayDispatchEvents.GuildRoleUpdate,
GatewayGuildRoleUpdateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#guild-role-update}
@@ -1520,7 +1576,7 @@ export interface GatewayInviteCreateDispatchData {
/**
* The time at which the invite was created
*/
created_at: number;
created_at: string;
/**
* The guild of the invite
*/

102
deno/gateway/v9.ts generated
View File

@@ -330,12 +330,17 @@ export type GatewayDispatchPayload =
| GatewayAutoModerationActionExecutionDispatch
| GatewayAutoModerationRuleCreateDispatch
| GatewayAutoModerationRuleDeleteDispatch
| GatewayAutoModerationRuleModifyDispatch
| GatewayChannelModifyDispatch
| GatewayAutoModerationRuleUpdateDispatch
| GatewayChannelCreateDispatch
| GatewayChannelDeleteDispatch
| GatewayChannelPinsUpdateDispatch
| GatewayEntitlementModifyDispatch
| GatewayChannelUpdateDispatch
| GatewayEntitlementCreateDispatch
| GatewayEntitlementDeleteDispatch
| GatewayEntitlementUpdateDispatch
| GatewayGuildAuditLogEntryCreateDispatch
| GatewayGuildBanModifyDispatch
| GatewayGuildBanAddDispatch
| GatewayGuildBanRemoveDispatch
| GatewayGuildCreateDispatch
| GatewayGuildDeleteDispatch
| GatewayGuildEmojisUpdateDispatch
@@ -345,8 +350,9 @@ export type GatewayDispatchPayload =
| GatewayGuildMembersChunkDispatch
| GatewayGuildMemberUpdateDispatch
| GatewayGuildModifyDispatch
| GatewayGuildRoleCreateDispatch
| GatewayGuildRoleDeleteDispatch
| GatewayGuildRoleModifyDispatch
| GatewayGuildRoleUpdateDispatch
| GatewayGuildScheduledEventCreateDispatch
| GatewayGuildScheduledEventDeleteDispatch
| GatewayGuildScheduledEventUpdateDispatch
@@ -381,7 +387,9 @@ export type GatewayDispatchPayload =
| GatewayStageInstanceCreateDispatch
| GatewayStageInstanceDeleteDispatch
| GatewayStageInstanceUpdateDispatch
| GatewaySubscriptionModifyDispatch
| GatewaySubscriptionCreateDispatch
| GatewaySubscriptionDeleteDispatch
| GatewaySubscriptionUpdateDispatch
| GatewayThreadCreateDispatch
| GatewayThreadDeleteDispatch
| GatewayThreadListSyncDispatch
@@ -528,7 +536,10 @@ export type GatewayAutoModerationRuleModifyDispatchData = APIAutoModerationRule;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#auto-moderation-rule-create}
*/
export type GatewayAutoModerationRuleCreateDispatch = GatewayAutoModerationRuleModifyDispatch;
export type GatewayAutoModerationRuleCreateDispatch = _DataPayload<
GatewayDispatchEvents.AutoModerationRuleCreate,
GatewayAutoModerationRuleCreateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#auto-moderation-rule-create}
@@ -538,7 +549,10 @@ export type GatewayAutoModerationRuleCreateDispatchData = GatewayAutoModerationR
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#auto-moderation-rule-update}
*/
export type GatewayAutoModerationRuleUpdateDispatch = GatewayAutoModerationRuleModifyDispatch;
export type GatewayAutoModerationRuleUpdateDispatch = _DataPayload<
GatewayDispatchEvents.AutoModerationRuleUpdate,
GatewayAutoModerationRuleUpdateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#auto-moderation-rule-update}
@@ -548,7 +562,10 @@ export type GatewayAutoModerationRuleUpdateDispatchData = GatewayAutoModerationR
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#auto-moderation-rule-delete}
*/
export type GatewayAutoModerationRuleDeleteDispatch = GatewayAutoModerationRuleModifyDispatch;
export type GatewayAutoModerationRuleDeleteDispatch = _DataPayload<
GatewayDispatchEvents.AutoModerationRuleDelete,
GatewayAutoModerationRuleDeleteDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#auto-moderation-rule-delete}
@@ -673,7 +690,10 @@ export type GatewaySubscriptionModifyDispatchData = APISubscription;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#subscription-create}
*/
export type GatewaySubscriptionCreateDispatch = GatewaySubscriptionModifyDispatch;
export type GatewaySubscriptionCreateDispatch = _DataPayload<
GatewayDispatchEvents.SubscriptionCreate,
GatewaySubscriptionCreateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#subscription-create}
@@ -683,7 +703,10 @@ export type GatewaySubscriptionCreateDispatchData = GatewaySubscriptionModifyDis
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#subscription-update}
*/
export type GatewaySubscriptionUpdateDispatch = GatewaySubscriptionModifyDispatch;
export type GatewaySubscriptionUpdateDispatch = _DataPayload<
GatewayDispatchEvents.SubscriptionUpdate,
GatewaySubscriptionUpdateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#subscription-update}
@@ -693,7 +716,10 @@ export type GatewaySubscriptionUpdateDispatchData = GatewaySubscriptionModifyDis
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#subscription-delete}
*/
export type GatewaySubscriptionDeleteDispatch = GatewaySubscriptionModifyDispatch;
export type GatewaySubscriptionDeleteDispatch = _DataPayload<
GatewayDispatchEvents.SubscriptionDelete,
GatewaySubscriptionDeleteDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#subscription-delete}
@@ -723,7 +749,10 @@ export type GatewayChannelModifyDispatchData = APIChannel & {
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#channel-create}
*/
export type GatewayChannelCreateDispatch = GatewayChannelModifyDispatch;
export type GatewayChannelCreateDispatch = _DataPayload<
GatewayDispatchEvents.ChannelCreate,
GatewayChannelCreateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#channel-create}
@@ -733,7 +762,10 @@ export type GatewayChannelCreateDispatchData = GatewayChannelModifyDispatchData;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#channel-update}
*/
export type GatewayChannelUpdateDispatch = GatewayChannelModifyDispatch;
export type GatewayChannelUpdateDispatch = _DataPayload<
GatewayDispatchEvents.ChannelUpdate,
GatewayChannelUpdateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#channel-update}
@@ -743,7 +775,10 @@ export type GatewayChannelUpdateDispatchData = GatewayChannelModifyDispatchData;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#channel-delete}
*/
export type GatewayChannelDeleteDispatch = GatewayChannelModifyDispatch;
export type GatewayChannelDeleteDispatch = _DataPayload<
GatewayDispatchEvents.ChannelDelete,
GatewayChannelDeleteDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#channel-delete}
@@ -803,7 +838,10 @@ export type GatewayEntitlementCreateDispatchData = GatewayEntitlementModifyDispa
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#entitlement-create}
*/
export type GatewayEntitlementCreateDispatch = GatewayEntitlementModifyDispatch;
export type GatewayEntitlementCreateDispatch = _DataPayload<
GatewayDispatchEvents.EntitlementCreate,
GatewayEntitlementCreateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#entitlement-update}
@@ -813,7 +851,10 @@ export type GatewayEntitlementUpdateDispatchData = GatewayEntitlementModifyDispa
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#entitlement-update}
*/
export type GatewayEntitlementUpdateDispatch = GatewayEntitlementModifyDispatch;
export type GatewayEntitlementUpdateDispatch = _DataPayload<
GatewayDispatchEvents.EntitlementUpdate,
GatewayEntitlementUpdateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#entitlement-delete}
@@ -823,7 +864,10 @@ export type GatewayEntitlementDeleteDispatchData = GatewayEntitlementModifyDispa
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#entitlement-delete}
*/
export type GatewayEntitlementDeleteDispatch = GatewayEntitlementModifyDispatch;
export type GatewayEntitlementDeleteDispatch = _DataPayload<
GatewayDispatchEvents.EntitlementDelete,
GatewayEntitlementDeleteDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#guild-update}
@@ -998,7 +1042,10 @@ export interface GatewayGuildBanModifyDispatchData {
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#guild-ban-add}
*/
export type GatewayGuildBanAddDispatch = GatewayGuildBanModifyDispatch;
export type GatewayGuildBanAddDispatch = _DataPayload<
GatewayDispatchEvents.GuildBanAdd,
GatewayGuildBanAddDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#guild-ban-add}
@@ -1008,7 +1055,10 @@ export type GatewayGuildBanAddDispatchData = GatewayGuildBanModifyDispatchData;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#guild-ban-remove}
*/
export type GatewayGuildBanRemoveDispatch = GatewayGuildBanModifyDispatch;
export type GatewayGuildBanRemoveDispatch = _DataPayload<
GatewayDispatchEvents.GuildBanRemove,
GatewayGuildBanRemoveDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#guild-ban-remove}
@@ -1225,7 +1275,10 @@ export interface GatewayGuildRoleModifyDispatchData {
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#guild-role-create}
*/
export type GatewayGuildRoleCreateDispatch = GatewayGuildRoleModifyDispatch;
export type GatewayGuildRoleCreateDispatch = _DataPayload<
GatewayDispatchEvents.GuildRoleCreate,
GatewayGuildRoleCreateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#guild-role-create}
@@ -1235,7 +1288,10 @@ export type GatewayGuildRoleCreateDispatchData = GatewayGuildRoleModifyDispatchD
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#guild-role-update}
*/
export type GatewayGuildRoleUpdateDispatch = GatewayGuildRoleModifyDispatch;
export type GatewayGuildRoleUpdateDispatch = _DataPayload<
GatewayDispatchEvents.GuildRoleUpdate,
GatewayGuildRoleUpdateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#guild-role-update}
@@ -1519,7 +1575,7 @@ export interface GatewayInviteCreateDispatchData {
/**
* The time at which the invite was created
*/
created_at: number;
created_at: string;
/**
* The guild of the invite
*/

View File

@@ -17,7 +17,6 @@ export const PermissionFlagsBits = {
/**
* Allows kicking members
*/
KickMembers: 1n << 1n,
/**
* Allows banning members
@@ -38,7 +37,7 @@ export const PermissionFlagsBits = {
*/
ManageGuild: 1n << 5n,
/**
* Allows for the addition of reactions to messages
* Allows for the addition of reactions to messages. This permission does not apply to reacting with an existing reaction on a message
*
* Applies to channel types: Text, Voice, Stage
*/
@@ -234,9 +233,9 @@ export const PermissionFlagsBits = {
*/
SendMessagesInThreads: 1n << 38n,
/**
* Allows for using Activities (applications with the {@link ApplicationFlags.Embedded} flag) in a voice channel
* Allows for using Activities (applications with the {@link ApplicationFlags.Embedded} flag)
*
* Applies to channel types: Voice
* Applies to channel types: Text, Voice
*/
UseEmbeddedActivities: 1n << 39n,
/**

View File

@@ -264,6 +264,7 @@ export interface APIInteractionDataResolved {
roles?: Record<Snowflake, APIRole>;
members?: Record<Snowflake, APIInteractionDataResolvedGuildMember>;
channels?: Record<Snowflake, APIInteractionDataResolvedChannel>;
messages?: Record<Snowflake, APIMessage>;
attachments?: Record<Snowflake, APIAttachment>;
}

View File

@@ -52,6 +52,10 @@ export interface APIMessageComponentBaseInteractionData<CType extends ComponentT
* The type of the component
*/
component_type: CType;
/**
* The unique identifier for the component, as defined when the component was sent
*/
id: number;
}
export type APIMessageButtonInteractionData = APIMessageComponentBaseInteractionData<ComponentType.Button>;

View File

@@ -83,7 +83,7 @@ export type ApplicationCommandOptionAllowedChannelType = Exclude<
export interface APISlowmodeChannel<T extends ChannelType> extends APIChannelBase<T> {
/**
* 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_CHANNELS`, are unaffected
* bots, as well as users with the permission `BYPASS_SLOWMODE`, are unaffected
*
* `rate_limit_per_user` also applies to thread creation. Users can send one message and create one thread during each `rate_limit_per_user` interval.
*
@@ -366,7 +366,7 @@ export interface APIThreadOnlyChannel<T extends ChannelType.GuildForum | Channel
last_message_id?: Snowflake | null;
/**
* Amount of seconds a user has to wait before creating another thread (0-21600);
* bots, as well as users with the permission `MANAGE_MESSAGES` or `MANAGE_CHANNELS`, are unaffected
* bots, as well as users with the permission `BYPASS_SLOWMODE`, are unaffected
*
* The absence of this field in API calls and Gateway events should indicate that slowmode has been reset to the default value.
*/

View File

@@ -9,7 +9,7 @@ import type { PresenceUpdateReceiveStatus } from './gateway.ts';
import type { OAuth2Scopes } from './oauth2.ts';
import type { APIRole } from './permissions.ts';
import type { APISticker } from './sticker.ts';
import type { APIAvatarDecorationData, APIUser } from './user.ts';
import type { APIAvatarDecorationData, APICollectibles, APIUser } from './user.ts';
export interface APIBaseGuild {
/**
@@ -127,7 +127,7 @@ export interface APIGuild extends APIPartialGuild {
* @see {@link https://discord.com/developers/docs/resources/voice#voice-region-object}
* @deprecated This field has been deprecated in favor of `rtc_region` on the channel.
*/
region: string;
region?: string | null;
/**
* ID of afk channel
*/
@@ -275,7 +275,7 @@ export interface APIGuild extends APIPartialGuild {
*
* @see {@link https://discord.com/developers/docs/resources/sticker#sticker-object}
*/
stickers: APISticker[];
stickers?: APISticker[];
/**
* Whether the guild has the boost progress bar enabled.
*/
@@ -638,7 +638,7 @@ export interface APIGuildPreview {
/**
* The description for the guild
*/
description: string;
description: string | null;
/**
* Custom guild stickers
*/
@@ -695,6 +695,12 @@ export interface APIBaseGuildMember {
* @see {@link https://discord.com/developers/docs/resources/user#avatar-decoration-data-object}
*/
avatar_decoration_data?: APIAvatarDecorationData | null;
/**
* The data for the member's collectibles
*
* @see {@link https://discord.com/developers/docs/resources/user#collectibles}
*/
collectibles?: APICollectibles | null;
}
/**

View File

@@ -253,6 +253,10 @@ export interface APIBaseMessageNoChannel {
* The call associated with the message
*/
call?: APIMessageCall;
/**
* The custom client-side theme shared via the message
*/
shared_client_theme?: APIMessageSharedClientTheme;
}
/**
@@ -463,6 +467,38 @@ export interface APIMessageCall {
ended_timestamp?: string | null;
}
/**
* @see https://docs.discord.com/developers/resources/message#base-theme-types
*/
export enum BaseThemeType {
Dark = 1,
Light,
Darker,
Midnight,
}
/**
* @see https://docs.discord.com/developers/resources/message#shared-client-theme-object
*/
export interface APIMessageSharedClientTheme {
/**
* The hexadecimal-encoded colors of the theme (max of 5)
*/
colors: string[];
/**
* The direction of the theme's colors (max of 360)
*/
gradient_angle: number;
/**
* The intensity of the theme's colors (max of 100)
*/
base_mix: number;
/**
* The mode of the theme
*/
base_theme?: BaseThemeType | null;
}
/**
* @see {@link https://discord.com/developers/docs/resources/message#role-subscription-data-object-role-subscription-data-object-structure}
*/
@@ -1036,20 +1072,14 @@ export enum ComponentType {
FileUpload,
/**
* Single-choice set of radio group option
*
* @unstable This component is not publicly released and is currently in preview.
*/
RadioGroup = 21,
/**
* Multi-select group of checkboxes
*
* @unstable This component is not publicly released and is currently in preview.
*/
CheckboxGroup,
/**
* Single checkbox for binary choice
*
* @unstable This component is not publicly released and is currently in preview.
*/
Checkbox,
// EVERYTHING BELOW THIS LINE SHOULD BE OLD NAMES FOR RENAMED ENUM MEMBERS //
@@ -1717,7 +1747,6 @@ export interface APIFileUploadComponent extends APIBaseComponent<ComponentType.F
/**
* @see {@link https://discord.com/developers/docs/components/reference#radio-group}
* @unstable This component is not publicly released and is currently in preview.
*/
export interface APIRadioGroupComponent extends APIBaseComponent<ComponentType.RadioGroup> {
/**
@@ -1738,7 +1767,6 @@ export interface APIRadioGroupComponent extends APIBaseComponent<ComponentType.R
/**
* @see {@link https://discord.com/developers/docs/components/reference#radio-group-option-structure}
* @unstable This feature is not publicly released and is currently in preview.
*/
export interface APIRadioGroupOption {
/**
@@ -1763,7 +1791,6 @@ export interface APIRadioGroupOption {
/**
* @see {@link https://discord.com/developers/docs/components/reference#checkbox-group}
* @unstable This component is not publicly released and is currently in preview.
*/
export interface APICheckboxGroupComponent extends APIBaseComponent<ComponentType.CheckboxGroup> {
/**
@@ -1796,7 +1823,6 @@ export interface APICheckboxGroupComponent extends APIBaseComponent<ComponentTyp
/**
* @see {@link https://discord.com/developers/docs/components/reference#checkbox-group-option-structure}
* @unstable This feature is not publicly released and is currently in preview.
*/
export interface APICheckboxGroupOption {
/**
@@ -1821,7 +1847,6 @@ export interface APICheckboxGroupOption {
/**
* @see {@link https://discord.com/developers/docs/components/reference#checkbox}
* @unstable This component is not publicly released and is currently in preview.
*/
export interface APICheckboxComponent extends APIBaseComponent<ComponentType.Checkbox> {
/**

View File

@@ -19,13 +19,14 @@ export interface APIRole {
/**
* Integer representation of hexadecimal color code
*
* @deprecated Use `colors` instead.
* @remarks `color` will still be returned by the API, but using the `colors` field is recommended when doing requests.
*/
color: number;
/**
* The role's colors
*/
colors?: APIRoleColors;
colors: APIRoleColors;
/**
* If this role is pinned in the user listing
*/

View File

@@ -37,7 +37,7 @@ export interface APIPoll extends APIBasePoll, APIPollDefaults {
/**
* The time when the poll ends (IS08601 timestamp)
*/
expiry: string;
expiry: string | null;
/**
* The results of the poll
*/

View File

@@ -123,14 +123,8 @@ export interface APIWebhookEventApplicationDeauthorizedData {
export type APIWebhookEventEntitlementCreateData = APIEntitlement;
/**
* @unstable
*/
export type APIWebhookEventEntitlementDeleteData = APIEntitlement;
/**
* @unstable
*/
export type APIWebhookEventEntitlementUpdateData = APIEntitlement;
export type APIWebhookEventQuestUserEnrollmentData = never;
@@ -201,14 +195,10 @@ export enum ApplicationWebhookEventType {
EntitlementCreate = 'ENTITLEMENT_CREATE',
/**
* Entitlement was updated
*
* @unstable This event is not yet documented but can be enabled from the developer portal
*/
EntitlementUpdate = 'ENTITLEMENT_UPDATE',
/**
* Entitlement was deleted
*
* @unstable This event is not yet documented but can be enabled from the developer portal
*/
EntitlementDelete = 'ENTITLEMENT_DELETE',
/**

View File

@@ -267,6 +267,7 @@ export interface APIInteractionDataResolved {
roles?: Record<Snowflake, APIRole>;
members?: Record<Snowflake, APIInteractionDataResolvedGuildMember>;
channels?: Record<Snowflake, APIInteractionDataResolvedChannel>;
messages?: Record<Snowflake, APIMessage>;
attachments?: Record<Snowflake, APIAttachment>;
}

View File

@@ -52,6 +52,10 @@ export interface APIMessageComponentBaseInteractionData<CType extends ComponentT
* The type of the component
*/
component_type: CType;
/**
* The unique identifier for the component, as defined when the component was sent
*/
id: number;
}
export type APIMessageButtonInteractionData = APIMessageComponentBaseInteractionData<ComponentType.Button>;

View File

@@ -78,7 +78,7 @@ export type GuildChannelType = Exclude<ChannelType, ChannelType.DM | ChannelType
export interface APISlowmodeChannel<T extends ChannelType> extends APIChannelBase<T> {
/**
* 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_CHANNELS`, are unaffected
* bots, as well as users with the permission `BYPASS_SLOWMODE`, are unaffected
*
* `rate_limit_per_user` also applies to thread creation. Users can send one message and create one thread during each `rate_limit_per_user` interval.
*
@@ -361,7 +361,7 @@ export interface APIThreadOnlyChannel<T extends ChannelType.GuildForum | Channel
last_message_id?: Snowflake | null;
/**
* Amount of seconds a user has to wait before creating another thread (0-21600);
* bots, as well as users with the permission `MANAGE_MESSAGES` or `MANAGE_CHANNELS`, are unaffected
* bots, as well as users with the permission `BYPASS_SLOWMODE`, are unaffected
*
* The absence of this field in API calls and Gateway events should indicate that slowmode has been reset to the default value.
*/

View File

@@ -9,7 +9,7 @@ import type { PresenceUpdateReceiveStatus } from './gateway.ts';
import type { OAuth2Scopes } from './oauth2.ts';
import type { APIRole } from './permissions.ts';
import type { APISticker } from './sticker.ts';
import type { APIAvatarDecorationData, APIUser } from './user.ts';
import type { APIAvatarDecorationData, APICollectibles, APIUser } from './user.ts';
export interface APIBaseGuild {
/**
@@ -127,7 +127,7 @@ export interface APIGuild extends APIPartialGuild {
* @see {@link https://discord.com/developers/docs/resources/voice#voice-region-object}
* @deprecated This field has been deprecated in favor of `rtc_region` on the channel.
*/
region: string;
region?: string | null;
/**
* ID of afk channel
*/
@@ -275,7 +275,7 @@ export interface APIGuild extends APIPartialGuild {
*
* @see {@link https://discord.com/developers/docs/resources/sticker#sticker-object}
*/
stickers: APISticker[];
stickers?: APISticker[];
/**
* Whether the guild has the boost progress bar enabled.
*/
@@ -630,7 +630,7 @@ export interface APIGuildPreview {
/**
* The description for the guild
*/
description: string;
description: string | null;
/**
* Custom guild stickers
*/
@@ -687,6 +687,12 @@ export interface APIBaseGuildMember {
* @see {@link https://discord.com/developers/docs/resources/user#avatar-decoration-data-object}
*/
avatar_decoration_data?: APIAvatarDecorationData | null;
/**
* The data for the member's collectibles
*
* @see {@link https://discord.com/developers/docs/resources/user#collectibles}
*/
collectibles?: APICollectibles | null;
}
/**

View File

@@ -248,6 +248,10 @@ export interface APIBaseMessageNoChannel {
* The call associated with the message
*/
call?: APIMessageCall;
/**
* The custom client-side theme shared via the message
*/
shared_client_theme?: APIMessageSharedClientTheme;
}
/**
@@ -458,6 +462,38 @@ export interface APIMessageCall {
ended_timestamp?: string | null;
}
/**
* @see https://docs.discord.com/developers/resources/message#base-theme-types
*/
export enum BaseThemeType {
Dark = 1,
Light,
Darker,
Midnight,
}
/**
* @see https://docs.discord.com/developers/resources/message#shared-client-theme-object
*/
export interface APIMessageSharedClientTheme {
/**
* The hexadecimal-encoded colors of the theme (max of 5)
*/
colors: string[];
/**
* The direction of the theme's colors (max of 360)
*/
gradient_angle: number;
/**
* The intensity of the theme's colors (max of 100)
*/
base_mix: number;
/**
* The mode of the theme
*/
base_theme?: BaseThemeType | null;
}
/**
* @see {@link https://discord.com/developers/docs/resources/message#role-subscription-data-object-role-subscription-data-object-structure}
*/
@@ -1031,20 +1067,14 @@ export enum ComponentType {
FileUpload,
/**
* Single-choice set of radio group option
*
* @unstable This component is not publicly released and is currently in preview.
*/
RadioGroup = 21,
/**
* Multi-select group of checkboxes
*
* @unstable This component is not publicly released and is currently in preview.
*/
CheckboxGroup,
/**
* Single checkbox for binary choice
*
* @unstable This component is not publicly released and is currently in preview.
*/
Checkbox,
// EVERYTHING BELOW THIS LINE SHOULD BE OLD NAMES FOR RENAMED ENUM MEMBERS //
@@ -1712,7 +1742,6 @@ export interface APIFileUploadComponent extends APIBaseComponent<ComponentType.F
/**
* @see {@link https://discord.com/developers/docs/components/reference#radio-group}
* @unstable This component is not publicly released and is currently in preview.
*/
export interface APIRadioGroupComponent extends APIBaseComponent<ComponentType.RadioGroup> {
/**
@@ -1758,7 +1787,6 @@ export interface APIRadioGroupOption {
/**
* @see {@link https://discord.com/developers/docs/components/reference#checkbox-group}
* @unstable This component is not publicly released and is currently in preview.
*/
export interface APICheckboxGroupComponent extends APIBaseComponent<ComponentType.CheckboxGroup> {
/**
@@ -1791,7 +1819,6 @@ export interface APICheckboxGroupComponent extends APIBaseComponent<ComponentTyp
/**
* @see {@link https://discord.com/developers/docs/components/reference#checkbox-group-option-structure}
* @unstable This feature is not publicly released and is currently in preview.
*/
export interface APICheckboxGroupOption {
/**
@@ -1816,7 +1843,6 @@ export interface APICheckboxGroupOption {
/**
* @see {@link https://discord.com/developers/docs/components/reference#checkbox}
* @unstable This component is not publicly released and is currently in preview.
*/
export interface APICheckboxComponent extends APIBaseComponent<ComponentType.Checkbox> {
/**

View File

@@ -19,13 +19,14 @@ export interface APIRole {
/**
* Integer representation of hexadecimal color code
*
* @deprecated Use `colors` instead.
* @remarks `color` will still be returned by the API, but using the `colors` field is recommended when doing requests.
*/
color: number;
/**
* The role's colors
*/
colors?: APIRoleColors;
colors: APIRoleColors;
/**
* If this role is pinned in the user listing
*/

View File

@@ -37,7 +37,7 @@ export interface APIPoll extends APIBasePoll, APIPollDefaults {
/**
* The time when the poll ends (IS08601 timestamp)
*/
expiry: string;
expiry: string | null;
/**
* The results of the poll
*/

View File

@@ -123,14 +123,8 @@ export interface APIWebhookEventApplicationDeauthorizedData {
export type APIWebhookEventEntitlementCreateData = APIEntitlement;
/**
* @unstable
*/
export type APIWebhookEventEntitlementDeleteData = APIEntitlement;
/**
* @unstable
*/
export type APIWebhookEventEntitlementUpdateData = APIEntitlement;
export type APIWebhookEventQuestUserEnrollmentData = never;
@@ -201,14 +195,10 @@ export enum ApplicationWebhookEventType {
EntitlementCreate = 'ENTITLEMENT_CREATE',
/**
* Entitlement was updated
*
* @unstable This event is not yet documented but can be enabled from the developer portal
*/
EntitlementUpdate = 'ENTITLEMENT_UPDATE',
/**
* Entitlement was deleted
*
* @unstable This event is not yet documented but can be enabled from the developer portal
*/
EntitlementDelete = 'ENTITLEMENT_DELETE',
/**

View File

@@ -25,11 +25,13 @@ export type RESTGetCurrentApplicationResult = APIApplication;
* @see {@link https://discord.com/developers/docs/resources/application#edit-current-application}
*/
export type RESTPatchCurrentApplicationJSONBody = _StrictPartial<
_Nullable<Pick<APIApplication, 'cover_image' | 'icon'>> &
_Nullable<Pick<APIApplication, 'cover_image' | 'event_webhooks_url' | 'icon'>> &
Pick<
APIApplication,
| 'custom_install_url'
| 'description'
| 'event_webhooks_status'
| 'event_webhooks_types'
| 'flags'
| 'install_params'
| 'integration_types_config'

View File

@@ -7,6 +7,7 @@ import type {
APIFollowedChannel,
APIMessage,
APIMessageReference,
APIMessageSharedClientTheme,
APIThreadList,
APIThreadMember,
APIUser,
@@ -84,8 +85,7 @@ export interface RESTPatchAPIChannelJSONBody {
nsfw?: boolean | null | undefined;
/**
* 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_CHANNELS`,
* are unaffected
* bots, as well as users with the permission `BYPASS_SLOWMODE`, are unaffected
*
* Channel types: text, newsThread, publicThread, privateThread, forum, media
*/
@@ -149,7 +149,7 @@ export interface RESTPatchAPIChannelJSONBody {
*
* Channel types: text, news, forum, media
*/
default_auto_archive_duration?: ThreadAutoArchiveDuration | undefined;
default_auto_archive_duration?: ThreadAutoArchiveDuration | null | undefined;
/**
* Channel flags combined as a bit field.
*/
@@ -171,7 +171,7 @@ export interface RESTPatchAPIChannelJSONBody {
*
* Channel types: forum, media
*/
default_reaction_emoji?: APIGuildForumDefaultReactionEmoji | undefined;
default_reaction_emoji?: APIGuildForumDefaultReactionEmoji | null | undefined;
/**
* The initial `rate_limit_per_user` to set on newly created threads in a channel.
* This field is copied to the thread at creation time and does not live update
@@ -338,6 +338,10 @@ export interface RESTPostAPIChannelMessageJSONBody {
* A poll!
*/
poll?: RESTAPIPoll | undefined;
/**
* The custom client-side theme to share via the message
*/
shared_client_theme?: APIMessageSharedClientTheme | undefined;
}
/**

11
deno/rest/v10/guild.ts generated
View File

@@ -20,6 +20,7 @@ import type {
GuildDefaultMessageNotifications,
GuildExplicitContentFilter,
GuildFeature,
GuildMemberFlags,
GuildMFALevel,
GuildSystemChannelFlags,
GuildVerificationLevel,
@@ -381,11 +382,11 @@ export type RESTPatchAPIGuildChannelPositionsJSONBody = {
/**
* Sorting position of the channel
*/
position: number;
position?: number | null | undefined;
/**
* Sync channel overwrites with the new parent, when moving to a new `parent_id`
*/
lock_permissions?: boolean | undefined;
lock_permissions?: boolean | null | undefined;
/**
* The new parent id of this channel
*/
@@ -522,6 +523,12 @@ export interface RESTPatchAPIGuildMemberJSONBody {
* Timestamp of when the time out will be removed; until then, they cannot interact with the guild
*/
communication_disabled_until?: string | null | undefined;
/**
* Guild member flags (only {@link GuildMemberFlags.BypassesVerification} can be set)
*
* @see {@link https://discord.com/developers/docs/resources/guild#guild-member-object-guild-member-flags}
*/
flags?: GuildMemberFlags | undefined;
}
/**

View File

@@ -56,7 +56,7 @@ export interface RESTPostAPIGuildScheduledEventJSONBody {
/**
* The scheduled entity type of the guild event
*/
entity_type?: GuildScheduledEventEntityType | undefined;
entity_type: GuildScheduledEventEntityType;
/**
* The entity metadata of the scheduled event
*/
@@ -98,8 +98,12 @@ export interface RESTPatchAPIGuildScheduledEventJSONBody
extends
_Nullable<Pick<RESTPostAPIGuildScheduledEventJSONBody, 'description' | 'entity_metadata' | 'recurrence_rule'>>,
_StrictPartial<
Omit<RESTPostAPIGuildScheduledEventJSONBody, 'description' | 'entity_metadata' | 'recurrence_rule'>
Omit<
RESTPostAPIGuildScheduledEventJSONBody,
'channel_id' | 'description' | 'entity_metadata' | 'recurrence_rule'
>
> {
channel_id?: Snowflake | null | undefined;
/**
* The status of the scheduled event
*/

View File

@@ -4,7 +4,7 @@ import type { APISoundboardSound } from '../../payloads/v10/mod.ts';
/**
* @see {@link https://discord.com/developers/docs/resources/soundboard#send-soundboard-sound}
*/
export type RESTPostAPISendSoundboardSoundResult = APISoundboardSound;
export type RESTPostAPISendSoundboardSoundResult = never;
/**
* @see {@link https://discord.com/developers/docs/resources/soundboard#send-soundboard-sound-json-params}

View File

@@ -25,11 +25,13 @@ export type RESTGetCurrentApplicationResult = APIApplication;
* @see {@link https://discord.com/developers/docs/resources/application#edit-current-application}
*/
export type RESTPatchCurrentApplicationJSONBody = _StrictPartial<
_Nullable<Pick<APIApplication, 'cover_image' | 'icon'>> &
_Nullable<Pick<APIApplication, 'cover_image' | 'event_webhooks_url' | 'icon'>> &
Pick<
APIApplication,
| 'custom_install_url'
| 'description'
| 'event_webhooks_status'
| 'event_webhooks_types'
| 'flags'
| 'install_params'
| 'integration_types_config'

View File

@@ -7,6 +7,7 @@ import type {
APIFollowedChannel,
APIMessage,
APIMessageReference,
APIMessageSharedClientTheme,
APIThreadList,
APIThreadMember,
APIUser,
@@ -84,8 +85,7 @@ export interface RESTPatchAPIChannelJSONBody {
nsfw?: boolean | null | undefined;
/**
* 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_CHANNELS`,
* are unaffected
* bots, as well as users with the permission `BYPASS_SLOWMODE`, are unaffected
*
* Channel types: text, newsThread, publicThread, privateThread, forum, media
*/
@@ -149,7 +149,7 @@ export interface RESTPatchAPIChannelJSONBody {
*
* Channel types: text, news, forum, media
*/
default_auto_archive_duration?: ThreadAutoArchiveDuration | undefined;
default_auto_archive_duration?: ThreadAutoArchiveDuration | null | undefined;
/**
* Channel flags combined as a bit field.
*/
@@ -171,7 +171,7 @@ export interface RESTPatchAPIChannelJSONBody {
*
* Channel types: forum, media
*/
default_reaction_emoji?: APIGuildForumDefaultReactionEmoji | undefined;
default_reaction_emoji?: APIGuildForumDefaultReactionEmoji | null | undefined;
/**
* The initial `rate_limit_per_user` to set on newly created threads in a channel.
* This field is copied to the thread at creation time and does not live update
@@ -345,6 +345,10 @@ export interface RESTPostAPIChannelMessageJSONBody {
* A poll!
*/
poll?: RESTAPIPoll | undefined;
/**
* The custom client-side theme to share via the message
*/
shared_client_theme?: APIMessageSharedClientTheme | undefined;
}
/**

11
deno/rest/v9/guild.ts generated
View File

@@ -18,6 +18,7 @@ import type {
GuildDefaultMessageNotifications,
GuildExplicitContentFilter,
GuildFeature,
GuildMemberFlags,
GuildMFALevel,
GuildSystemChannelFlags,
GuildVerificationLevel,
@@ -381,11 +382,11 @@ export type RESTPatchAPIGuildChannelPositionsJSONBody = {
/**
* Sorting position of the channel
*/
position: number;
position?: number | null | undefined;
/**
* Sync channel overwrites with the new parent, when moving to a new `parent_id`
*/
lock_permissions?: boolean | undefined;
lock_permissions?: boolean | null | undefined;
/**
* The new parent id of this channel
*/
@@ -522,6 +523,12 @@ export interface RESTPatchAPIGuildMemberJSONBody {
* Timestamp of when the time out will be removed; until then, they cannot interact with the guild
*/
communication_disabled_until?: string | null | undefined;
/**
* Guild member flags (only {@link GuildMemberFlags.BypassesVerification} can be set)
*
* @see {@link https://discord.com/developers/docs/resources/guild#guild-member-object-guild-member-flags}
*/
flags?: GuildMemberFlags | undefined;
}
/**

View File

@@ -56,7 +56,7 @@ export interface RESTPostAPIGuildScheduledEventJSONBody {
/**
* The scheduled entity type of the guild event
*/
entity_type?: GuildScheduledEventEntityType | undefined;
entity_type: GuildScheduledEventEntityType;
/**
* The entity metadata of the scheduled event
*/
@@ -98,8 +98,12 @@ export interface RESTPatchAPIGuildScheduledEventJSONBody
extends
_Nullable<Pick<RESTPostAPIGuildScheduledEventJSONBody, 'description' | 'entity_metadata' | 'recurrence_rule'>>,
_StrictPartial<
Omit<RESTPostAPIGuildScheduledEventJSONBody, 'description' | 'entity_metadata' | 'recurrence_rule'>
Omit<
RESTPostAPIGuildScheduledEventJSONBody,
'channel_id' | 'description' | 'entity_metadata' | 'recurrence_rule'
>
> {
channel_id?: Snowflake | null | undefined;
/**
* The status of the scheduled event
*/

View File

@@ -4,7 +4,7 @@ import type { APISoundboardSound } from '../../payloads/v9/mod.ts';
/**
* @see {@link https://discord.com/developers/docs/resources/soundboard#send-soundboard-sound}
*/
export type RESTPostAPISendSoundboardSoundResult = APISoundboardSound;
export type RESTPostAPISendSoundboardSoundResult = never;
/**
* @see {@link https://discord.com/developers/docs/resources/soundboard#send-soundboard-sound-json-params}

View File

@@ -4,5 +4,5 @@
export interface GatewayURLQuery {
v: string;
encoding: 'etf' | 'json';
compress?: 'zlib-stream';
compress?: 'zlib-stream' | 'zstd-stream';
}

View File

@@ -331,12 +331,17 @@ export type GatewayDispatchPayload =
| GatewayAutoModerationActionExecutionDispatch
| GatewayAutoModerationRuleCreateDispatch
| GatewayAutoModerationRuleDeleteDispatch
| GatewayAutoModerationRuleModifyDispatch
| GatewayChannelModifyDispatch
| GatewayAutoModerationRuleUpdateDispatch
| GatewayChannelCreateDispatch
| GatewayChannelDeleteDispatch
| GatewayChannelPinsUpdateDispatch
| GatewayEntitlementModifyDispatch
| GatewayChannelUpdateDispatch
| GatewayEntitlementCreateDispatch
| GatewayEntitlementDeleteDispatch
| GatewayEntitlementUpdateDispatch
| GatewayGuildAuditLogEntryCreateDispatch
| GatewayGuildBanModifyDispatch
| GatewayGuildBanAddDispatch
| GatewayGuildBanRemoveDispatch
| GatewayGuildCreateDispatch
| GatewayGuildDeleteDispatch
| GatewayGuildEmojisUpdateDispatch
@@ -346,8 +351,9 @@ export type GatewayDispatchPayload =
| GatewayGuildMembersChunkDispatch
| GatewayGuildMemberUpdateDispatch
| GatewayGuildModifyDispatch
| GatewayGuildRoleCreateDispatch
| GatewayGuildRoleDeleteDispatch
| GatewayGuildRoleModifyDispatch
| GatewayGuildRoleUpdateDispatch
| GatewayGuildScheduledEventCreateDispatch
| GatewayGuildScheduledEventDeleteDispatch
| GatewayGuildScheduledEventUpdateDispatch
@@ -382,7 +388,9 @@ export type GatewayDispatchPayload =
| GatewayStageInstanceCreateDispatch
| GatewayStageInstanceDeleteDispatch
| GatewayStageInstanceUpdateDispatch
| GatewaySubscriptionModifyDispatch
| GatewaySubscriptionCreateDispatch
| GatewaySubscriptionDeleteDispatch
| GatewaySubscriptionUpdateDispatch
| GatewayThreadCreateDispatch
| GatewayThreadDeleteDispatch
| GatewayThreadListSyncDispatch
@@ -529,7 +537,10 @@ export type GatewayAutoModerationRuleModifyDispatchData = APIAutoModerationRule;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#auto-moderation-rule-create}
*/
export type GatewayAutoModerationRuleCreateDispatch = GatewayAutoModerationRuleModifyDispatch;
export type GatewayAutoModerationRuleCreateDispatch = _DataPayload<
GatewayDispatchEvents.AutoModerationRuleCreate,
GatewayAutoModerationRuleCreateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#auto-moderation-rule-create}
@@ -539,7 +550,10 @@ export type GatewayAutoModerationRuleCreateDispatchData = GatewayAutoModerationR
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#auto-moderation-rule-update}
*/
export type GatewayAutoModerationRuleUpdateDispatch = GatewayAutoModerationRuleModifyDispatch;
export type GatewayAutoModerationRuleUpdateDispatch = _DataPayload<
GatewayDispatchEvents.AutoModerationRuleUpdate,
GatewayAutoModerationRuleUpdateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#auto-moderation-rule-update}
@@ -549,7 +563,10 @@ export type GatewayAutoModerationRuleUpdateDispatchData = GatewayAutoModerationR
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#auto-moderation-rule-delete}
*/
export type GatewayAutoModerationRuleDeleteDispatch = GatewayAutoModerationRuleModifyDispatch;
export type GatewayAutoModerationRuleDeleteDispatch = _DataPayload<
GatewayDispatchEvents.AutoModerationRuleDelete,
GatewayAutoModerationRuleDeleteDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#auto-moderation-rule-delete}
@@ -674,7 +691,10 @@ export type GatewaySubscriptionModifyDispatchData = APISubscription;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#subscription-create}
*/
export type GatewaySubscriptionCreateDispatch = GatewaySubscriptionModifyDispatch;
export type GatewaySubscriptionCreateDispatch = _DataPayload<
GatewayDispatchEvents.SubscriptionCreate,
GatewaySubscriptionCreateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#subscription-create}
@@ -684,7 +704,10 @@ export type GatewaySubscriptionCreateDispatchData = GatewaySubscriptionModifyDis
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#subscription-update}
*/
export type GatewaySubscriptionUpdateDispatch = GatewaySubscriptionModifyDispatch;
export type GatewaySubscriptionUpdateDispatch = _DataPayload<
GatewayDispatchEvents.SubscriptionUpdate,
GatewaySubscriptionUpdateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#subscription-update}
@@ -694,7 +717,10 @@ export type GatewaySubscriptionUpdateDispatchData = GatewaySubscriptionModifyDis
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#subscription-delete}
*/
export type GatewaySubscriptionDeleteDispatch = GatewaySubscriptionModifyDispatch;
export type GatewaySubscriptionDeleteDispatch = _DataPayload<
GatewayDispatchEvents.SubscriptionDelete,
GatewaySubscriptionDeleteDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#subscription-delete}
@@ -724,7 +750,10 @@ export type GatewayChannelModifyDispatchData = APIChannel & {
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#channel-create}
*/
export type GatewayChannelCreateDispatch = GatewayChannelModifyDispatch;
export type GatewayChannelCreateDispatch = _DataPayload<
GatewayDispatchEvents.ChannelCreate,
GatewayChannelCreateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#channel-create}
@@ -734,7 +763,10 @@ export type GatewayChannelCreateDispatchData = GatewayChannelModifyDispatchData;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#channel-update}
*/
export type GatewayChannelUpdateDispatch = GatewayChannelModifyDispatch;
export type GatewayChannelUpdateDispatch = _DataPayload<
GatewayDispatchEvents.ChannelUpdate,
GatewayChannelUpdateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#channel-update}
@@ -744,7 +776,10 @@ export type GatewayChannelUpdateDispatchData = GatewayChannelModifyDispatchData;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#channel-delete}
*/
export type GatewayChannelDeleteDispatch = GatewayChannelModifyDispatch;
export type GatewayChannelDeleteDispatch = _DataPayload<
GatewayDispatchEvents.ChannelDelete,
GatewayChannelDeleteDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#channel-delete}
@@ -804,7 +839,10 @@ export type GatewayEntitlementCreateDispatchData = GatewayEntitlementModifyDispa
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#entitlement-create}
*/
export type GatewayEntitlementCreateDispatch = GatewayEntitlementModifyDispatch;
export type GatewayEntitlementCreateDispatch = _DataPayload<
GatewayDispatchEvents.EntitlementCreate,
GatewayEntitlementCreateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#entitlement-update}
@@ -814,7 +852,10 @@ export type GatewayEntitlementUpdateDispatchData = GatewayEntitlementModifyDispa
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#entitlement-update}
*/
export type GatewayEntitlementUpdateDispatch = GatewayEntitlementModifyDispatch;
export type GatewayEntitlementUpdateDispatch = _DataPayload<
GatewayDispatchEvents.EntitlementUpdate,
GatewayEntitlementUpdateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#entitlement-delete}
@@ -824,7 +865,10 @@ export type GatewayEntitlementDeleteDispatchData = GatewayEntitlementModifyDispa
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#entitlement-delete}
*/
export type GatewayEntitlementDeleteDispatch = GatewayEntitlementModifyDispatch;
export type GatewayEntitlementDeleteDispatch = _DataPayload<
GatewayDispatchEvents.EntitlementDelete,
GatewayEntitlementDeleteDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#guild-update}
@@ -999,7 +1043,10 @@ export interface GatewayGuildBanModifyDispatchData {
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#guild-ban-add}
*/
export type GatewayGuildBanAddDispatch = GatewayGuildBanModifyDispatch;
export type GatewayGuildBanAddDispatch = _DataPayload<
GatewayDispatchEvents.GuildBanAdd,
GatewayGuildBanAddDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#guild-ban-add}
@@ -1009,7 +1056,10 @@ export type GatewayGuildBanAddDispatchData = GatewayGuildBanModifyDispatchData;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#guild-ban-remove}
*/
export type GatewayGuildBanRemoveDispatch = GatewayGuildBanModifyDispatch;
export type GatewayGuildBanRemoveDispatch = _DataPayload<
GatewayDispatchEvents.GuildBanRemove,
GatewayGuildBanRemoveDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#guild-ban-remove}
@@ -1226,7 +1276,10 @@ export interface GatewayGuildRoleModifyDispatchData {
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#guild-role-create}
*/
export type GatewayGuildRoleCreateDispatch = GatewayGuildRoleModifyDispatch;
export type GatewayGuildRoleCreateDispatch = _DataPayload<
GatewayDispatchEvents.GuildRoleCreate,
GatewayGuildRoleCreateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#guild-role-create}
@@ -1236,7 +1289,10 @@ export type GatewayGuildRoleCreateDispatchData = GatewayGuildRoleModifyDispatchD
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#guild-role-update}
*/
export type GatewayGuildRoleUpdateDispatch = GatewayGuildRoleModifyDispatch;
export type GatewayGuildRoleUpdateDispatch = _DataPayload<
GatewayDispatchEvents.GuildRoleUpdate,
GatewayGuildRoleUpdateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#guild-role-update}
@@ -1520,7 +1576,7 @@ export interface GatewayInviteCreateDispatchData {
/**
* The time at which the invite was created
*/
created_at: number;
created_at: string;
/**
* The guild of the invite
*/

View File

@@ -330,12 +330,17 @@ export type GatewayDispatchPayload =
| GatewayAutoModerationActionExecutionDispatch
| GatewayAutoModerationRuleCreateDispatch
| GatewayAutoModerationRuleDeleteDispatch
| GatewayAutoModerationRuleModifyDispatch
| GatewayChannelModifyDispatch
| GatewayAutoModerationRuleUpdateDispatch
| GatewayChannelCreateDispatch
| GatewayChannelDeleteDispatch
| GatewayChannelPinsUpdateDispatch
| GatewayEntitlementModifyDispatch
| GatewayChannelUpdateDispatch
| GatewayEntitlementCreateDispatch
| GatewayEntitlementDeleteDispatch
| GatewayEntitlementUpdateDispatch
| GatewayGuildAuditLogEntryCreateDispatch
| GatewayGuildBanModifyDispatch
| GatewayGuildBanAddDispatch
| GatewayGuildBanRemoveDispatch
| GatewayGuildCreateDispatch
| GatewayGuildDeleteDispatch
| GatewayGuildEmojisUpdateDispatch
@@ -345,8 +350,9 @@ export type GatewayDispatchPayload =
| GatewayGuildMembersChunkDispatch
| GatewayGuildMemberUpdateDispatch
| GatewayGuildModifyDispatch
| GatewayGuildRoleCreateDispatch
| GatewayGuildRoleDeleteDispatch
| GatewayGuildRoleModifyDispatch
| GatewayGuildRoleUpdateDispatch
| GatewayGuildScheduledEventCreateDispatch
| GatewayGuildScheduledEventDeleteDispatch
| GatewayGuildScheduledEventUpdateDispatch
@@ -381,7 +387,9 @@ export type GatewayDispatchPayload =
| GatewayStageInstanceCreateDispatch
| GatewayStageInstanceDeleteDispatch
| GatewayStageInstanceUpdateDispatch
| GatewaySubscriptionModifyDispatch
| GatewaySubscriptionCreateDispatch
| GatewaySubscriptionDeleteDispatch
| GatewaySubscriptionUpdateDispatch
| GatewayThreadCreateDispatch
| GatewayThreadDeleteDispatch
| GatewayThreadListSyncDispatch
@@ -528,7 +536,10 @@ export type GatewayAutoModerationRuleModifyDispatchData = APIAutoModerationRule;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#auto-moderation-rule-create}
*/
export type GatewayAutoModerationRuleCreateDispatch = GatewayAutoModerationRuleModifyDispatch;
export type GatewayAutoModerationRuleCreateDispatch = _DataPayload<
GatewayDispatchEvents.AutoModerationRuleCreate,
GatewayAutoModerationRuleCreateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#auto-moderation-rule-create}
@@ -538,7 +549,10 @@ export type GatewayAutoModerationRuleCreateDispatchData = GatewayAutoModerationR
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#auto-moderation-rule-update}
*/
export type GatewayAutoModerationRuleUpdateDispatch = GatewayAutoModerationRuleModifyDispatch;
export type GatewayAutoModerationRuleUpdateDispatch = _DataPayload<
GatewayDispatchEvents.AutoModerationRuleUpdate,
GatewayAutoModerationRuleUpdateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#auto-moderation-rule-update}
@@ -548,7 +562,10 @@ export type GatewayAutoModerationRuleUpdateDispatchData = GatewayAutoModerationR
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#auto-moderation-rule-delete}
*/
export type GatewayAutoModerationRuleDeleteDispatch = GatewayAutoModerationRuleModifyDispatch;
export type GatewayAutoModerationRuleDeleteDispatch = _DataPayload<
GatewayDispatchEvents.AutoModerationRuleDelete,
GatewayAutoModerationRuleDeleteDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#auto-moderation-rule-delete}
@@ -673,7 +690,10 @@ export type GatewaySubscriptionModifyDispatchData = APISubscription;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#subscription-create}
*/
export type GatewaySubscriptionCreateDispatch = GatewaySubscriptionModifyDispatch;
export type GatewaySubscriptionCreateDispatch = _DataPayload<
GatewayDispatchEvents.SubscriptionCreate,
GatewaySubscriptionCreateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#subscription-create}
@@ -683,7 +703,10 @@ export type GatewaySubscriptionCreateDispatchData = GatewaySubscriptionModifyDis
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#subscription-update}
*/
export type GatewaySubscriptionUpdateDispatch = GatewaySubscriptionModifyDispatch;
export type GatewaySubscriptionUpdateDispatch = _DataPayload<
GatewayDispatchEvents.SubscriptionUpdate,
GatewaySubscriptionUpdateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#subscription-update}
@@ -693,7 +716,10 @@ export type GatewaySubscriptionUpdateDispatchData = GatewaySubscriptionModifyDis
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#subscription-delete}
*/
export type GatewaySubscriptionDeleteDispatch = GatewaySubscriptionModifyDispatch;
export type GatewaySubscriptionDeleteDispatch = _DataPayload<
GatewayDispatchEvents.SubscriptionDelete,
GatewaySubscriptionDeleteDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#subscription-delete}
@@ -723,7 +749,10 @@ export type GatewayChannelModifyDispatchData = APIChannel & {
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#channel-create}
*/
export type GatewayChannelCreateDispatch = GatewayChannelModifyDispatch;
export type GatewayChannelCreateDispatch = _DataPayload<
GatewayDispatchEvents.ChannelCreate,
GatewayChannelCreateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#channel-create}
@@ -733,7 +762,10 @@ export type GatewayChannelCreateDispatchData = GatewayChannelModifyDispatchData;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#channel-update}
*/
export type GatewayChannelUpdateDispatch = GatewayChannelModifyDispatch;
export type GatewayChannelUpdateDispatch = _DataPayload<
GatewayDispatchEvents.ChannelUpdate,
GatewayChannelUpdateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#channel-update}
@@ -743,7 +775,10 @@ export type GatewayChannelUpdateDispatchData = GatewayChannelModifyDispatchData;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#channel-delete}
*/
export type GatewayChannelDeleteDispatch = GatewayChannelModifyDispatch;
export type GatewayChannelDeleteDispatch = _DataPayload<
GatewayDispatchEvents.ChannelDelete,
GatewayChannelDeleteDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#channel-delete}
@@ -803,7 +838,10 @@ export type GatewayEntitlementCreateDispatchData = GatewayEntitlementModifyDispa
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#entitlement-create}
*/
export type GatewayEntitlementCreateDispatch = GatewayEntitlementModifyDispatch;
export type GatewayEntitlementCreateDispatch = _DataPayload<
GatewayDispatchEvents.EntitlementCreate,
GatewayEntitlementCreateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#entitlement-update}
@@ -813,7 +851,10 @@ export type GatewayEntitlementUpdateDispatchData = GatewayEntitlementModifyDispa
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#entitlement-update}
*/
export type GatewayEntitlementUpdateDispatch = GatewayEntitlementModifyDispatch;
export type GatewayEntitlementUpdateDispatch = _DataPayload<
GatewayDispatchEvents.EntitlementUpdate,
GatewayEntitlementUpdateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#entitlement-delete}
@@ -823,7 +864,10 @@ export type GatewayEntitlementDeleteDispatchData = GatewayEntitlementModifyDispa
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#entitlement-delete}
*/
export type GatewayEntitlementDeleteDispatch = GatewayEntitlementModifyDispatch;
export type GatewayEntitlementDeleteDispatch = _DataPayload<
GatewayDispatchEvents.EntitlementDelete,
GatewayEntitlementDeleteDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#guild-update}
@@ -998,7 +1042,10 @@ export interface GatewayGuildBanModifyDispatchData {
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#guild-ban-add}
*/
export type GatewayGuildBanAddDispatch = GatewayGuildBanModifyDispatch;
export type GatewayGuildBanAddDispatch = _DataPayload<
GatewayDispatchEvents.GuildBanAdd,
GatewayGuildBanAddDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#guild-ban-add}
@@ -1008,7 +1055,10 @@ export type GatewayGuildBanAddDispatchData = GatewayGuildBanModifyDispatchData;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#guild-ban-remove}
*/
export type GatewayGuildBanRemoveDispatch = GatewayGuildBanModifyDispatch;
export type GatewayGuildBanRemoveDispatch = _DataPayload<
GatewayDispatchEvents.GuildBanRemove,
GatewayGuildBanRemoveDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#guild-ban-remove}
@@ -1225,7 +1275,10 @@ export interface GatewayGuildRoleModifyDispatchData {
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#guild-role-create}
*/
export type GatewayGuildRoleCreateDispatch = GatewayGuildRoleModifyDispatch;
export type GatewayGuildRoleCreateDispatch = _DataPayload<
GatewayDispatchEvents.GuildRoleCreate,
GatewayGuildRoleCreateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#guild-role-create}
@@ -1235,7 +1288,10 @@ export type GatewayGuildRoleCreateDispatchData = GatewayGuildRoleModifyDispatchD
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#guild-role-update}
*/
export type GatewayGuildRoleUpdateDispatch = GatewayGuildRoleModifyDispatch;
export type GatewayGuildRoleUpdateDispatch = _DataPayload<
GatewayDispatchEvents.GuildRoleUpdate,
GatewayGuildRoleUpdateDispatchData
>;
/**
* @see {@link https://discord.com/developers/docs/topics/gateway-events#guild-role-update}
@@ -1519,7 +1575,7 @@ export interface GatewayInviteCreateDispatchData {
/**
* The time at which the invite was created
*/
created_at: number;
created_at: string;
/**
* The guild of the invite
*/

View File

@@ -1,6 +1,6 @@
{
"name": "discord-api-types",
"version": "0.38.41",
"version": "0.38.42",
"description": "Discord API typings that are kept up to date for use in bot library creation.",
"homepage": "https://discord-api-types.dev",
"workspaces": [

View File

@@ -17,7 +17,6 @@ export const PermissionFlagsBits = {
/**
* Allows kicking members
*/
KickMembers: 1n << 1n,
/**
* Allows banning members
@@ -38,7 +37,7 @@ export const PermissionFlagsBits = {
*/
ManageGuild: 1n << 5n,
/**
* Allows for the addition of reactions to messages
* Allows for the addition of reactions to messages. This permission does not apply to reacting with an existing reaction on a message
*
* Applies to channel types: Text, Voice, Stage
*/
@@ -234,9 +233,9 @@ export const PermissionFlagsBits = {
*/
SendMessagesInThreads: 1n << 38n,
/**
* Allows for using Activities (applications with the {@link ApplicationFlags.Embedded} flag) in a voice channel
* Allows for using Activities (applications with the {@link ApplicationFlags.Embedded} flag)
*
* Applies to channel types: Voice
* Applies to channel types: Text, Voice
*/
UseEmbeddedActivities: 1n << 39n,
/**

View File

@@ -264,6 +264,7 @@ export interface APIInteractionDataResolved {
roles?: Record<Snowflake, APIRole>;
members?: Record<Snowflake, APIInteractionDataResolvedGuildMember>;
channels?: Record<Snowflake, APIInteractionDataResolvedChannel>;
messages?: Record<Snowflake, APIMessage>;
attachments?: Record<Snowflake, APIAttachment>;
}

View File

@@ -52,6 +52,10 @@ export interface APIMessageComponentBaseInteractionData<CType extends ComponentT
* The type of the component
*/
component_type: CType;
/**
* The unique identifier for the component, as defined when the component was sent
*/
id: number;
}
export type APIMessageButtonInteractionData = APIMessageComponentBaseInteractionData<ComponentType.Button>;

View File

@@ -83,7 +83,7 @@ export type ApplicationCommandOptionAllowedChannelType = Exclude<
export interface APISlowmodeChannel<T extends ChannelType> extends APIChannelBase<T> {
/**
* 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_CHANNELS`, are unaffected
* bots, as well as users with the permission `BYPASS_SLOWMODE`, are unaffected
*
* `rate_limit_per_user` also applies to thread creation. Users can send one message and create one thread during each `rate_limit_per_user` interval.
*
@@ -366,7 +366,7 @@ export interface APIThreadOnlyChannel<T extends ChannelType.GuildForum | Channel
last_message_id?: Snowflake | null;
/**
* Amount of seconds a user has to wait before creating another thread (0-21600);
* bots, as well as users with the permission `MANAGE_MESSAGES` or `MANAGE_CHANNELS`, are unaffected
* bots, as well as users with the permission `BYPASS_SLOWMODE`, are unaffected
*
* The absence of this field in API calls and Gateway events should indicate that slowmode has been reset to the default value.
*/

View File

@@ -9,7 +9,7 @@ import type { PresenceUpdateReceiveStatus } from './gateway';
import type { OAuth2Scopes } from './oauth2';
import type { APIRole } from './permissions';
import type { APISticker } from './sticker';
import type { APIAvatarDecorationData, APIUser } from './user';
import type { APIAvatarDecorationData, APICollectibles, APIUser } from './user';
export interface APIBaseGuild {
/**
@@ -127,7 +127,7 @@ export interface APIGuild extends APIPartialGuild {
* @see {@link https://discord.com/developers/docs/resources/voice#voice-region-object}
* @deprecated This field has been deprecated in favor of `rtc_region` on the channel.
*/
region: string;
region?: string | null;
/**
* ID of afk channel
*/
@@ -275,7 +275,7 @@ export interface APIGuild extends APIPartialGuild {
*
* @see {@link https://discord.com/developers/docs/resources/sticker#sticker-object}
*/
stickers: APISticker[];
stickers?: APISticker[];
/**
* Whether the guild has the boost progress bar enabled.
*/
@@ -638,7 +638,7 @@ export interface APIGuildPreview {
/**
* The description for the guild
*/
description: string;
description: string | null;
/**
* Custom guild stickers
*/
@@ -695,6 +695,12 @@ export interface APIBaseGuildMember {
* @see {@link https://discord.com/developers/docs/resources/user#avatar-decoration-data-object}
*/
avatar_decoration_data?: APIAvatarDecorationData | null;
/**
* The data for the member's collectibles
*
* @see {@link https://discord.com/developers/docs/resources/user#collectibles}
*/
collectibles?: APICollectibles | null;
}
/**

View File

@@ -253,6 +253,10 @@ export interface APIBaseMessageNoChannel {
* The call associated with the message
*/
call?: APIMessageCall;
/**
* The custom client-side theme shared via the message
*/
shared_client_theme?: APIMessageSharedClientTheme;
}
/**
@@ -463,6 +467,38 @@ export interface APIMessageCall {
ended_timestamp?: string | null;
}
/**
* @see https://docs.discord.com/developers/resources/message#base-theme-types
*/
export enum BaseThemeType {
Dark = 1,
Light,
Darker,
Midnight,
}
/**
* @see https://docs.discord.com/developers/resources/message#shared-client-theme-object
*/
export interface APIMessageSharedClientTheme {
/**
* The hexadecimal-encoded colors of the theme (max of 5)
*/
colors: string[];
/**
* The direction of the theme's colors (max of 360)
*/
gradient_angle: number;
/**
* The intensity of the theme's colors (max of 100)
*/
base_mix: number;
/**
* The mode of the theme
*/
base_theme?: BaseThemeType | null;
}
/**
* @see {@link https://discord.com/developers/docs/resources/message#role-subscription-data-object-role-subscription-data-object-structure}
*/
@@ -1036,20 +1072,14 @@ export enum ComponentType {
FileUpload,
/**
* Single-choice set of radio group option
*
* @unstable This component is not publicly released and is currently in preview.
*/
RadioGroup = 21,
/**
* Multi-select group of checkboxes
*
* @unstable This component is not publicly released and is currently in preview.
*/
CheckboxGroup,
/**
* Single checkbox for binary choice
*
* @unstable This component is not publicly released and is currently in preview.
*/
Checkbox,
// EVERYTHING BELOW THIS LINE SHOULD BE OLD NAMES FOR RENAMED ENUM MEMBERS //
@@ -1717,7 +1747,6 @@ export interface APIFileUploadComponent extends APIBaseComponent<ComponentType.F
/**
* @see {@link https://discord.com/developers/docs/components/reference#radio-group}
* @unstable This component is not publicly released and is currently in preview.
*/
export interface APIRadioGroupComponent extends APIBaseComponent<ComponentType.RadioGroup> {
/**
@@ -1738,7 +1767,6 @@ export interface APIRadioGroupComponent extends APIBaseComponent<ComponentType.R
/**
* @see {@link https://discord.com/developers/docs/components/reference#radio-group-option-structure}
* @unstable This feature is not publicly released and is currently in preview.
*/
export interface APIRadioGroupOption {
/**
@@ -1763,7 +1791,6 @@ export interface APIRadioGroupOption {
/**
* @see {@link https://discord.com/developers/docs/components/reference#checkbox-group}
* @unstable This component is not publicly released and is currently in preview.
*/
export interface APICheckboxGroupComponent extends APIBaseComponent<ComponentType.CheckboxGroup> {
/**
@@ -1796,7 +1823,6 @@ export interface APICheckboxGroupComponent extends APIBaseComponent<ComponentTyp
/**
* @see {@link https://discord.com/developers/docs/components/reference#checkbox-group-option-structure}
* @unstable This feature is not publicly released and is currently in preview.
*/
export interface APICheckboxGroupOption {
/**
@@ -1821,7 +1847,6 @@ export interface APICheckboxGroupOption {
/**
* @see {@link https://discord.com/developers/docs/components/reference#checkbox}
* @unstable This component is not publicly released and is currently in preview.
*/
export interface APICheckboxComponent extends APIBaseComponent<ComponentType.Checkbox> {
/**

View File

@@ -19,13 +19,14 @@ export interface APIRole {
/**
* Integer representation of hexadecimal color code
*
* @deprecated Use `colors` instead.
* @remarks `color` will still be returned by the API, but using the `colors` field is recommended when doing requests.
*/
color: number;
/**
* The role's colors
*/
colors?: APIRoleColors;
colors: APIRoleColors;
/**
* If this role is pinned in the user listing
*/

View File

@@ -37,7 +37,7 @@ export interface APIPoll extends APIBasePoll, APIPollDefaults {
/**
* The time when the poll ends (IS08601 timestamp)
*/
expiry: string;
expiry: string | null;
/**
* The results of the poll
*/

View File

@@ -123,14 +123,8 @@ export interface APIWebhookEventApplicationDeauthorizedData {
export type APIWebhookEventEntitlementCreateData = APIEntitlement;
/**
* @unstable
*/
export type APIWebhookEventEntitlementDeleteData = APIEntitlement;
/**
* @unstable
*/
export type APIWebhookEventEntitlementUpdateData = APIEntitlement;
export type APIWebhookEventQuestUserEnrollmentData = never;
@@ -201,14 +195,10 @@ export enum ApplicationWebhookEventType {
EntitlementCreate = 'ENTITLEMENT_CREATE',
/**
* Entitlement was updated
*
* @unstable This event is not yet documented but can be enabled from the developer portal
*/
EntitlementUpdate = 'ENTITLEMENT_UPDATE',
/**
* Entitlement was deleted
*
* @unstable This event is not yet documented but can be enabled from the developer portal
*/
EntitlementDelete = 'ENTITLEMENT_DELETE',
/**

View File

@@ -267,6 +267,7 @@ export interface APIInteractionDataResolved {
roles?: Record<Snowflake, APIRole>;
members?: Record<Snowflake, APIInteractionDataResolvedGuildMember>;
channels?: Record<Snowflake, APIInteractionDataResolvedChannel>;
messages?: Record<Snowflake, APIMessage>;
attachments?: Record<Snowflake, APIAttachment>;
}

View File

@@ -52,6 +52,10 @@ export interface APIMessageComponentBaseInteractionData<CType extends ComponentT
* The type of the component
*/
component_type: CType;
/**
* The unique identifier for the component, as defined when the component was sent
*/
id: number;
}
export type APIMessageButtonInteractionData = APIMessageComponentBaseInteractionData<ComponentType.Button>;

View File

@@ -78,7 +78,7 @@ export type GuildChannelType = Exclude<ChannelType, ChannelType.DM | ChannelType
export interface APISlowmodeChannel<T extends ChannelType> extends APIChannelBase<T> {
/**
* 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_CHANNELS`, are unaffected
* bots, as well as users with the permission `BYPASS_SLOWMODE`, are unaffected
*
* `rate_limit_per_user` also applies to thread creation. Users can send one message and create one thread during each `rate_limit_per_user` interval.
*
@@ -361,7 +361,7 @@ export interface APIThreadOnlyChannel<T extends ChannelType.GuildForum | Channel
last_message_id?: Snowflake | null;
/**
* Amount of seconds a user has to wait before creating another thread (0-21600);
* bots, as well as users with the permission `MANAGE_MESSAGES` or `MANAGE_CHANNELS`, are unaffected
* bots, as well as users with the permission `BYPASS_SLOWMODE`, are unaffected
*
* The absence of this field in API calls and Gateway events should indicate that slowmode has been reset to the default value.
*/

View File

@@ -9,7 +9,7 @@ import type { PresenceUpdateReceiveStatus } from './gateway';
import type { OAuth2Scopes } from './oauth2';
import type { APIRole } from './permissions';
import type { APISticker } from './sticker';
import type { APIAvatarDecorationData, APIUser } from './user';
import type { APIAvatarDecorationData, APICollectibles, APIUser } from './user';
export interface APIBaseGuild {
/**
@@ -127,7 +127,7 @@ export interface APIGuild extends APIPartialGuild {
* @see {@link https://discord.com/developers/docs/resources/voice#voice-region-object}
* @deprecated This field has been deprecated in favor of `rtc_region` on the channel.
*/
region: string;
region?: string | null;
/**
* ID of afk channel
*/
@@ -275,7 +275,7 @@ export interface APIGuild extends APIPartialGuild {
*
* @see {@link https://discord.com/developers/docs/resources/sticker#sticker-object}
*/
stickers: APISticker[];
stickers?: APISticker[];
/**
* Whether the guild has the boost progress bar enabled.
*/
@@ -630,7 +630,7 @@ export interface APIGuildPreview {
/**
* The description for the guild
*/
description: string;
description: string | null;
/**
* Custom guild stickers
*/
@@ -687,6 +687,12 @@ export interface APIBaseGuildMember {
* @see {@link https://discord.com/developers/docs/resources/user#avatar-decoration-data-object}
*/
avatar_decoration_data?: APIAvatarDecorationData | null;
/**
* The data for the member's collectibles
*
* @see {@link https://discord.com/developers/docs/resources/user#collectibles}
*/
collectibles?: APICollectibles | null;
}
/**

View File

@@ -248,6 +248,10 @@ export interface APIBaseMessageNoChannel {
* The call associated with the message
*/
call?: APIMessageCall;
/**
* The custom client-side theme shared via the message
*/
shared_client_theme?: APIMessageSharedClientTheme;
}
/**
@@ -458,6 +462,38 @@ export interface APIMessageCall {
ended_timestamp?: string | null;
}
/**
* @see https://docs.discord.com/developers/resources/message#base-theme-types
*/
export enum BaseThemeType {
Dark = 1,
Light,
Darker,
Midnight,
}
/**
* @see https://docs.discord.com/developers/resources/message#shared-client-theme-object
*/
export interface APIMessageSharedClientTheme {
/**
* The hexadecimal-encoded colors of the theme (max of 5)
*/
colors: string[];
/**
* The direction of the theme's colors (max of 360)
*/
gradient_angle: number;
/**
* The intensity of the theme's colors (max of 100)
*/
base_mix: number;
/**
* The mode of the theme
*/
base_theme?: BaseThemeType | null;
}
/**
* @see {@link https://discord.com/developers/docs/resources/message#role-subscription-data-object-role-subscription-data-object-structure}
*/
@@ -1031,20 +1067,14 @@ export enum ComponentType {
FileUpload,
/**
* Single-choice set of radio group option
*
* @unstable This component is not publicly released and is currently in preview.
*/
RadioGroup = 21,
/**
* Multi-select group of checkboxes
*
* @unstable This component is not publicly released and is currently in preview.
*/
CheckboxGroup,
/**
* Single checkbox for binary choice
*
* @unstable This component is not publicly released and is currently in preview.
*/
Checkbox,
// EVERYTHING BELOW THIS LINE SHOULD BE OLD NAMES FOR RENAMED ENUM MEMBERS //
@@ -1712,7 +1742,6 @@ export interface APIFileUploadComponent extends APIBaseComponent<ComponentType.F
/**
* @see {@link https://discord.com/developers/docs/components/reference#radio-group}
* @unstable This component is not publicly released and is currently in preview.
*/
export interface APIRadioGroupComponent extends APIBaseComponent<ComponentType.RadioGroup> {
/**
@@ -1758,7 +1787,6 @@ export interface APIRadioGroupOption {
/**
* @see {@link https://discord.com/developers/docs/components/reference#checkbox-group}
* @unstable This component is not publicly released and is currently in preview.
*/
export interface APICheckboxGroupComponent extends APIBaseComponent<ComponentType.CheckboxGroup> {
/**
@@ -1791,7 +1819,6 @@ export interface APICheckboxGroupComponent extends APIBaseComponent<ComponentTyp
/**
* @see {@link https://discord.com/developers/docs/components/reference#checkbox-group-option-structure}
* @unstable This feature is not publicly released and is currently in preview.
*/
export interface APICheckboxGroupOption {
/**
@@ -1816,7 +1843,6 @@ export interface APICheckboxGroupOption {
/**
* @see {@link https://discord.com/developers/docs/components/reference#checkbox}
* @unstable This component is not publicly released and is currently in preview.
*/
export interface APICheckboxComponent extends APIBaseComponent<ComponentType.Checkbox> {
/**

View File

@@ -19,13 +19,14 @@ export interface APIRole {
/**
* Integer representation of hexadecimal color code
*
* @deprecated Use `colors` instead.
* @remarks `color` will still be returned by the API, but using the `colors` field is recommended when doing requests.
*/
color: number;
/**
* The role's colors
*/
colors?: APIRoleColors;
colors: APIRoleColors;
/**
* If this role is pinned in the user listing
*/

View File

@@ -37,7 +37,7 @@ export interface APIPoll extends APIBasePoll, APIPollDefaults {
/**
* The time when the poll ends (IS08601 timestamp)
*/
expiry: string;
expiry: string | null;
/**
* The results of the poll
*/

View File

@@ -123,14 +123,8 @@ export interface APIWebhookEventApplicationDeauthorizedData {
export type APIWebhookEventEntitlementCreateData = APIEntitlement;
/**
* @unstable
*/
export type APIWebhookEventEntitlementDeleteData = APIEntitlement;
/**
* @unstable
*/
export type APIWebhookEventEntitlementUpdateData = APIEntitlement;
export type APIWebhookEventQuestUserEnrollmentData = never;
@@ -201,14 +195,10 @@ export enum ApplicationWebhookEventType {
EntitlementCreate = 'ENTITLEMENT_CREATE',
/**
* Entitlement was updated
*
* @unstable This event is not yet documented but can be enabled from the developer portal
*/
EntitlementUpdate = 'ENTITLEMENT_UPDATE',
/**
* Entitlement was deleted
*
* @unstable This event is not yet documented but can be enabled from the developer portal
*/
EntitlementDelete = 'ENTITLEMENT_DELETE',
/**

View File

@@ -25,11 +25,13 @@ export type RESTGetCurrentApplicationResult = APIApplication;
* @see {@link https://discord.com/developers/docs/resources/application#edit-current-application}
*/
export type RESTPatchCurrentApplicationJSONBody = _StrictPartial<
_Nullable<Pick<APIApplication, 'cover_image' | 'icon'>> &
_Nullable<Pick<APIApplication, 'cover_image' | 'event_webhooks_url' | 'icon'>> &
Pick<
APIApplication,
| 'custom_install_url'
| 'description'
| 'event_webhooks_status'
| 'event_webhooks_types'
| 'flags'
| 'install_params'
| 'integration_types_config'

View File

@@ -7,6 +7,7 @@ import type {
APIFollowedChannel,
APIMessage,
APIMessageReference,
APIMessageSharedClientTheme,
APIThreadList,
APIThreadMember,
APIUser,
@@ -84,8 +85,7 @@ export interface RESTPatchAPIChannelJSONBody {
nsfw?: boolean | null | undefined;
/**
* 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_CHANNELS`,
* are unaffected
* bots, as well as users with the permission `BYPASS_SLOWMODE`, are unaffected
*
* Channel types: text, newsThread, publicThread, privateThread, forum, media
*/
@@ -149,7 +149,7 @@ export interface RESTPatchAPIChannelJSONBody {
*
* Channel types: text, news, forum, media
*/
default_auto_archive_duration?: ThreadAutoArchiveDuration | undefined;
default_auto_archive_duration?: ThreadAutoArchiveDuration | null | undefined;
/**
* Channel flags combined as a bit field.
*/
@@ -171,7 +171,7 @@ export interface RESTPatchAPIChannelJSONBody {
*
* Channel types: forum, media
*/
default_reaction_emoji?: APIGuildForumDefaultReactionEmoji | undefined;
default_reaction_emoji?: APIGuildForumDefaultReactionEmoji | null | undefined;
/**
* The initial `rate_limit_per_user` to set on newly created threads in a channel.
* This field is copied to the thread at creation time and does not live update
@@ -338,6 +338,10 @@ export interface RESTPostAPIChannelMessageJSONBody {
* A poll!
*/
poll?: RESTAPIPoll | undefined;
/**
* The custom client-side theme to share via the message
*/
shared_client_theme?: APIMessageSharedClientTheme | undefined;
}
/**

View File

@@ -20,6 +20,7 @@ import type {
GuildDefaultMessageNotifications,
GuildExplicitContentFilter,
GuildFeature,
GuildMemberFlags,
GuildMFALevel,
GuildSystemChannelFlags,
GuildVerificationLevel,
@@ -381,11 +382,11 @@ export type RESTPatchAPIGuildChannelPositionsJSONBody = {
/**
* Sorting position of the channel
*/
position: number;
position?: number | null | undefined;
/**
* Sync channel overwrites with the new parent, when moving to a new `parent_id`
*/
lock_permissions?: boolean | undefined;
lock_permissions?: boolean | null | undefined;
/**
* The new parent id of this channel
*/
@@ -522,6 +523,12 @@ export interface RESTPatchAPIGuildMemberJSONBody {
* Timestamp of when the time out will be removed; until then, they cannot interact with the guild
*/
communication_disabled_until?: string | null | undefined;
/**
* Guild member flags (only {@link GuildMemberFlags.BypassesVerification} can be set)
*
* @see {@link https://discord.com/developers/docs/resources/guild#guild-member-object-guild-member-flags}
*/
flags?: GuildMemberFlags | undefined;
}
/**

View File

@@ -56,7 +56,7 @@ export interface RESTPostAPIGuildScheduledEventJSONBody {
/**
* The scheduled entity type of the guild event
*/
entity_type?: GuildScheduledEventEntityType | undefined;
entity_type: GuildScheduledEventEntityType;
/**
* The entity metadata of the scheduled event
*/
@@ -98,8 +98,12 @@ export interface RESTPatchAPIGuildScheduledEventJSONBody
extends
_Nullable<Pick<RESTPostAPIGuildScheduledEventJSONBody, 'description' | 'entity_metadata' | 'recurrence_rule'>>,
_StrictPartial<
Omit<RESTPostAPIGuildScheduledEventJSONBody, 'description' | 'entity_metadata' | 'recurrence_rule'>
Omit<
RESTPostAPIGuildScheduledEventJSONBody,
'channel_id' | 'description' | 'entity_metadata' | 'recurrence_rule'
>
> {
channel_id?: Snowflake | null | undefined;
/**
* The status of the scheduled event
*/

View File

@@ -4,7 +4,7 @@ import type { APISoundboardSound } from '../../payloads/v10/index';
/**
* @see {@link https://discord.com/developers/docs/resources/soundboard#send-soundboard-sound}
*/
export type RESTPostAPISendSoundboardSoundResult = APISoundboardSound;
export type RESTPostAPISendSoundboardSoundResult = never;
/**
* @see {@link https://discord.com/developers/docs/resources/soundboard#send-soundboard-sound-json-params}

View File

@@ -25,11 +25,13 @@ export type RESTGetCurrentApplicationResult = APIApplication;
* @see {@link https://discord.com/developers/docs/resources/application#edit-current-application}
*/
export type RESTPatchCurrentApplicationJSONBody = _StrictPartial<
_Nullable<Pick<APIApplication, 'cover_image' | 'icon'>> &
_Nullable<Pick<APIApplication, 'cover_image' | 'event_webhooks_url' | 'icon'>> &
Pick<
APIApplication,
| 'custom_install_url'
| 'description'
| 'event_webhooks_status'
| 'event_webhooks_types'
| 'flags'
| 'install_params'
| 'integration_types_config'

View File

@@ -7,6 +7,7 @@ import type {
APIFollowedChannel,
APIMessage,
APIMessageReference,
APIMessageSharedClientTheme,
APIThreadList,
APIThreadMember,
APIUser,
@@ -84,8 +85,7 @@ export interface RESTPatchAPIChannelJSONBody {
nsfw?: boolean | null | undefined;
/**
* 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_CHANNELS`,
* are unaffected
* bots, as well as users with the permission `BYPASS_SLOWMODE`, are unaffected
*
* Channel types: text, newsThread, publicThread, privateThread, forum, media
*/
@@ -149,7 +149,7 @@ export interface RESTPatchAPIChannelJSONBody {
*
* Channel types: text, news, forum, media
*/
default_auto_archive_duration?: ThreadAutoArchiveDuration | undefined;
default_auto_archive_duration?: ThreadAutoArchiveDuration | null | undefined;
/**
* Channel flags combined as a bit field.
*/
@@ -171,7 +171,7 @@ export interface RESTPatchAPIChannelJSONBody {
*
* Channel types: forum, media
*/
default_reaction_emoji?: APIGuildForumDefaultReactionEmoji | undefined;
default_reaction_emoji?: APIGuildForumDefaultReactionEmoji | null | undefined;
/**
* The initial `rate_limit_per_user` to set on newly created threads in a channel.
* This field is copied to the thread at creation time and does not live update
@@ -345,6 +345,10 @@ export interface RESTPostAPIChannelMessageJSONBody {
* A poll!
*/
poll?: RESTAPIPoll | undefined;
/**
* The custom client-side theme to share via the message
*/
shared_client_theme?: APIMessageSharedClientTheme | undefined;
}
/**

View File

@@ -18,6 +18,7 @@ import type {
GuildDefaultMessageNotifications,
GuildExplicitContentFilter,
GuildFeature,
GuildMemberFlags,
GuildMFALevel,
GuildSystemChannelFlags,
GuildVerificationLevel,
@@ -381,11 +382,11 @@ export type RESTPatchAPIGuildChannelPositionsJSONBody = {
/**
* Sorting position of the channel
*/
position: number;
position?: number | null | undefined;
/**
* Sync channel overwrites with the new parent, when moving to a new `parent_id`
*/
lock_permissions?: boolean | undefined;
lock_permissions?: boolean | null | undefined;
/**
* The new parent id of this channel
*/
@@ -522,6 +523,12 @@ export interface RESTPatchAPIGuildMemberJSONBody {
* Timestamp of when the time out will be removed; until then, they cannot interact with the guild
*/
communication_disabled_until?: string | null | undefined;
/**
* Guild member flags (only {@link GuildMemberFlags.BypassesVerification} can be set)
*
* @see {@link https://discord.com/developers/docs/resources/guild#guild-member-object-guild-member-flags}
*/
flags?: GuildMemberFlags | undefined;
}
/**

View File

@@ -56,7 +56,7 @@ export interface RESTPostAPIGuildScheduledEventJSONBody {
/**
* The scheduled entity type of the guild event
*/
entity_type?: GuildScheduledEventEntityType | undefined;
entity_type: GuildScheduledEventEntityType;
/**
* The entity metadata of the scheduled event
*/
@@ -98,8 +98,12 @@ export interface RESTPatchAPIGuildScheduledEventJSONBody
extends
_Nullable<Pick<RESTPostAPIGuildScheduledEventJSONBody, 'description' | 'entity_metadata' | 'recurrence_rule'>>,
_StrictPartial<
Omit<RESTPostAPIGuildScheduledEventJSONBody, 'description' | 'entity_metadata' | 'recurrence_rule'>
Omit<
RESTPostAPIGuildScheduledEventJSONBody,
'channel_id' | 'description' | 'entity_metadata' | 'recurrence_rule'
>
> {
channel_id?: Snowflake | null | undefined;
/**
* The status of the scheduled event
*/

View File

@@ -4,7 +4,7 @@ import type { APISoundboardSound } from '../../payloads/v9/index';
/**
* @see {@link https://discord.com/developers/docs/resources/soundboard#send-soundboard-sound}
*/
export type RESTPostAPISendSoundboardSoundResult = APISoundboardSound;
export type RESTPostAPISendSoundboardSoundResult = never;
/**
* @see {@link https://discord.com/developers/docs/resources/soundboard#send-soundboard-sound-json-params}

View File

@@ -7063,15 +7063,6 @@
"react-dom": ">=16.8"
}
},
"node_modules/@trysound/sax": {
"version": "0.2.0",
"resolved": "https://registry.npmjs.org/@trysound/sax/-/sax-0.2.0.tgz",
"integrity": "sha512-L7z9BgrNEcYyUYtF+HaEfiS5ebkh9jXqbszz7pC0hRBPaatV0XjSD3+eHrpqFemQfgwiFF0QPIarnIihIDn7OA==",
"license": "ISC",
"engines": {
"node": ">=10.13.0"
}
},
"node_modules/@ts-morph/common": {
"version": "0.27.0",
"resolved": "https://registry.npmjs.org/@ts-morph/common/-/common-0.27.0.tgz",
@@ -14972,10 +14963,9 @@
}
},
"node_modules/immutable": {
"version": "5.0.3",
"resolved": "https://registry.npmjs.org/immutable/-/immutable-5.0.3.tgz",
"integrity": "sha512-P8IdPQHq3lA1xVeBRi5VPqUm5HDgKnx0Ru51wZz5mjxHr5n3RWhjIpOFU7ybkUxfB+5IToy+OLaHYDBIWsv+uw==",
"license": "MIT"
"version": "5.1.5",
"resolved": "https://registry.npmjs.org/immutable/-/immutable-5.1.5.tgz",
"integrity": "sha512-t7xcm2siw+hlUM68I+UEOK+z84RzmN59as9DZ7P1l0994DKUWV7UXBMQZVxaoMSRQ+PBZbHCOoBt7a2wxOMt+A=="
},
"node_modules/import-fresh": {
"version": "3.3.0",
@@ -23409,9 +23399,12 @@
}
},
"node_modules/sax": {
"version": "1.4.1",
"resolved": "https://registry.npmjs.org/sax/-/sax-1.4.1.tgz",
"integrity": "sha512-+aWOz7yVScEGoKNd4PA10LZ8sk0A/z5+nXQG5giUO5rprX9jgYsTdov9qCchZiPIZezbZH+jRut8nPodFAX4Jg=="
"version": "1.5.0",
"resolved": "https://registry.npmjs.org/sax/-/sax-1.5.0.tgz",
"integrity": "sha512-21IYA3Q5cQf089Z6tgaUTr7lDAyzoTPx5HRtbhsME8Udispad8dC/+sziTNugOEx54ilvatQ9YCzl4KQLPcRHA==",
"engines": {
"node": ">=11.0.0"
}
},
"node_modules/scheduler": {
"version": "0.23.2",
@@ -24491,18 +24484,17 @@
"license": "MIT"
},
"node_modules/svgo": {
"version": "3.3.2",
"resolved": "https://registry.npmjs.org/svgo/-/svgo-3.3.2.tgz",
"integrity": "sha512-OoohrmuUlBs8B8o6MB2Aevn+pRIH9zDALSR+6hhqVfa6fRwG/Qw9VUMSMW9VNg2CFc/MTIfabtdOVl9ODIJjpw==",
"license": "MIT",
"version": "3.3.3",
"resolved": "https://registry.npmjs.org/svgo/-/svgo-3.3.3.tgz",
"integrity": "sha512-+wn7I4p7YgJhHs38k2TNjy1vCfPIfLIJWR5MnCStsN8WuuTcBnRKcMHQLMM2ijxGZmDoZwNv8ipl5aTTen62ng==",
"dependencies": {
"@trysound/sax": "0.2.0",
"commander": "^7.2.0",
"css-select": "^5.1.0",
"css-tree": "^2.3.1",
"css-what": "^6.1.0",
"csso": "^5.0.5",
"picocolors": "^1.0.0"
"picocolors": "^1.0.0",
"sax": "^1.5.0"
},
"bin": {
"svgo": "bin/svgo"
@@ -31633,11 +31625,6 @@
"tippy.js": "^6.3.1"
}
},
"@trysound/sax": {
"version": "0.2.0",
"resolved": "https://registry.npmjs.org/@trysound/sax/-/sax-0.2.0.tgz",
"integrity": "sha512-L7z9BgrNEcYyUYtF+HaEfiS5ebkh9jXqbszz7pC0hRBPaatV0XjSD3+eHrpqFemQfgwiFF0QPIarnIihIDn7OA=="
},
"@ts-morph/common": {
"version": "0.27.0",
"resolved": "https://registry.npmjs.org/@ts-morph/common/-/common-0.27.0.tgz",
@@ -37116,9 +37103,9 @@
"integrity": "sha512-IRqXKlaXwgSMAMtpNzZa1ZAe8m+Sa1770Dhk8VkSsP9LS+iHD62Zd8FQKs8fbPiagBE7BzoFX23cxFnwshpV6w=="
},
"immutable": {
"version": "5.0.3",
"resolved": "https://registry.npmjs.org/immutable/-/immutable-5.0.3.tgz",
"integrity": "sha512-P8IdPQHq3lA1xVeBRi5VPqUm5HDgKnx0Ru51wZz5mjxHr5n3RWhjIpOFU7ybkUxfB+5IToy+OLaHYDBIWsv+uw=="
"version": "5.1.5",
"resolved": "https://registry.npmjs.org/immutable/-/immutable-5.1.5.tgz",
"integrity": "sha512-t7xcm2siw+hlUM68I+UEOK+z84RzmN59as9DZ7P1l0994DKUWV7UXBMQZVxaoMSRQ+PBZbHCOoBt7a2wxOMt+A=="
},
"import-fresh": {
"version": "3.3.0",
@@ -42257,9 +42244,9 @@
}
},
"sax": {
"version": "1.4.1",
"resolved": "https://registry.npmjs.org/sax/-/sax-1.4.1.tgz",
"integrity": "sha512-+aWOz7yVScEGoKNd4PA10LZ8sk0A/z5+nXQG5giUO5rprX9jgYsTdov9qCchZiPIZezbZH+jRut8nPodFAX4Jg=="
"version": "1.5.0",
"resolved": "https://registry.npmjs.org/sax/-/sax-1.5.0.tgz",
"integrity": "sha512-21IYA3Q5cQf089Z6tgaUTr7lDAyzoTPx5HRtbhsME8Udispad8dC/+sziTNugOEx54ilvatQ9YCzl4KQLPcRHA=="
},
"scheduler": {
"version": "0.23.2",
@@ -43072,17 +43059,17 @@
"integrity": "sha512-e4hG1hRwoOdRb37cIMSgzNsxyzKfayW6VOflrwvR+/bzrkyxY/31WkbgnQpgtrNp1SdpJvpUAGTa/ZoiPNDuRQ=="
},
"svgo": {
"version": "3.3.2",
"resolved": "https://registry.npmjs.org/svgo/-/svgo-3.3.2.tgz",
"integrity": "sha512-OoohrmuUlBs8B8o6MB2Aevn+pRIH9zDALSR+6hhqVfa6fRwG/Qw9VUMSMW9VNg2CFc/MTIfabtdOVl9ODIJjpw==",
"version": "3.3.3",
"resolved": "https://registry.npmjs.org/svgo/-/svgo-3.3.3.tgz",
"integrity": "sha512-+wn7I4p7YgJhHs38k2TNjy1vCfPIfLIJWR5MnCStsN8WuuTcBnRKcMHQLMM2ijxGZmDoZwNv8ipl5aTTen62ng==",
"requires": {
"@trysound/sax": "0.2.0",
"commander": "^7.2.0",
"css-select": "^5.1.0",
"css-tree": "^2.3.1",
"css-what": "^6.1.0",
"csso": "^5.0.5",
"picocolors": "^1.0.0"
"picocolors": "^1.0.0",
"sax": "^1.5.0"
},
"dependencies": {
"commander": {

View File

@@ -1 +1 @@
[{"entryPoints":{"v10":{"path":"v10.ts","label":"API v10"},"v9":{"path":"v9.ts","label":"API v9"},"voice/v4":{"path":"voice/v4.ts","label":"Voice v4"},"voice/v8":{"path":"voice/v8.ts","label":"Voice v8"},"globals":{"path":"globals.ts","label":"Global Types"}},"packageRoot":"/home/runner/work/discord-api-types/discord-api-types/","packagePath":"./","packageSlug":"discord-api-types","packageName":"discord-api-types","packageVersion":"0.38.41"}]
[{"entryPoints":{"v10":{"path":"v10.ts","label":"API v10"},"v9":{"path":"v9.ts","label":"API v9"},"voice/v4":{"path":"voice/v4.ts","label":"Voice v4"},"voice/v8":{"path":"voice/v8.ts","label":"Voice v8"},"globals":{"path":"globals.ts","label":"Global Types"}},"packageRoot":"/home/runner/work/discord-api-types/discord-api-types/","packagePath":"./","packageSlug":"discord-api-types","packageName":"discord-api-types","packageVersion":"0.38.42"}]

View File

@@ -1,3 +1,3 @@
[
"0.38.41"
"0.38.42"
]

2486
yarn.lock

File diff suppressed because it is too large Load Diff