Interface IMcpTransport
- Namespace
- Mythosia.AI.Mcp.Transports
- Assembly
- Mythosia.AI.Mcp.dll
Abstraction for MCP transport layer (stdio, SSE, etc.)
public interface IMcpTransport : IAsyncDisposable
- Inherited Members
Properties
IsConnected
Whether the transport is connected and operational
bool IsConnected { get; }
Property Value
Methods
ReceiveAsync(CancellationToken)
Reads the next JSON message from the MCP server
Task<string?> ReceiveAsync(CancellationToken cancellationToken = default)
Parameters
cancellationTokenCancellationToken
Returns
SendAsync(string, CancellationToken)
Sends a JSON message to the MCP server
Task SendAsync(string json, CancellationToken cancellationToken = default)
Parameters
jsonstringcancellationTokenCancellationToken