Exit codes
Exit Codes
Section titled “Exit Codes”connect follows the standard convention: 0 for success, non-zero for failure. You can rely on this behaviour when wiring the CLI into scripts or schedulers.
Successful run
$ connect move report.zip sftp://monitor01:password@10.0.0.24/incoming/[report.zip] 10.00 MiB / 10.00 MiB done$ echo $?0Failure example
$ connect move --batch report.zip sftp://monitor01:password@10.0.0.24/incoming/2025/06/24 09:09:11 ERROR Failed to open SFTP session error=dial tcp 10.0.0.24:22: i/o timeout$ echo $?1A simple shell snippet demonstrates how to branch on the exit status:
#!/bin/bashconnect move "$1" sftp://monitor01:password@10.0.0.24/incoming/if [ $? -eq 0 ]; then echo "Transfer successful"else echo "Transfer failed"fi