void ConfigureServices public (IServiceCollection Services) { services.AddMvc () AddJsonOptions. (opt => { opt.SerializerSettings.ContractResolver new new Newtonsoft.Json.Serialization.DefaultContractResolver = (); // case of the string is output as JSON }); }