Net
Summary
Functions
Section titled “Functions”urlEncode
Section titled “urlEncode”Net . urlEncode ( url , binary ) -> string
Encodes the given string using URL encoding.
request
Section titled “request”Net . request ( config ) -> FetchResponse
Sends an HTTP request using the given url and / or parameters, and returns a dictionary that describes the response received.
Only throws an error if a miscellaneous network or I/O error occurs, never for unsuccessful status codes.
Parameters
| config: string | FetchParams |
Returns
| FetchResponse |
tcpSocket
Section titled “tcpSocket”Net . tcpSocket ( url ) -> WebSocket
Connects to a TCP web socket at the given URL.
Throws an error if the server at the given URL does not support web sockets, or if a miscellaneous network or I/O error occurs.
udpSocket
Section titled “udpSocket”Net . udpSocket ( host , port ) -> UdpSocket
Connects to a UDP web socket at the given URL.
Throws an error if the server at the given URL does not support web sockets, or if a miscellaneous network or I/O error occurs.