Use io.Copy(r, out) here to avoid duplicating out, this is important for large response bodies.