mirror of
https://github.com/Vendicated/Vencord.git
synced 2024-09-19 22:20:34 +00:00
create plugin, haven't tested yet but will soon
This commit is contained in:
parent
6e363814d1
commit
ccce4952cc
1 changed files with 39 additions and 0 deletions
39
src/userplugins/WebhookManager/index.ts
Normal file
39
src/userplugins/WebhookManager/index.ts
Normal file
|
@ -0,0 +1,39 @@
|
|||
/*
|
||||
|
||||
vencord is cool
|
||||
|
||||
*/
|
||||
|
||||
import definePlugin from "@utils/types";
|
||||
import { ApplicationCommandInputType, ApplicationCommandOptionType, findOption, sendBotMessage, RequiredMessageOption } from "@api/Commands";
|
||||
|
||||
export default definePlugin({
|
||||
name: "WebhookManager",
|
||||
description: "Manage your webhooks easily; delete, send messages, get detailed info and more.",
|
||||
authors: [{ id: 1, name: "byron", },], // will change ID soon, not home
|
||||
dependencies: ["CommandsAPI"],
|
||||
commands: [
|
||||
{
|
||||
name: "deletewebhook",
|
||||
description: "Delete a webhook.",
|
||||
inputType: ApplicationCommandInputType.BUILT_IN,
|
||||
options: [
|
||||
{
|
||||
RequiredMessageOption, // will this work? will debug when home.
|
||||
name: "url",
|
||||
description: "The URL of the webhook.",
|
||||
|
||||
|
||||
type: ApplicationCommandOptionType.STRING,
|
||||
execute: (opts, ctx) => {
|
||||
|
||||
sendBotMessage(ctx.channel.id, {
|
||||
content: "Hello world! \n " +
|
||||
"This is a string addition and \n, testing."
|
||||
});
|
||||
}
|
||||
}
|
||||
],
|
||||
},
|
||||
]
|
||||
});
|
Loading…
Reference in a new issue