-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
7 changed files
with
147 additions
and
0 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
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
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
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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 |
---|---|---|
@@ -0,0 +1,72 @@ | ||
# Open Weather Map <in-version value="0.9.0" /> | ||
|
||
<preview-service name="openweathermap" /> | ||
|
||
Получает данные о погоде с сервиса [Open Weather Map](https://openweathermap.org/). | ||
|
||
<!--@include: ../_parts/extends-base-service.md--> | ||
|
||
## Широта и долгота | ||
|
||
Для получения данных о погоде необходимо указать широту и долготу. Эти данные можно получить с помощью сервиса [LatLong](https://www.latlong.net/). | ||
|
||
```yaml | ||
options: | ||
lat: 51.5085 | ||
lon: -0.1257 | ||
``` | ||
|
||
## Единицы измерения | ||
|
||
Подробнее о единицах измерения можно прочитать в [документации](https://openweathermap.org/weather-data). | ||
|
||
```yaml | ||
options: | ||
units: metric | ||
``` | ||
|
||
Поддерживаемые значения: `metric`, `imperial`, `standard` | ||
|
||
Значение по умолчанию: `metric` | ||
|
||
## API ключ | ||
|
||
API ключ можно получить в личном кабинете [Open Weather Map](https://home.openweathermap.org/api_keys). | ||
|
||
```yaml | ||
secrets: | ||
apiKey: 7ss07b6f7vb3b8329b4ff810c34dfb51 | ||
``` | ||
|
||
<!--@include: ../_parts/secrets-safety.md--> | ||
|
||
## Примеры | ||
|
||
### Базовый сервис | ||
|
||
::: code-group | ||
```yaml [config.yml] | ||
services: | ||
- type: openweathermap | ||
options: | ||
lat: 51.5085 | ||
lon: -0.1257 | ||
secrets: | ||
apiKey: 7ss07b6f7vb3b8329b4ff810c34dfb51 | ||
``` | ||
::: | ||
|
||
### Имперская система | ||
|
||
::: code-group | ||
```yaml [config.yml] | ||
services: | ||
- type: openweathermap | ||
options: | ||
lat: 51.5085 | ||
lon: -0.1257 | ||
units: imperial | ||
secrets: | ||
apiKey: 7ss07b6f7vb3b8329b4ff810c34dfb51 | ||
``` | ||
::: |
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 |
---|---|---|
@@ -0,0 +1,72 @@ | ||
# Open Weather Map <in-version value="0.9.0" /> | ||
|
||
<preview-service name="openweathermap" /> | ||
|
||
Weather data is received from [Open Weather Map](https://openweathermap.org/). | ||
|
||
<!--@include: ../_parts/extends-base-service.md--> | ||
|
||
## Latitude and longitude | ||
|
||
For weather data, you need to specify the latitude and longitude. This data can be obtained using the [LatLong](https://www.latlong.net/) service. | ||
|
||
```yaml | ||
options: | ||
lat: 51.5085 | ||
lon: -0.1257 | ||
``` | ||
|
||
## Units | ||
|
||
Read more about units of measurement in the [documentation](https://openweathermap.org/weather-data). | ||
|
||
```yaml | ||
options: | ||
units: metric | ||
``` | ||
|
||
Values: `metric`, `imperial`, `standard` | ||
|
||
Default: `metric` | ||
|
||
## API key | ||
|
||
API key can be obtained in the personal account of [Open Weather Map](https://home.openweathermap.org/api_keys). | ||
|
||
```yaml | ||
secrets: | ||
apiKey: 7ss07b6f7vb3b8329b4ff810c34dfb51 | ||
``` | ||
|
||
<!--@include: ../_parts/secrets-safety.md--> | ||
|
||
## Examples | ||
|
||
### Base service | ||
|
||
::: code-group | ||
```yaml [config.yml] | ||
services: | ||
- type: openweathermap | ||
options: | ||
lat: 51.5085 | ||
lon: -0.1257 | ||
secrets: | ||
apiKey: 7ss07b6f7vb3b8329b4ff810c34dfb51 | ||
``` | ||
::: | ||
|
||
### Imperial units | ||
|
||
::: code-group | ||
```yaml [config.yml] | ||
services: | ||
- type: openweathermap | ||
options: | ||
lat: 51.5085 | ||
lon: -0.1257 | ||
units: imperial | ||
secrets: | ||
apiKey: 7ss07b6f7vb3b8329b4ff810c34dfb51 | ||
``` | ||
::: |