Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
JarbasAl authored Jan 8, 2025
1 parent a8b418e commit 632c178
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,11 @@ client.connect() # establish a secure end-to-end encrypted connection
import threading
from ovos_bus_client.message import Message
from hivemind_bus_client.message import HiveMessage, HiveMessageType
from hivemind_bus_client.http_client import HiveMindHTTPClient
from hivemind_bus_client.client import HiveMessageBusClient

# not passing key etc so it uses identity file
client = HiveMindHTTPClient(host="http://localhost", port=5679)
client = HiveMessageBusClient(host="ws://localhost", port=5678)
client.connect() # establish a secure end-to-end encrypted connection

# to handle agent responses, use client.on_mycroft("event", handler)
answered = threading.Event()
Expand Down Expand Up @@ -87,6 +88,7 @@ class BinaryDataHandler(BinaryDataCallbacks):
# not passing key etc so it uses identity file
client = HiveMindHTTPClient(host="http://localhost", port=5679,
bin_callbacks=BinaryDataHandler())
client.connect()

# send HiveMessages as usual
client.emit(HiveMessage(HiveMessageType.BUS,
Expand Down Expand Up @@ -175,4 +177,4 @@ Options:
--payload TEXT ovos message json payload
--help Show this message and exit.

```
```

0 comments on commit 632c178

Please sign in to comment.