public async Task <IActionResult> CreateSentence([FromBody] SentenceDto sentenceDto) { var sentence = _mapper.Map <Sentence>(sentenceDto); sentence = await _sentenceService.CreateSentenceAsync(sentence); if (sentence == null) { return(BadRequest()); } sentenceDto = _mapper.Map <SentenceDto>(sentence); return(Ok(sentenceDto)); }