A simple Dart wrapper for the Sunrise-Sunset API, enabling easy integration of sunrise and sunset time data into Flutter applications. It provides a clean interface to fetch accurate astronomical times based on geographic coordinates, supporting multiple platforms including mobile, web, and desktop. The package abstracts HTTP requests and JSON parsing, making it straightforward to use in apps that require time-of-day calculations for location-based features.
Use cases
- Fetching sunrise and sunset times by location
- Building weather or daylight tracking apps
- Enhancing calendar or scheduling tools with solar times
- Creating outdoor activity planners
- Integrating solar data into IoT or smart home apps
Key features
- Simple synchronous and async API calls
- Supports latitude and longitude input
- Returns precise sunrise and sunset timestamps
- Cross-platform compatibility
- Minimal setup required
- Automatic JSON handling
Suitable for
- Developers building location-aware apps
- Apps needing solar time data
- Flutter projects targeting multiple platforms
- Simple integrations without complex dependencies
Considerations
- Relies on external API availability
- Requires internet connection for data
- No caching built-in
- Limited to sunrise/sunset data only
- Not suitable for offline use