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

154
Views
Discord.js V13 Setup Command that collect a Channel

I want to make a Setup Command for my Bot, that I can use to set up channels for the bot e.g. a welcome channel. For this, I used a JSON file.

Code

collector.on('collect', async (i) => {
  if (i.customId === 'modchannelbutton') {
    const ModChannelSetEmbed = new MessageEmbed()
      .setTitle('<:vsl_settings:991655211179442216> | **__SERVER SETUP__**')
      .addField(
        '» Stand',
        setupconfig[interaction.guild.id].modlog === 'nochannel'
          ? '<:m_notdone:991657968296808478> Du hast noch kein Moderator Log gesetzt'
          : `<:m_done:991657855549710376> Dein aktueller Moderator Log ist: <#${
              setupconfig[interaction.guild.id].modlog
            }>`,
      )
      .setDescription(
        '> Du hast 1 Minute Zeit um einen neuen Moderator Log zu setzen, schreib dafür einfach nur den #Channel in diesem Channel',
      )
      .setColor('#0c06b6');

    row.components[0].setDisabled(true);
    await i.update({ embeds: [ModChannelSetEmbed], components: [] });

    // … Here I need the Message Collector for the Channel …
  }
});

I want to make a collector that collected if the message next to the button is clicked in a channel. But all my tries don't reply.

That means: Slash Command use —> Button Click —> Channel send

The Collector should control if the message next to the button click is a channel.

about 4 years ago · Juan Pablo Isaza
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!