Skip to content

TCP Server Node

Web/TCP

TCP Server

Binds a TCP server. Typed lifecycle events are exposed as pins; incoming data chunks are delivered to the referenced on-message handler.

tcp_serverwebLong running
Inputs2
Outputs7
Security exposure4/10
Packageweb

Ratings

Scores range from 0 to 10. Higher values mean more impact, exposure, or operational weight.

SecurityAttack surface and exposure impact.
4/10Medium
PrivacyPotential sensitivity of processed data.
3/10High
PerformanceRuntime or resource pressure.
2/10High
GovernancePolicy, audit, or compliance impact.
5/10Medium
ReliabilityOperational stability considerations.
3/10High
CostExternal or compute cost impact.
0/10High

Input Pins

2

Execute

Execution
exec_in

Start the TCP server

Config

Struct
config

TCP server configuration

TcpListenConfigTcpListenConfig5 fields
hoststringrequired
portinteger:uint16required
format uint16min 0max 65535
timeout_secondsinteger:uint64
format uint64default 0min 0
max_connectionsinteger:uint32
format uint32default 128min 0
tlsTlsConfig
default {"secure":false,"certificate":null,"ca_...
secureboolean
default false
certificateanyOf (2)
default null
variant 1TlsCertificatevariant
certificate_pemstringrequired
private_key_pemstringrequired
variant 2nullvariant
ca_certificate_pemstring | null
default null
server_namestring | null
default null
accept_invalid_certificatesboolean
default false
Schema enforced

Output Pins

7

On Listening

Execution
on_listening

Fires when the server is bound and ready

Local Addr

String
local_addr

Bound local socket address

On Connect

Execution
on_connect

Fires for each accepted TCP client

Session

Struct
session

Accepted TCP client session

TcpSessionTcpSession2 fields
ref_idstringrequired
remote_addrstringrequired
Schema enforced

Remote Addr

String
remote_addr

Remote client socket address

On Close

Execution
on_close

Fires when the server stops

Error

Execution
exec_error

Fires if the server fails to bind

Node Info

Internal name
tcp_server
Category
Web/TCP
Function references
Can reference functions