Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: MackinnonBuck <10456961+MackinnonBuck@users.noreply.github.com> Co-authored-by: eiriktsarpalis <2813363+eiriktsarpalis@users.noreply.github.com> Co-authored-by: Mackinnon Buck <mackinnon.buck@gmail.com> Co-authored-by: jeffhandley <1031940+jeffhandley@users.noreply.github.com> Co-authored-by: Jeff Handley <jeffhandley@users.noreply.github.com>
34 lines
1.4 KiB
C#
34 lines
1.4 KiB
C#
using ModelContextProtocol.Server;
|
|
using System.ComponentModel;
|
|
using System.Text.Json.Serialization;
|
|
|
|
namespace ModelContextProtocol.Protocol;
|
|
|
|
/// <summary>
|
|
/// Represents the server's capability to provide predefined prompt templates that clients can use.
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// The prompts capability allows a server to expose a collection of predefined prompt templates that clients
|
|
/// can discover and use. These prompts can be static (defined in the <see cref="McpServerOptions.PromptCollection"/>) or
|
|
/// dynamically generated through handlers.
|
|
/// </para>
|
|
/// <para>
|
|
/// See the <see href="https://github.com/modelcontextprotocol/specification/blob/main/schema/">schema</see> for details.
|
|
/// </para>
|
|
/// </remarks>
|
|
public sealed class PromptsCapability
|
|
{
|
|
/// <summary>
|
|
/// Gets or sets a value that indicates whether this server supports notifications for changes to the prompt list.
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// When set to <see langword="true"/>, the server will send notifications using
|
|
/// <see cref="NotificationMethods.PromptListChangedNotification"/> when prompts are added,
|
|
/// removed, or modified. Clients can register handlers for these notifications to
|
|
/// refresh their prompt cache. This capability enables clients to stay synchronized with server-side changes
|
|
/// to available prompts.
|
|
/// </remarks>
|
|
[JsonPropertyName("listChanged")]
|
|
public bool? ListChanged { get; set; }
|
|
}
|