📄️ Class 1: Why Spring AI + MCP?
What Spring AI adds to an MCP stack, how the two fit together, and the support desk we build across this course.
📄️ Class 2: From a REST Application to an MCP Server
Add the MCP server starter to an existing Spring Boot service, write the first @McpTool, and call it over curl.
📄️ Class 3: Tools in Depth
The rest of the order tools, structured output schemas, behavioral hints, and writing descriptions and errors a model can act on.
📄️ Class 4: Resources
Expose orders and policy documents as MCP resources with @McpResource and URI templates, and see why a resource is not a tool.
📄️ Class 5: Prompts and Completion
Expose a reusable refund-email prompt with @McpPrompt and @McpArg, and complete order IDs as its argument is filled in with @McpComplete.
📄️ Class 6: Connecting a Client
Add the support-agent module, connect it to order-service over Streamable HTTP, discover the tools and call one from Java.
📄️ Class 7: Handing the Tools to a Model
Configure a model provider, give the discovered MCP tools to ChatClient, add a system prompt and conversation memory, and answer support questions in English.
📄️ Class 8: Consuming Resources and Prompts
Read an MCP resource into a conversation and run a server-supplied prompt, calling the server directly with McpSyncClient.
📄️ Class 9: A Server We Did Not Write
Connect the agent to the npm filesystem MCP server over stdio, and reuse Claude Desktop's own configuration file to do it.
📄️ Class 10: Several Servers at Once
Connect two servers offering identical tool names, see how Spring AI renames them, and control the result with McpToolNamePrefixGenerator and McpToolFilter.
📄️ Class 11: Progress and Logging
Inject McpSyncRequestContext into a tool, report progress and log messages from a long job, and handle both on the client with @McpProgress and @McpLogging.
📄️ Class 12: Elicitation
A tool that stops mid-execution and asks a person to confirm, with context.elicit on the server and @McpElicitation on the client.
📄️ Class 13: Roots, Notifications and Sampling
Configure a client in Java with McpClientCustomizer, tell a server what it may reach with roots, react to change notifications, send application data in _meta, and see why roots and sampling are deprecated.
📄️ Class 14: Testing
Test tool methods as plain Java, assert the annotation scanner registered everything, stub the request context, and replace the model so the suite is fast and repeatable.
📄️ Class 15: Async and Stateless
Run the same service reactive and stateless, see how methods that do not match the configured type are filtered out at startup, and choose between the transports and starters.
📄️ Class 16: Guardrails and Budgets
Write a Spring AI advisor, block a request before it reaches the model with SafeGuardAdvisor, enforce a token budget of your own, and see why neither of them stops a prompt injection arriving in a tool result.
📄️ Class 17: Third-Party MCP Clients
Run the same order service over stdio, register it in Claude Desktop, import it into Claude Code, and watch the prompt, the resources and the confirmation dialog rendered by clients somebody else built.