# SiteCheck Sun & Moon Position Lookup

> SiteCheck Sun & Moon Position Lookup is a paid API for AI agents from api.sitecheck-api.workers.dev, paid per call via x402, $0.001/call, status unknown (last checked 2026-10-19).

Returns sunrise, sunset, solar noon, day length, and moon phase/rise/set times for a given latitude/longitude and date

## Facts

- Endpoint: GET https://api.sitecheck-api.workers.dev/api/sun?utm_source=zero.xyz
- Price: $0.001/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-19
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/sitecheck-sun-moon-position-lookup-3c8f1a07
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_ZTmSObfShV3TxbTFD7hOY

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 sitecheck-sun-moon-position-lookup-3c8f1a07
```

Example prompt: What time is sunrise and sunset in Berlin (52.52, 13.405) on October 14, 2026, and what moon phase will it be?

## When to prefer this

Choose this endpoint when you need accurate, per-coordinate sunrise/sunset/solar noon and moon phase data for any date and location worldwide. It is especially useful when you need both solar and lunar data in a single call. Backed by MET Norway (a trusted meteorological source), it is suitable for scheduling, photography planning, agricultural timing, or any use case requiring precise astronomical times at a geographic point.

## Known failure modes

- Missing lat or lon parameters returns a validation error
- Latitude outside -90 to 90 or longitude outside -180 to 180 causes rejection
- Invalid date format (not YYYY-MM-DD) may return an error or default to today
- Polar regions during midnight sun or polar night return null for some sun fields
- Upstream MET Norway API unavailability causes service failure

## How this service works

Sunrise, sunset, solar noon and day length for a coordinate and date (default today), with the moonrise, moonset and phase. Times are ISO 8601 with the offset MET Norway gives (+00:00 is UTC). Attribution: data from MET Norway (CC BY 4.0).

## Output

A JSON object containing: sunrise and sunset times in ISO 8601 format with UTC offset, solar noon time, day length in decimal hours, moon phase name (e.g. 'waxing crescent'), phase degrees, moonrise and moonset times, plus metadata including source attribution (MET Norway CC BY 4.0) and a checkedAt timestamp.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "required": [
      "lat",
      "lon"
     ],
     "properties": {
      "lat": {
       "type": "string",
       "description": "Latitude, -90 to 90"
      },
      "lon": {
       "type": "string",
       "description": "Longitude, -180 to 180"
      },
      "date": {
       "type": "string",
       "description": "Date, YYYY-MM-DD (default today)"
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object"
    }
   }
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "lat": 52.52,
  "lon": 13.405,
  "sun": {
   "polar": null,
   "sunset": "2026-10-14T16:14+00:00",
   "sunrise": "2026-10-14T05:29+00:00",
   "solarNoon": "2026-10-14T10:52+00:00",
   "dayLengthHours": 10.75
  },
  "date": "2026-10-14",
  "moon": {
   "phase": "waxing crescent",
   "moonset": "2026-10-14T17:11+00:00",
   "moonrise": "2026-10-14T10:20+00:00",
   "phaseDegrees": 38.41
  },
  "times": "ISO 8601 with the offset MET Norway gives (+00:00 is UTC)",
  "source": "https://api.met.no/weatherapi/sunrise/3.0 (sun, moon). Data from MET Norway (CC BY 4.0)",
  "checkedAt": "2026-10-14T07:00:46.216Z"
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/sitecheck-sun-moon-position-lookup-3c8f1a07/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.sitecheck-api.workers.dev](https://www.zero.xyz/host/api.sitecheck-api.workers.dev/llms.txt)
