pub fn from_spec(
spec: &McpServerSpec,
timeout: Duration,
) -> Result<McpClient, McpError>Expand description
Build an MCP client from a declared crate::config::McpServerSpec: resolve
its secret-free {{secret:…}} auth header templates (via auth) and connect
to the spec’s remote endpoint, stamping agentd’s client identity. The
config/auth-coupled counterpart of the crate’s transport-only
client::McpClient::connect. Call initialize on the result before use.