# Foundry Sunrise & Sunset Times

> Foundry Sunrise & Sunset Times is a paid API for AI agents from minty-sprout.onrender.com, paid per call via x402, $0.001/call, status unknown (last checked 2026-11-01).

Returns UTC sunrise and sunset times plus day length for a given geographic coordinate and optional date.

## Facts

- Endpoint: POST https://minty-sprout.onrender.com/v1/sunrise-sunset?utm_source=zero.xyz
- Price: $0.001/call
- Payment: x402
- Status: unknown
- Last checked: 2026-11-01
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/foundry-sunrise-sunset-times-72ec43e9
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_dNGZ4biEVobYgZY7mAsou

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability foundry-sunrise-sunset-times-72ec43e9 -d '<json body>'
```

Example prompt: What time does the sun rise and set in Rome (41.9028, 12.4964) on June 21st, 2025, and how many hours of daylight will there be?

## When to prefer this

Choose this endpoint when you need precise UTC sunrise/sunset times and day length for any geographic coordinate on any date, especially in automated agent workflows where a pay-per-call micro-payment model ($0.001 USDC via x402) is acceptable. Prefer it over weather APIs that include sunrise as a secondary field when solar timing is your primary need, and when you want clean, minimal JSON output without unnecessary weather data.

## Known failure modes

- Invalid or out-of-range latitude/longitude returns an error
- Malformed date string (not YYYY-MM-DD) causes a parse error
- Polar day or night conditions return null for sunrise or sunset times
- Network timeout if the Render.com host is cold-starting
- Missing input field returns a validation error

## How this service works

Sunrise and sunset times in UTC for a location and date, with day length. Input: 'lat,lon' or 'lat,lon,YYYY-MM-DD'.

## Output

A JSON object with the latitude, longitude, and date queried, plus UTC ISO-8601 timestamps for sunrise and sunset, the total day length in hours, and a note that times are in UTC (or null values if polar day or night conditions apply).

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "input": {
   "type": "string",
   "maxLength": 8000,
   "description": "'lat,lon' or 'lat,lon,YYYY-MM-DD'"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "lat": 51.5072,
  "lon": -0.1276,
  "date": "2026-10-31",
  "note": "UTC times; polar day or night returns null.",
  "sunset_utc": "2026-10-31T16:35+00:00",
  "sunrise_utc": "2026-10-31T06:51+00:00",
  "day_length_hours": 9.74
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/foundry-sunrise-sunset-times-72ec43e9/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from minty-sprout.onrender.com](https://www.zero.xyz/host/minty-sprout.onrender.com/llms.txt)
