TsgcWSAPIClient_MCP › Properties › MCPOptions
Centralises every runtime option for the MCP client (endpoint URL, TLS, authentication, client identity, heartbeat, transport).
property MCPOptions: TsgcAI_MCP_Client_Options read FMCPOptions write SetMCPOptions;
—
Aggregates every configuration sub-object the client needs to reach and negotiate with an MCP server. Populate HttpOptions.URL with the target endpoint (for example https://localhost:5001/mcp) and customise HttpOptions.TLSOptions and HttpOptions.LogOptions when required. Use ClientInfo to advertise the application Name, Title and Version during the initialize handshake. Enable HeartBeat to schedule automatic ping calls. Use AuthenticationOptions for API keys or custom HTTP headers, and pick Transport (aimcptrHttp or aimcptrHttpStreamable) to switch between classic JSON-RPC and streamable HTTP/SSE.
MCP.MCPOptions.HttpOptions.URL := 'https://localhost:5001/mcp';
MCP.MCPOptions.ClientInfo.Name := 'DemoClient';
MCP.MCPOptions.ClientInfo.Title := 'Operations assistant';
MCP.MCPOptions.ClientInfo.Version := '1.0.0';
MCP.MCPOptions.HeartBeat.Enabled := True;
MCP.MCPOptions.HeartBeat.Interval := 30;
MCP.MCPOptions.AuthenticationOptions.ApiKey.Enabled := True;
MCP.MCPOptions.AuthenticationOptions.ApiKey.Value := 'super-secret-token';
MCP.MCPOptions.Transport := aimcptrHttpStreamable;