New to Kestra?
Use blueprints to kickstart your first workflows.
Send raw TCP payloads to any host and port with Kestra. Validate open ports, smoke-test infrastructure, and orchestrate socket-level health checks.
Send a raw TCP payload from Kestra to any host and port, with a pre-flight reachability probe and a fail-fast assertion on the send output. This blueprint covers the network validation, infrastructure smoke testing, and socket-level health check scenarios where HTTP is not available or not appropriate, including echo servers, legacy daemons, internal appliances, and custom socket listeners.
check_port runs io.kestra.plugin.scripts.shell.Commands and uses the bash /dev/tcp pseudo-device to verify that {{ inputs.host }}:{{ inputs.port }} accepts a TCP connection before any payload is sent.log_inputs uses io.kestra.plugin.core.log.Log to record the destination and message, giving you a durable audit trail in execution logs.send_tcp uses io.kestra.plugin.fs.tcp.Send to open a TCP socket to host:port and transmit payload bytes.assert_send uses io.kestra.plugin.core.execution.Assert with the condition {{ outputs.send_tcp is not null }} so the execution fails immediately if the send task did not produce an output map.nc and telnet checks into versioned, auditable workflows.A bash one-liner or a cron-managed shell script can open a socket, but it cannot give you retries, alerting, lineage, and audit trails out of the box. With Kestra you get declarative YAML, event triggers (webhooks, message queues, schedules), automatic retries on transient socket errors, per-task logs, and a single place to chain TCP checks with downstream actions like Slack alerts, ticket creation, or deployment rollbacks. The TCP socket itself has no scheduler, no concurrency control, and no notion of an execution: Kestra supplies all of that.
plugin-fs plugin available (bundled by default).host:port.docker run --rm -p 9090:9090 alpine/socat -v tcp-listen:9090,reuseaddr,fork system:'cat'.This flow uses no secrets. TCP Send does not authenticate, so if you need TLS, mutual auth, or credentials, terminate them upstream (for example with a sidecar proxy) or switch to a protocol-aware plugin.
company.team.host, port, and payload inputs to point at your TCP service (defaults target 127.0.0.1:9090 with Hello from Kestra).check_port succeeds, send_tcp returns metadata, and assert_send passes.send_tcp in a retry policy on io.kestra.core.models.tasks.retries.Constant to tolerate flaky networks.io.kestra.plugin.core.flow.ForEach and a list of targets.payload for a binary or protocol-specific frame to talk to bespoke TCP daemons.