Swagger crashing on my api prototype.

14 views
Skip to first unread message

Erik Pepping

unread,
Jan 6, 2018, 2:51:23 AM1/6/18
to Swagger
Hi,

i'm using asp.net core for my Web-api's.
I have swagger installed and configured. Everything works fin until I add the following prototype:

    [HttpPost]
        public IActionResult Addall([FromBody] List<Account_group> items)
        {
           
            if (items == null)
            {
                return BadRequest();
            }
            account_groupRepository.Addall(items);
            return Content("Converted");

        }

The trick is the list.
Chaging it to Account_group[] items
does not work either.

Any help would be apriciated.
Reply all
Reply to author
Forward
0 new messages