https://github.com/jrswab/veterejo
Veterejo is a Go package for querying weather data from Open Weather Maps.
https://github.com/jrswab/veterejo
openweather-api openweathermap weather weather-data
Last synced: about 1 year ago
JSON representation
Veterejo is a Go package for querying weather data from Open Weather Maps.
- Host: GitHub
- URL: https://github.com/jrswab/veterejo
- Owner: jrswab
- License: bsd-3-clause
- Created: 2020-03-08T03:47:22.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2021-06-29T14:03:40.000Z (almost 5 years ago)
- Last Synced: 2025-02-06T10:40:15.016Z (over 1 year ago)
- Topics: openweather-api, openweathermap, weather, weather-data
- Language: Go
- Homepage:
- Size: 22.5 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
[](https://goreportcard.com/report/github.com/jrswab/veterejo)
# veterejo
Veterejo is a Go package for querying weather data from Open Weather Maps.
Vetero is "weather" in Esperanto and "ejo" is place.
By replacing the **o** of a noun with **ejo** the word discribes a place of that thing.
(eg: Computilejo = computer-place or in English a computer lab)
## Using This Package:
1. Get an API Key from [OpenWeatheMap](https://openweathermap.org)
2. Import this package
3. Create a new `WeatherData` struct: `w := new(veterejo.WeatherData)`
4. Parse the URL: `url, err := veterejo.MakeURL(yourCityID, unitsOfMeasure, yourApiId)`
- `yourApiId` is required
- The rest may be omitted by passing an empty string.
- This package defaults the units of mesaure to metric.
5. Call the data: `w.getData(url)`
6. Use the appropriate method to get the most recent data needed from OpenWeatherMap.
*veterejo is licensed under the BSD 3-Clause "New" or "Revised" License*