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

97
Views
Estoy tratando de dejar que mi discord webhook envíe un mensaje con botones

Pues aqui esta mi problema.

Estoy tratando de enviar mensajes a través de un webhook de Discord con botones, pero no se muestran o, a veces, solo dan un código de error.

El código de error básicamente dice que mi JSON stringicicator no funciona debido a un error de sintrax, lo cual es extraño porque si envío un mensaje sin ningún componente de botón, funciona sin problemas.

Aquí está mi código:

 const request = new XMLHttpRequest(); request.open("POST", "/* the url of the bot */"); request.setRequestHeader('Content-type', 'application/json'); const params = { "embeds": [ { "title": "test", "description": "test", "color": 65474 } ], "components": [ { "type": 1, "components": [ { "type": 2, "style": 5, "label": "kaas", "url": "/* url website */" } ] } ] request.send(JSON.stringify(params));
about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

Te falta un } para cerrar el objeto params .

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!