-
Notifications
You must be signed in to change notification settings - Fork 0
Backend rundown
elsapolo edited this page Mar 8, 2024
·
3 revisions
The backend is written in kotlin using the ktor framework by JetBrains to create an API. The backend is then hosted on Heroku, but this can be switched easily. The backend collates data from a wide variety of sources and also processes it to produce routes, weather conditions, and route difficulty.
The routes currently provided are:
- /beaches - returns every beach on the isle of wight
- /slipway - returns the closest slipway to a particular location
- /sunset - returns the sunrise and sunset at a particular location and date. If the date parameter is not provided it returns it for the current date
- /tidetimes - returns the times for high and low tide for the next 7 days at a certain location
- /tide - returns the tide at a certain time and location
- /tideGrid - returns a grid of tide data at between # two locations at a certain time
- /wind - returns wind at a certain time and location
- /winds - returns winds at for a route given the locations and list of checkpoints (seconds since start of route) and start (date at which the route starts)
- /windGrid - similar to tide grid
- /wave - returns wave height and direction at certain location and time
- /waveGrid - similar to tide grid
- /times - the times available for the data given the grib files - currently for tide, wind, wave
- /planRoute - plans a route given a location, maximum duration, start time from one location to another
- /planCircularRoute - plans a circular route given a location, maximum duration and a date where you are supported by the tide
The backend collates from a variety of data sources for all these routes. The current utilised data sources are listed below
- Beaches/Slipways - open street map
- Sunset/Sunrise - api.sunrisesunset.io
- Tidetimes - Admiralty api
- Tide, Wind, Wave data - Open skiron grib files
All data sources are easily interchangeable, and are configured using the config.yaml
. Currently no alternatives are programmed.