public ResponseAttributes.CardAttributes CreateCardContent(Dictionary <string, string> list) { var cardAttributes = new ResponseAttributes.CardAttributes(); cardAttributes.Title = _cardTitle; if (list.Count == 0) { cardAttributes.Content = "There are no birthdays in the period that you asked for."; } if (list.ContainsKey("5")) { cardAttributes.Content += list["5"]; } foreach (var birthday in list) { if (birthday.Key == "5") { continue; } cardAttributes.Content += "\n" + " On " + birthday.Key + " is " + birthday.Value.Replace("<s>", "").Replace("</s>", ""); } return(cardAttributes); }
public AlexaResponse CalculateResponse(Request request, string brthdayString, ResponseAttributes.CardAttributes card) { AlexaResponse response = new AlexaResponse(); response.Response.OutputSpeech.Ssml = "<speak>" + brthdayString + "</speak>"; response.Response.OutputSpeech.Type = "SSML"; response.Response.Card = card; return(response); }