go-airly is a Go client library for accessing the Airly API
go-airly is compatible with modern Go releases in module mode, with Go installed:
go get github.com/probakowski/go-airly
will resolve and add the package to the current development module, along with its dependencies.
Alternatively the same can be achieved if you use import in a package:
import "github.com/probakowski/go-airly"
and run go get
without parameters.
Finally, to use the top-of-trunk version of this repo, use the following command:
go get github.com/probakowski/go-airly@master
import "github.com/probakowski/go-airly"
Construct a new Airly client, then you can use different method from API, for example:
client := airly.Client{
Key: "<your API key>", //required
Language: "pl", //optional, options: en, pl, default en
HttpClient: client, //optional, HTTP client to use, http.DefaultClient will be used if nil
}
installations, err := client.NearestInstallations(airly.Location{Latitude: 50.062006, Longitude: 19.940984})
...