This commit is contained in:
2025-02-12 11:19:36 +01:00
parent 26b6b4cd98
commit 761536274b
3 changed files with 20 additions and 2 deletions

View File

@@ -34,8 +34,7 @@ def sendmessage(target, message):
responsejson = ws.recv() # Receive response
response = json.loads(responsejson)
print(response)
chatitems = response['resp']['chatitems']
for chatitem in chatitems:
for chatitem in response['chatitems']:
print(chatitem)
# print("Message %s sent over websocket to %s" % (chatitem['content'], target))
# ws.close() # Close WebSocket connection