summaryrefslogtreecommitdiff
path: root/mod.ts
blob: b25d6614bf17009b18b4ec4a2fc8c9b17ec2651b (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
import * as deploy from "https://deno.land/x/[email protected]/deploy.ts";
import { FUWN_ID, LOBBY_CHANNEL } from "./config.ts";

deploy.init({ env: true });

if ((await deploy.commands.all()).size) {
  deploy.commands.bulkEdit([
    {
      name: "setup",
      description: "Setup the informational message in the lobby channel.",
    },
  ]);
}

deploy.handle("setup", (_: deploy.ApplicationCommandInteraction) => {
  deploy.client.client?.channels.sendMessage(
    LOBBY_CHANNEL,
    "To access the rest of the server, send a message structured like this: " +
      "`/verify [name]`, with `name` being your full name as shown in Zoom." +
      "\n\nAn example of a valid verification request looks like this: " +
      "`/verify Zoltan Szabatin`.\n\nIf you are unable to verify yourself; " +
      "first, check if your name is recognized as a class member using the " +
      "`/check [name]` command, with `name` being your full name as show in " +
      "Zoom. An example of a valid check command looks like: " +
      "`/check Zoltan Szabatin`.\n\nIf you are unable to verify yourself and " +
      "your name is not recognized as a class member, you should then DM " +
      `<@${FUWN_ID}>.`,
  );
});