refactor(api): remove MCP marketplace cache integration

Removed dependencies on MCPCacheRepository and PulseMCPService from MCP routes to simplify installation and listing logic, avoiding reliance on potentially stale cached data and streamlining the codebase. Updated available-for-chat filter to include MCPs without explicit status.
This commit is contained in:
Evandro Fonseca Junior committed 2025-10-29 15:35:15 -03:00
1 parent 4739a13458
commit f96d4ed696
34 files changed
+260 -3775

No files matched your search

+7 -7
View File
@@ -8,7 +8,7 @@ import {
SettingsButton,
SettingsModal,
} from "@/components/settings/SettingsModal";
import { MCPMarketplaceModal } from "@/components/mcp/MCPMarketplaceModal";
import { MCPManualInstallModal } from "@/components/mcp/MCPManualInstallModal";
import { Store } from "lucide-react";
interface ClientHomeProps {
@@ -22,7 +22,7 @@ export function ClientHome({ offline, models }: ClientHomeProps) {
const [currentConversationId, setCurrentConversationId] = useState<
string | null
>(null);
const [showMCPMarketplace, setShowMCPMarketplace] = useState(false);
const [showManualInstall, setShowManualInstall] = useState(false);
const handleConversationCreated = () => {
// Incrementar trigger para forçar atualização da sidebar
@@ -49,11 +49,11 @@ export function ClientHome({ offline, models }: ClientHomeProps) {
</span>
)}
<button
onClick={() => setShowMCPMarketplace(true)}
onClick={() => setShowManualInstall(true)}
className="flex items-center gap-2 px-3 py-2 bg-[var(--surface)] border border-[var(--border)] rounded-md hover:bg-[var(--background)] transition-colors text-sm"
>
<Store className="h-4 w-4" />
MCP Marketplace
Install MCP Manually
</button>
<SettingsButton onOpen={() => setOpen(true)} />
<ModeToggle />
@@ -77,9 +77,9 @@ export function ClientHome({ offline, models }: ClientHomeProps) {
</div>
</main>
<SettingsModal isOpen={open} onClose={() => setOpen(false)} />
<MCPMarketplaceModal
isOpen={showMCPMarketplace}
onClose={() => setShowMCPMarketplace(false)}
<MCPManualInstallModal
isOpen={showManualInstall}
onClose={() => setShowManualInstall(false)}
/>
</div>
);