Using interfaces to represent the http request and response