fix(mcp): remove SSE support; keep stdio default when type is omitted
- Backend: reject "sse" in validators; accept missing type as stdio; require url only for http (mcp.rs, claude_mcp.rs) - Frontend: McpServer.type narrowed to "stdio" | "http" (optional) (src/types.ts) - UI: avoid undefined in list item details (McpListItem) - Claude-only sync after delete to update ~/.claude.json (commands.rs) Notes: - Ran typecheck and cargo check: both pass - Clippy shows advisory warnings unrelated to this change - Prettier check warns on a few files; limited scope changes kept minimal
This commit is contained in:
11
src/vite-env.d.ts
vendored
11
src/vite-env.d.ts
vendored
@@ -71,13 +71,18 @@ declare global {
|
||||
deleteClaudeMcpServer: (id: string) => Promise<boolean>;
|
||||
validateMcpCommand: (cmd: string) => Promise<boolean>;
|
||||
// 新:config.json 为 SSOT 的 MCP API
|
||||
getMcpConfig: () => Promise<McpConfigResponse>;
|
||||
getMcpConfig: (app?: AppType) => Promise<McpConfigResponse>;
|
||||
upsertMcpServerInConfig: (
|
||||
app: AppType | undefined,
|
||||
id: string,
|
||||
spec: Record<string, any>,
|
||||
) => Promise<boolean>;
|
||||
deleteMcpServerInConfig: (id: string) => Promise<boolean>;
|
||||
setMcpEnabled: (id: string, enabled: boolean) => Promise<boolean>;
|
||||
deleteMcpServerInConfig: (app: AppType | undefined, id: string) => Promise<boolean>;
|
||||
setMcpEnabled: (
|
||||
app: AppType | undefined,
|
||||
id: string,
|
||||
enabled: boolean,
|
||||
) => Promise<boolean>;
|
||||
syncEnabledMcpToClaude: () => Promise<boolean>;
|
||||
importMcpFromClaude: () => Promise<number>;
|
||||
testApiEndpoints: (
|
||||
|
||||
Reference in New Issue
Block a user