Files
the-nexus/send_ws.py
Alexander Whitestone 057c751c57
Some checks failed
CI / validate (pull_request) Failing after 5s
feat: first light test report and ws gateway fixes
2026-03-25 14:37:35 -04:00

12 lines
311 B
Python

import asyncio
import websockets
import json
import sys
async def send_msg(msg):
async with websockets.connect('ws://localhost:8765') as ws:
await ws.send(json.dumps({'type':'chat_message','content':msg,'username':'antigravity'}))
if __name__ == "__main__":
asyncio.run(send_msg(sys.argv[1]))