[Route("api/[controller]")] [ApiController] public class ValuesController : ControllerBase { // GET api/values [HttpGet] public ActionResult<IEnumerable<string>> Get() { return new string[] { "value1", "value2" }; } <pre>[HttpPost] [Route("post")] public async Task<string> post() { using (StreamReader reader = new StreamReader(Request.Body, Encoding.UTF8)) { string input = await reader.ReadToEndAsync(); Number_2Text objConvert = new Number_2Text(); string result = objConvert.ConvertText(input); return result; } }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)