Image upload + major refactor of http client