Make http_get higher order to encapsulate the agent