Skip to content

Commit

Permalink
Merge pull request #181 from dickwolff/main
Browse files Browse the repository at this point in the history
Added OpenWeatherMap service
  • Loading branch information
bastienwirtz authored Sep 13, 2021
2 parents 55c3ea4 + 92d5b8d commit fd18715
Show file tree
Hide file tree
Showing 4 changed files with 12,812 additions and 1 deletion.
5 changes: 4 additions & 1 deletion docs/configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ Title, icons, links, colors, and services can be configured in the `config.yml`
# Homepage configuration
# See https://fontawesome.com/icons for icons options

# Optional: Use external configuration file.
# Optional: Use external configuration file.
# Using this will ignore remaining config in this file
# externalConfig: https://example.com/server-luci/config.yaml

Expand Down Expand Up @@ -136,6 +136,9 @@ services:
# background: red # optional color for card to set color directly without custom stylesheet
```


View [Custom Services](customservices.md) for details about all available custom services (like PiHole) and how to configure them.

If you choose to fetch message information from an endpoint, the output format should be as follows (or you can [custom map fields as shown in tips-and-tricks](./tips-and-tricks.md#mapping-fields)):

```json
Expand Down
22 changes: 22 additions & 0 deletions docs/customservices.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,28 @@ The following configuration is available for the PiHole service.
type: "PiHole"
```


## OpenWeatherMap

Using the OpenWeatherMap service you can display weather information about a given location.

The following configuration is available for the OpenWeatherMap service

```
items:
- name: "Weather"
location: "Amsterdam" # your location.
locationId: "2759794" # OpenWeatherMap city ID.
apiKey: "<---insert-api-key-here--->" # insert your own API key here. Request one from https://openweathermap.org/api.
units: "metric" # units to display temperature. Can be one of: metric, imperial, kelvin. Defaults to kelvin.
background: "square" # choose which type of background you want behind the image. Can be one of: square, cicle, none. Defaults to none.
type: "OpenWeather"
```

**Remarks:**
If for some reason your city can't be found by entering the name in the `location` property, you could also try to configure the OWM city ID in the `locationId` property. To retrieve your specific City ID, go to the [OWM website](https://openweathermap.org), search for your city and retrieve the ID from the URL (for example, the City ID of Amsterdam is 2759794).


## Medusa

This service displays News (grey), Warning (orange) or Error (red) notifications bubbles from the Medusa application.
Expand Down
Loading

0 comments on commit fd18715

Please sign in to comment.