consider just using the fantastic [`request` library](https://github.com/mikeal/request)