AWS Connect + AWS Lex Send Multiple Messages

0

We are using AWSLex with AWS Connect. Our Api creates interactive messages (https://docs.aws.amazon.com/connect/latest/adminguide/interactive-messages.html) and sends it to the chat. Is there any way to send multiple messages via api? Sometimes we want to display some explanation and in next message we want to ask question with options. Is there anyway to do this?

Thank you

bbolek
已提問 2 年前檢視次數 549 次
3 個答案
0

You can do this using message groups: https://docs.aws.amazon.com/lexv2/latest/dg/API_ResponseSpecification.html

You can have multiple groups of messages (up to 2 variations per group), and Lex will return one message per group.

AWS
已回答 2 年前
0

Hello, Actually that is not what I am asking for. I want to send 2 messages together, For example Message 1: "Congratulations your appointment is created!" Message 2: "Your appointment details are...."

I want to send these both to the client in this order.

PS: I am using Lexv1.

Thank you

bbolek
已回答 2 年前
0

In Lex v2 JSON for Messages is a list, not a key pair as it was in v1. So, if you want to send multiple messages, try Lex v2 and enter into messages list as many messages as you need.

{ "sessionState": { "dialogAction": { "type": "Close" }, "intent": { "name": "Hello", "state": "Fulfilled" } }, "messages": [ { "contentType": "PlainText", "content": "Hi" }, { "contentType": "PlainText", "content": "How are you?" }, { "contentType": "PlainText", "content": "How may I help?" } ] }

已回答 2 年前

您尚未登入。 登入 去張貼答案。

一個好的回答可以清楚地回答問題並提供建設性的意見回饋,同時有助於提問者的專業成長。

回答問題指南