UNPKG

api-websocket-bridge

Version:

API WebSocket Bridge is a Node.js application that provides a WebSocket server for real-time communication. It allows clients to connect and exchange data using the WebSocket protocol

17 lines (13 loc) 471 B
const WebSocketBridge = require('./bridge'); // Load the configuration from config.json const config = require('/app/config/config.json'); // Create an instance of WebSocketDriver const driver = new WebSocketBridge(config); // Start the WebSocket Bridge driver.start() .then(() => { driver.log('WebSocket Bridge is running', 'info'); }) .catch((error) => { driver.log(`Failed to start WebSocket Bridge: ${error.message}`, 'error'); });