Build Node.js 22 WebSocket servers with ws library, room management, binary frames, heartbeat, and authentication.
Act as a Node.js 22 WebSocket expert. Build WS server for [REALTIME_FEATURE]. Implement room management for [ROOM_LOGIC]. Handle binary frames for [BINARY_DATA]. Add heartbeat ping/pong with [HEARTBEAT_INTERVAL]. Authenticate on upgrade with [AUTH_VALIDATION]. Scale with [PUBSUB_BACKEND] for multi-process.
Free to copy and use. Compatible with Claude 4 Opus, GPT-5, Gemini 2.0 Flash.
Describe realtime feature, room logic, binary data types, heartbeat interval, auth validation method, and pub/sub backend.
Initial release
Sign in and download this prompt to leave a review.