Sends a message to a channel of your choice when someone updates a channel
const lib = require('lib')({token: process.env.STDLIB_SECRET_TOKEN});
const event = context.params.event;
await lib.discord.channels['@0.3.0'].messages.create({
channel_id: `${process.env.LOG_CHANNEL_ID}`, //This is where the channel ID of your log channel comes in
content: '',
tts: false,
embeds: [
{
type: 'rich',
title: `Channel updated`,
description: `A channel has just been updated!`,
color: 0xff0000,
footer: {
text: `You can find more information in the Audit Logs!`,
},
timestamp: `${new Date().toISOString()}`,
},
],
});