From 4aeed923f6a5bf5210334550bde835bfe8b9fb9b Mon Sep 17 00:00:00 2001 From: Pavel Gorgulov Date: Thu, 13 Nov 2025 21:05:45 +0100 Subject: [PATCH] Add warning message to ExperimentalMcpApi annotation and change level (#398) - add the warning message to `ExperimentalMcpApi` annotation - change level from error to warning ## Types of changes - [ ] Bug fix (non-breaking change which fixes an issue) - [ ] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to change) - [x] Documentation update ## Checklist - [x] I have read the [MCP Documentation](https://modelcontextprotocol.io) - [x] My code follows the repository's style guidelines - [x] New and existing tests pass locally - [ ] I have added appropriate error handling - [x] I have added or updated documentation as needed --- .../io/modelcontextprotocol/kotlin/sdk/ExperimentalMcpApi.kt | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/kotlin-sdk-core/src/commonMain/kotlin/io/modelcontextprotocol/kotlin/sdk/ExperimentalMcpApi.kt b/kotlin-sdk-core/src/commonMain/kotlin/io/modelcontextprotocol/kotlin/sdk/ExperimentalMcpApi.kt index 7278f4e..aa8f179 100644 --- a/kotlin-sdk-core/src/commonMain/kotlin/io/modelcontextprotocol/kotlin/sdk/ExperimentalMcpApi.kt +++ b/kotlin-sdk-core/src/commonMain/kotlin/io/modelcontextprotocol/kotlin/sdk/ExperimentalMcpApi.kt @@ -35,7 +35,10 @@ import kotlin.annotation.AnnotationTarget.VALUE_PARAMETER * - Property setters * - Type aliases */ -@RequiresOptIn +@RequiresOptIn( + message = "This API is experimental. It may be changed in the future without notice.", + level = RequiresOptIn.Level.WARNING, +) @MustBeDocumented @Target( CLASS,