skills sourced live from GitHub · all skills listed are free · each skill is provided under its author's license.
home / AI Agents & MCP / Java MCP Server Generator Skill by @github
The skill is the skills/java-mcp-server-generator folder inside that repository. Copy it into the folder your agent loads skills from; check your agent's documentation for where that is.
Walks through building a Model Context Protocol server in Java or Spring Boot with the official SDK, from project creation to client config.
Follows a build-until-tests-pass loop: create the project, write the server, add tests, build, then register it with an MCP client. It carries version notes for the SDK and spec revisions plus a gotchas section for common setup mistakes.
The original SKILL.md is organised into these sections:
Written and maintained by @github. It is published under the MIT license, which allows reuse with attribution. See the author profile. SkillDirectory does not claim authorship: this page adds our own review and links back to the original, and the skill's text belongs to its author.
# Java MCP Server Generator
Create a Model Context Protocol (MCP) server in Java with the official [MCP Java SDK](https://github.com/modelcontextprotocol/java-sdk) 2.x. SDK 2.0.x supports the MCP specification revision [2025-11-25](https://modelcontextprotocol.io/specification/2025-11-25) and the earlier revisions. SDK 3.x will add the revision [2026-07-28](https://modelcontextprotocol.io/specification/2026-07-28).
## Workflow
Copy this checklist and track your progress:
- [ ] Step 1: Create the project.
- [ ] Step 2: Write the server.
- [ ] Step 3: Write the tests.
- [ ] Step 4: Build until the tests pass.
- [ ] Step 5: Configure the client.
### Step 1: Create the project
Use Maven by default. If the project uses Gradle or the user asks for Gradle, read [references/gradle.md](references/gradle.md). Use it for Step 1, Step 4, and Step 5.
Make this layout:
```text
project-name/
├── pom.xml
└── src/
├── main/java/com/example/McpServerApp.java
…
Excerpt only, quoted from the author's repository. Open the repository for the complete file.