import { Router } from 'express';
import { requireAuth } from '../middleware/auth';
import { chatMessage, deleteChatHistory, sendThreadMessage } from '../controllers/chat.controller';

const router = Router();

router.post('/threads/:threadId/message', requireAuth, sendThreadMessage);
router.post('/stream', requireAuth, chatMessage);
router.post('/:caseId/stream', requireAuth, chatMessage);
router.post('/:caseId/message', requireAuth, chatMessage);
router.delete('/:caseId', requireAuth, deleteChatHistory);

export default router;
