StreamableHttpClientTransport
constructor(client: HttpClient, url: String, reconnectionOptions: ReconnectionOptions = ReconnectionOptions(), requestBuilder: HttpRequestBuilder.() -> Unit = {})(source)
constructor(client: HttpClient, url: String, reconnectionTime: Duration?, requestBuilder: HttpRequestBuilder.() -> Unit = {})(source)
Deprecated
Use constructor with ReconnectionOptions
Replace with
import kotlin.time.Duration.Companion.seconds
import io.modelcontextprotocol.kotlin.sdk.client.ReconnectionOptions
Content copied to clipboard
StreamableHttpClientTransport(client, url, ReconnectionOptions(initialReconnectionDelay = reconnectionTime ?: 1.seconds), requestBuilder)Content copied to clipboard