import { Router } from "express";

import { matchingController } from "../controllers/matchingController.js";
import { asyncHandler } from "../utils/asyncHandler.js";

const router = Router();

router.get("/clients", asyncHandler(matchingController.getClients));
router.get("/suppliers", asyncHandler(matchingController.getSuppliers));
router.get("/unmatched", asyncHandler(matchingController.getUnmatched));
router.post("/letter", asyncHandler(matchingController.letter));
router.post("/auto-propose", asyncHandler(matchingController.autoPropose));
router.delete("/:matching_id", asyncHandler(matchingController.remove));

export default router;
