所以我想邀请执行服务器命令的默认通道。
const embed = new Discord.MessageEmbed()
.setAuthor("Testt", client.user.displayAvatarURL())
.setTitle("title")
.setThumbnail(client.user.displayAvatarURL())
.setDescription("description")
.setTimestamp()
.setFooter("© Test", client.user.displayAvatarURL())
channel.send(embed)
所以我希望邀请位于MessageEmbed之上
答案 0 :(得分:0)
由于defaultChannel
已经不复存在,因此我将其设置为:
let invite = await message.channel.createInvite({
maxAge: 0, // 0 = infinite expiration
maxUses: 0 // 0 = infinite uses
})
message.channel.send(`${invite}`, "test")