I want to know where the caller hung up during the call. My first thought was to pepper the code with:
<var name="hungup" expr="'got to A'" />
...
<var name="hungup" expr="'got to B'" />
Then use the "hungup" var with <catch> to know where they hung up. Unfortunately, the script keeps running when a caller hangs up, which always sets the hungup var to the very last value. So my next idea was to conditionally set it:
<if cond="_event != 'connection.disconnect.hangup'">
<var name="hungup" expr="'got to B'" />
</if>
That way, if a hangup occurred, only the appropriate var would be set. But that results in a semantic error. My guess is the _event var is only available within <catch>.
So I'm looking for other ideas that don't involved chopping my <form> into a bazillion little forms to be able to capture the point where the call ended. Is there a way to have the script abort immediately? Is there a way to conditionally test if an event has occurred outside of <catch>?
Thanks in advance.
- Bil
We've Moved! Please visit our new and improved forum over at our new portal: https://portal.plumvoice.com/hc/en-us/community/topics
Where the caller hung up
Here's my solution for the archives (can you search these?):
Instead of trying to save the location where the user hung up in a var, I instead have a "tickler" that periodically records their location in the call via <data>. It appears the script doesn't execute <data> if the caller has hung up. It's a bit chatty (many db calls per page), but it works. If there's a better solution, please let me know.
Just to be clear, this is what I'm doing:
<data name="pointA" src="tickle.lasso?tickle=pointA" namelist="mysession" />
... do stuff ...
<data name="pointB" src="tickle.lasso?tickle=pointB" namelist="mysession" />
... do stuff ...
<data name="pointC" src="tickle.lasso?tickle=pointC" namelist="mysession" />
- Bil
Instead of trying to save the location where the user hung up in a var, I instead have a "tickler" that periodically records their location in the call via <data>. It appears the script doesn't execute <data> if the caller has hung up. It's a bit chatty (many db calls per page), but it works. If there's a better solution, please let me know.
Just to be clear, this is what I'm doing:
<data name="pointA" src="tickle.lasso?tickle=pointA" namelist="mysession" />
... do stuff ...
<data name="pointB" src="tickle.lasso?tickle=pointB" namelist="mysession" />
... do stuff ...
<data name="pointC" src="tickle.lasso?tickle=pointC" namelist="mysession" />
- Bil
IVR server and your DB server are co-located on the same net
Hi,
If bandwith/speed is not an IVR issue (e.g. the IVR server and your DB server are co-located on the same network), then using a "tickler" is probably just fine.
We typically use the previous approach of setting variables at various points in the IVR call flow. However, you need to make sure that you end the IVR call somewhere in your <catch> block (or in some ensuing block). E.g.:
<catch event="connection.disconnect.hangup">
caller hung up at <value expr="hungup" />
<exit />
</catch>
The number of forms you break your IVR code into is dependent entirely on how specifically you need to know where the caller hung up.
Regards,
Plum Support
If bandwith/speed is not an IVR issue (e.g. the IVR server and your DB server are co-located on the same network), then using a "tickler" is probably just fine.
We typically use the previous approach of setting variables at various points in the IVR call flow. However, you need to make sure that you end the IVR call somewhere in your <catch> block (or in some ensuing block). E.g.:
<catch event="connection.disconnect.hangup">
caller hung up at <value expr="hungup" />
<exit />
</catch>
The number of forms you break your IVR code into is dependent entirely on how specifically you need to know where the caller hung up.
Regards,
Plum Support