Skip to main content
Glama

get_utm_zone

Determine the UTM zone for specific geographic coordinates to facilitate accurate geospatial analysis and coordinate transformations using GIS operations.

Instructions

Get UTM zone for given coordinates.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
coordinatesYes

Implementation Reference

  • The handler function implementing the 'get_utm_zone' tool. It computes the UTM zone for given longitude and latitude coordinates using pyproj's database query.
    @gis_mcp.tool() def get_utm_zone(coordinates: List[float]) -> Dict[str, Any]: """Get UTM zone for given coordinates.""" try: import pyproj lon, lat = coordinates zone = pyproj.database.query_utm_crs_info( datum_name="WGS84", area_of_interest=pyproj.aoi.AreaOfInterest( west_lon_degree=lon, south_lat_degree=lat, east_lon_degree=lon, north_lat_degree=lat ) )[0].to_authority()[1] return { "status": "success", "zone": zone, "message": "UTM zone retrieved successfully" } except Exception as e: logger.error(f"Error getting UTM zone: {str(e)}") raise ValueError(f"Failed to get UTM zone: {str(e)}")
  • Resource listing that registers 'get_utm_zone' as an available operation under gis://crs/info.
    @gis_mcp.resource("gis://crs/info") def get_crs_info_operations() -> Dict[str, List[str]]: """List available CRS information operations.""" return { "operations": [ "get_crs_info", "get_available_crs", "get_utm_zone", "get_utm_crs", "get_geocentric_crs" ] }

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/mahdin75/gis-mcp'

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