summary refs log tree commit diff
diff options
context:
space:
mode:
authoruurgothat <cckhmck@gmail.com>2021-11-17 22:28:41 +0300
committeruurgothat <cckhmck@gmail.com>2021-11-17 22:28:41 +0300
commit74dee34f69dfe138dcde43f09f77bf0329e2b3c8 (patch)
tree2cccdabc9a958471638326670ebc61b073f45569
parentAdd instance route (diff)
downloadserver-74dee34f69dfe138dcde43f09f77bf0329e2b3c8.tar.xz
Minor API stuff
-rw-r--r--api/src/routes/guilds/templates/index.ts5
-rw-r--r--api/src/routes/track.ts11
2 files changed, 13 insertions, 3 deletions
diff --git a/api/src/routes/guilds/templates/index.ts b/api/src/routes/guilds/templates/index.ts
index dd906198..98e42d1c 100644
--- a/api/src/routes/guilds/templates/index.ts
+++ b/api/src/routes/guilds/templates/index.ts
@@ -1,11 +1,10 @@
 import { Request, Response, Router } from "express";
-const router: Router = Router();
 import { Template, Guild, Role, Snowflake, Config, User, Member } from "@fosscord/util";
-const { enabled, allowTemplateCreation, allowDiscordTemplates, allowRaws } = Config.get().templates;
 import { route } from "@fosscord/api";
 import { DiscordApiErrors } from "@fosscord/util";
 import fetch from "node-fetch";
-
+const router: Router = Router();
+const { enabled, allowTemplateCreation, allowDiscordTemplates, allowRaws } = Config.get().templates;
 
 export interface GuildTemplateCreateSchema {
 	name: string;
diff --git a/api/src/routes/track.ts b/api/src/routes/track.ts
new file mode 100644
index 00000000..8556a3ad
--- /dev/null
+++ b/api/src/routes/track.ts
@@ -0,0 +1,11 @@
+import { Router, Response, Request } from "express";
+import { route } from "@fosscord/api";
+
+const router = Router();
+
+router.post("/", route({}), (req: Request, res: Response) => {
+	// TODO:
+	res.sendStatus(204);
+});
+
+export default router;