How to use proxy to setup a sftp connection

file writer snap provides function of sftp, but I don’t see it supports proxy(socks5) in-between?
Another way I can think of is to use the script snap and python script to connect, but not sure how to do it?

Could anyone give some hint? either an alternaive snap that support proxy(socks5) for sftp or a python script to use the proxy(socks5) for sftp connection?

thank you !!