websocat

Command-line client for WebSocket connections and communication

brewmacoslinux
Try with needOr install directly
Source

About

Command-line client for WebSockets

Commands

websocat

Examples

Connect to a WebSocket server and send messages interactively$ websocat ws://echo.websocket.org
Send a message to a WebSocket server and exit$ echo 'Hello' | websocat ws://echo.websocket.org
Act as a WebSocket server listening on port 8080$ websocat -s 127.0.0.1:8080