mirror of
https://github.com/home-assistant/home-assistant.io.git
synced 2025-07-22 08:46:51 +00:00
Not longer use the term 'API password'
This commit is contained in:
parent
59d59f2def
commit
9dec850d60
@ -16,16 +16,10 @@ The `mosquitto` broker package ships commandline tools (often as `*-clients` pac
|
||||
$ mosquitto_pub -h 127.0.0.1 -t home-assistant/switch/1/on -m "Switch is ON"
|
||||
```
|
||||
|
||||
If you are using the embedded MQTT broker, the command looks a little different because you need to add the MQTT protocol version.
|
||||
If you are using the embedded MQTT broker, the command looks a little different because you need to add the MQTT protocol version and your [broker credentials](/docs/mqtt/broker#embedded-broker).
|
||||
|
||||
```bash
|
||||
$ mosquitto_pub -V mqttv311 -t "hello" -m world
|
||||
```
|
||||
|
||||
or if you are using a API password:
|
||||
|
||||
```bash
|
||||
$ mosquitto_pub -V mqttv311 -u homeassistant -P <your api password> -t "hello" -m world
|
||||
$ mosquitto_pub -V mqttv311 -u homeassistant -P <broker password> -t "hello" -m world
|
||||
```
|
||||
|
||||
Another way to send MQTT messages by hand is to use the "Developer Tools" in the Frontend. Choose "Call Service" and then `mqtt/mqtt_send` under "Available Services". Enter something similar to the example below into the "Service Data" field.
|
||||
@ -52,8 +46,6 @@ $ mosquitto_sub -h 127.0.0.1 -v -t "home-assistant/#"
|
||||
For the embedded MQTT broker the command looks like:
|
||||
|
||||
```bash
|
||||
$ mosquitto_sub -v -V mqttv311 -t "#"
|
||||
$ mosquitto_sub -v -V mqttv311 -u homeassistant -P <broker password> -t "#"
|
||||
```
|
||||
|
||||
Add the username `homeassistant` and your API password if needed.
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user