Skip to main content
Glama

get_daily_forecast

Retrieve the daily weather forecast for any Spanish municipality using its AEMET code. Access accurate meteorological data directly via the AEMET-MCP server.

Instructions

Get the daily weather forecast for a Spanish municipality.

Args: municipality_code: AEMET municipality code (e.g., "28079" for Madrid)

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
municipality_codeYes

Implementation Reference

  • The main handler function for the 'get_daily_forecast' tool. It is registered via the @mcp.tool() decorator and fetches the daily weather forecast from AEMET API using the provided municipality code.
    @mcp.tool()
    async def get_daily_forecast(municipality_code: str):
        """Get the daily weather forecast for a Spanish municipality.
        
        Args:
            municipality_code: AEMET municipality code (e.g., "28079" for Madrid)
        """
    
        url = f"{AEMET_API_BASE}/prediccion/especifica/municipio/diaria/{municipality_code}"
        return await make_aemet_request(url)
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full burden of behavioral disclosure. It states the tool retrieves forecast data but doesn't describe what the return format looks like, whether it includes multiple days, time ranges, data fields (e.g., temperature, precipitation), error handling, rate limits, or authentication needs. For a data-fetching tool with zero annotation coverage, this leaves significant gaps in understanding its behavior.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is appropriately sized and front-loaded, with the core purpose stated first in a clear sentence. The 'Args' section efficiently documents the parameter with an example. There's no wasted text, though the structure could be slightly improved by integrating the parameter details more seamlessly rather than as a separate block.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's moderate complexity (fetching forecast data), lack of annotations, and no output schema, the description is incomplete. It doesn't explain what the forecast data includes (e.g., time periods, weather metrics), how results are formatted, or potential limitations. This leaves the agent with insufficient information to use the tool effectively beyond basic invocation.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The description adds meaningful context for the single parameter 'municipality_code' by explaining it's an 'AEMET municipality code' and providing an example ('28079' for Madrid). With 0% schema description coverage and only one parameter, this compensates well beyond the schema's basic type information, though it could specify format constraints or validation rules more explicitly.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool's purpose: 'Get the daily weather forecast for a Spanish municipality.' It specifies the verb ('Get'), resource ('daily weather forecast'), and geographic scope ('Spanish municipality'). However, it doesn't explicitly differentiate from sibling tools like 'get_historical_data' or 'monthly_climate_data', which prevents a perfect score.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no guidance on when to use this tool versus alternatives. It doesn't mention sibling tools like 'get_historical_data' for historical forecasts or 'monthly_climate_data' for monthly data, nor does it specify prerequisites or exclusions. The only contextual hint is the geographic scope ('Spanish municipality'), but this is part of the purpose statement rather than usage guidance.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Related Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/AnCode666/aemet-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server