Golden hour and blue hour API
Golden hour and blue hour are defined by the Sun's altitude, and providers do not all use the same thresholds. The day route returns both periods, morning and evening, in local time, and states its conventions in the result, next to sunrise, sunset and the Moon for the same day.
Get a free key Try it in the playground API reference
What you get
- Golden hour, morning and evening
- Blue hour, morning and evening
- Sunrise, sunset and the Moon's rise, set and phase the same day
- Any date, 1800-2200
Example
curl -X POST https://astro-agent.dev/v1/astronomy/day -H 'Content-Type: application/json' \
-H "X-Credits-Token: $ASTRO_AGENTS_KEY" -d '{"date":"2026-06-21","latitude":48.8566,"longitude":2.3522}'
A real answer to this request (excerpt). The same request always returns the same
result_sha256, which POST https://astro-agent.dev/v1/verify recomputes for free:
{
"endpoint": "astronomy/day",
"result": {
"golden_hour": [
{
"period": "morning",
"start": "2026-06-21T05:21:29+02:00",
"end": "2026-06-21T06:36:58+02:00"
},
{
"period": "evening",
"start": "2026-06-21T21:07:50+02:00",
"end": "2026-06-21T22:23:19+02:00"
}
],
"blue_hour": [
{
"period": "morning",
"start": "2026-06-21T05:04:17+02:00",
"end": "2026-06-21T05:21:29+02:00"
},
{
"period": "evening",
"start": "2026-06-21T22:23:19+02:00",
"end": "2026-06-21T22:40:32+02:00"
}
]
},
"meta": {
"result_sha256": "6f694b02cc506cafaa56f1cf76209f40a82839612346292d674afb0c9ec8f191"
}
}
Routes and prices
| Route | Name | Price per call | What it returns |
|---|---|---|---|
POST /v1/astronomy/day | Astronomical summary of the day for a place | $0.02 | One call for a day at a place: sunrise, sunset, twilight, day length, golden and blue hour; the Moon's phase, illumination, rise and set; the planets observable that night; the next lunations, planetary stations and eclipse. |
POST /v1/astronomy/rise-set | Rise, set and twilight times for a place | $0.01 | Rise, transit and set of the Sun, Moon and planets for a place and local day, with civil, nautical and astronomical twilight, day length, golden hour and blue hour. |
The same routes are MCP tools on https://astro-agent.dev/mcp.
Limits
- Dates from 1800 to 2200; range routes take up to a year per call.
- Without a key: 1 free call on the $0.01-0.02 routes, then HTTP 402 with a pay-per-call offer (USDC, x402).
- Free key (an email, no card): 10,000 calls a month, 30 a minute, personal, research and evaluation use only. Paid plans from $19 a month by card, for commercial use: see pricing.
- Past the quota, calls answer 429 until the 1st of the month: nothing is charged beyond the plan.
Alternatives
sunrisesunset.io and sunrise-sunset.org include golden hour for free. We do not forecast sunset colour or cloud cover: only the geometry.
Checked on the providers' own pages on 2026-11-20. Their terms may have changed since.
When Astro Agents fits
- Photography apps that also want the Moon and the planets
- Planning shoots far ahead or on past dates
- A stated, reproducible definition