elevation_line

Pack: openrouteservice · Endpoint: https://gateway.pipeworx.io/openrouteservice/mcp

“Elevation profile along a route” / “hiking trail elevation gain” / “topographic profile of [path]” / “how hilly is this route” — elevation samples along a geometry (linestring). Pass geojson / polyline / encodedpolyline5 / encodedpolyline6. Use for hiking elevation gain, cycling grade analysis, trail planning, terrain profiles.

Parameters

NameTypeRequiredDescription
format_instringyesgeojson | polyline | encodedpolyline5 | encodedpolyline6
geometryunknownyesPer format_in

Example call

Arguments

{
  "format_in": "geojson",
  "geometry": {
    "type": "LineString",
    "coordinates": [
      [
        8.681495,
        49.41461
      ],
      [
        8.687872,
        49.420318
      ]
    ]
  }
}

curl

curl -X POST https://gateway.pipeworx.io/openrouteservice/mcp \
  -H 'Content-Type: application/json' \
  -d '{"jsonrpc":"2.0","id":1,"method":"tools/call","params":{"name":"elevation_line","arguments":{"format_in":"geojson","geometry":{"type":"LineString","coordinates":[[8.681495,49.41461],[8.687872,49.420318]]}}}}'

TypeScript (@pipeworx/sdk)

import { Pipeworx } from '@pipeworx/sdk';
const pipeworx = new Pipeworx();

const result = await pipeworx.call('elevation_line', {
  "format_in": "geojson",
  "geometry": {
    "type": "LineString",
    "coordinates": [
      [
        8.681495,
        49.41461
      ],
      [
        8.687872,
        49.420318
      ]
    ]
  }
});

More examples

{
  "format_in": "polyline",
  "geometry": "u{~vFvyys@fS"
}

Response shape

Full JSON Schema
{
  "type": "object",
  "description": "Elevation along line response from OpenRouteService"
}

Connect

Add this to your MCP client config, or use one-click install buttons:

{
  "mcpServers": {
    "openrouteservice": {
      "url": "https://gateway.pipeworx.io/openrouteservice/mcp"
    }
  }
}

See Getting Started for client-specific install steps.

Regenerated from source · build July 6, 2026