Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions src/ModelContextProtocol/Client/SseClientTransportOptions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,15 @@ namespace ModelContextProtocol.Client;
/// <summary>
/// Provides options for configuring <see cref="SseClientTransport"/> instances.
/// </summary>
public record SseClientTransportOptions
public class SseClientTransportOptions
{
/// <summary>
/// Gets or sets the base address of the server for SSE connections.
/// </summary>
public required Uri Endpoint
{
get;
init
set
{
if (value is null)
{
Expand Down Expand Up @@ -43,12 +43,12 @@ public required Uri Endpoint
/// <see href="https://modelcontextprotocol.io/specification/2024-11-05/basic/transports#http-with-sse">HTTP with SSE transport specification</see>.
/// </para>
/// </remarks>
public HttpTransportMode TransportMode { get; init; } = HttpTransportMode.AutoDetect;
public HttpTransportMode TransportMode { get; set; } = HttpTransportMode.AutoDetect;

/// <summary>
/// Gets a transport identifier used for logging purposes.
/// </summary>
public string? Name { get; init; }
public string? Name { get; set; }

/// <summary>
/// Gets or sets a timeout used to establish the initial connection to the SSE server. Defaults to 30 seconds.
Expand All @@ -61,13 +61,13 @@ public required Uri Endpoint
/// </list>
/// If the timeout expires before the connection is established, a <see cref="TimeoutException"/> will be thrown.
/// </remarks>
public TimeSpan ConnectionTimeout { get; init; } = TimeSpan.FromSeconds(30);
public TimeSpan ConnectionTimeout { get; set; } = TimeSpan.FromSeconds(30);

/// <summary>
/// Gets custom HTTP headers to include in requests to the SSE server.
/// </summary>
/// <remarks>
/// Use this property to specify custom HTTP headers that should be sent with each request to the server.
/// </remarks>
public Dictionary<string, string>? AdditionalHeaders { get; init; }
public Dictionary<string, string>? AdditionalHeaders { get; set; }
}
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ namespace ModelContextProtocol.Client;
/// <summary>
/// Provides options for configuring <see cref="StdioClientTransport"/> instances.
/// </summary>
public record StdioClientTransportOptions
public class StdioClientTransportOptions
{
/// <summary>
/// Gets or sets the command to execute to start the server process.
Expand Down
2 changes: 1 addition & 1 deletion src/ModelContextProtocol/ProgressNotificationValue.cs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
namespace ModelContextProtocol;

/// <summary>Provides a progress value that can be sent using <see cref="IProgress{ProgressNotificationValue}"/>.</summary>
public record struct ProgressNotificationValue
public class ProgressNotificationValue
{
/// <summary>
/// Gets or sets the progress thus far.
Expand Down
2 changes: 1 addition & 1 deletion src/ModelContextProtocol/Protocol/Annotations.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ namespace ModelContextProtocol.Protocol;
/// Annotations enable filtering and prioritization of content for different audiences.
/// See the <see href="https://github.com/modelcontextprotocol/specification/blob/main/schema/">schema</see> for details.
/// </remarks>
public record Annotations
public class Annotations
{
/// <summary>
/// Gets or sets the intended audience for this content as an array of <see cref="Role"/> values.
Expand Down
2 changes: 1 addition & 1 deletion src/ModelContextProtocol/Protocol/InitializeResult.cs
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ namespace ModelContextProtocol.Protocol;
/// See the <see href="https://github.com/modelcontextprotocol/specification/blob/main/schema/">schema</see> for details.
/// </para>
/// </remarks>
public record InitializeResult
public class InitializeResult
{
/// <summary>
/// Gets or sets the version of the Model Context Protocol that the server will use for this session.
Expand Down
2 changes: 1 addition & 1 deletion src/ModelContextProtocol/Protocol/JsonRpcErrorDetail.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ namespace ModelContextProtocol.Protocol;
/// a standard format for error responses that includes a numeric code, a human-readable message,
/// and optional additional data.
/// </remarks>
public record JsonRpcErrorDetail
public class JsonRpcErrorDetail
{
/// <summary>
/// Gets an integer error code according to the JSON-RPC specification.
Expand Down
2 changes: 1 addition & 1 deletion src/ModelContextProtocol/Protocol/PingResult.cs
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,4 @@ namespace ModelContextProtocol.Protocol;
/// is still responsive.
/// </para>
/// </remarks>
public record PingResult;
public class PingResult;
2 changes: 1 addition & 1 deletion src/ModelContextProtocol/Protocol/Resource.cs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ namespace ModelContextProtocol.Protocol;
/// <remarks>
/// See the <see href="https://github.com/modelcontextprotocol/specification/blob/main/schema/">schema</see> for details.
/// </remarks>
public record Resource
public class Resource
{
/// <summary>
/// Gets or sets the URI of this resource.
Expand Down
2 changes: 1 addition & 1 deletion src/ModelContextProtocol/Protocol/ResourceTemplate.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ namespace ModelContextProtocol.Protocol;
/// Resource templates provide metadata about resources available on the server,
/// including how to construct URIs for those resources.
/// </remarks>
public record ResourceTemplate
public class ResourceTemplate
{
/// <summary>
/// Gets or sets the URI template (according to RFC 6570) that can be used to construct resource URIs.
Expand Down