Soy nuevo en la codificación...
Así que he estado tratando de hacer un webhook incrustado con JSON sin procesar, pero el webhook no parece funcionar.
Esto es lo que usé:
run: async (client, message, args) => { if (!message.member.hasPermission("MANAGE_WEBHOOKS")) { return message.channel.send( `You need to have permission to use this command!` ); } message.delete(); let user = message.mentions.members.first() || message.guild.members.cache.get(args[0]); if (!user) return message.channel.send("Please provide a user!"); const webhook = await message.channel.createWebhook(user.displayName, { avatar: user.user.displayAvatarURL(), channel: message.channel.id }); let message2 = args.slice(1).join(" ") await webhook.send(message2).then(() => { let embed1 = JSON.parse(message2); return message.channel.send({embed: embed1}); webhook.delete(); }); } }; Envía tanto el JSON como su incrustación...
necesito ayuda