Return json or xml response of request header is json/xml