Sunet/Sunrise - Request
https://sonicweather.com/API/sunset.php?lat=[latitude]&long=[longitude]&key=[SonicWeather key]
Request Parameters
latitude - required
The latitude of the location for sunset quality
longitude - required
The longitude of the location for sunset quality
key - required
Your SonicWeather secret key. Your secret key must be kept secret. Do not embed it in JavaScript source
code that you transmit to clients.
Sample Request
https://sonicweather.com/API/sunset.php?lat=39.55&long=-101.13&key=abcdefghijklmnop
( [sonic] => Array ( [key] => abcdefghijklmnop ) [loc] => Array ( [lat] => 39.55 [long] => -101.13 ) [sun] => Array ( [type] => sunset [time] => 23:46 [twilight] => Array ( [civil] => 00:19 [astro] => 01:31 ) [quality] => 0 ) )
Response Format
key - Your secret key
lat - The latitude of the requested location
long - The longitude of the requested location
set - An array of information regarding the quality of the sunrise or sunset. The type
is either the sunrise or sunset, depending on the current time of day. Sunrise will be set if it
is currently evening. The time is the local time of the sunrise/sunset in GMT. Daylight savings is not
included in the local time. Twilight times are also given. The quality
value is the quality of the sunrise/sunset on a scale of 0-10. 10 being the best and 0 the worst.