RestfulService improvements

From my recent work having to integrate quite a few APIs and some OAuth requests too, I've noticed the RestfulService is in need of some TLC.

Currently response headers are never passed to the response object, only the URL us used for caching (so method or other data that can easily change the responses are ignored) and there is no way to override the current User Agent.

I've added some code to get a full response from the cURL requests so that headers can be plucked out, which is desperately needed for the class to be useful for most modern APIs.