skip to Main Content

How to pass JSON array in body of web api c#

I am trying to capture a JSON array of string from POST Request in web api. [HttpPost] [Route("")] public async Task<IHttpActionResult> CancelItems([FromBody] List<string> items) { //codes } But I am getting null in items. Post Body: { "items":[ "1034908029943809497", "1034908029943809494"…

VIEW QUESTION
Back To Top
Search