Skip to main content
Glama

Solar position and irradiance

get_solar_position
Read-onlyIdempotent

The sun's position at one instant: azimuth, altitude, zenith, declination, hour angle and equation of time, plus clear-sky irradiance (GHI, DNI and DHI in W/m²) when include asks for it and the plan covers it. Use it for where the sun is at a given moment; for its track through a whole day use get_solar_path, and for rise and set times use get_sun_moon_times. timestamp defaults to now. Positions are NREL SPA-equivalent on JPL DE421; irradiance comes from the Bird clear-sky model. Requires an API key on a paid Solar plan.

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": {
      "lat": "<lat>",
      "lon": "<lon>"
    },
    "name": "get_solar_position"
  }
}

Input Schema

NameRequiredDescriptionDefault
tzNoIANA timezone for output timestamps, e.g. Europe/Dublin. Defaults to UTC.
latYesLatitude in decimal degrees.
lonYesLongitude in decimal degrees.
includeNoposition (default) or position,irradiance.
elevationNoMetres. For sun and moon times this is the observer's height above the horizon they look across: on a sea cliff or island peak, their height above sea level; on a plateau or in a valley, close to zero. For irradiance it is height above sea level. Supply it when known: from a height the sun rises measurably earlier than the sea-level answer. Omit only if it is genuinely unknown.
timestampNoISO 8601 instant, e.g. 2026-06-21T12:00:00Z. Defaults to now.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / elevation / description
      Previous value: -"Metres above sea level. Supply it when known: at altitude the sun rises measurably earlier than the sea-level answer. Omit only if the elevation is genuinely unknown."New value: +"Metres. For sun and moon times this is the observer's height above the horizon they look across: on a sea cliff or island peak, their height above sea level; on a plateau or in a valley, close to zero. For irradiance it is height above sea level. Supply it when known: from a height the sun rises measurably earlier than the sea-level answer. Omit only if it is genuinely unknown."
  2. Changed4 schema fields changed
    • changedInput schema / properties / include / description
      Previous value: -"Comma-separated sections, e.g. position,irradiance."New value: +"position (default) or position,irradiance."
    • addedInput schema / properties / include / enum
      Added value: +[
      +  "position",
      +  "position,irradiance"
      +]
    • changedInput schema / properties / timestamp / description
      Previous value: -"ISO 8601 instant, e.g. 2026-06-21T12:00:00Z."New value: +"ISO 8601 instant, e.g. 2026-06-21T12:00:00Z. Defaults to now."
    • changedInput schema / properties / tz / description
      Previous value: -"IANA timezone for output timestamps, e.g. Europe/Dublin."New value: +"IANA timezone for output timestamps, e.g. Europe/Dublin. Defaults to UTC."
  3. Added

TDQS

A4.3/5.0
Behavior4/5

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

Beyond the readOnly/idempotent/non-destructive annotations, it discloses a real operational constraint: an API key on a paid Solar plan is required, and irradiance is only returned when include requests it and the plan covers it. It also identifies the computational provenance (NREL SPA-equivalent on JPL DE421, Bird clear-sky model), which matters for accuracy expectations. It stops short of describing error behavior or precision caveats in numeric terms.

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?

The output contents and the sibling routing are front-loaded, followed by defaults, provenance, and auth requirement in compact form. It is dense but every clause carries information; the provenance sentence is the only part an agent might not strictly need to select or call the tool.

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?

With no output schema, the description carries the burden of naming return fields, and it does so thoroughly for both the position and irradiance branches, including units for irradiance. It leaves angular units (degrees) and output framing unspecified, a minor gap for a read-only single-instant query.

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%, so the schema already documents every parameter including elevation's dual meaning and tz. The description adds only marginal meaning, notably the plan-gating on the irradiance option and the timestamp default. Baseline 3 is appropriate when the schema does the heavy lifting.

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 names a specific resource (the sun's position at one instant) and enumerates the returned quantities: azimuth, altitude, zenith, declination, hour angle, equation of time, plus GHI/DNI/DHI. It explicitly contrasts itself with get_solar_path (whole-day track) and get_sun_moon_times (rise/set), so an agent can select it 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 Guidelines5/5

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

It gives an explicit selection rule: 'Use it for where the sun is at a given moment,' and routes two concrete alternatives to their own tools with the distinguishing condition for each. It also states that timestamp defaults to now, covering the common no-argument invocation.

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.