n8n-io/localtunnel ? reverse-engineered prompt

Reverse engineered prompt

Build me a small Node.js tool that lets me share my localhost with other people over a public URL.

I want to be able to run it from the command line like lt --port 8000, and have it connect to a tunnel server, give me back a public link, and keep working even if I restart my local app. It should also let me ask for a custom subdomain when possible, and point to a local host other than localhost if I need that.

Please also make it usable as a library in code, so I can create a tunnel with a port number and get the public URL back. It should support closing the tunnel cleanly, and it would be great if it could handle local HTTPS servers too. If you need to check current docs for any details, look them up online.

Are you gonna build this?

make sure you review the code using coderabbit

Try freeSponsored — opens CodeRabbit in a new tab