@@ -1273,16 +1273,12 @@ server.addTool(
12731273 Get weather alerts for a US state. Input is Two-letter US state code (e.g. CA, NY)
12741274 """ .trimIndent(),
12751275 inputSchema = Tool .Input (
1276- properties = JsonObject (
1277- mapOf (
1278- " state" to JsonObject (
1279- mapOf (
1280- " type" to JsonPrimitive (" string" ),
1281- " description" to JsonPrimitive (" Two-letter US state code (e.g. CA, NY)" )
1282- )
1283- ),
1284- )
1285- ),
1276+ properties = buildJsonObject {
1277+ putJsonObject(" state" ) {
1278+ put(" type" , " string" )
1279+ put(" description" , " Two-letter US state code (e.g. CA, NY)" )
1280+ }
1281+ },
12861282 required = listOf (" state" )
12871283 )
12881284) { request ->
@@ -1305,12 +1301,10 @@ server.addTool(
13051301 Get weather forecast for a specific latitude/longitude
13061302 """ .trimIndent(),
13071303 inputSchema = Tool .Input (
1308- properties = JsonObject (
1309- mapOf (
1310- " latitude" to JsonObject (mapOf (" type" to JsonPrimitive (" number" ))),
1311- " longitude" to JsonObject (mapOf (" type" to JsonPrimitive (" number" ))),
1312- )
1313- ),
1304+ properties = buildJsonObject {
1305+ putJsonObject(" latitude" ) { put(" type" , " number" ) }
1306+ putJsonObject(" longitude" ) { put(" type" , " number" ) }
1307+ },
13141308 required = listOf (" latitude" , " longitude" )
13151309 )
13161310) { request ->
0 commit comments