The ID of the channel to delete.
A promise that resolves to void when the channel is successfully deleted.
Will throw an error if there is a problem deleting the channel.
const token = 'your_discord_token_here'
const channelId = 'your_channel_id_here'
const run = async () => {
try {
await deleteChannel(token, channelId)
console.log('Channel deleted successfully.')
} catch (error) {
console.error(`Error: ${error.message}`)
}
}
run()
Generated using TypeDoc
The token used for authentication with the Discord API.