I'm using httpi library.
Usually in http libraries we can set a port for http connection, but in httpi I can't.
How to assign port for HTTPI connection?
Normally you'd include the port number in the URL, like this:
request = HTTPI::Request.new("http://example.com:1234/")