mirror of
https://github.com/infiniflow/ragflow.git
synced 2025-12-08 20:42:30 +08:00
### What problem does this PR solve? Feat: Synchronize MCP data to agent #3221 ### Type of change - [x] New Feature (non-breaking change which adds functionality)
61 lines
1.1 KiB
TypeScript
61 lines
1.1 KiB
TypeScript
export interface IMcpServer {
|
|
create_date: string;
|
|
description: null;
|
|
id: string;
|
|
name: string;
|
|
server_type: string;
|
|
update_date: string;
|
|
url: string;
|
|
variables: Record<string, any> & { tools?: IMCPToolObject };
|
|
}
|
|
|
|
export type IMCPToolObject = Record<string, Omit<IMCPTool, 'name'>>;
|
|
|
|
export type IMCPToolRecord = Record<string, IMCPTool>;
|
|
|
|
export interface IMcpServerListResponse {
|
|
mcp_servers: IMcpServer[];
|
|
total: number;
|
|
}
|
|
|
|
export interface IMCPTool {
|
|
annotations: null;
|
|
description: string;
|
|
enabled: boolean;
|
|
inputSchema: InputSchema;
|
|
name: string;
|
|
}
|
|
|
|
interface InputSchema {
|
|
properties: Properties;
|
|
required: string[];
|
|
title: string;
|
|
type: string;
|
|
}
|
|
|
|
interface Properties {
|
|
symbol: ISymbol;
|
|
}
|
|
|
|
interface ISymbol {
|
|
title: string;
|
|
type: string;
|
|
}
|
|
|
|
export interface IExportedMcpServers {
|
|
mcpServers: McpServers;
|
|
}
|
|
|
|
interface McpServers {
|
|
fetch_2: IExportedMcpServer;
|
|
github_1: IExportedMcpServer;
|
|
}
|
|
|
|
export interface IExportedMcpServer {
|
|
authorization_token: string;
|
|
name: string;
|
|
tool_configuration: Record<string, any>;
|
|
type: string;
|
|
url: string;
|
|
}
|