ASP.NET Core MVC JSONRESULT Przykład
public IActionResult ErrorJSON()
{
//return json with 400 error code with message
return new JsonResult(new { message = "Error Messages" })
{
StatusCode = StatusCodes.Status400BadRequest // Status code here
};
}
Mohamed Sami khiari