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

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

router.get('/', opportunityController.getOpportunities);
router.post('/', opportunityController.createOpportunity);
router.put('/:id', opportunityController.updateOpportunity);
router.post('/:id/convert', opportunityController.convertToApplication);

export default router;
