mirror of
https://github.com/ItzCrazyKns/Perplexica.git
synced 2025-06-17 15:28:37 +00:00
feat(search): update types
This commit is contained in:
@ -24,7 +24,7 @@ interface embeddingModel {
|
||||
model: string;
|
||||
}
|
||||
|
||||
interface RequestBody {
|
||||
interface ChatRequestBody {
|
||||
focusMode: string;
|
||||
chatModel?: chatModel;
|
||||
embeddingModel?: embeddingModel;
|
||||
@ -34,7 +34,7 @@ interface RequestBody {
|
||||
|
||||
router.post('/', async (req, res) => {
|
||||
try {
|
||||
const body: RequestBody = req.body;
|
||||
const body: ChatRequestBody = req.body;
|
||||
|
||||
if (!body.focusMode || !body.query) {
|
||||
return res.status(400).json({ message: 'Missing focus mode or query' });
|
||||
|
Reference in New Issue
Block a user