Discord.js: on('interactionCreate') 无效但 'messageCreate' 有效

Discord.js: on('interactionCreate') not working but 'messageCreate' does work

我目前正在研究机器人的命令,但似乎找不到解决我的问题的方法。当我 运行 我的

client.on('messageCreate', async interaction =>{
  // somethingHappens
})

它工作得很好,但是当我这样做时

client.on('interactionCreate', async interaction =>{
      // nothingHappens
    })

这是我的客户意图:

[Discord.Intents.FLAGS.GUILDS, Discord.Intents.FLAGS.GUILD_MESSAGES, Discord.Intents.FLAGS.DIRECT_MESSAGES]

我是不是漏掉了什么?

也许试试这个 intent 对我有用。

Discord.Intents.FLAGS.GUILD_INTEGRATIONS