- Newest
- Most votes
- Most comments
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.
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
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?" } ] }
Relevant content
- asked 2 years ago
- AWS OFFICIALUpdated 2 years ago
- AWS OFFICIALUpdated 9 months ago
- AWS OFFICIALUpdated 2 years ago