Skip to main content
Glama

get_station_info

Retrieve detailed station information including name, location, and type by providing a station code for Japan Meteorological Agency weather stations.

Instructions

Get AMeDAS station information by station code.

Args: code: Station code (e.g., '44132' for Tokyo)

Returns: Station information including name, location, and type

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
codeYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The async handler function for the 'get_station_info' MCP tool, registered via @mcp.tool() decorator. It fetches station info by code using the get_station helper or returns an error if not found.
    @mcp.tool()
    async def get_station_info(code: str) -> dict:
        """Get AMeDAS station information by station code.
    
        Args:
            code: Station code (e.g., '44132' for Tokyo)
    
        Returns:
            Station information including name, location, and type
        """
        station = get_station(code)
        if station:
            return station
        return {"error": f"Station with code '{code}' not found."}
  • Core helper function that loads AMeDAS stations data from JSON file (cached) and retrieves the specific station dictionary by its code.
    def get_station(code: str) -> Optional[dict]:
        """Get station by code."""
        stations = load_stations()
        return stations.get(code)
Behavior3/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. It discloses that the tool retrieves information (a read operation) and specifies the return content, but does not mention potential behaviors like error handling, rate limits, or authentication needs. The description is adequate but lacks rich behavioral context beyond basic functionality.

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

Conciseness5/5

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

The description is appropriately sized and front-loaded, with the core purpose in the first sentence and additional details in a structured format (Args and Returns sections). Every sentence earns its place by providing essential information without redundancy.

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

Completeness4/5

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

Given the tool's low complexity (1 parameter), no annotations, and the presence of an output schema (which handles return values), the description is mostly complete. It covers purpose, parameter semantics, and return content, but could improve by adding more behavioral context or usage guidelines to reach full completeness.

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

Parameters5/5

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

Schema description coverage is 0%, so the description must compensate. It adds significant meaning beyond the schema by explaining that 'code' is a 'Station code' and providing an example ('e.g., '44132' for Tokyo'), which clarifies the parameter's purpose and format, fully compensating for the lack of schema descriptions.

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

Purpose5/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 with a specific verb ('Get') and resource ('AMeDAS station information'), and distinguishes it from siblings by specifying it retrieves information 'by station code' rather than by location, type, or other criteria used by tools like get_weather_by_location or get_stations_of_type.

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

Usage Guidelines4/5

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

The description implies usage context by specifying 'by station code', which helps differentiate it from alternatives like list_stations or search_stations that don't require a code. However, it lacks explicit guidance on when to use this versus, for example, get_current_weather for weather data or list_stations for browsing, and does not mention exclusions.

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

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/koizumikento/jma-data-mcp'

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