This commit is contained in:
Fabian Affolter 2018-11-07 08:32:33 +01:00
parent 7f1251fc98
commit e97237dfc8
No known key found for this signature in database
GPG Key ID: E23CD2DD36A4397F

View File

@ -105,6 +105,7 @@ The intent `HangoutsHelp` is part of the component and return a list of all sent
## {% linkable_title Adding sentences %} ## {% linkable_title Adding sentences %}
{% raw %}
```yaml ```yaml
# The Hangouts component # The Hangouts component
hangouts: hangouts:
@ -123,11 +124,13 @@ hangouts:
intent_script: intent_script:
Ping: Ping:
speech: speech:
text: I know {% raw %}{{ states.hangouts.conversations.state }}{% endraw %} conversations text: I know {{ states.hangouts.conversations.state }} conversations
``` ```
{% endraw %}
This configuration will: This configuration will:
- Toggle the light in the given location in a specific conversation. - Toggle the light in the given location in a specific conversation.
- Return the conversations the bot know. - Return the conversations the bot know.
@ -144,6 +147,7 @@ The following configuration can handle the following sentences:
- Change the lights to the color green - Change the lights to the color green
- Change the lights to the color blue - Change the lights to the color blue
{% raw %}
```yaml ```yaml
# Example configuration.yaml entry # Example configuration.yaml entry
hangouts: hangouts:
@ -151,7 +155,7 @@ hangouts:
ColorLight: ColorLight:
sentences: sentences:
- Change the lights to [the color] {color} - Change the lights to [the color] {color}
{% raw %}
intent_script: intent_script:
ColorLight: ColorLight:
speech: speech:
@ -163,8 +167,8 @@ intent_script:
- "{% if color == 'red' %}255{% else %}0{% endif %}" - "{% if color == 'red' %}255{% else %}0{% endif %}"
- "{% if color == 'green' %}255{% else %}0{% endif %}" - "{% if color == 'green' %}255{% else %}0{% endif %}"
- "{% if color == 'blue' %}255{% else %}0{% endif %}" - "{% if color == 'blue' %}255{% else %}0{% endif %}"
{% endraw %}
``` ```
{% endraw %}
## {% linkable_title Services %} ## {% linkable_title Services %}
@ -201,6 +205,7 @@ Reconnects the hangouts bot.
The hangouts component can't detect if your ip address changes, so it can't automatic reconnect to the Google servers. This is a workaround for this problem. The hangouts component can't detect if your ip address changes, so it can't automatic reconnect to the Google servers. This is a workaround for this problem.
{% raw %}
```yaml ```yaml
sensor: sensor:
- platform: rest - platform: rest
@ -222,3 +227,4 @@ automation:
action: action:
- service: hangouts.reconnect - service: hangouts.reconnect
``` ```
{% endraw %}