I want my chatbot to review the session parameters it knows so far. However, some are optional. So while I can state most of them simply in the entry dialogue, some of them I would like to state only if they have been filled in already. After it has done so, I want to move on to the next page. My plan of doing this is as follows:
$session.params.something
and $session.params.something-else
".$session.params.optional
, fulfillment: Agent says: "I also know that $session.params.something-optional
."true
. -> goes to next page.However, I don't really know how I can tell the parameter to check for a previously filled in session parameter. Simply naming the parameter after the session parameter does not do the trick.
I don't know if I fully grasped your question: this is what I understood.
If this is the case I would probably come up with two solutions:
OPTION 1 Let's say the page is named Recap. As an entry dialogue to Recap you can add what you wrote in the first bullet: "So far I know that $session.params.something and $session.params.something-else".
Then I'd add two separate conditional routes:
The first checks whether the optional parameters have all been filled. If some optional params have been filled you can add a fulfillment here stating this optionals before going to the next page.
The second just goes to the next page, because the $session.params.optional will be null: pay attention to put them in this order!
OPTION 2 A second option could be to build your own conditional response: so go to Entry dialogue, then add dialogue option, then conditional response. This block allows you to write your own conditions, for example:
if $session.params.optional != null
So far I know that $session.params.something and $session.params.something-else. I also know that $session.params.optional
else
So far I know that $session.params.something and $session.params.something-else.
endif