Hi,

 

I have the following script snippet (simplified for the purposes of this request):

 

if (session.ready()) {

       // Play a welcome message, “please wait while we try to connect your call”

       session.sayPhrase('play', 'welcome.wav');

       session.execute("set", "ringback=%(400,200,400,450);%(400,2000,400,450)");      

session.execute("bridge", "{effective_caller_id_number=XXXX,origination_caller_id_number=XXXX,ignore_early_media=true,continue_on_fail=true,hangup_after_bridge=false,originate_timeout=20}sofia/outbound/YYYY@sip.node4.co.uk");

       if (session.getVariable("bridge_hangup_cause") != 'NORMAL_CLEARING') {

             // Play a sorry we could not connect your call message

             session.sayPhrase('play', 'sorry.wav');

// Ask if they would like a callback, “press 1 if you would like a callback”

             session.sayPhrase('play', 'callback.wav');

session.flushDigits();

var callback = session.getDigits(1, '', 5000);

if (callback=='1') {

       //Do some more stuff

}           

       }

}

 

The problem I have is that if the bridge attempt times out, after playing the callback.wav request message and whilst waiting for input the session receives a random dtmf digit ‘6’ without the caller pressing any keys on the keypad.

 

Can anyone tell me where this digit comes from and how to prevent it from coming in on the original session? Or else tell me that I’ve got it all completely wrong and tell me how I can achieve the required call handling in a different way?

 

Many thanks

Andy