private static ResponseBody CreateListResponseBody(SkillRequest request, SkillTypen typ, List <ListItem> listItems, IOutputSpeech speech, ICard card, string title, bool?shouldEndSession) { var hasDisplay = request.HasDisplay(); var body = new ResponseBody { OutputSpeech = speech, Card = card, Reprompt = CreateReprompt(), ShouldEndSession = shouldEndSession }; if (hasDisplay) { body.Directives = CreateListDirectives(typ, listItems, title); } return(body); }
private static ResponseBody CreateBodyResponseBody(SkillRequest request, BodyTemplate2 template, IOutputSpeech speech, ICard card, bool?shouldEndSession) { var hasDisplay = request.HasDisplay(); var body = new ResponseBody { OutputSpeech = speech, Card = card, Reprompt = CreateReprompt(), ShouldEndSession = shouldEndSession }; if (hasDisplay) { body.Directives = CreateBodyDirectives(template); } return(body); }