using System; using System.Collections.Generic; using System.Linq; using System.Web; using Newtonsoft.Json; namespace ResfullApi.Models { [Serializable] //{"fromDate":"01/02/2020","toDate":"20/02/2020"} public class newsWebLotteryRequest { [JsonProperty("fromDate")] public string fromDate { get; set; } [JsonProperty("toDate")] public string toDate { get; set; } public override string ToString() { return JsonConvert.SerializeObject(this); } } }