get options from interaction

how exactly are we supposed to get options from interaction when using @discordjs/core
No description
7 Replies
d.js toolkit
d.js toolkit3mo ago
NyR
NyR3mo ago
it should be interaction.data.options, and you'll need to further narrow the type by checking for command type i think, because PrimaryEntryPointCommandInteraction doesn't have options
Amgelo
Amgelo3mo ago
I think you meant === ApplicationCommand, not !==
NyR
NyR3mo ago
That too yeah ^^
Whimsy
WhimsyOP3mo ago
same thing happens tho, how do i narrow it down by checking if its APIMessageApplicationCommandInteractionData oh there is also data.type wha
NyR
NyR3mo ago
data.type is command type, so you need to exclude entrypoint too i believe
Amgelo
Amgelo3mo ago
/core is mostly raw data, so it's not as easy to use as djs its docs are pretty much discord's just with camelCase instead of snake_case

Did you find this page helpful?