GuidesAPI Reference
Guides

AstronomyItemType

The structure AstronomyItemsType represents the information about when the sun and moon rise and set, and the phase of the moon.

The following table documents the member elements of AstronomyItemsType.

ElementData typeDescription
sunRisestringTime when the Sun rises.
sunSetstringTime when the Sun sets.
moonRisestringTime when the Moon rises.
moonSetstringTime when the Moon sets.
moonPhasedoubleThe moon phase expressed as floating point number between -1 and 1.
The following logic should be used for displaying moonphase information: Moon phase value
Description
-0.1 <= moonphase <= 0.1New moon.
0.1 < moonphase < 0.4Waxing crescent.
0.4 <= moonphase <= 0.6First Quarter.
0.6 < moonphase < 0.9Waxing gibbous.
0.9 <= moonphase or moonphase <= -0.9Full moon.
-0.9 < moonphase < -0.6Waning gibbous.
-0.6 <= moonphase <= -0.4Last Quarter.
-0.4 < moonphase < -0.1Waning crescent.
moonPhaseDescriptionstringDescription of the phase of the moon.
moonIconNamestringName of the icon for moon phase from the reporting service.
timestringDate and time the forecast was issued. The format is either YYYY-MM-DDThh:mm:ss.SSS + the timezone offset, unless the forecast is for a location in the UTC zone, in which the date and time is terminated by a Z.
Note: If daylight saving time is in effect for a specified location, times will be adjusted for daylight savings time.