Skip to content

IMcpPromptClient

Namespace AgentPrism · Assembly AgentPrism.Abstractions.dll

The client that lists an MCP server’s prompts and resolves their content.

public interface IMcpPromptClient

Capability checking is mandatory: if the server does not report ServerCapabilities.Prompts, the request is never sent, and McpOperationStatus.CapabilityUnsupported is returned.

Each call opens a short-lived, separate connection; it is not shared with the tool-discovery connection AgentPrism.Mcp keeps in the background. This lets an administrator see a fresh prompt list at any moment — it does not wait for the refresh interval.

GetPromptAsync(string, string, string, IReadOnlyDictionary<string, string>?, CancellationToken)

Section titled “ GetPromptAsync(string, string, string, IReadOnlyDictionary<string, string>?, CancellationToken)”

Resolves a prompt’s content with arguments.

ValueTask<(McpOperationStatus Status, McpPromptContent? Content)> GetPromptAsync(string tenantId, string serverName, string promptName, IReadOnlyDictionary<string, string>? arguments, CancellationToken cancellationToken = default)

tenantId string

The tenant identifier.

serverName string

The server name.

promptName string

The prompt name.

arguments IReadOnlyDictionary<string, string>?

The prompt arguments.

cancellationToken CancellationToken

The cancellation token.

ValueTask<(McpOperationStatus Status, McpPromptContent? Content)>

ListPromptsAsync(string, string, CancellationToken)

Section titled “ ListPromptsAsync(string, string, CancellationToken)”

Fetches a server’s prompt list.

ValueTask<McpPromptListResult> ListPromptsAsync(string tenantId, string serverName, CancellationToken cancellationToken = default)

tenantId string

The tenant identifier.

serverName string

The server name.

cancellationToken CancellationToken

The cancellation token.

ValueTask<McpPromptListResult>