Skip to content

Commit d0f396d

Browse files
authored
Merge pull request modelcontextprotocol#962 from sunyuhan1998/fix-issue-933
fix: modelcontextprotocolGH-933 fixed the error code in the Java MCP Server documentation.
1 parent eae29bb commit d0f396d

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

docs/sdk/java/mcp-server.mdx

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -725,8 +725,7 @@ var mcpServer = McpServer.sync(mcpServerTransportProvider)
725725
// ...
726726
.build())
727727
// ...
728-
.completions(new McpServerFeatures.SyncCompletionSpecification( // register completion specification
729-
new McpSchema.PromptReference("code_review"), syncCompletionSpecification))
728+
.completions(syncCompletionSpecification) // register completion specification
730729
.build();
731730

732731
```
@@ -758,8 +757,7 @@ var mcpServer = McpServer.async(mcpServerTransportProvider)
758757
// ...
759758
.build())
760759
// ...
761-
.completions(new McpServerFeatures.AsyncCompletionSpecification( // register completion specification
762-
new McpSchema.PromptReference("code_review"), asyncCompletionSpecification))
760+
.completions(asyncCompletionSpecification) // register completion specification
763761
.build();
764762

765763
```

0 commit comments

Comments
 (0)