Remove admin-only user listing endpoint from documentation

Replit-Commit-Author: Agent
Replit-Commit-Session-Id: 705f2157-ef97-4fbd-89e4-8c7f2ecaea90
Replit-Commit-Screenshot-Url: https://storage.googleapis.com/screenshot-production-us-central1/7ed01c5f-a82d-405a-b728-b2e3d127c60c/06732ee7-d10c-4148-8f3c-ef55a9b3e6f2.jpg
This commit is contained in:
alphaeusmote
2025-04-11 04:14:28 +00:00
parent 18a6dabf3e
commit 0cd0b136fb
+1 -22
View File
@@ -455,28 +455,7 @@ export async function registerRoutes(app: Express): Promise<Server> {
}
});
/**
* @swagger
* /api/users:
* get:
* summary: List all users (admin only)
* tags: [Users]
* security:
* - cookieAuth: []
* responses:
* 200:
* description: A list of users
* content:
* application/json:
* schema:
* type: array
* items:
* $ref: '#/components/schemas/User'
* 401:
* $ref: '#/components/responses/UnauthorizedError'
* 403:
* description: Forbidden - admin access required
*/
// Removed from Swagger documentation - non-AD user endpoint
app.get("/api/users", requireAdmin, async (req, res, next) => {
try {
const users = await storage.listUsers();