Implement MCP task support (SEP-1686) (#1170)

Co-authored-by: Stephen Halter <halter73@gmail.com>
This commit is contained in:
Eirik Tsarpalis 2026-01-28 05:21:02 +02:00 • committed by GitHub
commit 10e4f5b20f
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -1,8 +1,9 @@
using ModelContextProtocol.Server;
using System.Diagnostics;
using System.Diagnostics.CodeAnalysis;
using System.Text.Json;
using System.Text.Json.Nodes;
using System.Text.Json.Serialization;
using ModelContextProtocol.Server;
namespace ModelContextProtocol.Protocol;
@ -111,6 +112,17 @@ public sealed class Tool : IBaseMetadata
[JsonPropertyName("annotations")]
public ToolAnnotations? Annotations { get; set; }
/// <summary>
/// Gets or sets execution-related metadata for this tool.
/// </summary>
/// <remarks>
/// This property provides hints about how the tool should be executed, particularly
/// regarding task augmentation support. See <see cref="ToolExecution"/> for details.
/// </remarks>
[Experimental(Experimentals.Tasks_DiagnosticId, UrlFormat = Experimentals.Tasks_Url)]
[JsonPropertyName("execution")]
public ToolExecution? Execution { get; set; }
/// <summary>
/// Gets or sets an optional list of icons for this tool.
/// </summary>