first commit
This commit is contained in:
@@ -0,0 +1,25 @@
|
||||
const express = require('express');
|
||||
const router = express.Router();
|
||||
const {
|
||||
executeTool,
|
||||
getToolExecutions,
|
||||
getToolExecution,
|
||||
getToolStats,
|
||||
retryToolExecution
|
||||
} = require('../controllers/toolController');
|
||||
const { authenticate, authorize } = require('../middleware/auth');
|
||||
const { validate, schemas } = require('../middleware/validation');
|
||||
|
||||
// All tool routes require authentication
|
||||
router.use(authenticate);
|
||||
|
||||
// Tool execution
|
||||
router.post('/execute', validate(schemas.executeTool), executeTool);
|
||||
|
||||
// Tool management
|
||||
router.get('/executions', getToolExecutions);
|
||||
router.get('/executions/:executionId', getToolExecution);
|
||||
router.get('/stats', authorize('admin'), getToolStats);
|
||||
router.post('/executions/:executionId/retry', retryToolExecution);
|
||||
|
||||
module.exports = router;
|
||||
Reference in New Issue
Block a user