Skip to main content
Glama

get_elevation

Read-onlyIdempotent

Query terrain elevation in meters for points, bbox grids, line-of-sight intervisibility, and route profiles. Use it to check elevation gain, grade, or whether two points see each other.

Instructions

Query terrain elevation in meters above sea level using the Open-Meteo 90m Copernicus DEM API (free for non-commercial use; commercial use requires a paid key or self-hosted ELEVATION_API_URL). Supports 4 modes: 'points' (discrete coordinates), 'grid' (N×N bbox sample statistics), 'line_of_sight' (3D terrain intervisibility with WGS84 Earth curvature & atmospheric refraction between two points), and 'profile' (cumulative elevation gain/loss and max grade % along a route_geometry or path).

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "get_elevation"
  }
}

Input Schema

NameRequiredDescriptionDefault
bboxNoA bounding box or point string to sample terrain elevation across (or SW-to-NE endpoints for 'line_of_sight'/'profile').
modeNoElevation query mode: 'points' (discrete coordinates), 'grid' (N×N bbox sample), 'line_of_sight' (3D terrain intervisibility & Earth curvature check between two points), or 'profile' (elevation gain/loss & grade profile along a path/route).
originNoStart point ('lat,lng' or place name) for 'line_of_sight' or 'profile' mode.
pointsNoList of {lat, lng, label?} points to query elevation for (up to 100 points). Also accepted as [observer, target] in 'line_of_sight' or path vertices in 'profile'.
locationNoA text location to sample elevation across (e.g. 'Mount Rainier', 'Denver').
grid_sizeNoGrid dimension N (N x N samples, from 2 to 10) when sampling a bounding box. Defaults to 5 (25 sample points).
destinationNoEnd/target point ('lat,lng' or place name) for 'line_of_sight' or 'profile' mode.
sample_countNoNumber of elevation samples along the ray or route for 'line_of_sight' or 'profile' (5 to 100, default 25).
route_geometryNoGeoJSON LineString ({ type: 'LineString', coordinates: [[lng, lat], ...] }) from calculate_route to sample an elevation profile along.
target_height_metersNoTarget height in meters above ground for 'line_of_sight' (default 0m).
observer_height_metersNoObserver height in meters above ground for 'line_of_sight' (default 1.7m).
refraction_coefficientNoAtmospheric refraction coefficient k for Earth curvature in 'line_of_sight' (default 0.13).

Output Schema

