diff --git a/deno/payloads/v10/invite.ts b/deno/payloads/v10/invite.ts index b2d0ea26..b23e67ea 100644 --- a/deno/payloads/v10/invite.ts +++ b/deno/payloads/v10/invite.ts @@ -4,11 +4,26 @@ import type { APIApplication } from './application.ts'; import type { APIPartialChannel } from './channel.ts'; -import type { APIPartialGuild } from './guild.ts'; +import type { APIGuild } from './guild.ts'; import type { APIGuildScheduledEvent } from './guildScheduledEvent.ts'; import type { APIInviteStageInstance } from './stageInstance.ts'; import type { APIUser } from './user.ts'; +export type APIInviteGuild = Pick< + APIGuild, + | 'id' + | 'name' + | 'splash' + | 'banner' + | 'icon' + | 'vanity_url_code' + | 'description' + | 'features' + | 'verification_level' + | 'nsfw_level' + | 'premium_subscription_count' +>; + /** * https://discord.com/developers/docs/resources/invite#invite-object */ @@ -22,7 +37,7 @@ export interface APIInvite { * * See https://discord.com/developers/docs/resources/guild#guild-object */ - guild?: APIPartialGuild; + guild?: APIInviteGuild; /** * The channel this invite is for * diff --git a/deno/payloads/v8/invite.ts b/deno/payloads/v8/invite.ts index 40758583..d427db0a 100644 --- a/deno/payloads/v8/invite.ts +++ b/deno/payloads/v8/invite.ts @@ -4,11 +4,26 @@ import type { APIApplication } from './application.ts'; import type { APIPartialChannel } from './channel.ts'; -import type { APIPartialGuild } from './guild.ts'; +import type { APIGuild } from './guild.ts'; import type { APIGuildScheduledEvent } from './guildScheduledEvent.ts'; import type { APIInviteStageInstance } from './stageInstance.ts'; import type { APIUser } from './user.ts'; +export type APIInviteGuild = Pick< + APIGuild, + | 'id' + | 'name' + | 'splash' + | 'banner' + | 'icon' + | 'vanity_url_code' + | 'description' + | 'features' + | 'verification_level' + | 'nsfw_level' + | 'premium_subscription_count' +>; + /** * https://discord.com/developers/docs/resources/invite#invite-object * @deprecated API and gateway v8 are deprecated and the types will not receive further updates, please update to v10. @@ -23,7 +38,7 @@ export interface APIInvite { * * See https://discord.com/developers/docs/resources/guild#guild-object */ - guild?: APIPartialGuild; + guild?: APIInviteGuild; /** * The channel this invite is for * diff --git a/deno/payloads/v9/invite.ts b/deno/payloads/v9/invite.ts index b2d0ea26..b23e67ea 100644 --- a/deno/payloads/v9/invite.ts +++ b/deno/payloads/v9/invite.ts @@ -4,11 +4,26 @@ import type { APIApplication } from './application.ts'; import type { APIPartialChannel } from './channel.ts'; -import type { APIPartialGuild } from './guild.ts'; +import type { APIGuild } from './guild.ts'; import type { APIGuildScheduledEvent } from './guildScheduledEvent.ts'; import type { APIInviteStageInstance } from './stageInstance.ts'; import type { APIUser } from './user.ts'; +export type APIInviteGuild = Pick< + APIGuild, + | 'id' + | 'name' + | 'splash' + | 'banner' + | 'icon' + | 'vanity_url_code' + | 'description' + | 'features' + | 'verification_level' + | 'nsfw_level' + | 'premium_subscription_count' +>; + /** * https://discord.com/developers/docs/resources/invite#invite-object */ @@ -22,7 +37,7 @@ export interface APIInvite { * * See https://discord.com/developers/docs/resources/guild#guild-object */ - guild?: APIPartialGuild; + guild?: APIInviteGuild; /** * The channel this invite is for * diff --git a/payloads/v10/invite.ts b/payloads/v10/invite.ts index 3a58e0ad..450caa38 100644 --- a/payloads/v10/invite.ts +++ b/payloads/v10/invite.ts @@ -4,11 +4,26 @@ import type { APIApplication } from './application'; import type { APIPartialChannel } from './channel'; -import type { APIPartialGuild } from './guild'; +import type { APIGuild } from './guild'; import type { APIGuildScheduledEvent } from './guildScheduledEvent'; import type { APIInviteStageInstance } from './stageInstance'; import type { APIUser } from './user'; +export type APIInviteGuild = Pick< + APIGuild, + | 'id' + | 'name' + | 'splash' + | 'banner' + | 'icon' + | 'vanity_url_code' + | 'description' + | 'features' + | 'verification_level' + | 'nsfw_level' + | 'premium_subscription_count' +>; + /** * https://discord.com/developers/docs/resources/invite#invite-object */ @@ -22,7 +37,7 @@ export interface APIInvite { * * See https://discord.com/developers/docs/resources/guild#guild-object */ - guild?: APIPartialGuild; + guild?: APIInviteGuild; /** * The channel this invite is for * diff --git a/payloads/v8/invite.ts b/payloads/v8/invite.ts index 18a2cc9b..7c5baf2e 100644 --- a/payloads/v8/invite.ts +++ b/payloads/v8/invite.ts @@ -4,11 +4,26 @@ import type { APIApplication } from './application'; import type { APIPartialChannel } from './channel'; -import type { APIPartialGuild } from './guild'; +import type { APIGuild } from './guild'; import type { APIGuildScheduledEvent } from './guildScheduledEvent'; import type { APIInviteStageInstance } from './stageInstance'; import type { APIUser } from './user'; +export type APIInviteGuild = Pick< + APIGuild, + | 'id' + | 'name' + | 'splash' + | 'banner' + | 'icon' + | 'vanity_url_code' + | 'description' + | 'features' + | 'verification_level' + | 'nsfw_level' + | 'premium_subscription_count' +>; + /** * https://discord.com/developers/docs/resources/invite#invite-object * @deprecated API and gateway v8 are deprecated and the types will not receive further updates, please update to v10. @@ -23,7 +38,7 @@ export interface APIInvite { * * See https://discord.com/developers/docs/resources/guild#guild-object */ - guild?: APIPartialGuild; + guild?: APIInviteGuild; /** * The channel this invite is for * diff --git a/payloads/v9/invite.ts b/payloads/v9/invite.ts index 3a58e0ad..450caa38 100644 --- a/payloads/v9/invite.ts +++ b/payloads/v9/invite.ts @@ -4,11 +4,26 @@ import type { APIApplication } from './application'; import type { APIPartialChannel } from './channel'; -import type { APIPartialGuild } from './guild'; +import type { APIGuild } from './guild'; import type { APIGuildScheduledEvent } from './guildScheduledEvent'; import type { APIInviteStageInstance } from './stageInstance'; import type { APIUser } from './user'; +export type APIInviteGuild = Pick< + APIGuild, + | 'id' + | 'name' + | 'splash' + | 'banner' + | 'icon' + | 'vanity_url_code' + | 'description' + | 'features' + | 'verification_level' + | 'nsfw_level' + | 'premium_subscription_count' +>; + /** * https://discord.com/developers/docs/resources/invite#invite-object */ @@ -22,7 +37,7 @@ export interface APIInvite { * * See https://discord.com/developers/docs/resources/guild#guild-object */ - guild?: APIPartialGuild; + guild?: APIInviteGuild; /** * The channel this invite is for *