/** * @name tools/tool-catalog * @description Runtime read-model for SAP MCP tool modules and execution policy. * * This module gives UI, wizard, release checks, and agent bootstrap code a * single catalog shape that combines selected tool modules with pricing, * signer-boundary, permission, and routing metadata. * * @module tools/tool-catalog */ import type { SapMcpContext, SapMcpMode, SapMcpToolCatalogContext } from '../../core/src/types.js'; import { type ToolModuleCategory, type ToolModuleDefinition, type ToolModuleMode } from './module-registry.js'; import { type ToolExecutionIntent, type ToolExecutionMetadata } from './tool-execution-metadata.js'; export interface ToolCatalogOptions { readonly profileId?: string; readonly profileDescription?: string; readonly paymentsBridgeOnly?: boolean; } export interface RuntimeToolDescriptor { readonly name: string; readonly title?: string; readonly description?: string; readonly inputSchema?: unknown; readonly outputSchema?: unknown; readonly annotations?: unknown; } export interface ToolCatalogRuntimeProfile extends ToolCatalogOptions { readonly id: string; readonly description: string; readonly context: SapMcpContext; } export interface ToolCatalogToolEntry { readonly moduleId: string; readonly moduleTitle: string; readonly moduleCategory: ToolModuleCategory; readonly toolName: string; readonly title?: string; readonly description?: string; readonly inputSchema?: unknown; readonly outputSchema?: unknown; readonly annotations?: unknown; readonly registered?: boolean; readonly metadata: ToolExecutionMetadata; } export interface ToolCatalogModuleEntry { readonly id: string; readonly title: string; readonly description: string; readonly category: ToolModuleCategory; readonly order: number; readonly mode: ToolModuleMode; readonly requires: readonly string[]; readonly namespace?: string; readonly packageName?: string; readonly version?: string; readonly expectedTools: readonly string[]; readonly tools: readonly ToolCatalogToolEntry[]; } export interface ToolCatalogCategorySummary { readonly category: ToolModuleCategory; readonly modules: number; readonly tools: number; } export interface ToolCatalogPolicySummary { readonly paymentTiers: Readonly>; readonly intents: Readonly>; readonly hostedAccountlessBlockedTools: readonly string[]; readonly localSignerTools: readonly string[]; } export interface ToolCatalog { readonly profileId: string; readonly profileDescription: string; readonly runtimeMode: SapMcpMode; readonly paymentsBridgeOnly: boolean; readonly moduleCount: number; readonly toolCount: number; readonly categories: readonly ToolCatalogCategorySummary[]; readonly policy: ToolCatalogPolicySummary; readonly modules: readonly ToolCatalogModuleEntry[]; readonly tools: readonly ToolCatalogToolEntry[]; } export declare function buildToolCatalog(modules: readonly ToolModuleDefinition[], context: SapMcpContext, options?: ToolCatalogOptions): ToolCatalog; export declare function buildToolCatalogFromRuntimeTools(modules: readonly ToolModuleDefinition[], context: SapMcpContext, runtimeTools: readonly RuntimeToolDescriptor[], options?: ToolCatalogOptions): ToolCatalog; export declare function buildToolCatalogForRuntimeProfiles(modules: readonly ToolModuleDefinition[], profiles: readonly ToolCatalogRuntimeProfile[]): readonly ToolCatalog[]; export declare function summarizeToolCatalog(catalog: ToolCatalog): SapMcpToolCatalogContext; //# sourceMappingURL=tool-catalog.d.ts.map