mirror of
https://github.com/danny-avila/LibreChat.git
synced 2025-12-18 01:10:14 +01:00
mcp example, mock i/o for client-to-server communications
This commit is contained in:
parent
799f0e5810
commit
7251308244
9 changed files with 343 additions and 22 deletions
|
|
@ -1,4 +1,5 @@
|
|||
const express = require('express');
|
||||
const { addTool } = require('@librechat/api');
|
||||
const { callTool, verifyToolAuth, getToolCalls } = require('~/server/controllers/tools');
|
||||
const { getAvailableTools } = require('~/server/controllers/PluginController');
|
||||
const { toolCallLimiter } = require('~/server/middleware/limiters');
|
||||
|
|
@ -36,4 +37,12 @@ router.get('/:toolId/auth', verifyToolAuth);
|
|||
*/
|
||||
router.post('/:toolId/call', toolCallLimiter, callTool);
|
||||
|
||||
/**
|
||||
* Add a new tool to the system
|
||||
* @route POST /agents/tools/add
|
||||
* @param {object} req.body - Request body containing tool data
|
||||
* @returns {object} Created tool object
|
||||
*/
|
||||
router.post('/add', addTool);
|
||||
|
||||
module.exports = router;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue