import express from 'express';
const router = express.Router();
import * as auditController from './audit.controller.js';
import { authenticate } from '../../common/middleware/auth.js';

// All audit routes require authentication
router.use(authenticate as any);

// GET /api/audit/logs?entityType=application&entityId=<uuid>&page=1&limit=50
router.get('/logs', auditController.getAuditLogs);

// GET /api/audit/summary?entityType=application&entityId=<uuid>
router.get('/summary', auditController.getAuditSummary);

export default router;
