mirror of
https://github.com/spacebarchat/server.git
synced 2026-04-04 10:55:44 +00:00
Actually map all endpoints for getting report menus
This commit is contained in:
@@ -21,20 +21,33 @@ import { Request, Response, Router } from "express";
|
||||
|
||||
const router = Router({ mergeParams: true });
|
||||
|
||||
router.get(
|
||||
"/",
|
||||
route({
|
||||
responses: {
|
||||
200: {
|
||||
body: "ReportingMenuResponse",
|
||||
for (const type of [
|
||||
"guild",
|
||||
"guild_discovery",
|
||||
"guild_directory_entry",
|
||||
"guild_scheduled_event",
|
||||
"message",
|
||||
"stage_channel",
|
||||
"first_dm",
|
||||
"user",
|
||||
"application",
|
||||
"widget",
|
||||
] as const) {
|
||||
router.get(
|
||||
`/${type}`,
|
||||
route({
|
||||
description: `Get reporting menu options for ${type} reports.`,
|
||||
responses: {
|
||||
200: {
|
||||
body: "ReportingMenuResponse",
|
||||
},
|
||||
204: {},
|
||||
},
|
||||
204: {},
|
||||
}),
|
||||
(req: Request, res: Response) => {
|
||||
// TODO: implement
|
||||
//res.send([] as ReportingMenuResponseSchema);
|
||||
},
|
||||
}),
|
||||
(req: Request, res: Response) => {
|
||||
// TODO: implement
|
||||
//res.send([] as ReportingMenuResponseSchema);
|
||||
},
|
||||
);
|
||||
|
||||
);
|
||||
}
|
||||
export default router;
|
||||
Reference in New Issue
Block a user