diff --git a/src/ModelContextProtocol.NET.Core/Models/Protocol/Shared/Content/EmbeddedResource.cs b/src/ModelContextProtocol.NET.Core/Models/Protocol/Shared/Content/EmbeddedResource.cs index c61b89a..854b58c 100644 --- a/src/ModelContextProtocol.NET.Core/Models/Protocol/Shared/Content/EmbeddedResource.cs +++ b/src/ModelContextProtocol.NET.Core/Models/Protocol/Shared/Content/EmbeddedResource.cs @@ -1,7 +1,10 @@ -namespace ModelContextProtocol.NET.Core.Models.Protocol.Shared.Content; +using System.Text.Json.Serialization; + +namespace ModelContextProtocol.NET.Core.Models.Protocol.Shared.Content; public record EmbeddedResource : Annotated { + [JsonIgnore] public string Type => "resource"; public required ResourceContents Resource { get; init; } } diff --git a/src/ModelContextProtocol.NET.Core/Models/Protocol/Shared/Content/ImageContent.cs b/src/ModelContextProtocol.NET.Core/Models/Protocol/Shared/Content/ImageContent.cs index b0acdb8..6c28ec8 100644 --- a/src/ModelContextProtocol.NET.Core/Models/Protocol/Shared/Content/ImageContent.cs +++ b/src/ModelContextProtocol.NET.Core/Models/Protocol/Shared/Content/ImageContent.cs @@ -1,7 +1,10 @@ -namespace ModelContextProtocol.NET.Core.Models.Protocol.Shared.Content; +using System.Text.Json.Serialization; + +namespace ModelContextProtocol.NET.Core.Models.Protocol.Shared.Content; public record ImageContent : Annotated { + [JsonIgnore] public string Type => "image"; public required string Data { get; init; } public required string MimeType { get; init; } diff --git a/src/ModelContextProtocol.NET.Core/Models/Protocol/Shared/Content/TextContent.cs b/src/ModelContextProtocol.NET.Core/Models/Protocol/Shared/Content/TextContent.cs index fe508b7..58cf4ce 100644 --- a/src/ModelContextProtocol.NET.Core/Models/Protocol/Shared/Content/TextContent.cs +++ b/src/ModelContextProtocol.NET.Core/Models/Protocol/Shared/Content/TextContent.cs @@ -1,7 +1,10 @@ +using System.Text.Json.Serialization; + namespace ModelContextProtocol.NET.Core.Models.Protocol.Shared.Content; public record TextContent : Annotated { + [JsonIgnore] public string Type => "text"; public required string Text { get; init; }