mirror of
https://github.com/Vendicated/Vencord.git
synced 2024-09-19 22:20:34 +00:00
Fixed bugs with plugin, on pc now & i use other plugins so i put it in gitignore
This commit is contained in:
parent
bde85e073a
commit
ff6f24b8c9
3 changed files with 50 additions and 61 deletions
2
.gitignore
vendored
2
.gitignore
vendored
|
@ -18,7 +18,7 @@ lerna-debug.log*
|
|||
.pnpm-debug.log*
|
||||
*.tsbuildinfo
|
||||
|
||||
src/userplugins
|
||||
src/userplugins/globalBadges.tsx
|
||||
|
||||
ExtensionCache/
|
||||
settings/
|
||||
|
|
49
src/userplugins/WebhookManager.tsx
Normal file
49
src/userplugins/WebhookManager.tsx
Normal file
|
@ -0,0 +1,49 @@
|
|||
import definePlugin from "@utils/types";
|
||||
import { ApplicationCommandInputType, ApplicationCommandOptionType, sendBotMessage } from "@api/Commands";
|
||||
import { Devs } from "@utils/constants";
|
||||
|
||||
export default definePlugin({
|
||||
name: "WebhookManager",
|
||||
description: "Manage your webhooks easily; delete, send messages, get detailed info and more.",
|
||||
authors: [Devs.Byron],
|
||||
dependencies: ["CommandsAPI"],
|
||||
|
||||
commands: [
|
||||
{
|
||||
name: "deletewebhook",
|
||||
description: "Delete a webhook.",
|
||||
inputType: ApplicationCommandInputType.BUILT_IN,
|
||||
options: [
|
||||
{
|
||||
name: "url",
|
||||
description: "The URL of the webhook.",
|
||||
type: ApplicationCommandOptionType.STRING
|
||||
}
|
||||
],
|
||||
execute: async (_, ctx) => {
|
||||
sendBotMessage(ctx.channel.id, {
|
||||
content: "Hello world! \n " +
|
||||
"This is a string addition and \n, testing."
|
||||
});
|
||||
}
|
||||
},
|
||||
{
|
||||
name: "webhookinfo",
|
||||
description: "Retrieve information about a webhook.",
|
||||
inputType: ApplicationCommandInputType.BUILT_IN,
|
||||
options: [
|
||||
{
|
||||
name: "url",
|
||||
description: "The URL of the webhook.",
|
||||
type: ApplicationCommandOptionType.STRING
|
||||
}
|
||||
],
|
||||
execute: async (_, ctx) => {
|
||||
sendBotMessage(ctx.channel.id, {
|
||||
content: "Hello world! \n " +
|
||||
"This is a string addition and \n, testing."
|
||||
});
|
||||
}
|
||||
}
|
||||
]
|
||||
});
|
|
@ -1,60 +0,0 @@
|
|||
/*
|
||||
|
||||
vencord is cool
|
||||
|
||||
*/
|
||||
|
||||
import definePlugin from "@utils/types";
|
||||
import { ApplicationCommandInputType, ApplicationCommandOptionType, findOption, sendBotMessage, RequiredMessageOption } from "@api/Commands";
|
||||
import Devs from "utils/constants";
|
||||
|
||||
export default definePlugin({
|
||||
name: "WebhookManager",
|
||||
description: "Manage your webhooks easily; delete, send messages, get detailed info and more.",
|
||||
authors: [Devs.byron],
|
||||
dependencies: ["CommandsAPI"],
|
||||
commands: [
|
||||
{
|
||||
name: "deletewebhook",
|
||||
description: "Delete a webhook.",
|
||||
inputType: ApplicationCommandInputType.BUILT_IN,
|
||||
options: [
|
||||
{
|
||||
RequiredMessageOption, // 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."
|
||||
});
|
||||
}
|
||||
}
|
||||
],
|
||||
},
|
||||
{
|
||||
name: "webhookinfo",
|
||||
description: "Retrieve information about a webhook.",
|
||||
inputType: ApplicationCommandInputType.BUILT_IN,
|
||||
options: [
|
||||
{
|
||||
RequiredMessageOption,
|
||||
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