JsonResult TryContext(MyData data) => new JsonResult(new { greetings = $"Hello {data.Name}" });
IResult TryContext(MyData data) => Results.Json(new { greetings = $"Hello {data.Name}" });
JsonResult TryContext([FromServices] MyData data) => new JsonResult(new { greetings = $"Hello {data.Name}" });