{"action":"opened","issue":{"url":"https://api.github.com/repos/go-resty/resty/issues/21","labels_url":"https://api.github.com/repos/go-resty/resty/issues/21/labels{/name}","comments_url":"https://api.github.com/repos/go-resty/resty/issues/21/comments","events_url":"https://api.github.com/repos/go-resty/resty/issues/21/events","html_url":"https://github.com/go-resty/resty/issues/21","id":127020607,"number":21,"title":"Allow file uploads with io.Reader and a name","user":{"login":"mrd0ll4r","id":15063379,"avatar_url":"https://avatars.githubusercontent.com/u/15063379?v=3","gravatar_id":"","url":"https://api.github.com/users/mrd0ll4r","html_url":"https://github.com/mrd0ll4r","followers_url":"https://api.github.com/users/mrd0ll4r/followers","following_url":"https://api.github.com/users/mrd0ll4r/following{/other_user}","gists_url":"https://api.github.com/users/mrd0ll4r/gists{/gist_id}","starred_url":"https://api.github.com/users/mrd0ll4r/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mrd0ll4r/subscriptions","organizations_url":"https://api.github.com/users/mrd0ll4r/orgs","repos_url":"https://api.github.com/users/mrd0ll4r/repos","events_url":"https://api.github.com/users/mrd0ll4r/events{/privacy}","received_events_url":"https://api.github.com/users/mrd0ll4r/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2016-01-16T12:11:53Z","updated_at":"2016-01-16T12:11:53Z","closed_at":null,"body":"Hey, first of all: thanks for this wonderful library! I've been using it for quite some time now, and it works like a charm.\r\n\r\nThere's one thing I'm missing, though: being able to upload files (as multipart) using an `io.Reader` and a name for the file. The scenario is, for example, something like this:\r\n\r\nI have a database of many small image files which are stored as BLOBs along with their original file name (or file type). I want to upload some of them to some endpoints, I know the server will check the extension of the file name to determine if I really send images. It'd be great if I could directly \"pipe\" the image from the DB along with its name (or a made up name) into resty. It's a pain to create temporary files for every upload I need (imagine the DB running on another machine)...\r\n\r\nOther scenarios might include receiving files over the network - I don't want to store a copy locally, I just want to pipe them through.\r\n\r\nWould it be possible to get that? I'm thinking of something like\r\n\r\n    func (r *Request) SetFileReader(param, fileName string, reader io.Reader) *Request\r\n\r\nWhat do you think?"}}