/** * Copyright (c) 2026-present, Goldman Sachs * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ import { ActionState, type GeneratorFn } from '@finos/legend-shared'; import { type McpServer, McpServerToolsResponse } from '@finos/legend-server-marketplace'; import type { LegendMarketplaceBaseStore } from '../LegendMarketplaceBaseStore.js'; export declare enum IntelligenceCatalogType { ALL = "All", AGENTS = "Agents", MCPS = "MCPs", SKILLS = "Skills" } export declare const UNAVAILABLE_CATALOG_TYPES: readonly IntelligenceCatalogType[]; /** * A catalog type the platform does not offer yet is neither selectable nor listed, so * everything that belongs to it stays hidden until it is taken off this list. */ export declare const isCatalogTypeAvailable: (catalogType: IntelligenceCatalogType) => boolean; export declare class IntelligenceCatalogStore { readonly marketplaceBaseStore: LegendMarketplaceBaseStore; readonly fetchingServersState: ActionState; mcpServers: McpServer[]; toolsByServerName: Map; serverNamesFetchingTools: Set; catalogType: IntelligenceCatalogType; vendorFilters: string[]; searchQuery: string; vendorSearchTerm: string; page: number; itemsPerPage: number; lastViewedMcpServerName: string | undefined; constructor(marketplaceBaseStore: LegendMarketplaceBaseStore); /** * The Legend AI orchestrator only serves the agent, so it is catalogued exactly when * the agents themselves are. */ get legendMcpServers(): McpServer[]; get vendorByServerName(): Map; getVendorForServer(server: McpServer): string; get availableVendors(): string[]; get searchableVendors(): string[]; get filteredMcpServers(): McpServer[]; get isAgentMatchingSearch(): boolean; get previewMcpServers(): McpServer[]; get paginatedMcpServers(): McpServer[]; get hasActiveFilters(): boolean; get isLoading(): boolean; setCatalogType(catalogType: IntelligenceCatalogType): void; setSearchQuery(searchQuery: string): void; setVendorSearchTerm(vendorSearchTerm: string): void; toggleVendorFilter(vendor: string): void; clearFilters(): void; setPage(page: number): void; setItemsPerPage(itemsPerPage: number): void; setLastViewedMcpServerName(serverName: string): void; countMcpServersForVendor(vendor: string): number; isFetchingToolsFor(serverName: string): boolean; findLegendMcpServer(name: string): McpServer | undefined; /** * The registry has no filter parameter, so the first page is read to learn the page * count, the remainder are fetched together, and Legend servers are selected here. */ fetchMcpServers(token: string): GeneratorFn; /** * Tracked per server rather than with a single action state, so that opening a * second server while the first is still loading does not drop its request. */ fetchMcpServerTools(serverName: string, token: string): GeneratorFn; } //# sourceMappingURL=IntelligenceCatalogStore.d.ts.map