import { FastifyInstance } from 'fastify';
import { chatController } from '../controllers/chatController.js';

export async function chatRoutes(fastify: FastifyInstance) {
  // 发送消息（流式输出）
  fastify.post('/chat/stream', chatController.sendMessageStream.bind(chatController));

  // 获取对话列表
  fastify.get('/chat/conversations', chatController.getConversations.bind(chatController));

  // 删除对话
  fastify.delete('/chat/conversations/:id', chatController.deleteConversation.bind(chatController));
}


