summary refs log tree commit diff
path: root/src/api/routes/auth/generate-registration-tokens.ts
diff options
context:
space:
mode:
authorPuyodead1 <puyodead@proton.me>2023-03-23 10:40:37 -0400
committerPuyodead1 <puyodead@proton.me>2023-04-13 14:58:53 -0400
commita567ca3f514b7671da5d523325751a8383885d2c (patch)
treeb9d6cb1ef0799007dbaa8a88a317486de9dd59c3 /src/api/routes/auth/generate-registration-tokens.ts
parentfix style action (diff)
downloadserver-a567ca3f514b7671da5d523325751a8383885d2c.tar.xz
auth routes
Diffstat (limited to 'src/api/routes/auth/generate-registration-tokens.ts')
-rw-r--r--src/api/routes/auth/generate-registration-tokens.ts7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/api/routes/auth/generate-registration-tokens.ts b/src/api/routes/auth/generate-registration-tokens.ts
index 723875f8..48fe6421 100644
--- a/src/api/routes/auth/generate-registration-tokens.ts
+++ b/src/api/routes/auth/generate-registration-tokens.ts
@@ -16,7 +16,7 @@
 	along with this program.  If not, see <https://www.gnu.org/licenses/>.
 */
 
-import { route, random } from "@spacebar/api";
+import { random, route } from "@spacebar/api";
 import { Config, ValidRegistrationToken } from "@spacebar/util";
 import { Request, Response, Router } from "express";
 
@@ -25,7 +25,10 @@ export default router;
 
 router.get(
 	"/",
-	route({ right: "OPERATOR" }),
+	route({
+		right: "OPERATOR",
+		responses: { 200: { body: "GenerateRegistrationTokensResponse" } },
+	}),
 	async (req: Request, res: Response) => {
 		const count = req.query.count ? parseInt(req.query.count as string) : 1;
 		const length = req.query.length