-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Updated readme and added a bunch of colourful badges
- Loading branch information
Showing
2 changed files
with
35 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,33 @@ | ||
# brightsky | ||
Brightsky Provider | ||
# PHP Weather Provider for Bright Sky | ||
|
||
![Packagist Version](https://img.shields.io/packagist/v/php-weather/brightsky) | ||
![GitHub Release Date](https://img.shields.io/github/release-date/php-weather/brightsky) | ||
![GitHub commits since tagged version](https://img.shields.io/github/commits-since/php-weather/brightsky/0.1.0) | ||
![GitHub Workflow Status](https://img.shields.io/github/workflow/status/php-weather/brightsky/PHP%20Composer) | ||
![GitHub](https://img.shields.io/github/license/php-weather/brightsky) | ||
![Packagist PHP Version Support](https://img.shields.io/packagist/php-v/php-weather/brightsky) | ||
|
||
This is the [Bright Sky](https://brightsky.dev/) provider from PHP Weather. | ||
|
||
> Bright Sky is an open-source project aiming to make some of the more popular data — in particular weather observations from the DWD station network and weather forecasts from the MOSMIX model — available in a free, simple JSON API. | ||
## Installation | ||
|
||
Via Composer | ||
|
||
```shell | ||
composer require php-weather/brightsky | ||
``` | ||
|
||
## Usage | ||
|
||
```php | ||
$httpClient = new \Http\Adapter\Guzzle7\Client(); | ||
$brightSky = new \PhpWeather\Provider\Brightsky\Brightsky($httpClient); | ||
|
||
$latitude = 47.873; | ||
$longitude = 8.004; | ||
|
||
$currentWeatherQuery = \PhpWeather\Common\WeatherQuery::create($latitude, $longitude); | ||
$currentWeather = $brightSky->getCurrentWeather($currentWeatherQuery); | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters