HttpRequest refactoring