Add a __getstate__ method to allow easier serialization of the reponse for caching in app.