Request parameters | Response parameters
Astronomy API query string parameters
Parameter | Description | Default value | |
api |
Hostname to be used only in production: api.accuweather.com |
N/A |
Required |
apidev |
Hostname to be used only in development: apidev.accuweather.com |
N/A |
Required |
apikey |
Unique code used to access the API |
N/A |
Required |
version |
Version of the API |
v1 |
Required |
locationkey |
Unique ID used to search for a specific location |
N/A |
Required |
format |
Format of the response |
JSON |
Optional |
q |
Text to match |
N/A |
Required |
start |
Date indicating the start date of a range |
N/A |
Required |
end |
Date indicating the end date of a range |
N/A |
Required |
gmtoffset |
The difference in hours and minutes from GMT |
N/A |
Required |
days |
The number of days to query |
N/A |
Optional |
phases |
The number of major phases |
N/A |
Optional |
Top of page
Astronomy API response parameters
Parameter | Description |
Date |
Date of the astronomy information displayed in ISO8601 format: yyyy-mm-ddThh:mm:ss±hh:mm |
Moon |
Moon |
|
BodyName |
Name of celestial body |
|
Age |
The age of the moon relative to the month |
|
Phase |
Refers to the shape of the illuminated (sunlit) portion of the moon |
|
Path |
The path of the body during this date |
|
Rise |
The rise date/time of the body |
|
RisesToday |
True/False response indicating whether the body rises above the horizon on this day at the given location |
|
Set |
The set date/time of the body |
|
SetsToday |
True/False response indicating whether the body sets below the horizon on this day at the given location |
Sun |
Sun |
|
BodyName |
Name of celestial body |
|
Path |
The path of the body during this date |
|
Rise |
The rise date/time of the body |
|
RisesToday |
True/False response indicating whether the body rises above the horizon on this day at the given location |
|
Set |
The set date/time of the body |
|
SetsToday |
True/False response indicating whether the body sets below the horizon on this day at the given location |
Top of page