Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

199
Vistas
how do I set my bot sending all the logs to a named channel?
let logschannel = message.guild.channels.cache.find(channel =\> channel.name === 'logs');

I want to get my bot to send logs from joining and leaving to deleting a message in a specifically named channel. Can someone help?

about 4 years ago · Juan Pablo Isaza
2 Respuestas
Responde la pregunta

0

Please change =/> to => And then, check this out: https://discord.js.org/#/docs/discord.js/stable/typedef/WSEventType

You would probably like to run your code with every guild event in the above docs link.

about 4 years ago · Juan Pablo Isaza Denunciar

0

You got one wrong code in your given code which is the =\> to do this you need to find first the channel, yes, you do it right. You just need to change =\> to =>.

Now when you finished changing that all you need to do is to call the logschannel

let logschannel = message.guild.channels.cache.find(channel => channel.name === 'logs');
loschannel.send({content: "your content"})

can do with embeds too.

let logschannel = message.guild.channels.cache.find(channel => channel.name === 'logs');
logschannel.send({embeds: [your_embed_name]});
about 4 years ago · Juan Pablo Isaza Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda