sun_times
Compute sunrise, sunset, solar noon, and civil twilight for any latitude/longitude on a given date. Times are computed in code from the standard NOAA solar-position equations (no third-party API is called, so the result is dependency-free and resale-safe). Times are returned in UTC by default; pa...
This record as markdown: /tools/io-github-blackboxfoundry-livedatalink/sun-times.md
What sun_times does on Livedatalink
AI agents use sun_times to create or update resources in Livedatalink, usually the action step of a workflow, after the agent has gathered context. Every call changes real data in your Livedatalink environment.
| Parameter | Type | Required | Description |
|---|---|---|---|
lat | number | Yes | Latitude in decimal degrees (positive north). |
lon | number | Yes | Longitude in decimal degrees (negative west). |
date | string | — | Date, 'YYYY-MM-DD'. Defaults to today (UTC). |
tz_offset | number | — | Hours from UTC applied to output times, e.g. -7 for US Pacific Daylight Time. Default 0 (UTC). |
Parameters from the server's own tool schema.
Why sun_times is rated Medium
An AI agent can call sun_times faster than any human can review: one bad instruction and it creates or modifies resources in Livedatalink by the hundred, each call as confident as the last.
Attacks that exploit this kind of access
The rule that runs sun_times safely
PolicyLayer is an MCP gateway: it sits between your AI agents and Livedatalink, and checks every tool call against a rule you set before the call runs. Nothing changes on the server itself. For sun_times, this is the rule to start with:
sun_times stays usable, but capped: an agent stuck in a loop can't make hundreds of changes a minute. Everything else on the server is denied unless you say otherwise.
The button opens the PolicyLayer dashboard: create your workspace, connect Livedatalink, apply this rule, and every sun_times call is checked against it from then on.
Questions about sun_times
Compute sunrise, sunset, solar noon, and civil twilight for any latitude/longitude on a given date. Times are computed in code from the standard NOAA solar-position equations (no third-party API is called, so the result is dependency-free and resale-safe). Times are returned in UTC by default; pass tz_offset (hours from UTC, e.g. -7 for US Pacific Daylight Time) to shift the output to local clock time. Polar day and polar night are reported when the sun does not rise or set. Use it for daylight planning, photography golden-hour timing, or agriculture and energy calculations. It is categorised as a Write tool in the Livedatalink MCP Server, which means it can create or modify data. Consider rate limits to prevent runaway writes.
sun_times accepts 4 parameters: lat, lon, date, tz_offset. Required: lat, lon. The full parameter table on this page comes from the server's own tool schema.
Register the Livedatalink MCP server in PolicyLayer and add a rule for sun_times: allow, deny, rate-limit, or require approval. Point your MCP client at the PolicyLayer proxy URL and the rule is enforced on every call, before it reaches Livedatalink. Nothing to install.
sun_times is a Write tool with medium risk. Write tools should be rate-limited to prevent accidental bulk modifications.
Yes. Add a rate_limit block to the sun_times rule in your PolicyLayer policy. For example, setting max: 10 and window: 60 limits the tool to 10 calls per minute. Rate limits are tracked per agent session and reset automatically.
Set action: deny in the PolicyLayer policy for sun_times. The AI agent will receive a policy violation error and cannot call the tool. You can also include a reason field to explain why the tool is blocked.
sun_times is provided by the Livedatalink MCP server (https://livedatalink.ai/mcp). PolicyLayer sits as a proxy in front of this server to enforce policies before tool calls reach the server.
More on Livedatalink, and thousands of servers like it.
This server
Across the catalogue