public IActionResult ReadText(TextDto dto) { var service = ImplementationFactory.Create(_services, dto.Implementation); var numberOfWords = service.Read(dto.Text); return(Ok("There are " + numberOfWords + " words in the text")); }