proposals
proposals copied to clipboard
TCP (and UDP) sockets
Plugin Request
Name: Sockets
Package: @capacitor-community/sockets
Platform(s)
This should work on all platforms (iOS and Android).
Existing Solutions
I have used this Cordova plugin for TCP sockets and this plugin for UDP sockets.
Description
Sometimes it may not be possible to use Websockets or HTTP requests to approach a certain API, and regular TCP/UDP sockets may be needed to accomplish these goals. For example, we might want to communicate with a server that implements a stream-based API over a pure binary TCP connection.
Similarly, you might need regular UDP sockets to perform packet broadcasts and receive broadcasted packets.