using System; using System.Collections.Generic; using System.Linq; using System.Net; using System.Net.Http; using System.Text; using System.Web.Http; namespace MP_MON.Controllers { public class DbTaskController : ApiController { #region Public Methods // DELETE: api/DbTask/5 public void Delete(int id) { } // GET: api/DbTask public IEnumerable Get() { return new string[] { "Refresh", "value2" }; } // GET: api/DbTask/5 public string Get(int id) { return $"DbMaint requested: {id} - {DateTime.Now}"; } // POST: api/DbTask public string Post([FromBody] List names) { string answ = ""; foreach (var item in names) { answ += $"{item} | "; } return answ; } // PUT: api/DbTask/5 public void Put(int id, [FromBody] string value) { } #endregion Public Methods } }