in reply to Problems creating a proper HTTP::Request object for sending files

According the manual page of HTTP::Request, HTTP::Request -> new takes up to four arguments. If there is a third argument, it should be a reference to an HTTP::Headers object.

Grepping through the source reveals that the error message is generated by HTTP::Message, while it's testing if a certain argument is indeed a reference...

I suggest consulting the documentation of HTTP::Request and sticking to its API.

Abigail