Files
ragflow/web/src/pages/agent/hooks/use-find-mcp-by-id.ts
balibabu ab4ad0f373 Feat: Render the mcp list on the agent page #3221 (#8829)
### What problem does this PR solve?
Feat: Render the mcp list on the agent page #3221

### Type of change


- [x] New Feature (non-breaking change which adds functionality)
2025-07-14 17:03:58 +08:00

13 lines
263 B
TypeScript

import { useListMcpServer } from '@/hooks/use-mcp-request';
export function useFindMcpById() {
const { data } = useListMcpServer();
const findMcpById = (id: string) =>
data.mcp_servers.find((item) => item.id === id);
return {
findMcpById,
};
}