spring-ai-mcp-server-patterns

Installation
Summary

Build MCP servers with Spring AI using declarative tools, prompt templates, and native Spring integration patterns.

  • Exposes Spring components as AI-callable tools via @Tool annotation, with parameter documentation through @ToolParam for AI model understanding
  • Supports three transport modes (stdio, HTTP, SSE) with built-in Spring Security integration for role-based access control and audit logging
  • Includes reusable prompt templates using @PromptTemplate, dynamic tool registration, multi-model support, and caching strategies for production deployments
  • Provides comprehensive testing patterns with unit, integration, and security test examples using MockMvc, Testcontainers, and Spring Boot test slices
SKILL.md

Spring AI MCP Server Implementation Patterns

Implements MCP servers with Spring AI for AI function calling, tool handlers, and MCP transport configuration.

Overview

Production-ready MCP server patterns: @Tool functions, @PromptTemplate resources, and stdio/HTTP/SSE transports with Spring AI security.

When to Use

MCP servers, Spring AI function calling, AI tools, tool calling, custom tool handlers, Spring Boot MCP, resource endpoints, or MCP transport configuration.

Quick Reference

Core Annotations

Annotation Target Purpose
@EnableMcpServer Class Enable MCP server auto-configuration
Related skills

More from giuseppe-trisciuoglio/developer-kit

Installs
919
GitHub Stars
246
First Seen
Feb 3, 2026