Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

76
Views
Enviar mensaje incluyendo botón

Estoy usando Discord.js v13.2. Necesito enviar un mensaje una vez que esté listo. Puedo enviar un mensaje de texto, pero el botón no aparece, así que supongo que no estoy enviando el parámetro correctamente.

 client.once("ready", async () => { const button = new MessageButton() .setLabel("Go To Site") .setStyle("blue") .setCustomId("btn-go-to-site"); const helpChannel = await client.channels.fetch(channelID); helpChannel.send('Welcome to Site', button); });
about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

Discord.js v13 ahora solo acepta 1 parámetro en el envío , edición y respuesta de mensajes. Debe enviar el mensaje con los parámetros de content y components .

 helpChannel.send({ content: "Welcome to Site", components: [ new MessageActionRow().addComponents([button]) ] })

Esto también debe hacerse con incrustaciones, archivos, pegatinas y otras opciones de mensajes.

about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!