Releases: modelcontextprotocol/kotlin-sdk
0.11.0
Adds URL-mode elicitation with typed schema definitions, configurable server payload size limits, and upgrades core dependencies to Kotlin 2.3.
Breaking Changes
ElicitRequestParams is now a sealed interface by @devcrocod in #660
Restructured to support both form-based and URL-based elicitation modes per the MCP specification. ElicitRequestParams changed from a data class to a sealed interface with two variants: ElicitRequestFormParams and ElicitRequestUrlParams. A deprecated factory function preserves source compatibility for existing calls.
- val params = ElicitRequestParams(message = "...", requestedSchema = schema)
+ val params = ElicitRequestFormParams(message = "...", requestedSchema = schema)RequestedSchema.properties type changed by @devcrocod in #660
Changed from JsonObject to Map<String, PrimitiveSchemaDefinition> for type safety.
macosX64 target removed by @devcrocod in #625
The macosX64 native target was removed following its deprecation in Kotlin 2.2 and scheduled removal in Kotlin 2.3. Use macosArm64 instead.
Features
- URL-mode elicitation and typed
PrimitiveSchemaDefinitionhierarchy aligned with MCP specification by @devcrocod in #660 - Configurable max request payload size for
StreamableHttpServerTransportviaConfiguration.maxRequestBodySizeby @jskjw157 in #646 - Auto-install
ContentNegotiationwithMcpJsoninmcp(),mcpStreamableHttp(), andmcpStatelessStreamableHttp()— users no longer need to configure JSON serialization manually (#664) by @kpavlov in
#665 notifications/elicitation/completenotification from server to client for out-of-band elicitation completion by
@devcrocod in #667
Fixed
- Elicitation schema defaults are now applied for missing fields in client responses by @devcrocod in #661
- Duplicate
initializerequests are now rejected withINVALID_REQUESTerror by @devcrocod in #624
Maintenance
- Updated Kotlin to 2.3.10, Ktor to 3.3.3, kotlinx-io to 0.9.0, kotlinx-serialization to 1.10.0 by @devcrocod in #611
- Enabled SseTransportTest on Wasm and refactored test structure by @devcrocod in #662
- Improved dependabot configuration by @devcrocod in #619
- Updated mcp-kotlin to 0.10.0 across sample projects by @kpavlov in #645
Dependencies
- modelcontextprotocol/conformance to 0.1.16 in #657
- atomicfu-gradle-plugin to 0.32.1 in #644
- path-to-regexp to 8.4.0 in #647
- Kotest group in #629
- Testing group in #630
- Gradle-plugins group in #633
- Infrastructure group in #632
- GitHub Actions group in #631
- JavaScript dependencies group in #627
- Cross-directory dependencies in #634, #648
- Sample project dependencies (mcp-kotlin, Ktor BOM) in #638, #651, #652, #654
Full Changelog: 0.10.0...0.11.0
0.10.0
Highlights
This release adds MCP conformance testing infrastructure, SSE reconnection support, Tasks protocol types, resource template matching, and
tool execution properties. It also completes a deprecation cycle — removing all previously deprecated (error-level) symbols from
io.modelcontextprotocol.kotlin.sdk in favor of their replacements in io.modelcontextprotocol.kotlin.sdk.types.
Breaking Changes
- Deprecation cycle completed — All symbols deprecated at
ERRORlevel in 0.9.0 have been removed by @devcrocod (#615). This includes
the entireio.modelcontextprotocol.kotlin.sdk.types.ktcompatibility file (type aliases such asCallToolResult,CancelledNotification,
ClientCapabilities,CompleteRequest, etc.) and the legacyMcpJsoninio.modelcontextprotocol.kotlin.sdk. Migrate to the equivalents
inio.modelcontextprotocol.kotlin.sdk.types. - SSE/Streamable HTTP transport changes —
StreamableHttpClientTransportnow acceptsReconnectionOptionsfor configurable retry
behavior by @devcrocod (#585, #596). The previous constructor signatures remain available.
Features
- MCP conformance test infrastructure — Comprehensive conformance test suite covering core protocol operations, tool calls, elicitation,
resources, prompts, and 20 OAuth/auth scenarios. Includes CI workflow, baseline tracking, and shell runner by @devcrocod (#585) - SSE reconnection with retry support — Client transports now support configurable reconnection with exponential backoff via
ReconnectionOptions(initial delay, max delay, multiplier, max retries) by @devcrocod (#596) - Tasks protocol types — Added
Task,TaskStatus, and related models per the MCP tasks specification by @devcrocod (#566) - Resource templates with basic template matcher — Server-side support for URI template-based resource matching by @kpavlov (#502, #606)
- Tool execution properties —
Toolnow exposes execution properties for richer tool metadata by @devcrocod (#567)
Bug Fixes
- Notifications not delivered over Streamable HTTP — Fixed server-side notification delivery for Streamable HTTP transport sessions by
@kpavlov (#587, #599) - Conformance: SEP-1330 enum schemas — Corrected elicitation enum schemas in conformance tests by @kpavlov (#600)
Documentation
- New Streamable HTTP server sample by @devcrocod (#595)
- Updated client and server samples by @devcrocod (#598)
- Added Context7 config file by @devcrocod (#605)
- Updated AGENTS.md by @devcrocod (#612)
- Added missing KDoc for public API members by @kpavlov (#621)
Maintenance
- Simplified and cleaned up CI workflows by @devcrocod (#617)
- Modernized TypeScript integration tests, renamed SSE references to HTTP by @devcrocod (#618)
- Bumped Gradle wrapper from 9.3.1 to 9.4.1 by @dependabot (#614)
- Fix Kotlin language and api version to 2.1 by @kpavlov (#620)
Full Changelog: 0.9.0...0.10.0
0.9.0
What's Changed
Breaking Changes
- Server call handlers now receive a
RequestContext— handler lambdas for tools, prompts, and resources have a newcontextparameter providing access to request metadata (#515) by @rnett - Ktor extension functions moved from
RoutingtoRoute— update call sites:routing { mcpSse() }→route("/mcp") { mcpSse() }or use directly in anyRouteblock (#531) by @kpavlov StdioServerTransportrethrowsCancellationException— cancellation is no longer silently swallowed;ReadBufferparsing was also fixed (#571) by @kpavlov
New Features
kotlin-sdk-testingmodule — new artifact providing an in-process, channel-basedTestClientTransport/TestServerTransportfor unit testing MCP servers and clients without network I/O (#505) by @kpavlovStreamableHttpServerTransport.Configuration— configurable builder for the Streamable HTTP server transport (timeouts, session handling, etc.) (#560) by @kpavlov- Ktor extensions for Streamable HTTP —
mcpStreamableHttp()Ktor plugin and routing DSL for mounting a Streamable HTTP MCP server (#504 by @devcrocod, #568 by @kpavlov) $defssupport inToolSchema— JSON Schema$defs/ definitions can now be expressed in tool input schemas (#526) by @i1bro
Bug Fixes
- Fixed SSE transport endpoint resolution for non-root mount paths (#565) by @Amaneusz
- Fixed
StdioClientTransporthanging indefinitely by adding proper read timeouts (#528) by @kpavlov
Improvements
- Introduced
AbstractClientTransportbase class, simplifying client transport lifecycle management (#516) by @kpavlov - Deprecation cycle started — annotated APIs scheduled for removal in a future release (#498) by @devcrocod
- Detekt static analysis integrated into CI (#493, #507) by @kpavlov
- Code coverage reporting added via Codecov (#579, #580) by @kpavlov
- Flaky
StdioClientTransporttests replaced with real stdin pipe–based tests (#508) by @kpavlov
Dependency Updates
- Kotest 6.1.2, MockK 1.14.9, AtomicFU 0.31.0, Gradle 9.3.1, Kover 0.9.7
New Contributors
- @jskjw157 made their first contribution in #486
- @i1bro made their first contribution in #526
- @localden made their first contribution in #536
- @aozherelyeva made their first contribution in #551
- @rnett made their first contribution in #515
- @Amaneusz made their first contribution in #565
Full Changelog: 0.8.4...0.9.0
0.8.4
Changes
- feat: Ktor extensions for streamable http (#504) by @devcrocod
- fix: Add $defs to ToolSchema and tests (#526) by @i1bro
Full Changelog: 0.8.3...0.8.4
0.8.3
What's Changed
Bugfixes
- breaking change!:
StdioClientTransport.send(...)andStreamableHttpClientTransport.send(...)now throwMcpExceptionwhen not ready (#487) by @kpavlov - #450 Properly check content type (#451) by @nerzhulart
- Fix flaky StdioClientTransportErrorHandlingTest (#457) by @kpavlov
- Fix tests for notifications (#446) by @tiginamaria
- Fix kotlin-mcp-server sample (#459) by @devcrocod
- Fix GitHub Actions build workflow (#474) by @kpavlov
- Fix confirmance tests (#483) by @Fuud and @kpavlov
- Refactor integration test infrastructure, fix and enable tests with ts-client (#478) by @kpavlov
New features
Chores
- Update licensing to Apache 2.0 for new contributions (#481) by @domdomegg
- Add centralized TypeScript server factory for integration tests (#477) by @kpavlov
- Bump actions/setup-node from 4 to 6 (#453) by @dependabot
- Update GitHub Actions workflow (#452) by @kpavlov
- Bump io.mockk:mockk from 1.14.6 to 1.14.7 (#455) by @dependabot
- Bump io.github.oshai:kotlin-logging from 7.0.13 to 7.0.14 (#471) by @dependabot
- Bump org.jetbrains.kotlinx.kover from 0.9.3 to 0.9.4 (#466) by @dependabot
- Bump io.netty:netty-bom from 4.2.7.Final to 4.2.9.Final (#468) by @dependabot
- Bump actions/upload-artifact from 5 to 6 (#465) by @dependabot
New Contributors
- @nathaniellombardi-toast made their first contribution in #472
- @domdomegg made their first contribution in #481
- @Fuud made their first contribution in #483
Full Changelog: 0.8.1...0.8.2
0.8.1
What's Changed
- fix(stdio-client): Monitor STDERR and refactor
StdioClientTransportto use flows. Fixes #107 by @kpavlov - fix(sse-client): Skip SSE in StreamableHttpClientTransport when data is empty (#433) by @kpavlov
- Server feature list changed and resource updated notifications (#441) by @tiginamaria
- Add MCP conformance test coverage (#435) by @skarpovdev
Chores
- Update samples to use new schema (#443) by @kpavlov
- Bump org.jetbrains.kotlinx:kotlinx-io-core from 0.8.1 to 0.8.2 (#440)
- Bump dev.mokksy:mokksy from 0.6.1 to 0.6.2 (#431)
- Bump kotest from 6.0.4 to 6.0.7 (#439)
- Bump actions/checkout from 5 to 6 (#429)
Full Changelog: 0.8.0...0.8.1
0.8.0
🚨 Breaking changes
MCP schema types refactor (#386)
The MCP schema implementation has been updated to the latest MCP spec and reorganized into dedicated packages:
- All MCP types moved to
io.modelcontextprotocol.kotlin.sdk.typespackage - Many schema types have new fields and updated constructor signatures
- Request/response types now use nested
paramsobjects
Migration:
// Before:
import io.modelcontextprotocol.kotlin.sdk.InitializeRequest
import io.modelcontextprotocol.kotlin.sdk.Resource
// After:
import io.modelcontextprotocol.kotlin.sdk.types.InitializeRequest
import io.modelcontextprotocol.kotlin.sdk.types.ResourceMinimum JVM version raised to 11 (#394)
The minimum supported JVM version is now 11. Projects running on Java 8 must upgrade their runtime and build toolchain.
Transport.send signature change (#408)
The Transport.send method now accepts TransportSendOptions? parameter to support resumption tokens, progress callbacks, and request–response association.
Note
Who is affected?
Only custom Transport implementations. Built-in transports require no changes.
Migration:
Update all Transport.send implementations to include the new TransportSendOptions? parameter.
Features
- New MCP Schema types (#386) @devcrocod
- Add server session id (#381) @tiginamaria
- Add new helper properties to request and notification types (#388) @devcrocod
- Add experimental mcpClient(...) factory method (#396) @kpavlov
- Proposal: DSL Builders for request types (#399) @devcrocod
- Add options in Transport.send method (#408) @devcrocod
- Add convenience constructors to JSONRPCRequest (#336) @kpavlov
Improvements
- Raise the version of the supported specification (#391) @devcrocod
- Increase deprecation levels (#393) @devcrocod
- Updated ServerPromptsTest, move AbstractTransport to its own file (#376) @kpavlov
- Add backwards compatibility constructors and tests (#395) @kpavlov
- Add warning message to ExperimentalMcpApi annotation and change level (#398) @devcrocod
- Handle additional error types in client initialization handling (#404) @devcrocod
- Add test with new schema types (#389) @devcrocod
Bug Fixes
- Kotlin-MCP can't be used without ktor-bom starting from 0.7.5 (#392) @IRus
- Fix providing progressToken with request (#405) @devcrocod
Documentation & Examples
Build & Dependencies
- Bump version to 0.8.0-SNAPSHOT and update mcp-kotlin dependency in samples (#385) @kpavlov
- Update JVM target to 11 in Gradle build configuration (#394) @kpavlov
- Bump org.jlleitschuh.gradle.ktlint from 13.1.0 to 14.0.1 (#402) @dependabot[bot]
- Bump com.vanniktech:gradle-maven-publish-plugin from 0.34.0 to 0.35.0 (#403) @dependabot[bot]
New Contributors
Full Changelog: 0.7.7...0.8.0
0.7.7
0.7.6
What's Changed
Bugfixes
Dependencies
- Bump version to 0.7.6-SNAPSHOT and update version to 0.7.5 in samples by @kpavlov in #374
- Update Gradle to version 9.2.0 across all projects by @kpavlov in #377
Full Changelog: 0.7.5...0.7.6
0.7.5
What's Changed
- Refactor WebSocket dependency by @devcrocod in #350
- Fix: Return CallToolResult with isError for tool errors to conform with MCP spec by @devcrocod in #354
- Relocate
WebSocketIntegrationTestfromcommonTesttojvmTestby @devcrocod in #352 - Fix kotlin-mcp-server example and update samples by @devcrocod in #345
- Fix security for logging in server by @devcrocod in #360
- Refactor mcp server, rename connect to by @tiginamaria in #364
- Fix: Memory leak from unclosed sessions in Server by @devcrocod in #359
- Move features(tools, prompts, resources) management to the FeatureRegistry by @tiginamaria in #365
- Refactor ServerTest test structure by @tiginamaria in #366
- Fix: Handle logging/setLevel request for server by @devcrocod in #358
- Add Ktor BOM for dependency management across all modules, run Kotlin-MCP-Server Sample by @kpavlov in #367
- Add tests to server samples by @tiginamaria in #369
- Adds optional _meta field to Tool by @jclyne in #339
- Update Kotlin-MCP-Server with STDIO support, logging & CORS by @kpavlov in #371
- Update .gitignore to exclude kotlin-js-store directory by @devcrocod in #343
- Add AGENTS.md by @devcrocod in #349
Dependencies
- Bump org.openapi.generator from 7.16.0 to 7.17.0 by @dependabot[bot] in #362
- Bump mikepenz/action-junit-report from 5 to 6 by @dependabot[bot] in #363
- Bump actions/upload-artifact from 4 to 5 by @dependabot[bot] in #348
Full Changelog: 0.7.4...0.7.5