McpTransports

Holds the shared McpTransport used by McpTools that don't bring their own (see the transport overload of the MCPTool(...) factory).

Resolution order:

  1. factory provided via register (highest priority);

  2. McpTransportFactory discovered via ServiceLoader (JVM; the kory-ktor module ships the service file);

  3. otherwise - IllegalStateException with setup instructions.

The created transport lives for the whole application lifetime and is never closed automatically (like most global HTTP clients).

Functions

Link copied to clipboard
fun register(transport: McpTransport)
Link copied to clipboard
suspend fun shared(): McpTransport