Using a category ID to log all new channels name and IDs

Viewed 40

So I know that categories are classified as the parent with an ID and the channels inside the category are classified as the child of the parent. What I am trying to figure out is if after launching my discord.js bot, is there a way to note new channels made in that category? Particularly noting the channel name and ID if a new channel is made and meets the condition of being in that category. Any help is appreciated, I've looked everywhere and haven't found anything hinting at an answer

1 Answers

There is an event called whenever a channel is created, #channelCreate.

client.on('channelCreate', async channel => {
    //Do something?...
});

Also in the code above I have used client, so if you want to do something with guild, fetch it first.

Related