{
"mcpServers": {
"weather-starter-webmvc-server": {
"args": [
"-Dspring.ai.mcp.server.stdio=true",
"-Dspring.main.web-application-type=none",
"-Dlogging.pattern.console=",
"-jar",
"/absolute/path/to/mcp-weather-starter-webmvc-server-0.0.1-SNAPSHOT.jar"
],
"command": "java"
}
}
}Are you the author?
Add this badge to your README to show your security score and help users find safe servers.
This sample project demonstrates how to create an MCP server using the Spring AI MCP Server Boot Starter with WebMVC transport. It implements a location service that exposes tools for retrieving location information using the National Location Service API.
Is it safe?
No package registry to scan.
No authentication — any process on your machine can connect.
License not specified.
Is it maintained?
Last commit 196 days ago.
Will it work with my client?
Transport: stdio, sse, http. Works with Claude Desktop, Cursor, Claude Code, and most MCP clients.
No automated test available for this server. Check the GitHub README for setup instructions.
No known vulnerabilities.
Have you used this server?
Share your experience — it helps other developers decide.
Sign in to write a review.
🌱 Agricultural AI: Soil analysis, crop recommendations, weather forecasts. FREE TurboQuant.
Hierarchical markdown memory palace for AI agents — structured palace navigation via MCP tools.
Bounding box(bbox) GIS tool: coords conversion, EPSG, WKT, GeoJSON, H3, Overpass, POI, map viz
MCP server for DaData.ru — address validation, company lookup, geocoding. 31 tools.
MCP Security Weekly
Get CVE alerts and security updates for Mcp Server3 and similar servers.
Start a conversation
Ask a question, share a tip, or report an issue.
Sign in to join the discussion.
This sample project demonstrates how to create an MCP server using the Spring AI MCP Server Boot Starter with WebMVC transport. It implements a location service that exposes tools for retrieving location information using the National Location Service API.
For more information, see the MCP Server Boot Starter reference documentation.
The sample showcases:
spring-ai-mcp-server-webmvc-spring-boot-starter@Tool annotationThe project requires the Spring AI MCP Server WebMVC Boot Starter:
<dependency>
<groupId>org.springframework.ai</groupId>
<artifactId>spring-ai-mcp-server-webmvc-spring-boot-starter</artifactId>
</dependency>
This starter provides:
WebMvcSseServerTransport)spring-boot-starter-web and mcp-spring-webmvc dependenciesBuild the project using Maven:
./mvnw clean install -DskipTests
The server supports two transport modes:
java -jar target/mcp-weather-starter-webmvc-server-0.0.1-SNAPSHOT.jar
To enable STDIO transport, set the appropriate properties:
java -Dspring.ai.mcp.server.stdio=true -Dspring.main.web-application-type=none -jar target/mcp-weather-starter-webmvc-server-0.0.1-SNAPSHOT.jar
Configure the server through application.properties:
# Server identification
spring.ai.mcp.server.name=my-weather-server
spring.ai.mcp.server.version=0.0.1
# Server type (SYNC/ASYNC)
spring.ai.mcp.server.type=SYNC
# Transport configuration
spring.ai.mcp.server.stdio=false
spring.ai.mcp.server.sse-message-endpoint=/mcp/message
# Change notifications
spring.ai.mcp.server.resource-change-notification=true
spring.ai.mcp.server.tool-change-notification=true
spring.ai.mcp.server.prompt-change-notification=true
# Logging (required for STDIO transport)
spring.main.banner-mode=off
logging.file.name=./target/starter-webmvc-server.log
getWeatherForecastByLocationlatitude: double - Latitude coordinatelongitude: double - Longitude coordinategetAlertsstate: String - Two-letter US state code (e.g., CA, NY)The server uses Spring Boot and Spring AI's tool annotations for automatic tool registration:
@SpringBootApplication
public class McpServerApplication {
public static void main(String[] args) {
SpringApplication.run(McpServerApplication.class, args);
}
@Bean
public ToolCallbackProvider weatherTools(WeatherService weatherService){
return MethodToolCallbackProvider.builder().toolObjects(weatherService).build();
}
}
The WeatherService implements the weather tools using the @Tool annotation:
@Service
public class WeatherService {
@Tool(description = "Get weather forecast for a specific latitude/longitude")
public String getWeatherForecastByLocation(double latitude, double longitude) {
// Implementation using weather.gov API
... [View full README on GitHub](https://github.com/somasekharraju9/mcp-server3#readme)