🦀 ClawHub
S2G - General Purpose Workflow Engine
by @helmutsreinis
Connect to S2G (s2g.run) visual workflow automation platform over WebSocket. Execute workflow nodes as tools — password generators, hash functions, date math...
💡 Examples
1. Install the bridge
# Copy bridge script to workspace
cp scripts/s2g-bridge.js ~/.openclaw/workspace/s2g-bridge.js
npm install ws
2. Get the OpenClaw node ID
In the S2G designer at s2g.run, click the OpenClaw node → copy the Node ID (UUID) from properties.
3. Start the bridge
# Connect to public S2G
node s2g-bridge.js --s2g wss://s2g.run --node-id YOUR_NODE_UUID [--port 18792] [--secret SECRET]Or with environment variables:
S2G_WS_HOST=wss://s2g.run S2G_NODE_ID=abc-123 node s2g-bridge.jsSelf-hosted S2G instance (development)
node s2g-bridge.js --s2g ws://YOUR_HOST:5184 --node-id YOUR_NODE_UUID
4. Verify
curl http://localhost:18792/health
{"healthy":true,"uptime":42.5}
curl http://localhost:18792/nodes
Lists all discovered nodes with names, types, and IDs
⚙️ Configuration
1. S2G account at s2g.run (or self-hosted instance)
2. A workflow with an OpenClaw node and tool nodes connected to it
3. Workflow running — the WebSocket endpoint only accepts connections while the workflow is active
4. Node.js with ws module: npm install ws
📋 Tips & Best Practices
_TriggeredTags in output indicates which connection tag fired (success/error).TERMINAL
clawhub install s2g-workflow-engine