Updated request class to support an optional proxy