- Namespace
- ModelContextProtocol.Protocol
- Assembly
- ModelContextProtocol.Core.dll
Provides a base class representing contents of a resource in the Model Context Protocol.
[JsonConverter(typeof(ResourceContents.Converter))]
public abstract class ResourceContents
- Inheritance
-
ResourceContents
- Derived
- Inherited Members
- Extension Methods
Remarks
Properties
Meta
Gets or sets metadata reserved by MCP for protocol-level metadata.
[JsonPropertyName("_meta")]
public JsonObject? Meta { get; set; }
Property Value
Remarks
MimeType
Gets or sets the MIME type of the resource content.
[JsonPropertyName("mimeType")]
public string? MimeType { get; set; }
Property Value
Uri
Gets or sets the URI of the resource.
[JsonPropertyName("uri")]
[StringSyntax("Uri")]
public required string Uri { get; set; }