Skip to content

SubcommandOption types have a required property #1510

@lisekilis

Description

@lisekilis

Issue description

try to use type APIApplicationCommandSubcommandOption or APIApplicationCommandSubcommandGroupOption

see that they have a required boolean property instead of being never
Discord Docs: https://discord.com/developers/docs/interactions/application-commands#:~:text=all%20but,SUB_COMMAND_GROUP

Image

Code sample

const testSubcommandOption: APIApplicationCommandSubcommandOption = {
	description: 'test',
	name: 'test',
	type: ApplicationCommandOptionType.Subcommand,
	options: [],
	required: true
}
const testSubcommandGroupOption: APIApplicationCommandSubcommandGroupOption = {
	name: 'testGroup',
	description: 'test group',
	type: ApplicationCommandOptionType.SubcommandGroup,
	options: [],
	required: false
}

Package version

0.38.38

Runtime

Node.js

Runtime version

v23.10.0

Priority this issue should have

Low (slightly annoying)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions