Skip to main content
Glama

Get a course's hills

ourpr_get_course_terrain
Read-onlyIdempotent

The elevation profile of one course, sampled, plus every climb and descent ourpr. named on it.

THIS IS THE TOOL FOR "what are the hills and where". Each named section carries the street it runs on, the miles it spans, its net rise or fall and its average grade.

The elevation comes from a public terrain model sampled along the measured centerline (elevation_source names it), not from a watch barometer. A barometer drifts; the model is checked against published race figures.

Args:

  • slug (string): From ourpr_list_courses.

  • points (number): Elevation samples to return, 2 to 200. Default 40. The stored profile holds up to 4,873.

  • response_format ('markdown' | 'json'): Default 'markdown'.

Returns: { "slug": string, "name": string, "distance_mi": number, "climb_ft": number | null, "descent_ft": number | null, "min_ft": number | null, "max_ft": number | null, "steepest_pct": number | null, "climb_ft_per_mi": number | null, "elevation_source": string, "profile_points_stored": number, "profile": [{ "mi": number, "ft": number }], "named_sections": [{ "kind": "climb" | "descent", "name": string, "from_mi": number, "to_mi": number, "net_ft": number, "grade_pct": number }], "page_url": string }

The sampled profile always keeps the first point, the last point, the highest and the lowest, so its extremes agree with min_ft and max_ft.

A course with no named sections returns an empty array. That means the seeder found no stretch that qualified, not that the course is flat: read climb_ft.

Examples:

  • "What are the hills on Boston?" -> slug="boston-marathon"

  • "Is Houston flat?" -> slug="houston-marathon", read climb_ft_per_mi

  • "Give me the profile in detail" -> points=200

Error handling:

  • Returns the slug list suggestion when the slug is unknown.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "slug": "<slug>"
    },
    "name": "ourpr_get_course_terrain"
  }
}

Input Schema

NameRequiredDescriptionDefault
slugYesThe course's slug.
pointsNoHow many elevation samples to return. The stored profile holds up to 4,873 points, which no agent should read whole. 40 describes the shape; 200 is close to the source.
response_formatNoOutput format. 'markdown' reads well in a chat answer. 'json' carries every field for further computation.markdown

Output Schema

NameRequiredDescriptionDefault
nameYes
slugYes
max_ftYes
min_ftYes
profileYesSampled elevation. The highest and lowest points are kept.
climb_ftYes
page_urlYes
descent_ftYes
distance_miYes
steepest_pctYes
named_sectionsYes
climb_ft_per_miYes
elevation_sourceYes
profile_points_storedYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changed
    • changedInput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
    • changedOutput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
  2. First observed

TDQS

A4.6/5.0
Behavior5/5

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

Annotations already cover safety (readOnly, idempotent, non-destructive), and the description adds genuinely new behavior: the elevation comes from a public terrain model along the measured centerline rather than a drifting barometer, the sampling always preserves first/last/highest/lowest so extremes agree with min_ft/max_ft, and an empty named_sections array means no qualifying stretch rather than flat terrain. Error behavior (slug-list suggestion on unknown slug) is also disclosed.

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?

Front-loaded with the one-line purpose and the 'THIS IS THE TOOL FOR' callout, then ordered into source, args, returns, examples, errors. The full Returns block duplicates an existing output schema and the points rationale appears twice, costing a little length without adding information.

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

Completeness5/5

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

For a read-only, three-parameter lookup with an output schema, the description supplies everything an agent still needs: where slug comes from, what the sample count trades off, how the source differs from a watch barometer, how to interpret empty named sections, and what happens on a bad slug.

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?

Schema coverage is 100%, so the baseline is 3, but the description adds cross-tool provenance for slug ('From ourpr_list_courses') and reinforces the sampling tradeoff (40 describes the shape, 200 is close to the source) with a worked example. It is additive rather than merely restating the schema.

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?

Opens with a specific verb+resource ('The elevation profile of one course, sampled, plus every climb and descent') and then explicitly positions itself: 'THIS IS THE TOOL FOR "what are the hills and where"'. That phrasing separates it from the route/terrain siblings without the agent needing to open another 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?

Three concrete example intents map queries to arguments ('What are the hills on Boston?', 'Is Houston flat?' -> read climb_ft_per_mi, 'profile in detail' -> points=200), which is strong contextual guidance. It stops short of naming an alternative tool or an explicit when-not-to-use condition, so it falls below a 5.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources