Table of Contents

Class ElicitationCapability

Namespace
ModelContextProtocol.Protocol
Assembly
ModelContextProtocol.Core.dll

Represents the capability for a client to provide server-requested additional information during interactions.

public class ElicitationCapability
Inheritance
ElicitationCapability
Inherited Members

Remarks

This capability enables the MCP client to respond to elicitation requests from an MCP server.

When this capability is enabled, an MCP server can request the client to provide additional information during interactions. The client must set a ElicitationHandler to process these requests.

Properties

ElicitationHandler

Gets or sets the handler for processing ElicitationCreate requests.

[JsonIgnore]
public Func<ElicitRequestParams?, CancellationToken, ValueTask<ElicitResult>>? ElicitationHandler { get; set; }

Property Value

Func<ElicitRequestParams, CancellationToken, ValueTask<ElicitResult>>

Remarks

This handler function is called when an MCP server requests the client to provide additional information during interactions. The client must set this property for the elicitation capability to work.

The handler receives message parameters and a cancellation token. It should return a ElicitResult containing the response to the elicitation request.