For reference, here is the flow in question:
"Get Customer Input" (Lex) -> "Set Contact Attribute" -> "Play Prompt"
After the call to Lex, I set a contact attribute using "Save Text As Attribute" option:
DestinationKey Value ProductType $.Lex.SessionAttributes.ProductType
Then, in the "Play Prompt" I can't reference the set attribute. I use "Text to speech (Ad hoc)" and have tried the following syntax:
The interesting thing is, if I add a "Check contact attributes" after the "Set contact attributes" it does match on "User Defined" attribute "ProductType".
How may I reference the attribute?
We recommend using the contact ID to search for recordings. Even though many call recordings for specific contact IDs may be named with the contact ID prefix itself (for example, 123456-aaaa-bbbb-3223-2323234. wav), there is no guarantee that the contact IDs and name of the contact recording file always match.
A contact attribute represents this data as a key-value pair. You might think of it as a field name together with the data entered into that field. For example, here are a couple of key-value pairs for the customer name: Key. Value.
Amazon Connect stores the following Personally Identifiable Information (PII) data related to your customers: The customer's phone number: ANI for inbound calls, and DNIS for outbound calls or transfers.
Contact trace records (CTR) captures transactional metrics such as hold time, wait time, and agent interaction time in JavaScript Object Notation (JSON) format. Amazon Connect aggregates CTR data to create metrics reporting. Data retention for CTR is 24 months upon contact initiation.
Try $.Attributes.ProductType
$.Attributes is how you get to contact attributes set with Set Contact Attribute. $.External is to get to the values returned by the last Lambda execution. $.Lex for the last Lex execution.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With