Table of Contents

Class TextContentBlock

Namespace
ModelContextProtocol.Protocol
Assembly
ModelContextProtocol.Core.dll

Represents text provided to or from an LLM.

public sealed class TextContentBlock : ContentBlock
Inheritance
TextContentBlock
Inherited Members
Extension Methods

Constructors

TextContentBlock()

Initializes the instance of the TextContentBlock class.

public TextContentBlock()

Properties

Meta

Gets or sets metadata reserved by MCP for protocol-level metadata.

[JsonPropertyName("_meta")]
public JsonObject? Meta { get; set; }

Property Value

JsonObject

Remarks

Implementations must not make assumptions about its contents.

Text

Gets or sets the text content of the message.

[JsonPropertyName("text")]
public required string Text { get; set; }

Property Value

string