NameRequiredDescriptionDefault
bboxYes
modeYes
samplesYes
completeYes
warningsYes
share_urlYes
provenanceYes
sample_countYes
sample_statsYes
line_of_sightNo
matched_placeNo
profile_statsNo
dem_resolution_metersYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed12 schema fields changedv1.7.0
    • changedInput schema / properties / bbox / description
      Previous value: -"A bounding box or point string to sample terrain elevation across."New value: +"A bounding box or point string to sample terrain elevation across (or SW-to-NE endpoints for 'line_of_sight'/'profile')."
    • addedInput schema / properties / destination
      Added value: +{
      +  "description": "End/target point ('lat,lng' or place name) for 'line_of_sight' or 'profile' mode.",
      +  "type": "string"
      +}
    • addedInput schema / properties / mode
      Added value: +{
      +  "description": "Elevation query mode: 'points' (discrete coordinates), 'grid' (N×N bbox sample), 'line_of_sight' (3D terrain intervisibility & Earth curvature check between two points), or 'profile' (elevation gain/loss & grade profile along a path/route).",
      +  "enum": [
      +    "points",
      +    "grid",
      +    "line_of_sight",
      +    "profile"
      +  ],
      +  "type": "string"
      +}
    • addedInput schema / properties / observer_height_meters
      Added value: +{
      +  "description": "Observer height in meters above ground for 'line_of_sight' (default 1.7m).",
      +  "type": "number"
      +}
    • addedInput schema / properties / origin
      Added value: +{
      +  "description": "Start point ('lat,lng' or place name) for 'line_of_sight' or 'profile' mode.",
      +  "type": "string"
      +}
    • changedInput schema / properties / points / description
      Previous value: -"List of {lat, lng, label?} points to query elevation for (up to 100 points)."New value: +"List of {lat, lng, label?} points to query elevation for (up to 100 points). Also accepted as [observer, target] in 'line_of_sight' or path vertices in 'profile'."
    • addedInput schema / properties / refraction_coefficient
      Added value: +{
      +  "description": "Atmospheric refraction coefficient k for Earth curvature in 'line_of_sight' (default 0.13).",
      +  "type": "number"
      +}
    • addedInput schema / properties / route_geometry
      Added value: +{
      +  "description": "GeoJSON LineString ({ type: 'LineString', coordinates: [[lng, lat], ...] }) from calculate_route to sample an elevation profile along.",
      +  "properties": {
      +    "coordinates": {
      +      "items": {
      +        "items": {
      +          "type": "number"
      +        },
      +        "type": "array"
      +      },
      +      "type": "array"
      +    },
      +    "type": {
      +      "type": "string"
      +    }
      +  },
      +  "required": [
      +    "type",
      +    "coordinates"
      +  ],
      +  "type": "object"
      +}
    • addedInput schema / properties / sample_count
      Added value: +{
      +  "description": "Number of elevation samples along the ray or route for 'line_of_sight' or 'profile' (5 to 100, default 25).",
      +  "type": "number"
      +}
    • addedInput schema / properties / target_height_meters
      Added value: +{
      +  "description": "Target height in meters above ground for 'line_of_sight' (default 0m).",
      +  "type": "number"
      +}
    • addedOutput schema / properties / line_of_sight
      Added value: +{
      +  "properties": {
      +    "destination": {
      +      "type": "object"
      +    },
      +    "distance_km": {
      +      "type": "number"
      +    },
      +    "distance_meters": {
      +      "type": "number"
      +    },
      +    "effective_earth_radius_meters": {
      +      "type": "number"
      +    },
      +    "elevation_angle_degrees": {
      +      "type": "number"
      +    },
      +    "initial_bearing_degrees": {
      +      "type": "number"
      +    },
      +    "is_visible": {
      +      "type": "boolean"
      +    },
      +    "limiting_point": {
      +      "type": "object"
      +    },
      +    "max_obstruction_meters": {
      +      "type": "number"
      +    },
      +    "min_clearance_meters": {
      +      "type": "number"
      +    },
      +    "origin": {
      +      "type": "object"
      +    },
      +    "radio_horizon_km": {
      +      "type": "number"
      +    },
      +    "refraction_coefficient": {
      +      "type": "number"
      +    }
      +  },
      +  "type": "object"
      +}
    • addedOutput schema / properties / profile_stats
      Added value: +{
      +  "properties": {
      +    "cumulative_gain_meters": {
      +      "type": "number"
      +    },
      +    "cumulative_loss_meters": {
      +      "type": "number"
      +    },
      +    "max_decline_grade_percent": {
      +      "type": "number"
      +    },
      +    "max_incline_grade_percent": {
      +      "type": "number"
      +    },
      +    "net_elevation_change_meters": {
      +      "type": "number"
      +    },
      +    "steepest_segment": {
      +      "type": "object"
      +    },
      +    "total_distance_km": {
      +      "type": "number"
      +    },
      +    "total_distance_meters": {
      +      "type": "number"
      +    }
      +  },
      +  "type": "object"
      +}
  2. Addedv1.5.0

TDQS

A3.8/5.0
Behavior3/5

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

Annotations already declare readOnlyHint, idempotentHint, openWorldHint and destructiveHint=false, so the safety profile is covered. The description adds genuinely useful context the annotations cannot: 90m DEM resolution, free non-commercial licensing, and that commercial use needs a paid key or self-hosted ELEVATION_API_URL. It does not mention rate limits, failure behavior, or cost of large grids, which matters for a metered third-party API.

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?

A single front-loaded sentence that leads with what is queried and how, then layers the four modes with concrete semantics ('WGS84 Earth curvature & atmospheric refraction', 'cumulative elevation gain/loss and max grade %'). Dense but every clause carries information; the licensing parenthetical could be moved to a trailing note.

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

Completeness3/5

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

With 12 optional parameters and zero required ones, the description never states which parameter combinations satisfy each mode (e.g. points vs origin+destination for line_of_sight); the agent must reconstruct that from the individual schema descriptions. Output-schema presence and strong annotations keep this from being a blocking gap, but per-mode required inputs belong here.

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

Parameters3/5

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

Schema coverage is 100% and every parameter, including the enum and nested route_geometry, is already documented, so baseline is 3. The description's mode summary overlaps the schema's own enum description and adds little new per-parameter meaning beyond naming 'route_geometry or path' as profile input.

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?

States a specific verb and resource ('Query terrain elevation in meters above sea level') plus the exact upstream provider (Open-Meteo 90m Copernicus DEM), and enumerates the four supported modes with their distinct outputs. An agent can distinguish this from siblings like spatial_calc or get_bounds without opening the schema.

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 mode list effectively tells the agent which query shape to pick (discrete points vs bbox grid vs intervisibility vs route profile), and 'route_geometry ... from calculate_route' hints at the upstream sibling. It stops short of explicit when-not-to-use guidance, e.g. it never says to prefer spatial_calc for pure geometry math or get_h3_indices for aggregation.

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