mirror of
https://github.com/home-assistant/home-assistant.io.git
synced 2025-07-15 05:16:49 +00:00
Vasttrafik sensor configuration variable style (#6414)
* Style for configuration variables description Change to new style for configuration variables description (#6385). * Updated configuration example * Corrected from to be required variable. * Removed quote of decsription text. * Corrected incorrect linebreak. * Minor change * Change to list
This commit is contained in:
parent
871aafad10
commit
a2ba9f46b3
@ -23,22 +23,48 @@ Add the data to your `configuration.yaml` file as shown in the example:
|
|||||||
# Example configuration.yaml entry
|
# Example configuration.yaml entry
|
||||||
sensor:
|
sensor:
|
||||||
- platform: vasttrafik
|
- platform: vasttrafik
|
||||||
key: XXXXXXXXXXXXXXXXXXX
|
key: YOUR_API_KEY
|
||||||
secret: YYYYYYYYYYYYYYYYY
|
secret: YOUR_API_SECRET
|
||||||
departures:
|
departures:
|
||||||
- from: Musikvägen
|
- from: Musikvägen
|
||||||
```
|
```
|
||||||
|
|
||||||
Configuration variables:
|
{% configuration %}
|
||||||
|
key:
|
||||||
- **key** (*Required*): The API key to access your Västtrafik account.
|
description: The API key to access your Västtrafik account.
|
||||||
- **secret** (*Required*): The API secret to access your Västtrafik account.
|
required: true
|
||||||
- **departures** array (*Required*): List of travel routes.
|
type: string
|
||||||
- **name** (*Optional*): Name of the route.
|
secret:
|
||||||
- **from** (*Required*): The start station.
|
description: The API secret to access your Västtrafik account.
|
||||||
- **heading** (*Optional*): Direction of the traveling.
|
required: true
|
||||||
- **lines** (*Optional*): Only consider these lines.
|
type: string
|
||||||
- **delay** (*Optional*): Delay in minutes. Defaults to 0.
|
departures:
|
||||||
|
description: List of travel routes.
|
||||||
|
required: true
|
||||||
|
type: list
|
||||||
|
keys:
|
||||||
|
name:
|
||||||
|
description: Name of the route.
|
||||||
|
required: false
|
||||||
|
type: string
|
||||||
|
from:
|
||||||
|
description: The start station.
|
||||||
|
required: true
|
||||||
|
type: string
|
||||||
|
heading:
|
||||||
|
description: Direction of the traveling.
|
||||||
|
required: false
|
||||||
|
type: string
|
||||||
|
lines:
|
||||||
|
description: Only consider these lines.
|
||||||
|
required: false
|
||||||
|
type: [list, string]
|
||||||
|
delay:
|
||||||
|
description: Delay in minutes.
|
||||||
|
required: false
|
||||||
|
type: string
|
||||||
|
default: 0
|
||||||
|
{% endconfiguration %}
|
||||||
|
|
||||||
The data are coming from [Västtrafik](https://vasttrafik.se/).
|
The data are coming from [Västtrafik](https://vasttrafik.se/).
|
||||||
|
|
||||||
@ -48,8 +74,8 @@ A full configuration example could look like this:
|
|||||||
# Example configuration.yaml entry
|
# Example configuration.yaml entry
|
||||||
sensor:
|
sensor:
|
||||||
- platform: vasttrafik
|
- platform: vasttrafik
|
||||||
key: XXXXXXXXXXXXXXXXXXX
|
key: YOUR_API_KEY
|
||||||
secret: YYYYYYYYYYYYYYYYY
|
secret: YOUR_API_SECRET
|
||||||
departures:
|
departures:
|
||||||
- name: Mot järntorget
|
- name: Mot järntorget
|
||||||
from: Musikvägen
|
from: Musikvägen
|
||||||
|
Loading…
x
Reference in New Issue
Block a user