Pass (Send) JSON data to Web API in ASP.Net MVC

Last Reply 26 days ago By SUJAYS

Posted 26 days ago

As I have created WebAPI in MVC.

Is it possible to pass data as json ?


Posted 26 days ago

Adding this code in Global.asax

GlobalConfiguration.Configuration.Formatters.XmlFormatter.SupportedMediaTypes.Clear();

As I have got result in XML, this line of coding convert XML data to JSON format