MCP server providing weather tools for retrieving current weather forecasts
Single tool with adequate naming (get_city_weather follows verb_noun pattern) and clear description (97 chars, within 10-1024 range). Input schema present with proper type and description. However, output schema is NOT documented, WeatherResponse class exists in code but is never described in tool metadata or documentation. No error handling guidance for LLMs (e.g., 'city not found' scenarios). No parameter constraints (city accepts any string; no validation hints). Tool lacks idempotency/destructiveness annotations. Overall: functional but incomplete for production agent use.
Retrieves the current weather forecast for a specified city.
Output schema not documented. WeatherResponse class exists in code but tool metadata does not describe return fields (location, current, temperature, humidity, etc.). LLMs cannot plan downstream operations or extract specific fields without explicit schema documentation.
No error handling guidance for LLMs. Tool throws InvalidOperationException and ArgumentException but does not document recovery paths. E.g., 'City not found' should suggest 'Try a different city name or use a country code (e.g., London, UK).' Current errors give LLM no actionable next step.
Input parameter lacks constraints. 'city' parameter accepts any string with no format, length, or example guidance. LLMs may pass invalid city names (e.g., '123', 'xyz') without validation hints. Description should specify: 'City name (2-50 chars, e.g., London, New York, Tokyo).'
Inferred effective spec: <=2025-11-25.
| Scored | Grade | Overall | Spec posture | Rubric |
|---|---|---|---|---|
| 2026-09-23 | D | 52 | <=2025-11-25 | v2 |
No tool annotations. Tool lacks readOnlyHint, destructiveHint, or idempotentHint metadata. LLMs cannot determine if the tool is safe to retry or has side effects. Should include readOnlyHint=true since get_city_weather is a read-only query.
API key exposed in .mcp.json configuration. Credentials should never appear in config files or environment variables visible in source control. Use secure secret injection (e.g., Azure Key Vault, HashiCorp Vault) or user secrets with restricted file permissions.