Jump to content

Component: WebSocketClient ( Comms)

From Flowcode Help
Revision as of 12:08, 2 October 2026 by Wiki bot (talk | contribs) (Created page with "{| style="width:50%" |- | width="20%" style="color:gray;" | Author | MatrixTSL |- | width="20%" style="color:gray;" | Version | 1.0 |- | width="20%" style="color:gray;" | Category | Comms |} ==WebSocketClient component== A websocket client component which can be used to create a 2-way communications channel with a websocket server. ==Detailed description== ''No detailed description exists yet for this component'' ==Examples== ''<span style="c...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Author MatrixTSL
Version 1.0
Category Comms


WebSocketClient component

A websocket client component which can be used to create a 2-way communications channel with a websocket server.

Detailed description

No detailed description exists yet for this component

Examples

No additional examples

Macro reference

Connect

Connect
Connects to the WebSocket server (returns false if already connected) 
- BOOL Return


Disconnect

Disconnect
Disconnect from the WebSocket server 
- VOID Return


SendString

SendString
Sends a string to the connected WebSocket server (returns false in the client is not connected) 
- STRING Data
The string data to send 
- BOOL Return


Property reference

Properties
Url
The url of a WebSocket server, e.g. ws://127.0.0.1:8080/ 
Debug
Determines if additional logging information is sent to the JavaScript console 
Callbacks
OnOpen
Called when the connection to a WebSocket server is successfully established  
OnClose
Called when the WebSocket connection has been lost  
OnReceiveString
Called when a string-based WebSocket message is received 
OnReceiveArray
Called when an array-based WebSocket message is received 
OnError
Called when a WebSocket error occurs  

Component Source Code

Please click here to download the component source project: FC_Comp_Source_WEBEXP_Websocket.fcsx

Please click here to view the component source code (Beta): FC_Comp_Source_WEBEXP_Websocket.fcsx