/v1/eclipses/lunar
Next lunar eclipse.
What this tells you
Next upcoming lunar eclipse. Unlike solar eclipses which require being in a narrow path, lunar eclipses are visible everywhere on the night-side of Earth. Culturally associated with reflection, fasting, and Rahu/Ketu significations.
Request
All requests require an Authorization header with your dv_live_* API key.
curl "https://api.divyastroapi.com/v1/eclipses/lunar?date=2026-04-19&time=06%3A30&tz=%2B05%3A30&lat=28.61&lon=77.21" \
-H "Authorization: Bearer dv_live_0123456789abcdef0123456789abcdef"Response (200 OK)
Successful requests return a JSON body. Field names are stable across versions.
{
"next": {
"type": "total",
"peak_jd": 2461544.3183,
"peak_local": "2027-02-13T02:58:46+05:30",
"magnitude": 1.164,
"duration_minutes": 82.4,
"visibility_at_request_location": "total"
}
}Field reference
Every field in the response, with its type, a real example, and what it means.
| Field | Type | Meaning |
|---|---|---|
| next.type | string | total / partial / penumbral. example: "total" |
| next.magnitude | number | Umbral magnitude. >1 = total. example: 1.164 |
| next.duration_minutes | number | Duration of totality. example: 82.4 |
| next.visibility_at_request_location | string | Lunar eclipses are visible from the entire night-side of Earth, so visibility is based on whether it's night at your location. example: "total" |
Usage tips
How to use it
- Fasting remindersMany observances (like not eating cooked food during eclipse) are tied to eclipse visibility. Use `visibility_at_request_location` to decide whether to send a reminder.
Errors
Every error follows the same envelope. Use the error.code field (not the message) for conditional logic in your integration.
401 Unauthorized
{
"error": {
"code": "unauthorized",
"message": "missing or invalid API key",
"request_id": "req_01hqy7k8c3e7m1n"
}
}402 Payment Required
{
"error": {
"code": "trial_exhausted",
"message": "your free trial credits are exhausted — pick a plan to continue",
"top_up_url": "https://divyastroapi.com/pricing",
"request_id": "req_01hqy7k8c3e7m1n"
}
}429 Too Many Requests
{
"error": {
"code": "rate_limited",
"message": "rate limit exceeded; retry after 12 seconds",
"request_id": "req_01hqy7k8c3e7m1n"
}
}Try it
Get a dv_live_* key from your dashboard and paste into the cURL snippet above. New accounts get 500 free credits. Sign up.