Co-authored-by: harold <haroldmciver@google.com> Co-authored-by: N. Taylor Mullen <ntaylormullen@google.com>
19 lines
457 B
TypeScript
19 lines
457 B
TypeScript
/**
|
|
* @license
|
|
* Copyright 2025 Google LLC
|
|
* SPDX-License-Identifier: Apache-2.0
|
|
*/
|
|
|
|
import { Config } from '../config/config.js';
|
|
import { DiscoveredMCPPrompt } from '../tools/mcp-client.js';
|
|
|
|
export function getMCPServerPrompts(
|
|
config: Config,
|
|
serverName: string,
|
|
): DiscoveredMCPPrompt[] {
|
|
const promptRegistry = config.getPromptRegistry();
|
|
if (!promptRegistry) {
|
|
return [];
|
|
}
|
|
return promptRegistry.getPromptsByServer(serverName);
|
|
}
|